WongKinYiu / yolov7

Implementation of paper - YOLOv7: Trainable bag-of-freebies sets new state-of-the-art for real-time object detectors
GNU General Public License v3.0
13.01k stars 4.11k forks source link

Images augmented, but bounding boxes not (in train_batch*.jpg) #1549

Closed JakobStr closed 1 year ago

JakobStr commented 1 year ago

Hi guys, first of all: I am a beginner at object detection, so please excuse if my question is stupid. But to my problem: I am trying to train a kaggle dataset on yolo for educational purposes. This one, if someone is interested: https://www.kaggle.com/competitions/understanding_cloud_organization/overview But it seems, that the bounding-boxes are wrong in the train_batch*.jpg files (runs/train/yolov7-tiny/train_batch1.jpg):

Screenshot from 2023-03-03 15-28-48 If you look on the right picture for example, the bounding box seems to be out of the image. The corresponding labels file looks like this: image and if I plot this in my custom script, it looks like this: image which is what I would expect.

The command, which i use to train the network is:

!python3.8 train.py \
    --batch 8 \
    --epochs 55 \
    --data /data/fromwheeler/yolov7_bus_and_trucks/data.yaml \
    --cfg cfg/training/yolov7-tiny.yaml \
    --weights '' \
    --name yolov7-tiny \
    --hyp data/hyp.scratch.tiny.yaml \
    --device 0 --workers 0

and the data/hyp.scratch.tiny.yaml-file looks like this (mosaic disabled!): image

Any help would be highly appreciated. Thank you!

JakobStr commented 1 year ago

My fault. The labels have been in the wrong format!