allanzelener / YAD2K

YAD2K: Yet Another Darknet 2 Keras
Other
2.71k stars 879 forks source link

yad2k.py Unsupported yolo_0(yolov3-tiny)? #144

Open zihaozhang9 opened 5 years ago

zihaozhang9 commented 5 years ago

i use ‘python yad2k.py yolov3-tiny.cfg yolov3-tiny.weights model_data/yolov3-tiny.h5’ .But Throw an exception:

Parsing section yolo_0 Traceback (most recent call last): File "yad2k.py", line 270, in _main(parser.parse_args()) File "yad2k.py", line 249, in _main 'Unsupported section header type: {}'.format(section)) ValueError: Unsupported section header type: yolo_0

tanzeel-ur-rehman-khan commented 2 years ago

@prakharcode used your changed file as well, but it says (buffer is too small for requested array) for last two layers (conv_20 and yolo_1). i'm actually trying to convert YOLO v4-tiny .weights file into .h5 format so that i can access those weights and reuse them in my own code in c++. i've tried all convert.py files and yad2k.py files on internet but same issue. the cfg and weights file works fine itself when read from cv.dnn.readfromdarkent("cfg path", "weights path") but i need to acess weights as floating point values arrays and always stuck on last two layers, can you plzz help me in this case, i'd be grateful to you. i've attached my cfg file and weights file along with some convert files i tried but each time ended up having the same issue. yolov4-tiny.zip