这篇文章给大家介绍海思NNIE mapper转换模型出错提示:"input shape size is not equal to input name size"怎么办,内容非常详细,感兴趣的小伙伴们可以参考借鉴,希望对大家能有所帮助。
caffe模型在电脑上运行正常,使用海思nnie_mapper
转换模型时失败,输出如下:
wuyy@wuyy-VirtualBox:~/dl/weights$ nnie_mapper_12 yolov3_608.cfg Mapper Version 1.2.2.1_B030 (NNIE_1.2) 19090610466402 begin net parsing.... ********************************************************** ERROR: file: parseInputDim line: 2244 input shape size is not equal to input name size! ********************************************************** ERROR: file: parseInputParamOldVersion line: 2151 ERROR: RUN FAILURE in line 2151. Return = 262148 ********************************************************** ERROR: file: parseModel line: 14827 ERROR: RUN FAILURE in line 14827. Return = 262148 ********************************************************** ERROR: file: compile line: 609 ERROR: RUN FAILURE in line 609. Return = 262148 ********************************************************** ERROR: file: iFEPCompile line: 114 ERROR: RUN FAILURE in line 114. Return = 262148 ********************************************************** ERROR: file: main line: 164 iFEPCompile failed(262148) begin quant files writing.... end quant files writing
原因是deploy.prototxt
文件输入层的格式与海思的nnie_mapper
支持的格式不兼容,海思支持的格式参阅文档:HiSVP 开发指南.pdf
,章节:3.2.1 deploy.prototxt 输入层格式
原来的格式如下:
input: "data" input_dim: 1 input_dim: 3 input_dim: 608 input_dim: 608
修改如下:
input: "data" input_shape { dim: 1 dim: 3 dim: 608 dim: 608 }
修改后重新运行nnie_mapper
,转换成功:
wuyy@wuyy-VirtualBox:~/dl/weights$ nnie_mapper_12 yolov3_608.cfg Mapper Version 1.2.2.1_B030 (NNIE_1.2) 19090610466402 begin net parsing.... end net parsing begin prev optimizing.... end prev optimizing.... begin net quantalizing(CPU).... end quantalizing begin optimizing.... end optimizing begin NNIE[0] mem allocation.... end NNIE[0] memory allocating begin NNIE[0] instruction generating.... end NNIE[0] instruction generating begin parameter compressing.... end parameter compressing begin compress index generating.... end compress index generating begin binary code generating.... end binary code generating begin quant files writing.... end quant files writing wuyy@wuyy-VirtualBox:~/dl/weights$ ls cnn_net_tree.dot dog_bike_car.jpg instruction.txt yolov3_416.caffemodel yolov3_608_inst.wk cnn_net_tree_gv.dot dout_nne_para.txt mapper_debug.log yolov3_416.cfg yolov3_608.prototxt cnn_net_tree_org.dot gfpq_param.txt mapper_error.log yolov3_416.prototxt cnn_net_tree_pre.dot ibd_para.txt netmem_info.data yolov3_608.caffemodel cnn_net_tree_pre_org.dot image_ref_list.txt RUNTIME.txt yolov3_608.cfg
关于海思NNIE mapper转换模型出错提示:"input shape size is not equal to input name size"怎么办就分享到这里了,希望以上内容可以对大家有一定的帮助,可以学到更多知识。如果觉得文章不错,可以把它分享出去让更多的人看到。
免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。