{"id":16489601,"url":"https://github.com/alvinwan/squeezedetmx","last_synced_at":"2025-07-05T01:06:30.619Z","repository":{"id":89467789,"uuid":"91506226","full_name":"alvinwan/squeezeDetMX","owner":"alvinwan","description":"squeezeDet for object detection port to MXNet","archived":false,"fork":false,"pushed_at":"2017-06-22T20:02:12.000Z","size":349,"stargazers_count":19,"open_issues_count":1,"forks_count":4,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-17T10:28:24.710Z","etag":null,"topics":["computer-vision","deep-learning","kitti-dataset","mobile","object-detection","squeezedet"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-2-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/alvinwan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2017-05-16T21:29:40.000Z","updated_at":"2021-07-17T10:21:07.000Z","dependencies_parsed_at":"2023-03-08T21:30:14.342Z","dependency_job_id":null,"html_url":"https://github.com/alvinwan/squeezeDetMX","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/alvinwan/squeezeDetMX","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alvinwan%2FsqueezeDetMX","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alvinwan%2FsqueezeDetMX/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alvinwan%2FsqueezeDetMX/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alvinwan%2FsqueezeDetMX/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alvinwan","download_url":"https://codeload.github.com/alvinwan/squeezeDetMX/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alvinwan%2FsqueezeDetMX/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263641602,"owners_count":23493419,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["computer-vision","deep-learning","kitti-dataset","mobile","object-detection","squeezedet"],"created_at":"2024-10-11T13:44:41.469Z","updated_at":"2025-07-05T01:06:30.584Z","avatar_url":"https://github.com/alvinwan.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SqueezeDetMX\n\n\u003e This repository is built in Python3.6. With small syntax changes, it could be adapted to Python3.*. To my knowledge, those changes would render the repository backwards-compatible with Python2.*.\n\nThis repository contains an implementation of SqueezeDet, a [\"unified, small, low power fully convolutional neural network for real-time object detection for autonomous driving\"](https://arxiv.org/abs/1612.01051), in MXNet. Note that this *only* runs on Python3. It additionally holds utilities for reading and writing compact binary data, on top of deserialization functions for the KITTI dataset.\n\nYou can find the original squeezeDet implementation, using Tensorflow, [here](https://github.com/BichenWuUCB/squeezeDet). Parts of the codebase were taken from the original repository; all such instances have been cited accordingly.\n\n# 1. Install\n\n(Optional) We recommend setting up a virtual environment.\n\n```\nvirtualenv squeezeDetMX --python=python3\nsource activate squeezeDetMX/bin/activate\n```\n\nSay `$SDMX_ROOT` is the root of your repository. Navigate to your root repository.\n\n```\ncd $SDMX_ROOT\n```\n\nWe need to setup our Python dependencies.\n\n```\npip install -r requirements.txt\n```\n\n# 2. Setup KITTI\n\n*The first two steps were taken nearly word-for-word from the [original README](https://github.com/BichenWuUCB/squeezeDet#trainingvalidation).*\n\nFirst, obtain the KITTI object detection dataset links: [images](http://www.cvlibs.net/download.php?file=data_object_image_2.zip) and [labels](http://www.cvlibs.net/download.php?file=data_object_label_2.zip). Start by creating and changing into a directory for KITTI.\n\n```\nmkdir $SDMX_ROOT/data/KITTI\ncd $SDMX_ROOT/data/KITTI\n```\n\nDownload and then unzip both files.\n\n```\nwget \u003clink to object zip\u003e\nunzip data_object_image_2.zip\nwget \u003clink to label zip\u003e\nunzip data_object_label_2.zip\n```\n\n## Train-Val Splitting\n\nNow we need to split the training data into a training set and a validation set. Create a directory to hold both.\n\n```Shell\nmkdir ImageSets\ncd ./ImageSets\n```\n\nThen, create a new file `trainval.txt`, containing indices to all the images in the training data. In our experiments, we randomly split half of indices in `trainval.txt` into `train.txt` to form a training set and rest of them into `val.txt` to form a validation set.\n\n```\nls ../training/image_2/ | grep \".png\" | sed s/.png// \u003e trainval.txt\n```\n\nFor your convenience, we provide a script to split the train-val set automatically. Navigate to the data directory's root.\n\n```\ncd $SDMX_ROOT/data\n```\n\nSimply run\n\n```Shell\npython random_split_train_val.py\n```\n\nYou should get both `train.txt` and `val.txt` under `$SQDT_ROOT/data/KITTI/ImageSets`.\n\nWhen above two steps are finished, the structure of `$SQDT_ROOT/data/KITTI/` should at least contain:\n\n```Shell\n$SQDT_ROOT/data/KITTI/\n                  |-\u003etraining/\n                  |     |-\u003e image_2/00****.png\n                  |     L-\u003e label_2/00****.txt\n                  |-\u003etesting/\n                  |     L-\u003e image_2/00****.png\n                  L-\u003eImageSets/\n                        |-\u003e trainval.txt\n                        |-\u003e train.txt\n                        L-\u003e val.txt\n```\n\n## Converting into RecordIO\n\nThis repository additionally contains a conversion script, from KITTI to RecordIO file objects. Navigate to the repository root, and run `convert.py`.\n\n```\ncd $SDMX_ROOT\npython convert.py\n```\n\nIf your data was downloaded and setup per the above `Data` section, the script will require no flags. Otherwise, run `python convert.py --help` for more information.\n\n# 3. Train\n\nThe repository will support any RecordIO binary, written using the `squeezeDetMX.utils.Writer` object. By default, the script will look for RecordIO objects in `./data/KITTI`. To start running, use\n\n```\npython train.py\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falvinwan%2Fsqueezedetmx","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falvinwan%2Fsqueezedetmx","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falvinwan%2Fsqueezedetmx/lists"}