-
Notifications
You must be signed in to change notification settings - Fork 8k
FAQ frequently asked questions
-
The most common problem - you do not follow strictly the manual. You must use:
default anchors
,learning_rate=0.001
,batch=64
(you can change only subdivisions=),max_batches = max(6000, number_of_training_images, 2000*classes)
= and you must train this number of iterations equal tomax_batches
, ... read more Do not do anything that is not written in the manual. -
Your datasets are wrong - check the AP50 (average precision) for validation and training dataset by using command
./darknet detector map obj.data yolo.cfg yolo.weights
-
if you get high mAP for both Training and Validation datasets, but the network detects objects poorly in real life, then your training dataset is not representative - add more images from real life to it
-
if you get high mAP for Training dataset, but low for Validation dataset, then your Training dataset isn't suitable for Validation dataset, read paragraph 4
-
if you get low mAP for both Training and Validation datasets, then labels in your Training dataset are wrong, read paragraph 3
-
-
Your dataset is wrong - run training with flag
-show_imgs
, i.e../darknet detector train ... -show_imgs
do you see correct bounded boxes? Or check your dataset by using Yolo_mark tool: https://github.com/AlexeyAB/Yolo_mark -
Your training dataset doesn't suitable for your Test dataset:
- Training dataset contains: cars (rear view) from distance 100m
- Test dataset contains: cars (side view) from distance 5m
-
You must compile Darknet with GPU support for training.
-
After you have verified that you do not have these mistakes, create an Issue and provide all the necessary information: https://github.com/AlexeyAB/darknet/issues/new?assignees=&labels=Training+issue&template=training-issue---no-detections---nan-avg-loss---low-accuracy.md&title=
-
Read error message, and try to understand the cause of the error.
-
If
CUDA Out of memory
error occurs, then increasesubdivisions=
2 times in cfg-file, but not higher than batch= (don't change batch). If it doesn't help - setrandom=0
andwidth=416 height=416
in cfg-file. -
Check content of files
bad.list
andbad_label.list
if they exist near with./darknet
executable file. -
Do not move some files from Darknet folder - you may forget the necessary files.
-
Download libraries CUDA, cuDNN, OpenCV, ... only from official sources. Don't download libs from other sites.
-
Make sure that you do everything in accordance with the manual, and do not do anything that is not written in the manual.
-
Sometimes there are bugs in the libraries CUDA/cuDNN. Try to use another version.
-
Sometimes, there are Hardware bugs: https://github.com/AlexeyAB/darknet/issues?q=is%3Aissue+label%3A%22Hardware+bug%22+is%3Aclosed
-
If it doesn't help - create an Issue: https://github.com/AlexeyAB/darknet/issues/new?assignees=&labels=&template=any-other-question-or-issue.md&title=