YunYang1994 / tensorflow-yolov3

🔥 TensorFlow Code for technical report: "YOLOv3: An Incremental Improvement"
https://yunyang1994.gitee.io/2018/12/28/YOLOv3-算法的一点理解/
MIT License
3.63k stars 1.36k forks source link

"convert_weight.py", line 65, in <module> raise RuntimeError #154

Open herywang opened 5 years ago

karanChrysalis commented 5 years ago

Im facing the same issue. Any solution?

ITKing80 commented 5 years ago

same issue

org_weights_num = len(org_weights_mess) cur_weights_num = len(cur_weights_mess) if cur_weights_num != org_weights_num: raise RuntimeError

I trained from scratch. Have no idea, why the length aren't equal.

CNUyue commented 5 years ago

我也遇到相同的问题,有人解决了吗? @YunYang1994 @ITKing80 @deepBrainWH ,谢谢

karanChrysalis commented 5 years ago

I used the convert weight from older commit, to get pretrained weights and rescale. Used the checkpoints with the latest code to train. Worked well.

CNUyue commented 5 years ago

@karanChrysalis How do you do about the problem?Can you elaborate on that?Thanks!

arnauqb commented 5 years ago

Hi, I had the same problem, but I could solve it by restoring the core/config.py file to the default one. I had changed it to fit my dataset.

ghost commented 5 years ago

Hi, I had the same problem, but I could solve it by restoring the core/config.py file to the default one. I had changed it to fit my dataset.

Can you please tell me how to restore core/config.py to the default one? I have been getting this error Traceback (most recent call last): File "convert_weight.py", line 74, in raise RuntimeError RuntimeError Thank you.

arnauqb commented 5 years ago

Hi, I had the same problem, but I could solve it by restoring the core/config.py file to the default one. I had changed it to fit my dataset.

Can you please tell me how to restore core/config.py to the default one? I have been getting this error Traceback (most recent call last): File "convert_weight.py", line 74, in raise RuntimeError RuntimeError Thank you.

just reclone the repo or dump the contents of https://github.com/YunYang1994/tensorflow-yolov3/blob/master/core/config.py into core/config.py

xiaozhubenben commented 5 years ago

Same Error here. I trained from scratch. Who can give some advice ,thanks.

imglearning commented 5 years ago

在 cmd 命令行下,运行 python convert_weight.py --train_from_coco.就可以解决 主要的原因是在config.py中,改变了__C.YOLO.CLASSES = "./data/classes/traffic.names"这个参数

hexin6688 commented 4 years ago

我train from strach,然后用训练好的模型转换为.pb时,出现runtime error,具体是org_weights_num = len(org_weights_mess) cur_weights_num = len(cur_weights_mess) if cur_weights_num != org_weights_num: raise RuntimeError org_weights_num =1049, cur_weights_num =366出错的 请问是什么原因呢?

hexin6688 commented 4 years ago

same issue

org_weights_num = len(org_weights_mess) cur_weights_num = len(cur_weights_mess) if cur_weights_num != org_weights_num: raise RuntimeError

I trained from scratch. Have no idea, why the length aren't equal.

have you solved the problem?I'm facing the same problem