Yolov5-lite export.py 导出onnx模型运行报错【ValueError: operands could not be broadcast together with shapes (3,2,40,6) (4800,2) 】
使用export.py转换onnx后报错:数组形状不匹配
ine 54, in cal_outputs
outs[row_ind:row_ind + length, 0:2] = (outs[row_ind:row_ind + length, 0:2] * 2. - 0.5 + np.tile(grid[i], (na, 1))) * int(stride[i])
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~
ValueError: operands could not be broadcast together with shapes (3,2,40,6) (4800,2)
解决办法:打开export.py,找到第51行,将store_true更改为store_false
parser.add_argument('--concat', action='store_false', help='concat or not') #store_true

浙公网安备 33010602011771号