YOLO-pytorch icon indicating copy to clipboard operation
YOLO-pytorch copied to clipboard

Can't get yad2t.py to function

Open robhammett opened this issue 4 years ago • 2 comments

command ran: python3 tools/yad2t.py --cfg_path config/yolov4-custom.cfg --weight_path config/yolov4-custom_best.weights --output_path config/model

results from command: Weights Header: [ 0 2 5 320000] Traceback (most recent call last): File "tools/yad2t.py", line 124, in weight2pth(config.cfg_path, config.weight_path, config.output_path) File "tools/yad2t.py", line 48, in weight2pth cfg = importlib.import_module('config.' + cfgname) File "/usr/lib/python3.8/importlib/init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1014, in _gcd_import File "", line 991, in _find_and_load File "", line 973, in _find_and_load_unlocked ModuleNotFoundError: No module named 'config.yolov4-custom'

Any idea how to get this to function?

robhammett avatar Dec 14 '20 21:12 robhammett

same problem: File "yad2t.py", line 48, in weight2pth cfg = importlib.import_module('config.' + cfgname) File "/usr/lib/python3.8/importlib/init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1014, in _gcd_import File "", line 991, in _find_and_load File "", line 973, in _find_and_load_unlocked ModuleNotFoundError: No module named 'config.yolo-obj'

Did you solve it?

RuochenQi avatar May 28 '21 01:05 RuochenQi

Your files need to be yolo.cfg and yolo.weights (or tiny-yolo.cfg and tiny-yolo.weights)

dorianboille avatar Dec 07 '22 09:12 dorianboille