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.37k stars 4.22k forks source link

An error in train_aux.py #201

Open M15-3080 opened 2 years ago

M15-3080 commented 2 years ago

According to your requirements, I used train_AUX for training, but the result showed an error.What have I not changed. I hope to get your help image

cslee99 commented 2 years ago

Is the latest source correct? There seems to be no problem in learning from the latest sources. I think it would be better to update to the latest source by doing a git pull.

M15-3080 commented 2 years ago

最新的来源是否正确?从最新来源学习似乎没有问题。我认为最好通过执行git拉取来更新到最新的源代码。

It's the latest Git, I tried it again, but it's the same mistake image

cslee99 commented 2 years ago

It doesn't seem to be the latest source. The newer sources have different cfg parts. In newer sources, default is blank in cfg. parser.add_argument('--cfg', type=str, default='', help='model.yaml path') I also had this problem in the past, but I am learning without any problems with the latest sources.

M15-3080 commented 2 years ago

它似乎不是最新的来源。较新的源具有不同的cfg部分。在较新的源中,cfg 中的默认值为空。 parser.add_argument('--cfg', type=str, default='', help='model.yaml path') 我过去也遇到过这个问题,但是我正在学习,而最新的源代码没有任何问题。

I just downloaded it from Git today. My yolov7-d6.yaml is from CFG image

WongKinYiu commented 2 years ago

train_aux.py should use cfg/training/*.yaml.

M15-3080 commented 2 years ago

train_aux.py should use cfg/training/*.yaml.

I get an error message when I use the yolov7-d6.pt model.  When I delete the yolov7-d6.pt model, it works fine.  Why is that? image

​​​​​​​​​​ image

WongKinYiu commented 2 years ago

Please use yolov7-d6_training.pt instead.

M15-3080 commented 2 years ago

请使用 yolov7-d6_training.pt 代替。

Where is the yolov7-d6 train.pt file you mentioned?

WongKinYiu commented 2 years ago

https://github.com/WongKinYiu/yolov7#transfer-learning

young169 commented 2 years ago

I have the same error as mentioned when finetuning yolov7.pt. I'm wondering whether "train_aux.py" works for all six models if I make sure the cfg/training/*.yaml matches the .pt file. Or "train_aux.py" only works for yolov7-d6 or w6?