keras-yolo3 icon indicating copy to clipboard operation
keras-yolo3 copied to clipboard

Error in loading annotaion labels while training

Open naveenvj25 opened this issue 1 year ago • 1 comments

I have created the train.txt file in the format specified in the step 1 of training headline in the format path/to/img1.jpg 50,100,150,200,0 30,50,200,120,3 Create 6 permanent cpu-threads Cannot load image /content/gdrive/MyDrive/Custom_data/train/261.jpg 116.0,43.000181,158.0,92.00013899999999,0 99.0,279.9999125,171.0,338.9997835,0

Error in load_data_detection() - OpenCV Cannot load image /content/gdrive/MyDrive/Custom_data/train/638.jpg 97.00016,127.99986849999999,154.00016,185.9997055,0

Error in load_data_detection() - OpenCV Cannot load image /content/gdrive/MyDrive/Custom_data/train/966.jpg 115.99984,156.00018,192.99984,233.00023600000003,0

Error in load_data_detection() - OpenCV This is the error I am getting. Actually the training works if I remove these yolo box coorodinate labels from the train.text file but I get MAP value as zero and precision zero. So could you pls tell how should I create the training .tex file..?

naveenvj25 avatar Jun 10 '23 05:06 naveenvj25

YOLO expects the file to be in a specific format, and it seems like there might be a problem with the coordinates or the way they are specified.

To resolve this issue, ensure that your train.txt file follows the correct format

Example:- 50,100,150,200,0 30,50,200,120,3 60,110,160,210,1 40,60,210,130,2

Make sure that the coordinates and class labels are separated by spaces, and each line corresponds to one image.

Dhruv-Bajaj-code avatar Oct 23 '23 18:10 Dhruv-Bajaj-code