AlexeyAB / darknet

YOLOv4 / Scaled-YOLOv4 / YOLO - Neural Networks for Object Detection (Windows and Linux version of Darknet )
http://pjreddie.com/darknet/
Other
21.73k stars 7.96k forks source link

Why this fork gives extremely low mAP and recall results #1667

Open novate opened 6 years ago

novate commented 6 years ago

Recently I trained a dataset of ~8000 images for ~50000 iterations on darknet yolov3(pjreddie's repo). Then I use detector recall(set the threshold at 0.5 in detector.c) and get a result of around 50%. Then I want to calculate mAP and checked this repo, using detector map and I get extremely low mAP of less than 1% with recall lesser. Then I tried detector recall on this repo and found that only 2 objects were detected all the round so the recall became less and less. Could anyone help me out?

P.S. My labels are directly yolo format, because I labelled them on LabelImg with yolo format. So that there is neither PASCAL format labels, nor label conversion is used.

If something more should be stated, please ask me to do so.

P.S.2 My dataset is with only 1 class: 'person'.

2This is the result from pjreddie's repo. 3This is the result from AlexeyAB's repo.

AlexeyAB commented 6 years ago

I use detector recall

novate commented 6 years ago

Thank you for your reply.

My conditions:

P.S. I used AlexeyAB's repo to train with the same cfg/weights and darknet53.conv.74 and the same pics, same labels(everything is the same), but I cannot train properly as with pjreddie's repo(yolov3) did, everything goes to nan in the log file when training with AlexeyAB's repo.

This is some of the log file for training with pjreddie's repo. 1

This is some of the log file for training with AlexeyAB's repo. 2

AlexeyAB commented 6 years ago
novate commented 6 years ago
AlexeyAB commented 6 years ago
  • Here is a sample of my bad_label.list. 1

You should label each object on images from your dataset. Use this visual GUI-software for marking bounded boxes of objects and generating annotation files for Yolo v2 & v3: https://github.com/AlexeyAB/Yolo_mark

It will create .txt-file for each .jpg-image-file - in the same directory and with the same name, but with .txt-extension, and put to file: object number and object coordinates on this image, for each object in new line:

Where:

- integer object number from 0 to (classes-1)