已合并
修复pooling作用域 #2512
修复pooling作用域 #2512
已合并
胡一航创建于 3月10日
胡一航成员
3月10日

描述

adaptive_max_pool_common.cpp和pool_3d_util.cpp修改作用域,不修改作用域可能会和内联函数造成冲突。

关联的Issue

测试

文档更新

类型标签

likedislike
Pull Request已成功合入, 合并人@CANN-robot
(感谢 胡一航 的贡献)
胡胡一航成员
3月10日 创建了 pull request,commit 3a18ca03
CANN-robotCANN-robot成员
3月10日 添加了label:stat/needs-squash
CANN-robot
CANN-robot成员
3月10日 评论:

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
*/*/op_api/*.h ✅ wangyongguang, chenqi317 (2/2) ✅ wangyongguang (1/1)
pooling ✅ chenqi317, zhangyuxiang0119, wangyongguang (3/2) ✅ wangyongguang, chenqi317, zhangyuxiang0119 (3/1)

💡 Tip:

  • Committer can comment /approve or /lgtm
  • Commenting /approve implies both code review (lgtm) and intent to merge (approve)
likedislike
CANN-robotCANN-robot成员
3月10日 将crystalhu,fanqirui,zhou-qilong,chenqi317,liubo75,tangweiwei2,zhangyuxiang0119,wangyongguang,zhang-wu设为评审人
CANN-robotCANN-robot成员
3月10日 将crystalhu,zhou-qilong,chenqi317,liubo75,tangweiwei2,zhangyuxiang0119,wangyongguang,zhang-wu设为审查人
CANN-robotCANN-robot成员
3月10日 添加了label:cann-cla/yes
CANN-robot
CANN-robot成员
3月10日 评论:

CLA Signature Pass

huyihang1117, thanks for your pull request. All authors of the commits have signed the CLA. 👍

likedislike
胡一航成员
3月10日 评论:

compile

likedislike
CANN-robot
CANN-robot成员
3月10日 评论:

🔵 source code change are detected, tasks labels is removed in this pull request!

likedislike
CANN-robotCANN-robot成员
3月10日 添加了label:ci-pipeline-running
CANN-robot
CANN-robot成员
3月10日 评论:

流水线任务触发成功
任务链接 [fd25a43db6494e45a1e1051a4b5a104a][流水线指导]

任务名称状态日志下载链接
解析CI分支 ✅ SUCCESS
codecheck ✅ SUCCESS >>>>>
anti_virus ✅ SUCCESS >>>>>
Check_Pr ✅ SUCCESS >>>>>
Compile_Ascend_X86_ubuntu24 ✅ SUCCESS >>>>>
Compile_Ascend_X86_mobile_station ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_single ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_experimental ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_950 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_950 ✅ SUCCESS >>>>> >>>>>
API_Check ⚠️ WARNING >>>>>
Pre_Compile ✅ SUCCESS
pre_comment ✅ SUCCESS >>>>>
Compile_Ascend_X86 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_mobile_station_ubuntu24 ✅ SUCCESS >>>>>
Compile_Ascend_X86_950_ubuntu24 ✅ SUCCESS >>>>>
UT_Test_ophost ✅ SUCCESS
UT_Test_opapi ✅ SUCCESS
UT_Test_kernel ✅ SUCCESS
UT_Test_opgraph ✅ SUCCESS
Smoke_A900_npupool ✅ SUCCESS >>>>>

[2026-03-10 19:21:23]    CI执行结束

likedislike
CANN-robot
CANN-robot成员
3月10日 评论:

问题/功能描述

本次PR主要解决了多个3D池化算子(包括自适应最大池化、平均池化、最大池化及其反向传播)实现中的命名空间引用不完整问题,旨在修复由此引发的编译或链接错误。同时,对部分公共工具代码进行了重构,将原有的C风格接口封装为C++命名空间,以提升代码的组织性、可读性和可维护性,避免潜在的符号冲突。

修改方案描述

修改方案分为两部分:一是修复性修改,在多个算子实现文件中添加了 using namespace Pool3DCommon; 或 using namespace AdaptiveMaxPoolCommon; 声明,以确保能正确调用公共命名空间中的工具函数(如 View3Das4D、CheckReduceOutShape 等)。二是重构性修改,将 pool_3d_util 等公共模块的代码从 extern "C" 风格重构为使用 Pool3DCommon 和 AdaptiveMaxPoolCommon 命名空间进行封装,使代码结构更清晰、更符合C++规范。所有修改均不涉及核心算法逻辑的变更。

likedislike
CANN-robotCANN-robot成员
3月10日 添加了label:api-check-failed
CANN-robotCANN-robot成员
3月10日 删除了label:ci-pipeline-running
CANN-robotCANN-robot成员
3月10日 添加了label:ci-pipeline-passed
胡胡一航成员
3月10日 关联了issue:[Bug-Report|缺陷反馈]: adaptive_max_pool_common.cpp和pool_3d_util.cpp需要修改作用域
胡胡一航成员
3月10日 修改了pull request 的描述
张喻翔
张喻翔
3月10日 评论:

/lgtm
/approve

likedislike
wangyongguang成员
3月10日 评论:

/approve

likedislike
CANN-robotCANN-robot成员
3月10日 添加了label:approved
chenqi317成员
3月10日 评论:

/lgtm
/approve

likedislike
CANN-robotCANN-robot成员
3月10日 添加了label:lgtm
CANN-robot
CANN-robot成员
3月10日 评论:

Review Guide

This pull-request passes review.
Committers who wrote a comment of /approve are: zhangyuxiang0119, wangyongguang, chenqi317.
Reviewers who wrote a comment of /lgtm are: zhangyuxiang0119, wangyongguang, chenqi317.

likedislike
CANN-robotCANN-robot成员
3月10日 合入了pull request