---
title: YoloV5DetectionOutput算子报错“RuntimeError: box_info's height[1] multi with width[4]'s size must bigger 
description: 在修改的自定义网络上，对数据先进行了nms后处理，接着使用了YoloV5DetectionOutput算子，最后使用atc工具转换模型遇到了报错。
keywords: YoloV5
url: https://www.hiascend.com/document/caselibrary/detail/case_9495
section: (其他)
---

# YoloV5DetectionOutput算子报错“RuntimeError: box_info's height[1] multi with width[4]'s size must bigger 

URL: https://www.hiascend.com/document/caselibrary/detail/case_9495
描述: 在修改的自定义网络上，对数据先进行了nms后处理，接着使用了YoloV5DetectionOutput算子，最后使用atc工具转换模型遇到了报错。
关键词: YoloV5

昇腾文档 [了解详情](https://www.hiascend.com/document)

故障案例 [了解详情](https://www.hiascend.com/document/caselibrary)

YoloV5DetectionOutput算子报错“RuntimeError: box_info's height[1] multi with width[4]'s size must bigger than 32b”

YoloV5DetectionOutput算子报错“RuntimeError: box_info's height[1] multi with width[4]'s size must bigger than 32b”

2024/02/20

1k

问题信息

| 问题来源 | 产品大类 | 关键字 |
| --- | --- | ---|
| 官方 | 算子开发 | YoloV5 |

#### 问题现象描述

在修改的自定义网络上，对数据先进行了nms后处理，接着使用了YoloV5DetectionOutput算子，最后使用atc工具转换模型遇到了报错。

日志文件上显示以下报错信息：

```
[ERROR] TEFUSION(2333,atc.bin):2023-01-18-08:35:17.957.136  Stack:
File "/home/xxx/CANN6.0.0/install/ascend-toolkit/latest/opp/built-in/op_impl/ai_core/tbe/impl/yolo_v3_cls_prob_v2.py", line 737, in check_param
must bigger than 32b" % (height, width))
RuntimeError: box_info's height[1] multi with width[4]'s size   must bigger than 32b
```

#### 原因分析

从日志上和算子源码上直观看，可以发现用户的输入数据有问题，不符合规范。

#### 排查方法

检测算子并经过排查后却发现了真实的原因，对于nms后处理过的数据，在使用YoloV5DetectionOutputD算子时，需要指定该算子的一个attr属性N，且指定N=13，才可正常处理。

#### 解决措施

nms后处理过的数据 ，使用YoloV5DetectionOutput算子后，需要在这段代码需要额外添加一个参数 “N=13”。

图1代码添加参数示例

本页内容

- 问题信息
- 问题现象描述
- 原因分析
- 排查方法
- 解决措施
