Pull Request已成功合入, 合并人@CANN-robot
(感谢 majiajian_hw 的贡献)Thanks for your pull-request.
The full list of commands accepted by me can be found at here。
You can get sig-info at here
PR Approval Progress
✅ Congratulations! All modules have met the lgtm and approve requirements.
Module Approval Details
| module | lgtm status | approve status |
|---|---|---|
| ** | ✅ 徐鲁威, gcw_kUomxQ2l, 刘伟 (3/2) | ✅ gcw_kUomxQ2l (1/1) |
💡 Tip:
- Committer can comment
/approveor/lgtm- Commenting
/approveimplies both code review (lgtm) and intent to merge (approve)
CLA Signature Pass
nunnons2, thanks for your pull request. All authors of the commits have signed the CLA. 👍


compile


流水线任务触发成功
任务链接 [2a904e3d26ac4ae18020cc7e3299b0dd][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| Compile_Ascend_X86 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_X86_mobile_station | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_X86_experimental | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM_experimental | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_X86_A5 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_Ascend_ARM_A5 | ✅ SUCCESS | >>>>> | >>>>> |
| pre_comment | ✅ SUCCESS | >>>>> | |
| Compile_Pre | ✅ SUCCESS | >>>>> | |
| Compile_X86_monitor_910b | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_X86_monitor_910c | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_X86_monitor_950 | ✅ SUCCESS | >>>>> | >>>>> |
| Compile_harmony-infer-chs-cv | ✅ SUCCESS | >>>>> | |
| UT_Test | ✅ SUCCESS | ||
| PreSmoke_A900 | ✅ SUCCESS | >>>>> | |
| PreSmoke_ATK_Test_A2 | ✅ SUCCESS | >>>>> |
[2026-07-06 12:04:38] CI执行结束


流水线任务触发成功
任务链接 [e8792d4047604aa18e1ad75dfdff2e79][流水线指导]
| 任务名称 | 状态 | 日志 | 下载链接 |
|---|---|---|---|
| codecheck | ✅ SUCCESS | >>>>> | |
| SCA | ✅ SUCCESS | >>>>> | |
| antipoison | ✅ SUCCESS | >>>>> | |
| codecheck_checkpr | ✅ SUCCESS | ||
| StaticCheck_codespell_check | ✅ SUCCESS | ||
| StaticCheck_link_validity_check | ✅ SUCCESS | ||
| StaticCheck_resource_existence_check | ✅ SUCCESS | ||
| StaticCheck_tag_closed_check | ✅ SUCCESS | ||
| StaticCheck_markdownlint | ✅ SUCCESS | ||
| codecheck_codestyle | ⚠️ WARNING | >>>>> | |
| codecheck_precommit | ⚠️ WARNING | >>>>> | >>>>> |
[2026-07-06 11:47:12] CI执行结束


变更摘要
此 PR 主要对 test_roi_pooling_grad_with_arg_max.cpp 测试文件进行代码清理和格式调整,包括注释掉唯一的测试用例 test_roi_pooling_grad_with_arg_max_950_fp16、重新组织头文件包含顺序,以及统一代码缩进风格。
主要改动
- 注释掉测试用例:将
TEST_F(roi_pooling_grad_with_arg_max_test, test_roi_pooling_grad_with_arg_max_950_fp16)整个测试体及其内存分配与释放逻辑注释掉,该测试目前处于停用状态。 - 头文件包含重排:移除了
<array>头文件,将<cmath>、<cstdint>、<cstdlib>等 C 标准库头文件提前,<vector>移至最后,并将"tikicpulib.h"调整到 kernel 相关头文件之后。 - tiling 数据头文件路径调整:将
#include "../../../op_kernel/arch35/roi_pooling_grad_with_arg_max_tiling_data.h"从末尾移至"data_utils.h"下方,使包含顺序更加合乎依赖层级。 - 代码格式统一:将类访问修饰符
protected:缩进调整为 3 空格,模板函数声明参数分行对齐,以及SetUpTestCase/TearDownTestCase改为单行内联风格。


代码审查
审查结束
各文件审查结果
- objdetect/roi_pooling_grad_with_arg_max/tests/ut/op_kernel/test_roi_pooling_grad_with_arg_max.cpp:发现 1 个问题
问题统计
| 优先级 | 数量 |
|---|---|
| P0 | 0 |
| P1 | 1 |
| P2 | 0 |
| P3 | 0 |
总体风险评估
高风险。该变更将内核 UT 文件中唯一的测试用例整体注释掉,导致该算子的内核级单元测试完全失效。Issue #598 所描述的命名空间冲突应通过代码层面的符号隔离来解决(如添加全局命名空间限定),而非直接禁用测试。此变更合入后,该算子在后续迭代中将失去内核 UT 的回归保护能力。
| 类型 | 数量 |
|---|---|
| 🔴 阻塞 | 1 |
| 🟡 建议 | 0 |
⛔ 需要修改


🟠 High Priority
变更将文件中仅有的一个 TEST_F(roi_pooling_grad_with_arg_max_test, test_roi_pooling_grad_with_arg_max_950_fp16) 测试用例整体注释(第 46–94 行),使得该测试文件不再包含任何活跃的测试用例。Issue #598 提到原始问题是"cpu debug 中存在同名函数导致"的命名空间冲突,正确做法应是通过添加命名空间限定符(如 ::roi_pooling_grad_with_arg_max<0>)或调整 include 顺序来解决名称冲突,而非直接禁用测试。后果:内核级 UT 完全失效,该算子的回归保护丧失,后续代码变更无法被此测试捕获。


/lgtm
/approve


/approve


描述
去掉RoiPoolingGradWithArgMax的kernel ut
关联的Issue
https://gitcode.com/cann/ops-cv/issues/598
https://gitcode.com/cann/ops-cv/issues/593
测试
已完成
文档更新
不涉及
类型标签