升腾928 OPTG模型转换失败
收藏回复举报
升腾928 OPTG模型转换失败
t('forum.solved') 已解决
新人帖
发表于2024-05-16 17:19:14
0 查看

一、软件版本
1、CANN:Ascend-cann-toolkit_6.10.t01spc030b270_linux.x86_64.run
2、python:3.8.19
3、操作系统:Ubuntu 18.04
二、测试步骤
1、运行转换命令:atc --model=yolov5s_nms.onnx --output=yolov5s_nms_bs1 --framework=5 --input_format=NCHW --soc_version=OPTG--log=error --input_shape="images:1,3,640,640;img_info:1,4" --enable_small_channel=1 --insert_op_conf=aipp.cfg
报错如下:
(yolov5_v6) HwHiAiUser@ubuntu:~/chengy/modelzoo-GPL-master/built-in/ACL_Pytorch/yolov5$ bash onnx2om.sh --tag 6.0 --model yolov5s_nms --nms_mode nms_op --bs 1 --soc OPTG
=== onnx2om args ===
tag: 6.0
model: yolov5s_nms
nms_mode: nms_op
quantify: False
bs: 1
soc: OPTG
with_aipp: False
nms后处理算子
atc --model=yolov5s_nms.onnx --output=yolov5s_nms_bs1 --framework=5 --input_format=NCHW --soc_version=OPTG --log=error --input_shape="images:1,3,640,640;img_info:1,4" --enable_small_channel=1 --insert_op_conf=aipp.cfg
ATC start working now, please wait for a moment.
ATC run failed, Please check the detail log, Try 'atc --help' for more informati on
EZ3003: No supported Ops kernel and engine are found for [yolo_2], optype [YoloP reDetection].
build graph failed, graph id:0, ret:-1[FUNC:BuildModel][FILE:ge_generato r.cc][LINE:1327]
三、日志和模型下载
1、链接:https://pan.baidu.com/s/1MV54co4K2rZp67T0YG7sNA
提取码:v3in

四、其他
1、同样的环境,将二中转换命令修改为--soc_version=Ascend310,模型转换成功,模型放到Atlas 200
盒子正常运行识别,日志如下

HwHiAiUser@davinci-mini:~/chengy/acl_yolov3$ ./ACL_YOLOV3 ./yolov5s.om 000000000139.jpg
acl init successfully
Create context successfully
set context successfully
Create stream successfully
ModelProcess:Begin to init instance.
finish init AclProcess
set context successfully
ModelProcess:Begin to inference.
begin postprocess
The number of output buffers of yolov3 model is 2
outputSizes[0]: 24576
outputSizes[1]: 32
Object detected number is 13
#Obj0, box(415, 158.125, 466, 294.25) confidence: 0.471436 lable: 0
#Obj1, box(292, 216.375, 353, 320.25) confidence: 0.829102 lable: 56
#Obj2, box(360.5, 217.125, 425.5, 312.5) confidence: 0.70752 lable: 56
#Obj3, box(398.75, 220.125, 443.75, 309.5) confidence: 0.55957 lable: 56
#Obj4, box(231.875, 176.75, 265.75, 213.25) confidence: 0.516602 lable: 58
#Obj5, box(332.5, 177.25, 367.5, 226.125) confidence: 0.476807 lable: 58
#Obj6, box(4.375, 164.75, 156.375, 266) confidence: 0.903809 lable: 62
#Obj7, box(556, 208.875, 639, 288) confidence: 0.522949 lable: 62
#Obj8, box(443.75, 168.5, 513, 292.5) confidence: 0.404297 lable: 72
#Obj9, box(67.5, 61.1562, 73.0625, 100.125) confidence: 0.533691 lable: 73
#Obj10, box(448, 120.25, 462, 141.875) confidence: 0.570312 lable: 74
#Obj11, box(549, 299, 587, 400.5) confidence: 0.612305 lable: 75
#Obj12, box(166.875, 232.5, 186.375, 266.75) confidence: 0.567383 lable: 75
model run success!

cost time : 17ms
ModelProcess:Begin to deinit instance.
ModelProcess:Finished deinit instance.
all tasks in stream done
Destroy Stream successfully
Destroy Context successfully
acl deinit successfully

我要发帖子