Bobo-y / flexible-yolov5

More readable and flexible yolov5 with more backbone(gcn, resnet, shufflenet, moblienet, efficientnet, hrnet, swin-transformer, etc) and (cbam,dcn and so on), and tensorrt

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

0 gradients 问题

huangzizheng01 opened this issue · comments

` Epoch gpu_mem box obj cls labels img_size

0%| | 0/4 [00:00<?, ?it/s]
0/99 11.1G 0.1135 0.06343 0 415 640: 0%| | 0/4 [00:00<?, ?it/s]
0/99 11.1G 0.1135 0.06343 0 415 640: 25%|██▌ | 1/4 [00:02<00:07, 2.64s/it]
0/99 11.2G 0.1125 0.06845 0 438 640: 25%|██▌ | 1/4 [00:04<00:07, 2.64s/it]
0/99 11.2G 0.1125 0.06845 0 438 640: 50%|█████ | 2/4 [00:04<00:04, 2.21s/it]
0/99 11.2G 0.1124 0.06684 0 385 640: 50%|█████ | 2/4 [00:06<00:04, 2.21s/it]
0/99 11.2G 0.1124 0.06684 0 385 640: 75%|███████▌ | 3/4 [00:06<00:02, 2.14s/it]
0/99 11.2G 0.1125 0.067 0 394 640: 75%|███████▌ | 3/4 [00:08<00:02, 2.14s/it]
0/99 11.2G 0.1125 0.067 0 394 640: 100%|██████████| 4/4 [00:08<00:00, 2.21s/it]
0/99 11.2G 0.1125 0.067 0 394 640: 100%|██████████| 4/4 [00:08<00:00, 2.23s/it]
Model summary: 271 layers, 7022326 parameters, 0 gradients`

我训练voc和coco128时候,都碰到了这个问题,0 gradients,我没有设置freeze。请问这是怎么回事呢,是哪个步骤设置了grad=False吗

翻看了以往的issues,问题出在没改model_xxx.py中的nc。感谢大佬的repo奉献!

模型可以打印出来flop吗?