Scalsol / mega.pytorch

Memory Enhanced Global-Local Aggregation for Video Object Detection, CVPR2020
Other
570 stars 116 forks source link

Training custom dataset classes_map in vid.py #48

Closed Hastyrush closed 4 years ago

Hastyrush commented 4 years ago

Hello, I'm following your instructions to train a custom dataset. You mentioned in your customize.md that the classes list should be changed to accomodate the new classes, but what do the classes_map mean? Is there any way to create a new classes_map for the categories in the custom dataset? Thanks a lot!

fengyue20 commented 4 years ago

I also want to know what's the meaning of the classes_map mean? Can I delete the DET_train_30classes in BASE_RCNN_1gpu?

Hastyrush commented 4 years ago

No you cant, that is the dataset that will be used to be trained loaded by the dataloader class. You will need to change vid.py under mega.core/data/datasets to match your own dataset. Inside the vid.py, there is a classes_map list which is essentially a map of each class to a code (e.g. n01234567). This code will need to match the identification of the class in the annotation. If your annotation does not have a mapping code, then this classes_map can be exactly the same as the classes_list inside the vid.py file. Hope this helps!