pytorch-yolov4-deepsort icon indicating copy to clipboard operation
pytorch-yolov4-deepsort copied to clipboard

training yolo-v4 detector

Open YHassan002 opened this issue 2 years ago • 1 comments

Thanks for sharing this useful repository! I'm trying to retrain the detector with my own data, in which format should I restructure my data into?

Particularly, how to construct the train.txt file to be compatible with your code?

Thank you,

YHassan002 avatar Sep 09 '22 15:09 YHassan002

  1. Use the VOC format for training.
  2. Before training, put the label file in the Annotation under the VOC2007 folder under the VOCdevkit folder.
  3. Before training, put the image files in JPEGImages under the VOC2007 folder under the VOCdevkit folder.
  4. Use the voc2yolo4.py file to generate the corresponding txt before training.
  5. Run voc_annotation.py in the root directory again. Before running, you need to change the classes to your own classes. Be careful not to use Chinese labels and no spaces in the folder!
  6. At this time, the corresponding 2007_train.txt will be generated, and each line corresponds to its picture position and its real frame position.

deyiwang89 avatar Sep 11 '22 13:09 deyiwang89