This document provides tutorials to develop CenterNet. lib/src/opts
lists a few more options that the current version supports.
Basically there are three steps:
- Convert the dataset annotation to COCO format. Please refer to src/tools/convert_kitti_to_coco.py for an example to convert kitti format to coco format.
- Create a dataset intilization file in
src/lib/datasets/dataset
. In most cases you can just copysrc/lib/datasets/dataset/coco.py
to your dataset name and change the category information, and annotation path. - Import your dataset at
src/lib/datasets/dataset_factory
.
You will need to add files to src/lib/datasets/sample/
, src/lib/datasets/trains/
, and src/lib/datasets/detectors/
, which specify the data generation during training, the training targets, and the testing, respectively.
- Add your model file to
src/lib/models/networks/
. The model should accept a dictheads
of{name: channels}
, which specify the name of each network output and its number of channels. Make sure your model returns a list (for multiple stages. Single stage model should return a list containing a single element.). The element of the list is a dict contraining the same keys withheads
. - Add your model in
model_factory
ofsrc/lib/models/model.py
.