Closed Softwaring closed 4 years ago
I have the same problem as you,It seems that ‘weights buf’ is not enough to convert.
Thanks for your help.
unknow layer type yolo Traceback (most recent call last): File "darknet2caffe.py", line 519, in <module> darknet2caffe(cfgfile, weightfile, protofile, caffemodel) File "darknet2caffe.py", line 61, in darknet2caffe start = load_conv_bn2caffe(buf, start, params[conv_layer_name], params[bn_layer_name], params[scale_layer_name]) File "darknet2caffe.py", line 150, in load_conv_bn2caffe conv_param[0].data[...] = np.reshape(buf[start:start+conv_weight.size], conv_weight.shape); start = start + conv_weight.size File "/usr/local/lib/python2.7/dist-packages/numpy/core/fromnumeric.py", line 257, in reshape return _wrapfunc(a, 'reshape', newshape, order=order) File "/usr/local/lib/python2.7/dist-packages/numpy/core/fromnumeric.py", line 52, in _wrapfunc return getattr(obj, method)(*args, **kwds) ValueError: cannot reshape array of size 695826 into shape (256,384,3,3)
Hi, Softwaring [route] layers=-1 groups=2 group_id=1 This layer output_size = input_size / groups, you should change concate layer in caffe.
The yolov4(not tiny) has the same ‘route’ layer.Although the current tool can successfully convert yolov4 to caffe,Will there be some problems.
@ChenYingpeng Thanks for your reply!
so,I want to know how to solve this problem(groups and group_id)
@Softwaring @ChenYingpeng is there some tips to convert caffe without change the layers,thanks
Thanks for your help.
unknow layer type yolo Traceback (most recent call last): File "darknet2caffe.py", line 519, in <module> darknet2caffe(cfgfile, weightfile, protofile, caffemodel) File "darknet2caffe.py", line 61, in darknet2caffe start = load_conv_bn2caffe(buf, start, params[conv_layer_name], params[bn_layer_name], params[scale_layer_name]) File "darknet2caffe.py", line 150, in load_conv_bn2caffe conv_param[0].data[...] = np.reshape(buf[start:start+conv_weight.size], conv_weight.shape); start = start + conv_weight.size File "/usr/local/lib/python2.7/dist-packages/numpy/core/fromnumeric.py", line 257, in reshape return _wrapfunc(a, 'reshape', newshape, order=order) File "/usr/local/lib/python2.7/dist-packages/numpy/core/fromnumeric.py", line 52, in _wrapfunc return getattr(obj, method)(*args, **kwds) ValueError: cannot reshape array of size 695826 into shape (256,384,3,3)
Hi, Softwaring [route] layers=-1 groups=2 group_id=1 This layer output_size = input_size / groups, you should change concate layer in caffe.
Hi,ChenYingpeng As well know, concate layer in caffe did not have parameter like dropout 50% to select the group id to the output, chould you point out how to motify the concate layer? I had train a networking and facing the same problem, now I delect the "groups" and "groups_id" parameter to sucessfully convert the model to caffemodel format.
Hoping Ur reply @.@
Hello, @ChenYingpeng @Softwaring
I also meet ths same problem,
Traceback (most recent call last):
File "darknet2caffe.py", line 569, in
Could you share how to fix this problem?
Thanks,
Thanks for your help.
yolov4-tiny.cfg