| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
feat: 18个迁移算子适配unknown shape/rank InferShape并补UT及入口日志 Co-authored-by: xuejinghui<xuejinghui@huawei.com> # message auto-generated for no-merge-commit merge: !8821 merge InferShape into master feat: 18个迁移算子适配unknown shape/rank InferShape并补UT及入口日志 Created-by: xuejinghui Commit-by: xuejinghui Merged-by: cann-robot Description: ## 描述 18个迁移算子适配unknown shape/rank InferShape并补UT及入口日志 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5250 <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他,请描述:Unknown Shape/ Unknown Rank迁移适配 ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [x] AI辅助编写 See merge request: cann/ops-nn!8821 | 1 个月前 | |
refactor(apply_top_k_top_p_with_sorted): reduce duplicate code Co-authored-by: yangziqi_007<yangziqi4@huawei.com> # message auto-generated for no-merge-commit merge: !9916 merge cleancode into master refactor(apply_top_k_top_p_with_sorted): reduce duplicate code Created-by: yangziqi_007 Commit-by: yangziqi_007 Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> apply_top_k_top_p_with_sorted降低重复代码 cleancode ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> ## 测试 <!--描述进行了哪些测试来验证你的改动。--> atk验证通过 ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他,请描述: cleancode ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [x] AI辅助编写 See merge request: cann/ops-nn!9916 | 1 个月前 | |
perf(arg_max_grad): arch35 轴下标改寄存器生成并开双缓冲, UB 记账由容量反解 Co-authored-by: tangpingchuan<tangpingchuan@huawei.com> # message auto-generated for no-merge-commit merge: !9546 merge fix/arg-max-grad-perf into master perf(arg_max_grad): arch35 轴下标改寄存器生成并开双缓冲, UB 记账由容量反解 Created-by: zl_hw Commit-by: tangpingchuan Merged-by: cann-robot Description: ## 描述 ArgMaxGrad 在 arch35 上改为不带 D 的原型后,轴下标(A2 融合 pass 里的 assist 张量)由内核自生成。原实现每段都要把轴下标**物化到 UB** 再读回比较,既占 UB(每元素 4B)又多走一趟写;同时 BUFFER_NUM 固定为 1,MTE2→V→MTE3 全串行。本 PR 按「腾地方 + 用地方」两步优化,并把 UB 记账从「先定尺寸再回头检查」改为「按容量反解」。 ### 改动方法 1. **多行合并按行长分四档分派**(arg_max_grad_nd.h) - MERGE_COMPACT_DIRECT 逐行直算:行长是 32B 整数倍且不短于「车道数/铺设遍数」时,轴下标退化成该行的标量常量留在寄存器,indices/updates 只驻留一行并原地重复读; - MERGE_COMPACT_FILL 紧排铺 tile:行长对齐但过短时改回 UB→UB 倍增铺设; - MERGE_PAD 按行补齐:行长非 32B 整数倍且长于一个寄存器时每行一个 burst; - MERGE_COMPACT_STREAM 判据已实现但以常量 false 关闭,原因见代码注释(非对齐流式写会覆盖 32B 块内前导车道)。 2. **轴下标改为寄存器内生成**(arg_max_grad_vf.h) VF 入口新增 AssistSrc 模板档:ARANGE(inner==1,沿被选轴连续,一条 Reg::Arange)/ SCALAR(inner>1 单行段,一条 Reg::Duplicate)/ UB(仅剩「一个寄存器块跨多行」的紧排与补齐两档,k 在寄存器内算不出闭式)。ComputeSeg、ComputeOuters、ComputeRows 三条路径不再调 GenAssist。 3. **UB 记账由容量反解**(arg_max_grad_tiling_arch35.cpp) 新增 UbLayout,六个字段与内核 InitBuffer 的六次调用一一对应,Total() 即一段的真实 UB 需求;SolveColsPerChunk 对其单调性二分,求满足 Total() <= ubSize 的最大整宽段长。i32BufBytes 按档记账:inner==1 或逐行直算档记 0,每元素少 4B。 4. **开启双缓冲**:BUFFER_NUM 1 → 2。上一条腾出的 UB 正好抵消队列翻倍(fp16 每元素 ~8.1B → ~4.1B → ~8.2B,UB 占用基本持平),换来 MTE2 搬入与 V 计算重叠。 5. Process() 拆成 ProcessOuterSeg / ProcessRowSeg(纯重构,语义不变);host UT 补 10 类拒收分支用例。 ### 性能实测(Ascend950PR,ttk -d false -b release,--run 12) 两步收益必须分开说明,**不能合并成一句「优化」**: | 阶段 | 大形状 6 例 | 小形状 8 例 | |---|---|---| | 仅第 2、3 条(轴下标寄存器化) | 几何均值 **0.98x**(无收益) | 0.99x | | 叠加第 4 条(双缓冲)vs 原始 | 中位 **1.13x**,最好 1.35x | 中位 1.05x,最好 1.42x | - 收益集中在 inner>1 的三档(DIRECT/FILL/PAD,1.11~1.42x);inner==1 基本持平(0.98~0.99x,一进一出没有可重叠的流)。 - 轴下标寄存器化单独看没有收益,它的作用是**腾出 UB 让双缓冲开得起**;两步缺一不可。 - 已知退化 1 例:(2,128,129) 0.88x(两次测一致)。段数不足 2 时双缓冲多付一次同步,后续可按段数决定 buffer 深度收回。 ## 关联的Issue 关联 Issue #5418 https://gitcode.com/cann/ops-nn/issues/5418 ## 测试 Ascend950PR 真机,干净包(无插桩符号),kernel .o 与 op_tiling.so 同步部署;每份结果条数与用例数逐份核对一致。 | 集合 | 例数 | 结果 | |---|---:|---| | 泛化(R7 派生量全值域集) | 578 | 578/578 PASS | | 泛化(交付主集) | 1224 | 1224/1224 PASS | | GE 图通路 | 56 | 56/56 PASS | | 三方精度 | 100 | 100/100 PASS | | A/B 对照 | 42 | 42/42 PASS | | DFX(7 例预期拒收 + 2 例行为记录) | 9 | 与改造前基线逐例一致 | | host UT(--soc=ascend950) | 28 | 28/28 PASS | | 性能抽检(精度/越界列) | 14 | 14/14 PASS | 真机功能用例合计 **1839 例**全过。 ## 文档更新 无。 ## 类型标签 - [ ] Bug修复 - [ ] 新特性 - [x] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [x] AI辅助编写 See merge request: cann/ops-nn!9546 | 1 个月前 | |
fix(proto): 修复 norm/softmax 算子 proto 注释拼写/语法/描述错误 Co-authored-by: sun-yibo1<sunyibo1@hisilicon.com> # message auto-generated for no-merge-commit merge: !9032 merge fix-proto-comment-typos into master fix(proto): 修复 norm/softmax 算子 proto 注释拼写/语法/描述错误 Created-by: sun-yibo1 Commit-by: sun-yibo1 Merged-by: cann-robot Description: ## 描述 修复 21 个算子 proto 头文件中 Doxygen 注释的拼写、语法、描述错误与公式括号不匹配问题。所有改动仅涉及注释文本,不改动任何 REG_OP 定义。 ### 改动原因 proto 头文件的 Doxygen 注释存在拼写错误、语法错误(冠词/单复数/主谓一致)、描述误导(输入描述与实际语义不符)以及 rstd 公式多余的右括号等问题,会误导接口使用者。 ### 改动方法 仅修改注释文本,不改动 REG_OP/INPUT/OUTPUT/ATTR/DATATYPE 等代码定义。同时按 pre-commit clang-format 要求对部分文件做格式化。 ### 涉及修复 **拼写错误:** - normlization→normalization、while→will(AddLayerNormQuant) - smooth_scales1/2→smooth_scale1/2(AddRmsNormDynamicQuant,4 处) - listBool→ListBool(AddRmsNormDynamicQuant/V2) - secend→second、opertaion→operation(AddRmsNormQuant) - reseluts→results(BatchNormGrad) - support→supported(BatchNormV3) - dype→type(GroupNormV2,4 处) - Layernorm→LayerNorm、中文或→or、全角,→ASCII(LayerNorm) - \file 文件名错误 nn_norm_ops.h→layer_norm_grad_proto.h(LayerNormGrad) **语法错误(~20 处):** - A optional→An optional(AddLayerNorm/InplaceAddRmsNorm/InstanceNorm) - A ND tensor→An ND tensor(SoftmaxV2/LogSoftmaxGrad/ConfusionSoftmaxGrad) - An required→A required(GroupNormV2) - support→supports(SoftmaxV2/BroadcastGradientArgs/AddRmsNormDynamicMxQuant) - 缺复数 s:input→inputs、output→outputs、group→groups(GroupNormGrad/V2) **描述错误:** - GroupNormGrad:x 输入描述从 the offset 改为 input tensor **公式括号(7 处):** - rstd 公式多余的右括号 ))→)(AddRmsNorm/AddRmsNormCast/AddRmsNormDynamicMxQuant/AddRmsNormDynamicQuant/AddRmsNormQuant/AddRmsNormQuantV2/InplaceAddRmsNorm) ## 关联的Issue - #4989 ## 测试 - 仅注释修改,无代码变更,不影响编译与功能。 - pre-commit 全部 hook 通过(trailing-whitespace/end-of-file-fixer/clang-format/codespell/check-*/detect-private-key);OAT 合规检查 0 issues。 ## 文档更新 无。 ## 类型标签 - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [x] AI辅助编写 See merge request: cann/ops-nn!9032 | 20 天前 | |
feat(aicpu): enable constant folding for migrated ops Co-authored-by: hid29204727<wangboyu20@huawei.com> # message auto-generated for no-merge-commit merge: !9280 merge codex/aicpu-const-folding into master feat(aicpu): enable constant folding for migrated ops Created-by: hid29204727 Commit-by: hid29204727 Merged-by: cann-robot Description: ## 描述 补充 ops-nn 仓 AICPU host 常量折叠注册通路,并为当前已标记 OPEN_OPS_FLAG 的 18 个迁移算子统一开启常量折叠支持。 主要改动: - 新增仓级 OPS_NN_REGISTER_CPU_KERNELV2 注册包装宏,host 构建优先注册 V2,device/custom/UT 保持 V1 回退。 - 为 add_modules_sources 和 add_all_modules_sources 增加 HOSTCPU 参数及 host OBJECT 收集逻辑。 - 为 18 个 OPEN_OPS_FLAG 算子补充 HOSTCPU TRUE、注册头文件和 V2 注册。 - host OBJECT 汇入 libopconstant_folding_nn.so。 ## 关联的Issue 无。 ## 测试 已完成以下静态验证: - git diff --check 通过。 - 18 个 OPEN_OPS_FLAG 算子均具备 HOSTCPU TRUE。 - 18 个算子均使用 OPS_NN_REGISTER_CPU_KERNELV2,无直接 V1 注册残留。 - 注册头文件、host 编译宏和仓级 so 收集通路检查通过。 当前 Windows 环境缺少 CANN、NPU、CMake 和远端构建桥,未执行 bash build.sh --pkg -j16;完整打包构建及常量折叠功能验证待 CANN Linux 环境/CI 完成。 ## 文档更新 无仓内文档变更。 ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [x] AI辅助编写 See merge request: cann/ops-nn!9280 | 20 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
index clean code Co-authored-by: yue-ma<mayue54@huawei.com> # message auto-generated for no-merge-commit merge: !9028 merge master_bak into master index clean code Created-by: yue-ma Commit-by: yue-ma Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> index目录下进行clean code整改 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> https://gitcode.com/cann/ops-nn/issues/4233 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> UT/ST通过 ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> NA ## 类型标签 <!-- [x] 表示选中 --> - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!9028 | 1 个月前 | |
erfinv等3个算子新增ascend350平台支持 Co-authored-by: c00887544<chenshengze@huawei.com> # message auto-generated for no-merge-commit merge: !9912 merge 350 into master erfinv等3个算子新增ascend350平台支持 Created-by: chengzhi1120 Commit-by: c00887544 Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> erfinv等3个算子新增ascend350平台支持 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> https://gitcode.com/cann/ops-nn/issues/5664 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [x] AI辅助编写 See merge request: cann/ops-nn!9912 | 30 天前 | |
legacy下线:整改NN算子图模式注册与日志规范 Co-authored-by: zhouxuan78<zhouxuan78@huawei.com> # message auto-generated for no-merge-commit merge: !8388 merge master into master legacy下线:整改NN算子图模式注册与日志规范 Created-by: zhouxuan78 Commit-by: zhouxuan78 Merged-by: cann-robot Description: ## 描述 本 PR 用于 ops-nn 仓 Legacy 下线整改,补齐部分算子的直调/图模式注册、InferShape / InferDataType 拆分、日志规范整改及必要的编译/预提交问题修复。 1. 补齐多个算子的 op_graph 侧 InferDataType / graph infer 注册文件,并同步补充对应 CMakeLists.txt: - 如 FastGeluV2、HardShrinkGrad、HardSigmoidGrad、HardSwish、HardSwishGrad、Selu、SeluGrad、Shrink、SoftplusGrad、SoftplusV2、SoftplusV2Grad、Softsign、SoftsignGrad、SmoothL1Loss、SoftMarginLoss、LpNormUpdateV2、ApplyFtrlV2、ApplyMomentum、ApplyRMSProp 等。 2. 调整部分算子的 op_host infer 文件: - 将 InferDataType 逻辑从 infershape 文件中拆分/迁移到 op_graph 侧; - 保留 InferShape 逻辑,避免 shape/type 混在同一处注册; - 收敛 IndexCheck infershape 日志,仅保留入口日志。 3. 补充 SoftMarginLoss 图模式原型: - 新增 loss/soft_margin_loss/op_graph/soft_margin_loss_proto.h; - 新增 OPS_PROTO_DEF_SOFTMARGINLOSS 去重宏,避免重复注册; - 补充 SoftMarginLoss 的 op_graph/CMakeLists.txt 和 graph infer 注册。 4. 日志整改: - 为 Arch35 tiling 入口补充统一入口日志; - 对本 PR 修改范围内新增/调整的外部输入错误日志,按规范使用 OP_LOGE_FOR_INVALID_* 系列上报接口; - 收敛部分过多的 tiling / infershape 日志打印,避免循环或冗余打印。 5. 回退/收敛不属于本次整改范围的 Softshrink 重命名相关改动: - Softshrink -> SoftShrink 的命名调整不放在本 PR 中,后续单独 PR 处理。 6. 修复 pre-commit 格式问题: - 按仓库 .clang-format 修复格式; - 不修改 .pre-commit-config.yaml。 影响范围 主要影响 activation、index、loss、norm、optim、quant、vfusion 等目录下 Legacy 下线相关算子的 op_graph 注册、InferDataType 拆分、tiling 入口日志和错误日志规范。 ## 变更内容 ## 关联的Issue ## 测试 ## 文档更新 ## 类型标签 - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他:Legacy包下线整改 See merge request: cann/ops-nn!8388 | 29 天前 | |
feat: Embedding算子新增SIMD模板支持pice through场景(连续二维+非连续场景) Co-authored-by: Apricityh<wangxu359@huawei.com> # message auto-generated for no-merge-commit merge: !8200 merge feat/embedding-simd-template-clean into master feat: Embedding算子新增SIMD模板支持pice through场景(连续二维+非连续场景) Created-by: Apricityh Commit-by: Apricityh Merged-by: cann-robot Description: ## 描述 Embedding算子新增SIMD模板支持pice through场景(连续二维+非连续场景) ## 关联的Issue 关联Issue #5027 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 白盒用例、端对端通路验证:包括geir通路、aclnn、aclgraph通路 ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!8200 | 1 个月前 | |
本 PR 为 6 个算子新增 ascend350 平台的适配支持(EmbeddingBag、EmbeddingDenseGrad、EmbeddingDenseGradV2、AvgPool3D、AvgPool3DGrad、MaxPoolWithArgmax),和 1 个 算子 fusion pass 通路(max_pool_fusion_pass.cpp)的 ascend350 适配。 Co-authored-by: duxinlei<duxinlei@h-partners.com> Co-authored-by: u010470851<shangguanqinnan@huawei.com> # message auto-generated for no-merge-commit merge: !10135 merge ascend3500909 into master ascend350 算子适配350平台 Created-by: duxinlei Commit-by: duxinlei;u010470851 Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> 给 6 个算子新增 ascend350 平台的适配支持(EmbeddingBag、EmbeddingDenseGrad、EmbeddingDenseGradV2、AvgPool3D、AvgPool3DGrad、MaxPoolWithArgmax),给 1 个 算子 fusion pass 通路(max_pool_fusion_pass.cpp)新增 ascend350 适配。 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> 关联Issue [#5820](https://gitcode.com/cann/ops-nn/issues/5820) ## 测试 <!--描述进行了哪些测试来验证你的改动。--> david冒烟 david通路测试 dvlite通路测试 ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10135 | 27 天前 | |
本 PR 为 6 个算子新增 ascend350 平台的适配支持(EmbeddingBag、EmbeddingDenseGrad、EmbeddingDenseGradV2、AvgPool3D、AvgPool3DGrad、MaxPoolWithArgmax),和 1 个 算子 fusion pass 通路(max_pool_fusion_pass.cpp)的 ascend350 适配。 Co-authored-by: duxinlei<duxinlei@h-partners.com> Co-authored-by: u010470851<shangguanqinnan@huawei.com> # message auto-generated for no-merge-commit merge: !10135 merge ascend3500909 into master ascend350 算子适配350平台 Created-by: duxinlei Commit-by: duxinlei;u010470851 Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> 给 6 个算子新增 ascend350 平台的适配支持(EmbeddingBag、EmbeddingDenseGrad、EmbeddingDenseGradV2、AvgPool3D、AvgPool3DGrad、MaxPoolWithArgmax),给 1 个 算子 fusion pass 通路(max_pool_fusion_pass.cpp)新增 ascend350 适配。 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> 关联Issue [#5820](https://gitcode.com/cann/ops-nn/issues/5820) ## 测试 <!--描述进行了哪些测试来验证你的改动。--> david冒烟 david通路测试 dvlite通路测试 ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10135 | 27 天前 | |
fix: 0904日志整改 Co-authored-by: duxinlei<duxinlei@h-partners.com> # message auto-generated for no-merge-commit merge: !10129 merge 0907logModify into master fix: 0904日志整改 Created-by: duxinlei Commit-by: duxinlei Merged-by: cann-robot Description: ## 描述 fix: 0904+0908日志整改+eof日志整改+maxpoolmd的autopad参数错误+maxpoolV3 readme修改 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> 关联Issue [#5607](https://gitcode.com/cann/ops-nn/issues/5607) ## 测试 <!--描述进行了哪些测试来验证你的改动。--> 冒烟正常 出包正常 ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10129 | 24 天前 | |
md大模型检测低错修复 Co-authored-by: gitcode-chenjiao<chenjiao31@huawei.com> # message auto-generated for no-merge-commit merge: !9420 merge master into master md大模型检测低错修复 Created-by: gitcode-chenjiao Commit-by: gitcode-chenjiao Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> md aidd大模型检测低错修复 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> https://gitcode.com/cann/ops-nn/issues/5254 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ok ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> acl*.md ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!9420 | 1 个月前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
补充aclnnGather资料中缺少的dtype Co-authored-by: sikaiwei<sikaiwei1@h-partners.com> # message auto-generated for no-merge-commit merge: !10244 merge aclnnGather_md into master 补充aclnnGather资料中缺少的dtype Created-by: sikaiwei Commit-by: sikaiwei Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> 资料补充 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> https://gitcode.com/cann/ops-nn/issues/5789 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> NA ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> 更新了index/gather_elements_v2/docs/aclnnGather.md ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10244 | 27 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
【mc62】workspaceSize硬编码16M大小,替换为通过接口获取,ascendcPlatform.GetLibApiWorkSpaceSize(); Co-authored-by: xufeng12121<1074805447@qq.com> # message auto-generated for no-merge-commit merge: !10415 merge nn_work into master 【mc62】workspaceSize硬编码16M大小,替换为通过接口获取,ascendcPlatform.GetLibApiWorkSpaceSize(); Created-by: xufeng12121 Commit-by: xufeng12121 Merged-by: cann-robot Description: ## 描述 1. 背景:mc62算子workspace占用对比1951增大 2. 由于mc62代码和A5是onetrack, 所有workspacesize硬编码为16M, 在mc62上也同样是16M,asc 提供接口,对mc62进行区分,从原来的16M 变成1K,A5和A2大小不变。 3. 修改:算子侧tiling中硬编码为16M大小的workspacesize统一改为用接口获取。 GetLibApiWorkSpaceSize实现如下: const static uint32_t WORK_SPACE_SIZE_910B = 16 * 1024 * 1024; const static uint32_t WORK_SPACE_SIZE_950 = 16 * 1024 * 1024; const static uint32_t WORK_SPACE_SIZE = 1024; uint32_t PlatformAscendC::GetLibApiWorkSpaceSize(void) const { auto npuArch = GetCurNpuArch(); if (npuArch == NpuArch::DAV_RESV) { PF_LOGE("get platform failed, CurNpuArch is NpuArch::DAV_RESV"); return -1; } else if (npuArch == NpuArch::DAV_2201) { return WORK_SPACE_SIZE_910B; } else if (npuArch == NpuArch::DAV_3510) { return WORK_SPACE_SIZE_950; } return WORK_SPACE_SIZE; } ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5979 ## 测试 1.单算子框架测试通过 2.二级冒烟通过 文档更新 类型标签 - [x] Bug修复 See merge request: cann/ops-nn!10415 | 20 天前 | |
format cpp Co-authored-by: yang-di52<yangdi52@huawei.com> # message auto-generated for no-merge-commit merge: !6784 merge issue_fix into master format cpp Created-by: yang-di52 Commit-by: yang-di52 Merged-by: cann-robot Description: ## 描述 批量刷新cpp代码格式 ## 关联的Issue [#3791](https://gitcode.com/cann/ops-nn/issues/3791) ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他,请描述:代码格式化 ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!6784 | 3 个月前 | |
index: 支持动态shape(-1/-2/混合)推导并补充UT Co-authored-by: xuejinghui<xuejinghui@huawei.com> # message auto-generated for no-merge-commit merge: !10481 merge index_inferShape into master index: 支持动态shape(-1/-2/混合)推导并补充UT Created-by: xuejinghui Commit-by: xuejinghui Merged-by: cann-robot Description: ## 描述 index: 支持动态shape(-1/-2/混合)推导并补充UT <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5915 <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [x] AI辅助编写 See merge request: cann/ops-nn!10481 | 21 天前 | |
legacy下线:整改NN算子图模式注册与日志规范 Co-authored-by: zhouxuan78<zhouxuan78@huawei.com> # message auto-generated for no-merge-commit merge: !8388 merge master into master legacy下线:整改NN算子图模式注册与日志规范 Created-by: zhouxuan78 Commit-by: zhouxuan78 Merged-by: cann-robot Description: ## 描述 本 PR 用于 ops-nn 仓 Legacy 下线整改,补齐部分算子的直调/图模式注册、InferShape / InferDataType 拆分、日志规范整改及必要的编译/预提交问题修复。 1. 补齐多个算子的 op_graph 侧 InferDataType / graph infer 注册文件,并同步补充对应 CMakeLists.txt: - 如 FastGeluV2、HardShrinkGrad、HardSigmoidGrad、HardSwish、HardSwishGrad、Selu、SeluGrad、Shrink、SoftplusGrad、SoftplusV2、SoftplusV2Grad、Softsign、SoftsignGrad、SmoothL1Loss、SoftMarginLoss、LpNormUpdateV2、ApplyFtrlV2、ApplyMomentum、ApplyRMSProp 等。 2. 调整部分算子的 op_host infer 文件: - 将 InferDataType 逻辑从 infershape 文件中拆分/迁移到 op_graph 侧; - 保留 InferShape 逻辑,避免 shape/type 混在同一处注册; - 收敛 IndexCheck infershape 日志,仅保留入口日志。 3. 补充 SoftMarginLoss 图模式原型: - 新增 loss/soft_margin_loss/op_graph/soft_margin_loss_proto.h; - 新增 OPS_PROTO_DEF_SOFTMARGINLOSS 去重宏,避免重复注册; - 补充 SoftMarginLoss 的 op_graph/CMakeLists.txt 和 graph infer 注册。 4. 日志整改: - 为 Arch35 tiling 入口补充统一入口日志; - 对本 PR 修改范围内新增/调整的外部输入错误日志,按规范使用 OP_LOGE_FOR_INVALID_* 系列上报接口; - 收敛部分过多的 tiling / infershape 日志打印,避免循环或冗余打印。 5. 回退/收敛不属于本次整改范围的 Softshrink 重命名相关改动: - Softshrink -> SoftShrink 的命名调整不放在本 PR 中,后续单独 PR 处理。 6. 修复 pre-commit 格式问题: - 按仓库 .clang-format 修复格式; - 不修改 .pre-commit-config.yaml。 影响范围 主要影响 activation、index、loss、norm、optim、quant、vfusion 等目录下 Legacy 下线相关算子的 op_graph 注册、InferDataType 拆分、tiling 入口日志和错误日志规范。 ## 变更内容 ## 关联的Issue ## 测试 ## 文档更新 ## 类型标签 - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他:Legacy包下线整改 See merge request: cann/ops-nn!8388 | 29 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
format cpp Co-authored-by: yang-di52<yangdi52@huawei.com> # message auto-generated for no-merge-commit merge: !6784 merge issue_fix into master format cpp Created-by: yang-di52 Commit-by: yang-di52 Merged-by: cann-robot Description: ## 描述 批量刷新cpp代码格式 ## 关联的Issue [#3791](https://gitcode.com/cann/ops-nn/issues/3791) ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他,请描述:代码格式化 ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!6784 | 3 个月前 | |
aclnnIndexPutImpl非连续输入场景value广播修复 Co-authored-by: zyf0712<zhangyufei63@huawei.com> # message auto-generated for no-merge-commit merge: !10149 merge indexputBug into master aclnnIndexPutImpl非连续输入场景value广播修复 Created-by: zyf0712 Commit-by: zyf0712 Merged-by: cann-robot Description: ## 描述 修复aclnnIndexPutImpl算子非连续场景下value广播逻辑 ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5813 ## 测试 本地ST、冒烟均通过 ## 文档更新 不涉及 ## 类型标签 <!-- [x] 表示选中 --> - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10149 | 24 天前 | |
算子日志可读性与代码规范性的优化 Co-authored-by: xingtaowu<wuxingtao3@h-partners.com> # message auto-generated for no-merge-commit merge: !9376 merge fix_nn_log into master 算子日志可读性与代码规范性的优化 Created-by: xingtaowu Commit-by: xingtaowu Merged-by: cann-robot Description: ## 描述 批量修正日志/报错信息中的英文拼写错误与语法问题,并补充更明确的参数越界诊断信息,同时修正示例测试程序中的日志级别与代码格式问题。改动不涉及业务逻辑与算法流程变化,均为日志可读性与代码规范性的优化。 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5291 <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> ## 测试 冒烟通过 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ x] 其他,请描述:算子日志可读性与代码规范性的优化 ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!9376 | 1 个月前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
fix(cleancode): AICPU算子告警整改(第二批) Co-authored-by: liu-wei<lovline.liuwei@huawei.com> # message auto-generated for no-merge-commit merge: !10662 merge fix/warning-cleanup-v2 into master fix(cleancode): AICPU算子告警整改(第二批) Created-by: liu-wei Commit-by: liu-wei Merged-by: cann-robot Description: ## 描述 ops-nn AICPU算子告警整改第二批,修复3类告警。 ## 改动内容 - G.EXP.15: reinterpret_cast → PtrToPtr (scatter_nd_min/scatter_nd_max/sparse_segment_sum/sparse_to_dense/sparse_fill_empty_rows) - G.CLS.12: 析构函数加 override (index_to_addr) - G.RES.06: lambda默认捕获改为显式捕获 (scatter_nd_max/log_softmax_v2) ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5951 ## 测试 - pre-commit 全部 Passed - aicpu kernel UT: 80/80 PASSED - graph example: 7/7 success - eager example: log_softmax_v2 success ## 类型标签 - [x] ♻️ 重构 - [x] 🧹 代码清理 See merge request: cann/ops-nn!10662 | 20 天前 | |
test(inplace_add): consolidate TTK golden assets Co-authored-by: raoliang_sac<raoliang4@huawei.com> # message auto-generated for no-merge-commit merge: !10592 merge test/inplace-add-consolidate-golden into master test(inplace_add): consolidate TTK golden assets Created-by: raoliang_sac Commit-by: raoliang_sac Merged-by: cann-robot Description: See merge request: cann/ops-nn!10592 | 21 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
算子DVLite芯片适配 Co-authored-by: gcw_DS4cmz2b<1312925094@qq.com> # message auto-generated for no-merge-commit merge: !10012 merge DVLite into master 算子DVLite芯片适配 Created-by: gcw_DS4cmz2b Commit-by: gcw_DS4cmz2b Merged-by: cann-robot Description: ## 描述 repeat_interleave_grad和where等4个算子新增DVLite适配,where修改了fusion_pass融合规则,repeat_interleave_grad和cross_entropy_sum_exp_and_index_logit改成了新版的Cmakelists同时适配了DVLite芯片版本。 ## 关联的Issue [算子缺少350芯片适配](https://gitcode.com/cann/ops-nn/issues/5748) ## 测试 算子二级冒烟通过,aclnn通路验证通过 ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10012 | 27 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
docs: 补齐repeat_interleave与scatter_nd_update文档数据类型,统一index_add日志格式 Co-authored-by: AdogDboy<liuchenghao14@huawei.com> # message auto-generated for no-merge-commit merge: !10237 merge feat9_10 into master docs: 补齐repeat_interleave与scatter_nd_update文档数据类型,统一index_add日志格式 Created-by: AdogDboy Commit-by: AdogDboy Merged-by: cann-robot Description: 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> 本 PR 修复文档与代码实际支持的数据类型不一致问题,并统一 aclnnIndexAdd 报错日志格式。用户按文档使用文档中缺失的数据类型时,实际代码可以正常执行,文档与实现不一致。 改动内容: 1. aclnnRepeatInterleave / aclnnRepeatInterleaveInt / aclnnRepeatInterleaveIntWithDim / aclnnRepeatInterleaveWithDim 4 个接口文档:self/out 参数支持的数据类型从 9 种补齐为 12 种,新增 UINT16、UINT32、UINT64。代码依据:index/repeat_interleave/op_api/aclnn_repeat_interleave.cpp 中 ASCEND950_DTYPE_SUPPORT_LIST_SELF(Ascend 950 平台共支持 12 种类型),4 个变体接口共用同一 dtype 支持列表,且 out 强制与 self 类型一致。 2. aclnnScatterNdUpdate 接口文档:varRef/updates 参数补齐 UINT8。代码依据:index/scatter_nd_update/op_api/aclnn_scatter_nd_update.cpp 中 ASCEND950_DTYPE_DTYPE_SUPPORT_LIST,且代码要求 updates 与 varRef 数据类型一致。 3. aclnnIndexAdd:CheckDtypeValid 中 4 条 dtype 校验报错日志去掉支持列表的方括号,与仓库主流日志风格统一,仅日志文案调整,无逻辑改动。 平台说明:新增的 UINT16/UINT32/UINT64/UINT8 仅 Ascend 950PR/Ascend 950DT 系列产品支持(A2/A3 平台走各自的 dtype 支持列表,不含上述类型)。 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> [Documentation|文档反馈]: aclnnRepeatInterleave系列及aclnnScatterNdUpdate文档支持的数据类型与代码不一致 #5769 [Bug-Report|缺陷反馈]: aclnnIndexAdd dtype校验失败时日志打印变量与文案和实际校验对象不符 #5770 测试 <!--描述进行了哪些测试来验证你的改动。--> - 逐行对照 op_api 层代码的 dtype 支持列表核验文档描述(ASCEND950_DTYPE_SUPPORT_LIST_SELF / ASCEND950_DTYPE_DTYPE_SUPPORT_LIST); - git diff 确认改动范围:6 个文件、14 行(4 个 repeat_interleave 文档 self/out 行、scatter_nd_update 文档 varRef/updates 行、index_add 4 条日志字符串); - 文档改动不涉及功能逻辑;aclnn_index_add.cpp 仅修改日志字符串字面量,不影响编译产物行为; - 保留各文档所在分支基线的官方排版规范(中英文空格),无冲突标记残留。 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> - index/repeat_interleave/docs/aclnnRepeatInterleave.md(self/out 数据类型) - index/repeat_interleave/docs/aclnnRepeatInterleaveInt.md(self/out 数据类型) - index/repeat_interleave/docs/aclnnRepeatInterleaveIntWithDim.md(self/out 数据类型) - index/repeat_interleave/docs/aclnnRepeatInterleaveWithDim.md(self/out 数据类型) - index/scatter_nd_update/docs/aclnnScatterNdUpdate.md(varRef/updates 数据类型) 类型标签 <!-- [x] 表示选中 --> - Bug修复 - 新特性 - 性能优化 - 文档更新 - 其他,请描述: AI/Agent生成声明 <!-- [x] 表示选中 --> - AI辅助编写 See merge request: cann/ops-nn!10237 | 27 天前 | |
fix: ApplyAdagrad,HardSwishGradV2,HardSigmoid,InplaceSub检视意见闭环 Co-authored-by: tianyu52<tianyu52@huawei.com> # message auto-generated for no-merge-commit merge: !10724 merge master into master fix: ApplyAdagrad,HardSwishGradV2,HardSigmoid,InplaceSub检视意见闭环 Created-by: tianyu52 Commit-by: tianyu52 Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ApplyAdagrad,HardSwishGradV2,HardSigmoid,InplaceSub检视意见闭环 1.补充通路golden及测试用例 2.增加校验保护 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> ## 测试 <!--描述进行了哪些测试来验证你的改动。--> UT/ST 通路验证 PASS ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [x] AI辅助编写 See merge request: cann/ops-nn!10724 | 20 天前 | |
feat: 18个迁移算子适配unknown shape/rank InferShape并补UT及入口日志 Co-authored-by: xuejinghui<xuejinghui@huawei.com> # message auto-generated for no-merge-commit merge: !8821 merge InferShape into master feat: 18个迁移算子适配unknown shape/rank InferShape并补UT及入口日志 Created-by: xuejinghui Commit-by: xuejinghui Merged-by: cann-robot Description: ## 描述 18个迁移算子适配unknown shape/rank InferShape并补UT及入口日志 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5250 <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他,请描述:Unknown Shape/ Unknown Rank迁移适配 ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [x] AI辅助编写 See merge request: cann/ops-nn!8821 | 1 个月前 | |
fix(index): 修复 median、nan_median 和 kth_value 的 C++ codecheck 及接口问题 Co-authored-by: ConanHuang<huangxiaobin1@huawei.com> # message auto-generated for no-merge-commit merge: !10515 merge fix/median-kthvalue-codecheck into master fix(index): 修复 median、nan_median 和 kth_value 的 C++ codecheck 及接口问题 Created-by: ConanHuang Commit-by: ConanHuang Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> 修复 median、nan_median 和 kth_value 的 C++ codecheck 及接口问题: - 为只读 InferShape/Tiling context 参数补充 const; - 移除头文件冗余 include 和全局 using namespace,补充精确命名空间限定; - 增加维度合法性校验,并使用安全的有符号/无符号转换; - 修复 nan_median 标量分支对 ZerosLike 返回值的错误空指针校验; - 新增 aclnn_nan_median.h,将 aclnnNanMedian 和 aclnnNanMedianDim 两段式接口声明迁移到 nan_median 算子目录; - 在原 aclnn_median.h 中转发包含新头文件,保持已有调用代码的头文件兼容性,并同步更新实现、UT、示例和接口文档。 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> https://gitcode.com/cann/ops-nn/issues/5862 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> - 二级冒烟通过 - 四个aclnn接口各自抽取50个用例通过 ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> - 更新 aclnnNanMedian.md 和 aclnnNanMedianDim.md,示例改为包含 aclnnop/aclnn_nan_median.h。 ## 类型标签 <!-- [x] 表示选中 --> - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [x] AI辅助编写 See merge request: cann/ops-nn!10515 | 21 天前 | |
算子日志可读性与代码规范性的优化 Co-authored-by: xingtaowu<wuxingtao3@h-partners.com> # message auto-generated for no-merge-commit merge: !9376 merge fix_nn_log into master 算子日志可读性与代码规范性的优化 Created-by: xingtaowu Commit-by: xingtaowu Merged-by: cann-robot Description: ## 描述 批量修正日志/报错信息中的英文拼写错误与语法问题,并补充更明确的参数越界诊断信息,同时修正示例测试程序中的日志级别与代码格式问题。改动不涉及业务逻辑与算法流程变化,均为日志可读性与代码规范性的优化。 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5291 <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> ## 测试 冒烟通过 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ x] 其他,请描述:算子日志可读性与代码规范性的优化 ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!9376 | 1 个月前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
nn仓vector算子适配350平台 Co-authored-by: zhouliang<zhouliang88@huawei.com> # message auto-generated for no-merge-commit merge: !10004 merge master into master nn仓vector算子适配350平台 Created-by: zhou-liang1027 Commit-by: zhouliang Merged-by: cann-robot Description: ## 描述 p_relu等算子适配350平台 ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5755 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10004 | 28 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
fix: 修复文件重名问题 Co-authored-by: duxinlei<duxinlei@h-partners.com> # message auto-generated for no-merge-commit merge: !9675 merge checkRepeat2 into master fix: 修复文件重名问题 Created-by: duxinlei Commit-by: duxinlei Merged-by: cann-robot Description: ## 描述 解决单仓内和多仓间文件名重复问题, 1、对于将公共文件引入单算子目录的重命名问题,改引用公共目录下的文件 2、对于单纯重名问题,重命名 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> 关联issue #5460 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!9675 | 1 个月前 | |
md大模型检测低错修复 Co-authored-by: gitcode-chenjiao<chenjiao31@huawei.com> # message auto-generated for no-merge-commit merge: !9420 merge master into master md大模型检测低错修复 Created-by: gitcode-chenjiao Commit-by: gitcode-chenjiao Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> md aidd大模型检测低错修复 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> https://gitcode.com/cann/ops-nn/issues/5254 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ok ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> acl*.md ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!9420 | 1 个月前 | |
fix(index): 修复 median、nan_median 和 kth_value 的 C++ codecheck 及接口问题 Co-authored-by: ConanHuang<huangxiaobin1@huawei.com> # message auto-generated for no-merge-commit merge: !10515 merge fix/median-kthvalue-codecheck into master fix(index): 修复 median、nan_median 和 kth_value 的 C++ codecheck 及接口问题 Created-by: ConanHuang Commit-by: ConanHuang Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> 修复 median、nan_median 和 kth_value 的 C++ codecheck 及接口问题: - 为只读 InferShape/Tiling context 参数补充 const; - 移除头文件冗余 include 和全局 using namespace,补充精确命名空间限定; - 增加维度合法性校验,并使用安全的有符号/无符号转换; - 修复 nan_median 标量分支对 ZerosLike 返回值的错误空指针校验; - 新增 aclnn_nan_median.h,将 aclnnNanMedian 和 aclnnNanMedianDim 两段式接口声明迁移到 nan_median 算子目录; - 在原 aclnn_median.h 中转发包含新头文件,保持已有调用代码的头文件兼容性,并同步更新实现、UT、示例和接口文档。 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> https://gitcode.com/cann/ops-nn/issues/5862 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> - 二级冒烟通过 - 四个aclnn接口各自抽取50个用例通过 ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> - 更新 aclnnNanMedian.md 和 aclnnNanMedianDim.md,示例改为包含 aclnnop/aclnn_nan_median.h。 ## 类型标签 <!-- [x] 表示选中 --> - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [x] AI辅助编写 See merge request: cann/ops-nn!10515 | 21 天前 | |
format cpp Co-authored-by: yang-di52<yangdi52@huawei.com> # message auto-generated for no-merge-commit merge: !6784 merge issue_fix into master format cpp Created-by: yang-di52 Commit-by: yang-di52 Merged-by: cann-robot Description: ## 描述 批量刷新cpp代码格式 ## 关联的Issue [#3791](https://gitcode.com/cann/ops-nn/issues/3791) ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他,请描述:代码格式化 ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!6784 | 3 个月前 | |
fix(index): 修复 median、nan_median 和 kth_value 的 C++ codecheck 及接口问题 Co-authored-by: ConanHuang<huangxiaobin1@huawei.com> # message auto-generated for no-merge-commit merge: !10515 merge fix/median-kthvalue-codecheck into master fix(index): 修复 median、nan_median 和 kth_value 的 C++ codecheck 及接口问题 Created-by: ConanHuang Commit-by: ConanHuang Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> 修复 median、nan_median 和 kth_value 的 C++ codecheck 及接口问题: - 为只读 InferShape/Tiling context 参数补充 const; - 移除头文件冗余 include 和全局 using namespace,补充精确命名空间限定; - 增加维度合法性校验,并使用安全的有符号/无符号转换; - 修复 nan_median 标量分支对 ZerosLike 返回值的错误空指针校验; - 新增 aclnn_nan_median.h,将 aclnnNanMedian 和 aclnnNanMedianDim 两段式接口声明迁移到 nan_median 算子目录; - 在原 aclnn_median.h 中转发包含新头文件,保持已有调用代码的头文件兼容性,并同步更新实现、UT、示例和接口文档。 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> https://gitcode.com/cann/ops-nn/issues/5862 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> - 二级冒烟通过 - 四个aclnn接口各自抽取50个用例通过 ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> - 更新 aclnnNanMedian.md 和 aclnnNanMedianDim.md,示例改为包含 aclnnop/aclnn_nan_median.h。 ## 类型标签 <!-- [x] 表示选中 --> - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [x] AI辅助编写 See merge request: cann/ops-nn!10515 | 21 天前 | |
修改aclnnNonzero.md、aclnnNonzeroV2.md示例代码问题 Co-authored-by: rsj007<renshuojian@huawei.com> # message auto-generated for no-merge-commit merge: !10607 merge doc_bug into master 修改aclnnNonzero.md、aclnnNonzeroV2.md示例代码问题 Created-by: rsj007 Commit-by: rsj007 Merged-by: cann-robot Description: ## 描述 修改aclnnNonzero.md、aclnnNonzeroV2.md示例代码问题 ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5924 ## 测试 运行示例代码,冒烟 ## 文档更新 aclnnNonzero.md、aclnnNonzeroV2.md ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10607 | 20 天前 | |
fix(assets,index,loss): ScatterList 资料/校验、loss 检视整改、TTK spec 适配、tf 三方腿与三方精度修正 Co-authored-by: tangpingchuan<tangpingchuan@huawei.com> # message auto-generated for no-merge-commit merge: !9870 merge fix/ttk-golden-tf-third-party into master fix(assets,index,loss): ScatterList 资料/校验、loss 检视整改、TTK spec 适配、tf 三方腿与三方精度修正 Created-by: zl_hw Commit-by: tangpingchuan Merged-by: cann-robot Description: ### 当前PR是否有AI参与: [x] 否 [ ] 是 __1. AI Agent 平台: __2. AI 模型: __3. Prompt上下文 : ## 描述 补齐foreach类、scatter类及lamb类算子的tf等通路三方 ## 关联的Issue NA ## 测试 st ## 文档更新 不涉及 ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!9870 | 1 个月前 | |
feat(aicpu): enable constant folding for migrated ops Co-authored-by: hid29204727<wangboyu20@huawei.com> # message auto-generated for no-merge-commit merge: !9280 merge codex/aicpu-const-folding into master feat(aicpu): enable constant folding for migrated ops Created-by: hid29204727 Commit-by: hid29204727 Merged-by: cann-robot Description: ## 描述 补充 ops-nn 仓 AICPU host 常量折叠注册通路,并为当前已标记 OPEN_OPS_FLAG 的 18 个迁移算子统一开启常量折叠支持。 主要改动: - 新增仓级 OPS_NN_REGISTER_CPU_KERNELV2 注册包装宏,host 构建优先注册 V2,device/custom/UT 保持 V1 回退。 - 为 add_modules_sources 和 add_all_modules_sources 增加 HOSTCPU 参数及 host OBJECT 收集逻辑。 - 为 18 个 OPEN_OPS_FLAG 算子补充 HOSTCPU TRUE、注册头文件和 V2 注册。 - host OBJECT 汇入 libopconstant_folding_nn.so。 ## 关联的Issue 无。 ## 测试 已完成以下静态验证: - git diff --check 通过。 - 18 个 OPEN_OPS_FLAG 算子均具备 HOSTCPU TRUE。 - 18 个算子均使用 OPS_NN_REGISTER_CPU_KERNELV2,无直接 V1 注册残留。 - 注册头文件、host 编译宏和仓级 so 收集通路检查通过。 当前 Windows 环境缺少 CANN、NPU、CMake 和远端构建桥,未执行 bash build.sh --pkg -j16;完整打包构建及常量折叠功能验证待 CANN Linux 环境/CI 完成。 ## 文档更新 无仓内文档变更。 ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [x] AI辅助编写 See merge request: cann/ops-nn!9280 | 20 天前 | |
feat(aicpu): enable constant folding for migrated ops Co-authored-by: hid29204727<wangboyu20@huawei.com> # message auto-generated for no-merge-commit merge: !9280 merge codex/aicpu-const-folding into master feat(aicpu): enable constant folding for migrated ops Created-by: hid29204727 Commit-by: hid29204727 Merged-by: cann-robot Description: ## 描述 补充 ops-nn 仓 AICPU host 常量折叠注册通路,并为当前已标记 OPEN_OPS_FLAG 的 18 个迁移算子统一开启常量折叠支持。 主要改动: - 新增仓级 OPS_NN_REGISTER_CPU_KERNELV2 注册包装宏,host 构建优先注册 V2,device/custom/UT 保持 V1 回退。 - 为 add_modules_sources 和 add_all_modules_sources 增加 HOSTCPU 参数及 host OBJECT 收集逻辑。 - 为 18 个 OPEN_OPS_FLAG 算子补充 HOSTCPU TRUE、注册头文件和 V2 注册。 - host OBJECT 汇入 libopconstant_folding_nn.so。 ## 关联的Issue 无。 ## 测试 已完成以下静态验证: - git diff --check 通过。 - 18 个 OPEN_OPS_FLAG 算子均具备 HOSTCPU TRUE。 - 18 个算子均使用 OPS_NN_REGISTER_CPU_KERNELV2,无直接 V1 注册残留。 - 注册头文件、host 编译宏和仓级 so 收集通路检查通过。 当前 Windows 环境缺少 CANN、NPU、CMake 和远端构建桥,未执行 bash build.sh --pkg -j16;完整打包构建及常量折叠功能验证待 CANN Linux 环境/CI 完成。 ## 文档更新 无仓内文档变更。 ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [x] AI辅助编写 See merge request: cann/ops-nn!9280 | 20 天前 | |
nn仓vector算子适配350平台 Co-authored-by: zhouliang<zhouliang88@huawei.com> # message auto-generated for no-merge-commit merge: !10004 merge master into master nn仓vector算子适配350平台 Created-by: zhou-liang1027 Commit-by: zhouliang Merged-by: cann-robot Description: ## 描述 p_relu等算子适配350平台 ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5755 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10004 | 28 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
算子DVLite芯片适配 Co-authored-by: gcw_DS4cmz2b<1312925094@qq.com> # message auto-generated for no-merge-commit merge: !10012 merge DVLite into master 算子DVLite芯片适配 Created-by: gcw_DS4cmz2b Commit-by: gcw_DS4cmz2b Merged-by: cann-robot Description: ## 描述 repeat_interleave_grad和where等4个算子新增DVLite适配,where修改了fusion_pass融合规则,repeat_interleave_grad和cross_entropy_sum_exp_and_index_logit改成了新版的Cmakelists同时适配了DVLite芯片版本。 ## 关联的Issue [算子缺少350芯片适配](https://gitcode.com/cann/ops-nn/issues/5748) ## 测试 算子二级冒烟通过,aclnn通路验证通过 ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10012 | 27 天前 | |
feat(aicpu): enable constant folding for migrated ops Co-authored-by: hid29204727<wangboyu20@huawei.com> # message auto-generated for no-merge-commit merge: !9280 merge codex/aicpu-const-folding into master feat(aicpu): enable constant folding for migrated ops Created-by: hid29204727 Commit-by: hid29204727 Merged-by: cann-robot Description: ## 描述 补充 ops-nn 仓 AICPU host 常量折叠注册通路,并为当前已标记 OPEN_OPS_FLAG 的 18 个迁移算子统一开启常量折叠支持。 主要改动: - 新增仓级 OPS_NN_REGISTER_CPU_KERNELV2 注册包装宏,host 构建优先注册 V2,device/custom/UT 保持 V1 回退。 - 为 add_modules_sources 和 add_all_modules_sources 增加 HOSTCPU 参数及 host OBJECT 收集逻辑。 - 为 18 个 OPEN_OPS_FLAG 算子补充 HOSTCPU TRUE、注册头文件和 V2 注册。 - host OBJECT 汇入 libopconstant_folding_nn.so。 ## 关联的Issue 无。 ## 测试 已完成以下静态验证: - git diff --check 通过。 - 18 个 OPEN_OPS_FLAG 算子均具备 HOSTCPU TRUE。 - 18 个算子均使用 OPS_NN_REGISTER_CPU_KERNELV2,无直接 V1 注册残留。 - 注册头文件、host 编译宏和仓级 so 收集通路检查通过。 当前 Windows 环境缺少 CANN、NPU、CMake 和远端构建桥,未执行 bash build.sh --pkg -j16;完整打包构建及常量折叠功能验证待 CANN Linux 环境/CI 完成。 ## 文档更新 无仓内文档变更。 ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [x] AI辅助编写 See merge request: cann/ops-nn!9280 | 20 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
ScatterMul/Div/Max/Min 排序路径改直排 int64 key,消除 var 首维能力上限 Co-authored-by: tangpingchuan<tangpingchuan@huawei.com> # message auto-generated for no-merge-commit merge: !10655 merge feat/scatter-int64-index into master ScatterMul/Div/Max/Min 排序路径改直排 int64 key,消除 var 首维能力上限 Created-by: zl_hw Commit-by: tangpingchuan Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10655 | 20 天前 | |
feat(aicpu): enable constant folding for migrated ops Co-authored-by: hid29204727<wangboyu20@huawei.com> # message auto-generated for no-merge-commit merge: !9280 merge codex/aicpu-const-folding into master feat(aicpu): enable constant folding for migrated ops Created-by: hid29204727 Commit-by: hid29204727 Merged-by: cann-robot Description: ## 描述 补充 ops-nn 仓 AICPU host 常量折叠注册通路,并为当前已标记 OPEN_OPS_FLAG 的 18 个迁移算子统一开启常量折叠支持。 主要改动: - 新增仓级 OPS_NN_REGISTER_CPU_KERNELV2 注册包装宏,host 构建优先注册 V2,device/custom/UT 保持 V1 回退。 - 为 add_modules_sources 和 add_all_modules_sources 增加 HOSTCPU 参数及 host OBJECT 收集逻辑。 - 为 18 个 OPEN_OPS_FLAG 算子补充 HOSTCPU TRUE、注册头文件和 V2 注册。 - host OBJECT 汇入 libopconstant_folding_nn.so。 ## 关联的Issue 无。 ## 测试 已完成以下静态验证: - git diff --check 通过。 - 18 个 OPEN_OPS_FLAG 算子均具备 HOSTCPU TRUE。 - 18 个算子均使用 OPS_NN_REGISTER_CPU_KERNELV2,无直接 V1 注册残留。 - 注册头文件、host 编译宏和仓级 so 收集通路检查通过。 当前 Windows 环境缺少 CANN、NPU、CMake 和远端构建桥,未执行 bash build.sh --pkg -j16;完整打包构建及常量折叠功能验证待 CANN Linux 环境/CI 完成。 ## 文档更新 无仓内文档变更。 ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [x] AI辅助编写 See merge request: cann/ops-nn!9280 | 20 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
[Test] 补充 ScatterListTorchSpec 的 torch 三方标杆注册 Co-authored-by: chendunyang<chendunyang1@huawei.com> # message auto-generated for no-merge-commit merge: !10238 merge fix/scatter-list-torch-third-party into master [Test] 补充 ScatterListTorchSpec 的 torch 三方标杆注册 Created-by: qq_37913898 Commit-by: chendunyang Merged-by: cann-robot Description: ## 问题 ScatterListTorchSpec 缺少 third_party 注册,E2E 三方比对无法从该 Spec 获取 torch 组合实现。 ## 修改 - 补充 third_party = {"torch": _Compose}。 - 新增最小参数名适配,将 Torch API 的 input/indices/updates 转交现有 _ScatterListCompose,mask、axis 等参数原样透传。 - 不修改现有计算逻辑、CPU golden、Kernel/ACLNN 注册或精度标准。仅修改 index/scatter_list/tests/assets/golden.py,新增 5 行。 ## 验证 - 使用真实 TTK get_spec_attr 成功加载 torch_npu.npu_scatter_list 的 third_party。 See merge request: cann/ops-nn!10238 | 28 天前 | |
ScatterMul/Div/Max/Min 排序路径改直排 int64 key,消除 var 首维能力上限 Co-authored-by: tangpingchuan<tangpingchuan@huawei.com> # message auto-generated for no-merge-commit merge: !10655 merge feat/scatter-int64-index into master ScatterMul/Div/Max/Min 排序路径改直排 int64 key,消除 var 首维能力上限 Created-by: zl_hw Commit-by: tangpingchuan Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10655 | 20 天前 | |
feat: 18个迁移算子适配unknown shape/rank InferShape并补UT及入口日志 Co-authored-by: xuejinghui<xuejinghui@huawei.com> # message auto-generated for no-merge-commit merge: !8821 merge InferShape into master feat: 18个迁移算子适配unknown shape/rank InferShape并补UT及入口日志 Created-by: xuejinghui Commit-by: xuejinghui Merged-by: cann-robot Description: ## 描述 18个迁移算子适配unknown shape/rank InferShape并补UT及入口日志 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5250 <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他,请描述:Unknown Shape/ Unknown Rank迁移适配 ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [x] AI辅助编写 See merge request: cann/ops-nn!8821 | 1 个月前 | |
ScatterMul/Div/Max/Min 排序路径改直排 int64 key,消除 var 首维能力上限 Co-authored-by: tangpingchuan<tangpingchuan@huawei.com> # message auto-generated for no-merge-commit merge: !10655 merge feat/scatter-int64-index into master ScatterMul/Div/Max/Min 排序路径改直排 int64 key,消除 var 首维能力上限 Created-by: zl_hw Commit-by: tangpingchuan Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10655 | 20 天前 | |
ScatterMul/Div/Max/Min 排序路径改直排 int64 key,消除 var 首维能力上限 Co-authored-by: tangpingchuan<tangpingchuan@huawei.com> # message auto-generated for no-merge-commit merge: !10655 merge feat/scatter-int64-index into master ScatterMul/Div/Max/Min 排序路径改直排 int64 key,消除 var 首维能力上限 Created-by: zl_hw Commit-by: tangpingchuan Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10655 | 20 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
fix(cleancode): AICPU算子告警整改(第二批) Co-authored-by: liu-wei<lovline.liuwei@huawei.com> # message auto-generated for no-merge-commit merge: !10662 merge fix/warning-cleanup-v2 into master fix(cleancode): AICPU算子告警整改(第二批) Created-by: liu-wei Commit-by: liu-wei Merged-by: cann-robot Description: ## 描述 ops-nn AICPU算子告警整改第二批,修复3类告警。 ## 改动内容 - G.EXP.15: reinterpret_cast → PtrToPtr (scatter_nd_min/scatter_nd_max/sparse_segment_sum/sparse_to_dense/sparse_fill_empty_rows) - G.CLS.12: 析构函数加 override (index_to_addr) - G.RES.06: lambda默认捕获改为显式捕获 (scatter_nd_max/log_softmax_v2) ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5951 ## 测试 - pre-commit 全部 Passed - aicpu kernel UT: 80/80 PASSED - graph example: 7/7 success - eager example: log_softmax_v2 success ## 类型标签 - [x] ♻️ 重构 - [x] 🧹 代码清理 See merge request: cann/ops-nn!10662 | 20 天前 | |
fix(cleancode): AICPU算子告警整改(第二批) Co-authored-by: liu-wei<lovline.liuwei@huawei.com> # message auto-generated for no-merge-commit merge: !10662 merge fix/warning-cleanup-v2 into master fix(cleancode): AICPU算子告警整改(第二批) Created-by: liu-wei Commit-by: liu-wei Merged-by: cann-robot Description: ## 描述 ops-nn AICPU算子告警整改第二批,修复3类告警。 ## 改动内容 - G.EXP.15: reinterpret_cast → PtrToPtr (scatter_nd_min/scatter_nd_max/sparse_segment_sum/sparse_to_dense/sparse_fill_empty_rows) - G.CLS.12: 析构函数加 override (index_to_addr) - G.RES.06: lambda默认捕获改为显式捕获 (scatter_nd_max/log_softmax_v2) ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5951 ## 测试 - pre-commit 全部 Passed - aicpu kernel UT: 80/80 PASSED - graph example: 7/7 success - eager example: log_softmax_v2 success ## 类型标签 - [x] ♻️ 重构 - [x] 🧹 代码清理 See merge request: cann/ops-nn!10662 | 20 天前 | |
feat(scatter_nd_sub): indices支持1D(单条深度K索引),与A2语义对齐 Co-authored-by: aiteer<lujiale4@huawei.com> # message auto-generated for no-merge-commit merge: !10563 merge scatterndsub_916 into master feat(scatter_nd_sub): indices支持1D(单条深度K索引),与A2语义对齐 Created-by: aiteer Commit-by: aiteer Merged-by: cann-robot Description: ## 描述 ScatterNdSub 算子 A5(ascend950/arch35)host 侧 tiling 强制要求 indices rank ≥ 2,与 A2 不兼容,本修改支持indices 1D(单条深度K索引),与A2语义对齐。 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> [#5980](https://gitcode.com/cann/ops-nn/issues/5980) ## 测试 ut测试,根据问题单用例进行ttk测试 ## 文档更新 更新scatter_nd_sub算子README.md,支持一维indices。 ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10563 | 20 天前 | |
TensorScatterUpdate Add CheckNodeSupportOnAicore Co-authored-by: lihang_13123<lihang106@h-partners.com> # message auto-generated for no-merge-commit merge: !10540 merge scatter_add into master TensorScatterUpdate Add CheckNodeSupportOnAicore Created-by: lihang_13123 Commit-by: lihang_13123 Merged-by: cann-robot Description: ## 描述 TensorScatterUpdate 融合规则预期需校验当前输入是否被ScatterNdUpdate算子支持,不支持需回退到aicpu。nn仓当前融合规则缺少此校验,会导致ScatterNdUpdate aicore算子不支持的输入走进aicore导致功能报错。因此需增加校验。 ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5892 ## 测试 验证OK,冒烟OK ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10540 | 20 天前 | |
feat: 18个迁移算子适配unknown shape/rank InferShape并补UT及入口日志 Co-authored-by: xuejinghui<xuejinghui@huawei.com> # message auto-generated for no-merge-commit merge: !8821 merge InferShape into master feat: 18个迁移算子适配unknown shape/rank InferShape并补UT及入口日志 Created-by: xuejinghui Commit-by: xuejinghui Merged-by: cann-robot Description: ## 描述 18个迁移算子适配unknown shape/rank InferShape并补UT及入口日志 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5250 <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他,请描述:Unknown Shape/ Unknown Rank迁移适配 ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [x] AI辅助编写 See merge request: cann/ops-nn!8821 | 1 个月前 | |
ScatterMul/Div/Max/Min 排序路径改直排 int64 key,消除 var 首维能力上限 Co-authored-by: tangpingchuan<tangpingchuan@huawei.com> # message auto-generated for no-merge-commit merge: !10655 merge feat/scatter-int64-index into master ScatterMul/Div/Max/Min 排序路径改直排 int64 key,消除 var 首维能力上限 Created-by: zl_hw Commit-by: tangpingchuan Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10655 | 20 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
确定性计算中搬出时同时写某一行时要加搬出同步,因为指令发射是同步的,但是实际搬运并不是同步的。 Co-authored-by: xiaodong666<yuanxiaodong6@huawei.com> # message auto-generated for no-merge-commit merge: !10642 merge fix_mte3sync_bug into master 确定性计算中搬出时同时写某一行时要加搬出同步,因为指令发射是同步的,但是实际搬运并不是同步的。 Created-by: xiaodong666 Commit-by: xiaodong666 Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> 确定性计算中搬出时同时写某一行时要加搬出同步,因为指令发射是同步的,但是实际搬运并不是同步的。 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> 关联Issue [#5941](https://gitcode.com/cann/ops-nn/issues/5941) ## 测试 <!--描述进行了哪些测试来验证你的改动。--> 批跑st用例、冒烟通过 ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> NA ## 类型标签 <!-- [x] 表示选中 --> - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [x] AI辅助编写 See merge request: cann/ops-nn!10642 | 20 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
fix(cleancode): AICPU算子告警整改(第二批) Co-authored-by: liu-wei<lovline.liuwei@huawei.com> # message auto-generated for no-merge-commit merge: !10662 merge fix/warning-cleanup-v2 into master fix(cleancode): AICPU算子告警整改(第二批) Created-by: liu-wei Commit-by: liu-wei Merged-by: cann-robot Description: ## 描述 ops-nn AICPU算子告警整改第二批,修复3类告警。 ## 改动内容 - G.EXP.15: reinterpret_cast → PtrToPtr (scatter_nd_min/scatter_nd_max/sparse_segment_sum/sparse_to_dense/sparse_fill_empty_rows) - G.CLS.12: 析构函数加 override (index_to_addr) - G.RES.06: lambda默认捕获改为显式捕获 (scatter_nd_max/log_softmax_v2) ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5951 ## 测试 - pre-commit 全部 Passed - aicpu kernel UT: 80/80 PASSED - graph example: 7/7 success - eager example: log_softmax_v2 success ## 类型标签 - [x] ♻️ 重构 - [x] 🧹 代码清理 See merge request: cann/ops-nn!10662 | 20 天前 | |
feat(aicpu): enable constant folding for migrated ops Co-authored-by: hid29204727<wangboyu20@huawei.com> # message auto-generated for no-merge-commit merge: !9280 merge codex/aicpu-const-folding into master feat(aicpu): enable constant folding for migrated ops Created-by: hid29204727 Commit-by: hid29204727 Merged-by: cann-robot Description: ## 描述 补充 ops-nn 仓 AICPU host 常量折叠注册通路,并为当前已标记 OPEN_OPS_FLAG 的 18 个迁移算子统一开启常量折叠支持。 主要改动: - 新增仓级 OPS_NN_REGISTER_CPU_KERNELV2 注册包装宏,host 构建优先注册 V2,device/custom/UT 保持 V1 回退。 - 为 add_modules_sources 和 add_all_modules_sources 增加 HOSTCPU 参数及 host OBJECT 收集逻辑。 - 为 18 个 OPEN_OPS_FLAG 算子补充 HOSTCPU TRUE、注册头文件和 V2 注册。 - host OBJECT 汇入 libopconstant_folding_nn.so。 ## 关联的Issue 无。 ## 测试 已完成以下静态验证: - git diff --check 通过。 - 18 个 OPEN_OPS_FLAG 算子均具备 HOSTCPU TRUE。 - 18 个算子均使用 OPS_NN_REGISTER_CPU_KERNELV2,无直接 V1 注册残留。 - 注册头文件、host 编译宏和仓级 so 收集通路检查通过。 当前 Windows 环境缺少 CANN、NPU、CMake 和远端构建桥,未执行 bash build.sh --pkg -j16;完整打包构建及常量折叠功能验证待 CANN Linux 环境/CI 完成。 ## 文档更新 无仓内文档变更。 ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [x] AI辅助编写 See merge request: cann/ops-nn!9280 | 20 天前 | |
feat(aicpu): enable constant folding for migrated ops Co-authored-by: hid29204727<wangboyu20@huawei.com> # message auto-generated for no-merge-commit merge: !9280 merge codex/aicpu-const-folding into master feat(aicpu): enable constant folding for migrated ops Created-by: hid29204727 Commit-by: hid29204727 Merged-by: cann-robot Description: ## 描述 补充 ops-nn 仓 AICPU host 常量折叠注册通路,并为当前已标记 OPEN_OPS_FLAG 的 18 个迁移算子统一开启常量折叠支持。 主要改动: - 新增仓级 OPS_NN_REGISTER_CPU_KERNELV2 注册包装宏,host 构建优先注册 V2,device/custom/UT 保持 V1 回退。 - 为 add_modules_sources 和 add_all_modules_sources 增加 HOSTCPU 参数及 host OBJECT 收集逻辑。 - 为 18 个 OPEN_OPS_FLAG 算子补充 HOSTCPU TRUE、注册头文件和 V2 注册。 - host OBJECT 汇入 libopconstant_folding_nn.so。 ## 关联的Issue 无。 ## 测试 已完成以下静态验证: - git diff --check 通过。 - 18 个 OPEN_OPS_FLAG 算子均具备 HOSTCPU TRUE。 - 18 个算子均使用 OPS_NN_REGISTER_CPU_KERNELV2,无直接 V1 注册残留。 - 注册头文件、host 编译宏和仓级 so 收集通路检查通过。 当前 Windows 环境缺少 CANN、NPU、CMake 和远端构建桥,未执行 bash build.sh --pkg -j16;完整打包构建及常量折叠功能验证待 CANN Linux 环境/CI 完成。 ## 文档更新 无仓内文档变更。 ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [x] AI辅助编写 See merge request: cann/ops-nn!9280 | 20 天前 | |
fix(cleancode): AICPU算子告警整改(第二批) Co-authored-by: liu-wei<lovline.liuwei@huawei.com> # message auto-generated for no-merge-commit merge: !10662 merge fix/warning-cleanup-v2 into master fix(cleancode): AICPU算子告警整改(第二批) Created-by: liu-wei Commit-by: liu-wei Merged-by: cann-robot Description: ## 描述 ops-nn AICPU算子告警整改第二批,修复3类告警。 ## 改动内容 - G.EXP.15: reinterpret_cast → PtrToPtr (scatter_nd_min/scatter_nd_max/sparse_segment_sum/sparse_to_dense/sparse_fill_empty_rows) - G.CLS.12: 析构函数加 override (index_to_addr) - G.RES.06: lambda默认捕获改为显式捕获 (scatter_nd_max/log_softmax_v2) ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5951 ## 测试 - pre-commit 全部 Passed - aicpu kernel UT: 80/80 PASSED - graph example: 7/7 success - eager example: log_softmax_v2 success ## 类型标签 - [x] ♻️ 重构 - [x] 🧹 代码清理 See merge request: cann/ops-nn!10662 | 20 天前 | |
修改SparseSegmentSumGrad、Dilation2D infershape并增加对应UT Co-authored-by: wang-shilong32<wangshilong23@huawei.com> # message auto-generated for no-merge-commit merge: !8931 merge fix_dilation_sparse_infer into master 修改SparseSegmentSumGrad、Dilation2D infershape并增加对应UT Created-by: wang-shilong32 Commit-by: wang-shilong32 Merged-by: cann-robot Description: ## 描述 修改SparseSegmentSumGrad、Dilation2D infershape -1/-2场景 并增加对应UT <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> https://gitcode.com/cann/ops-nn/issues/4950 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> 本地验证对应UT用例,出包验证,冒烟测试。 ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!8931 | 1 个月前 | |
nn仓vector算子适配350平台 Co-authored-by: zhouliang<zhouliang88@huawei.com> # message auto-generated for no-merge-commit merge: !10004 merge master into master nn仓vector算子适配350平台 Created-by: zhou-liang1027 Commit-by: zhouliang Merged-by: cann-robot Description: ## 描述 p_relu等算子适配350平台 ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5755 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10004 | 28 天前 | |
fix(cleancode): AICPU算子告警整改(第二批) Co-authored-by: liu-wei<lovline.liuwei@huawei.com> # message auto-generated for no-merge-commit merge: !10662 merge fix/warning-cleanup-v2 into master fix(cleancode): AICPU算子告警整改(第二批) Created-by: liu-wei Commit-by: liu-wei Merged-by: cann-robot Description: ## 描述 ops-nn AICPU算子告警整改第二批,修复3类告警。 ## 改动内容 - G.EXP.15: reinterpret_cast → PtrToPtr (scatter_nd_min/scatter_nd_max/sparse_segment_sum/sparse_to_dense/sparse_fill_empty_rows) - G.CLS.12: 析构函数加 override (index_to_addr) - G.RES.06: lambda默认捕获改为显式捕获 (scatter_nd_max/log_softmax_v2) ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5951 ## 测试 - pre-commit 全部 Passed - aicpu kernel UT: 80/80 PASSED - graph example: 7/7 success - eager example: log_softmax_v2 success ## 类型标签 - [x] ♻️ 重构 - [x] 🧹 代码清理 See merge request: cann/ops-nn!10662 | 20 天前 | |
feat(aicpu): enable constant folding for migrated ops Co-authored-by: hid29204727<wangboyu20@huawei.com> # message auto-generated for no-merge-commit merge: !9280 merge codex/aicpu-const-folding into master feat(aicpu): enable constant folding for migrated ops Created-by: hid29204727 Commit-by: hid29204727 Merged-by: cann-robot Description: ## 描述 补充 ops-nn 仓 AICPU host 常量折叠注册通路,并为当前已标记 OPEN_OPS_FLAG 的 18 个迁移算子统一开启常量折叠支持。 主要改动: - 新增仓级 OPS_NN_REGISTER_CPU_KERNELV2 注册包装宏,host 构建优先注册 V2,device/custom/UT 保持 V1 回退。 - 为 add_modules_sources 和 add_all_modules_sources 增加 HOSTCPU 参数及 host OBJECT 收集逻辑。 - 为 18 个 OPEN_OPS_FLAG 算子补充 HOSTCPU TRUE、注册头文件和 V2 注册。 - host OBJECT 汇入 libopconstant_folding_nn.so。 ## 关联的Issue 无。 ## 测试 已完成以下静态验证: - git diff --check 通过。 - 18 个 OPEN_OPS_FLAG 算子均具备 HOSTCPU TRUE。 - 18 个算子均使用 OPS_NN_REGISTER_CPU_KERNELV2,无直接 V1 注册残留。 - 注册头文件、host 编译宏和仓级 so 收集通路检查通过。 当前 Windows 环境缺少 CANN、NPU、CMake 和远端构建桥,未执行 bash build.sh --pkg -j16;完整打包构建及常量折叠功能验证待 CANN Linux 环境/CI 完成。 ## 文档更新 无仓内文档变更。 ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [x] AI辅助编写 See merge request: cann/ops-nn!9280 | 20 天前 | |
修改aclnn文档示例代码问题 Co-authored-by: lihang_13123<lihang106@h-partners.com> # message auto-generated for no-merge-commit merge: !9489 merge scatter_add into master 修改aclnn文档示例代码问题 Created-by: lihang_13123 Commit-by: lihang_13123 Merged-by: cann-robot Description: ## 描述 修改aclnnTfScatterAdd.md文档示例代码问题 ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5326 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 aclnnScatterAdd.md和aclnnTfScatterAdd.md ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!9489 | 1 个月前 | |
Fix top_k_top_p_sample docs and example Co-authored-by: licheng261<licheng261@huawei.com> # message auto-generated for no-merge-commit merge: !9906 merge top_k_top_p_sample_doc_0904 into master Fix top_k_top_p_sample docs and example Created-by: licheng261 Commit-by: licheng261 Merged-by: cann-robot Description: ## 描述 修复top_k_top_p_sample文档和示例代码,保持一致 ## 关联的Issue [#5591](https://gitcode.com/cann/ops-nn/issues/5591) ## 测试 ## 文档更新 ops-nn/index/top_k_top_p_sample/docs/aclnnTopKTopPSample.md ops-nn/index/top_k_top_p_sample/examples/test_aclnn_top_k_top_p_sample.cpp ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!9906 | 1 个月前 | |
修复aclnnTopKTopPSampleV2文档示例代码与参数表不一致问题 Co-authored-by: 陈赵旻熠<chenzhaominyi1@huawei.com> # message auto-generated for no-merge-commit merge: !10065 merge master into master 修复aclnnTopKTopPSampleV2文档示例代码与参数表不一致问题 Created-by: zerosaki_admin Commit-by: 陈赵旻熠 Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> 修复aclnnTopKTopPSampleV2文档示例代码与参数表不一致问题 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> [#5681](https://gitcode.com/cann/ops-nn/issues/5681) ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> 更新了aclnnTopKTopPSampleV2文档 ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10065 | 30 天前 | |
refactor(unique): 清理冗余测试 CMake 配置 Co-authored-by: yourealize<chenzhanxi1@huawei.com> # message auto-generated for no-merge-commit merge: !10421 merge codex/unique-top-level-cmake-cleanup into master refactor(unique): 清理冗余测试 CMake 配置 Created-by: yourealize Commit-by: yourealize Merged-by: cann-robot Description: ## 描述 PR #10273 将 aclnnUnique/Unique2 迁移到独立目录后,新增检视意见指出:算子顶层配置 CMake 后,tests 目录不需要重复配置。 本 PR 将 index/unique/CMakeLists.txt 切换为 add_all_modules_sources 统一入口,由顶层直接收集生产源码及 tests/ut/op_host 下的 UT 源,并删除 tests 目录下三份冗余 CMakeLists.txt。接口行为和计算逻辑不变。 ## 关联的Issue [#5427](https://gitcode.com/cann/ops-nn/issues/5427) ## 测试 - pre-commit run --from-ref upstream/master --to-ref HEAD:通过。 - bash build.sh -u --opapi --ops=unique --ut_mode=fast -j8:通过。 - Unique/Unique2 OpApi UT:16/16 通过。 - 构建日志确认 test_aclnn_unique.cpp 和 test_aclnn_unique2.cpp 由顶层统一入口正确收集。 ## 文档更新 无文档更新。 ## 类型标签 - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他,请描述:构建配置清理 ## AI/Agent生成声明 - [x] AI辅助编写 See merge request: cann/ops-nn!10421 | 23 天前 | |
refactor(unique): 将全局去重接口迁移到独立目录 Co-authored-by: yourealize<chenzhanxi1@huawei.com> # message auto-generated for no-merge-commit merge: !10273 merge codex/unique-api-independent-dir into master refactor(unique): 将全局去重接口迁移到独立目录 Created-by: yourealize Commit-by: yourealize Merged-by: cann-robot Description: ## 描述 aclnnUnique/Unique2 提供全局去重,当前与连续去重算子 UniqueConsecutive 放在同一目录。将两个接口及其共享实现 unique_common 迁移至独立的 index/unique/op_api,由该模块管理 AI Core 组合路径和 AI CPU 回退依赖。 同步迁移文档、示例、ST 和 UT,补齐独立模块的构建和测试入口,更新接口索引和分类路径。UniqueConsecutive 接口、L0 和 Kernel 保留原目录。15 个迁移文件内容完全不变,不调整接口行为和计算逻辑。 ## 关联的Issue [#5427](https://gitcode.com/cann/ops-nn/issues/5427) ## 测试 - git diff --check 通过。 - 15 个迁移文件与基线 Git blob 哈希一致。 - 迁移旧路径无残留,迁移文档的本地链接及 UT 相对 include 检查通过。 - 已静态核对模块源码收集、头文件导出及 UT 注册入口。 - 本机无可用 CANN 编译环境,未运行编译、UT 或设备测试。 ## 文档更新 新增 index/unique/README.md,迁移 aclnnUnique/Unique2 文档与示例,更新接口菜单及列表。 ## 类型标签 - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [x] 其他,请描述:目录结构调整 ## AI/Agent生成声明 - [x] AI辅助编写 See merge request: cann/ops-nn!10273 | 24 天前 | |
将卷积和matmul的ut根据版本隔离开, 整改950 ophost ut Co-authored-by: 18811725231<yangdi52@huawei.com> # message auto-generated for no-merge-commit merge: !9549 merge master into master 将卷积和matmul的ut根据版本隔离开, 整改950 ophost ut Created-by: yang-di52 Commit-by: 18811725231 Merged-by: cann-robot Description: ## 描述 主要修改内容: 1. nn仓完成和legacy common 动态库解耦后,卷积和matmul的不同版本 ophost ut 已经不能混合一起跑了。需要版本隔离 2. ascend950的ut全量编译 失败,需要修改 ## 关联的Issue [https://gitcode.com/cann/ops-nn/issues/5425](https://gitcode.com/cann/ops-nn/issues/5425) ## 测试 <!--描述进行了哪些测试来验证你的改动。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!9549 | 1 个月前 | |
算子插件迁移 Co-authored-by: welt_lester<songlizhe1@h-partners.com> Co-authored-by: x00842564<xuyanke@huawei.com> # message auto-generated for no-merge-commit merge: !8474 merge master into master 算子插件迁移 Created-by: welt_lester Commit-by: x00842564;welt_lester Merged-by: cann-robot Description: ## 描述 落实issue #4279,将adaptive_avg_pool2d、adaptive_max_pool2d、ascend_anti_quant、ascend_dequant、ascend_quant、batch_mat_mul_v3、batch_norm、celu_v2、instance_norm_v3、ascend_quant、log_softmax_v2、mat_mul_v3、unique_with_counts_and_sorting这13个算子对应的插件从common\src\framework迁出到各自算子目录新建的\framework目录下。 ## 关联的Issue [Bug-Report|缺陷反馈]: 有对应算子的插件不应该放到公共目录 [#4279](https://gitcode.com/cann/ops-nn/issues/4279) ## 测试 compile、本地验证build通过 ## 文档更新 不涉及 ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他,请描述:代码重构(算子插件归属迁移,落实 #4279 ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!8474 | 1 个月前 | |
docs:修复Unique系列 ACLNN文档中的格式与示例错误 Co-authored-by: jerry_gd<jerry.luo@huawei.com> # message auto-generated for no-merge-commit merge: !9697 merge master into master docs:修复Unique系列 ACLNN文档中的格式与示例错误 Created-by: jerry_gd Commit-by: jerry_gd Merged-by: cann-robot Description: ## 描述 修复Unique系列 ACLNN文档中的格式与示例错误。 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> https://gitcode.com/cann/ops-nn/issues/5491 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> 本次仅修改 Markdown 文档和文档内示例代码,未执行编译或运行测试 ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> - index/unique_consecutive/docs/aclnnUnique.md - index/unique_consecutive/docs/aclnnUnique2.md - index/unique_consecutive/docs/aclnnUniqueConsecutive.md - index/unique_with_counts_ext2/docs/aclnnUniqueDim.md ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [x] AI辅助编写 See merge request: cann/ops-nn!9697 | 1 个月前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Co-authored-by: klein8793<zhangli24@huawei.com> # message auto-generated for no-merge-commit merge: !9754 merge dev_zl_2026_0902 into master Feature: 为 index 和 pooling 类算子新增 Ascend350 平台支持 Created-by: klein8793 Commit-by: klein8793 Merged-by: cann-robot Description: ## 描述 为 index 和 pooling 类算子新增 Ascend350 平台支持。具体变更包括: 1. **新增 Ascend350 平台配置文件**(42 个 JSON):为每个算子新增 op_host/config/ascend350/ 下的二进制配置 JSON 2. **注册 Ascend350 平台**:在各算子 _def.cpp 中添加 his->AICore().AddConfig(ascend350, aicoreConfig) 3. **更新编译配置**:修改各算子 CMakeLists.txt,添加 Ascend350 编译选项;更新 scendc_config.json 中对应算子的 compute_units 列表,将 [ascend950] 扩展为 [ascend950, ascend350] 4. **更新 Fusion Pass 平台判断**:在 bucketize_v2_fusion_pass、inplace_add_fusion_pass、gather_fusion_pass、tensor_scatter_add_fusion_pass、sorted_sparse_segment_mean_grad_fusion_pass 中将 Ascend350 加入平台白名单 涉及算子(35+): - index: bucketize_v2, concat_offset, gather_elements, gather_nd, gather_v2, index_fill, index_fill_d, index_put_v2, inplace_index_add, inplace_index_fill, linear_index_v2, masked_scatter, repeat_interleave, reverse_sequence, reverse_v2, scatter, scatter_add, scatter_add_with_sorted, scatter_elements, scatter_elements_v2, scatter_nd, scatter_nd_add, scatter_nd_max, scatter_nd_min, scatter_nd_update, scatter_sub, scatter_update, segment_sum, sorted_sparse_segment_mean_grad, sparse_segment_mean, sparse_to_dense, unsorted_segment_max, unsorted_segment_min - pooling: avg_pool, avg_pool_v2 - 公共库: scatter_nd_common, unsorted_segment_common, sort_lib ## 关联的Issue - #5651 ## 测试 obp冒烟、david冒烟已通过 ## 文档更新 NA ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [ ] AI辅助编写 See merge request: cann/ops-nn!9754 | 21 天前 | |
UnsortedSegmentProd性能优化 Co-authored-by: zhangxiyan7<zhangxiyan7@huawei.com> # message auto-generated for no-merge-commit merge: !9677 merge UnsortedSegmentProd into master UnsortedSegmentProd性能优化 Created-by: zhangxiyan7 Commit-by: zhangxiyan7 Merged-by: cann-robot Description: ## 描述 针对 UnsortedSegmentProd 算子性能对标竞品部分用例不达标的问题,从单一 Simt 路径扩展为多模板路径体系,并增加全无效 id 向量化快路径。分模板优化说明: 1. OutFl / OutFlWsMerge(输出全载)模板 - 输入行数远超输出规模( inputOuterDim > outputSize × 总核数 × 2)时启用:输出整块驻留 UB,输入行按批流入直接累乘,消除逐行原子写 - WsMerge 变体:各核在 workspace 私有段累乘局部积,最后按输出行跨核 merge,突破单核 UB 容量限制 2. InputPart(输入分区)模板 - 输入行数 ≥ 1024 且输出可驻留 workspace 时启用:按输入行多核分区并行,各核产出局部积后按输出行 merge,解决输入长、输出短的负载并行度问题 - strided flag 跨核聚合:各核将"是否存在有效 id"写入带 stride 的 GM flag,清缓存 + SyncAll 后汇聚,全局无有效 id 时直接跳过 merge 写初值 1 3. SegmentSort(段排序)模板 - float32 且 128 ≤ innerDim < 512、行数 ≥ 1024 时启用:RadixSort 对 segmentIds 排序(多核本地排序 + 归并树合并),归约阶段按连续 segment 顺次连乘,消除随机访存 4. SplitCol / SortSimt 模板:复用公共路径 + Prod 特化 - SplitCol 的 baseA ;sLoopNum == 1 时走单块快路径——一次性读入全部 ids 并先做全无效检测,再决定是否搬运数据 ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/5636 ## 测试 目标用例性能达标(换算带宽后实现 竞品耗时/NPU耗时 > 0.2),冒烟通过。部分用例性能对比结果如下: | # | 用例 / dtype | 输入形状(seg数) | GPU耗时(µs) | 初始NPU耗时(µs) | 初始耗时比 | 最终NPU耗时(µs) | 最终耗时比 | |---|---|---|---|---|---|---|---| | 1 | 000132 fp32/int32 | [5410,77,4] (554) | 19.35 | 381.08 | 0.051 | 30.09 | 0.643 | | 2 | 000040 bf16/int32 | [20,1,8,9,12] (906) | 13.32 | 235.62 | 0.057 | 10.40 | 1.280 | | 3 | 000047 bf16/int64 | [2,2019,33,2,2,2,2,2] (231) | 451.06 | 12101.55 | 0.037 | 110.87 | 4.068 | | 4 | 000116 fp16/int32 | [63,5,10044] (834) | 28.21 | 518.22 | 0.054 | 27.30 | 1.033 | | 5 | 000062 int32/int32 | [3,2,1110,2,2,11,2,2] (224) | 14.59 | 1248.42 | 0.012 | 29.71 | 0.491 | | 6 | 000140 fp32/int32 | [2,4,4,1,8,5,8] (308) | 4.98 | 76.65 | 0.065 | 4.97 | 1.003 | | 7 | 000131 fp32/int64 | [60,5717] (262) | 6.69 | 144.32 | 0.046 | 7.02 | 0.953 | | 8 | 000163 int32/int64 | [101,32383] (853) | 70.59 | 1705.76 | 0.041 | 148.06 | 0.477 | | 9 | 000130 fp32/int32 | [1605,1054] (724) | 620.00 | 34430.41 | 0.018 | 141.21 | 4.391 | | 10 | 000171 int32/int64 | [10090,3,3,3,5,3] (822) | 490.38 | 26759.76 | 0.018 | 270.01 | 1.816 | | 11 | 000017 fp32/int64 | [770] (909) | 8.04 | 1084.10 | 0.007 | 20.81 | 0.386 | | 12 | 000007 fp32/int32 | [52,9739,4,4] (97) | 434.26 | 19934.99 | 0.022 | 66.02 | 6.577 | | 13 | 000134 fp32/int32 | [5,28,34,19] (66) | 160.63 | 34359.26 | 0.005 | 638.77 | 0.251 | | 14 | 000024 fp32/int32 | [20,4,5,21,9] (769) | 5.45 | 198.86 | 0.027 | 7.66 | 0.711 | | 15 | 000006 fp16/int32 | [68,4,4,13603] (208) | 208.56 | 4464.44 | 0.047 | 113.08 | 1.844 | | 16 | 000126 fp16/int32 | [136,2,2,2,645,2,2,2] (965) | 58.30 | 1237.38 | 0.047 | 46.24 | 1.261 | | 17 | 000046 bf16/int32 | [2,2,2,272,2,2,2,63] (406) | 143.06 | 3622.09 | 0.039 | 63.18 | 2.264 | | 18 | 000021 fp32/int64 | [5,12,3171] (383) | 23.28 | 152.96 | 0.152 | 26.94 | 0.864 | | 19 | 000011 fp32/int64 | [2,7081,2,2,2,6,3,2] (632) | 57.57 | 4150.62 | 0.014 | 140.37 | 0.410 | | 20 | 000037 bf16/int64 | [145,4,8254] (1000) | 78.42 | 1037.15 | 0.076 | 96.01 | 0.817 | | 21 | 000135 fp32/int64 | [5,5,4,41] (839) | 45.12 | 3645.09 | 0.012 | 15.85 | 2.847 | | 22 | 000146 bf16/int32 | [23,47] (269) | 14.94 | 480.06 | 0.031 | 15.58 | 0.959 | | 23 | 000017 fp32/int64 | [9718] (954) | 44.76 | 2030.42 | 0.022 | 19.37 | 2.310 | | 24 | 000056 int32/int32 | [4,4,17,4,6535] (396) | 3092.56 | 209483.03 | 0.015 | 552.16 | 5.601 | | 25 | 000227 int32/int64 | [116,317,10,446] (788) | 1254.56 | 83651.63 | 0.015 | 2683.99 | 0.467 | ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他,请描述:UnsortedSegmentProd算子性能优化 ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [x] AI辅助编写 See merge request: cann/ops-nn!9677 | 30 天前 | |
feat(index): 支持ascend350平台适配 Co-authored-by: gh_M<meiguohan@huawei.com> # message auto-generated for no-merge-commit merge: !10151 merge Ascend350_adapt into master feat(index): 支持ascend350平台适配 Created-by: gh_M Commit-by: gh_M Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> 新增DV100-lite芯片,相比DV100,从2D2U变为1D1U,算力、memory规格变为一半(单核的L0A、L0B、L0C、L1等规格不变),NPU ARCH仍与DV100保持一致,SOC VERSION为Ascend 350。需要index/NonZero等算子新增ascend350平台支持。 算子代码中,流程控制中放开Ascend350,与Ascend950(原为910_95)拉齐;算子原型增加Ascend350注册 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。例如:关联Issue #000--> https://gitcode.com/cann/ops-nn/issues/5775 ## 测试 <!--描述进行了哪些测试来验证你的改动。--> 各泛化测试 ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> 不涉及 ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 <!-- [x] 表示选中 --> - [ ] AI辅助编写 See merge request: cann/ops-nn!10151 | 27 天前 | |
feat(aicpu): enable constant folding for migrated ops Co-authored-by: hid29204727<wangboyu20@huawei.com> # message auto-generated for no-merge-commit merge: !9280 merge codex/aicpu-const-folding into master feat(aicpu): enable constant folding for migrated ops Created-by: hid29204727 Commit-by: hid29204727 Merged-by: cann-robot Description: ## 描述 补充 ops-nn 仓 AICPU host 常量折叠注册通路,并为当前已标记 OPEN_OPS_FLAG 的 18 个迁移算子统一开启常量折叠支持。 主要改动: - 新增仓级 OPS_NN_REGISTER_CPU_KERNELV2 注册包装宏,host 构建优先注册 V2,device/custom/UT 保持 V1 回退。 - 为 add_modules_sources 和 add_all_modules_sources 增加 HOSTCPU 参数及 host OBJECT 收集逻辑。 - 为 18 个 OPEN_OPS_FLAG 算子补充 HOSTCPU TRUE、注册头文件和 V2 注册。 - host OBJECT 汇入 libopconstant_folding_nn.so。 ## 关联的Issue 无。 ## 测试 已完成以下静态验证: - git diff --check 通过。 - 18 个 OPEN_OPS_FLAG 算子均具备 HOSTCPU TRUE。 - 18 个算子均使用 OPS_NN_REGISTER_CPU_KERNELV2,无直接 V1 注册残留。 - 注册头文件、host 编译宏和仓级 so 收集通路检查通过。 当前 Windows 环境缺少 CANN、NPU、CMake 和远端构建桥,未执行 bash build.sh --pkg -j16;完整打包构建及常量折叠功能验证待 CANN Linux 环境/CI 完成。 ## 文档更新 无仓内文档变更。 ## 类型标签 - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: ## AI/Agent生成声明 - [x] AI辅助编写 See merge request: cann/ops-nn!9280 | 20 天前 | |
License Change Split2 Co-authored-by: huohuo_wy<wangyan389@huawei.com> # message auto-generated for no-merge-commit merge: !371 merge spilit2License3 into master License Change Split2 Created-by: huohuo_wangyan Commit-by: huohuo_wy Merged-by: cann-robot Description: ## 描述 批量整改文件copyright注释 ## 关联的Issue https://gitcode.com/cann/ops-nn/issues/177 ## 测试 COPYRIGHT注释头按新要求刷新 ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: See merge request: cann/ops-nn!371 | 9 个月前 |
| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
| 1 个月前 | ||
| 1 个月前 | ||
| 1 个月前 | ||
| 20 天前 | ||
| 20 天前 | ||
| 21 天前 | ||
| 1 个月前 | ||
| 30 天前 | ||
| 29 天前 | ||
| 1 个月前 | ||
| 27 天前 | ||
| 27 天前 | ||
| 24 天前 | ||
| 1 个月前 | ||
| 21 天前 | ||
| 27 天前 | ||
| 21 天前 | ||
| 20 天前 | ||
| 3 个月前 | ||
| 21 天前 | ||
| 29 天前 | ||
| 21 天前 | ||
| 21 天前 | ||
| 3 个月前 | ||
| 24 天前 | ||
| 1 个月前 | ||
| 21 天前 | ||
| 20 天前 | ||
| 21 天前 | ||
| 21 天前 | ||
| 27 天前 | ||
| 21 天前 | ||
| 27 天前 | ||
| 20 天前 | ||
| 1 个月前 | ||
| 21 天前 | ||
| 1 个月前 | ||
| 21 天前 | ||
| 28 天前 | ||
| 21 天前 | ||
| 1 个月前 | ||
| 1 个月前 | ||
| 21 天前 | ||
| 3 个月前 | ||
| 21 天前 | ||
| 20 天前 | ||
| 1 个月前 | ||
| 20 天前 | ||
| 20 天前 | ||
| 28 天前 | ||
| 21 天前 | ||
| 27 天前 | ||
| 20 天前 | ||
| 21 天前 | ||
| 21 天前 | ||
| 21 天前 | ||
| 21 天前 | ||
| 20 天前 | ||
| 20 天前 | ||
| 21 天前 | ||
| 28 天前 | ||
| 20 天前 | ||
| 1 个月前 | ||
| 20 天前 | ||
| 20 天前 | ||
| 21 天前 | ||
| 21 天前 | ||
| 21 天前 | ||
| 20 天前 | ||
| 20 天前 | ||
| 20 天前 | ||
| 20 天前 | ||
| 1 个月前 | ||
| 20 天前 | ||
| 21 天前 | ||
| 20 天前 | ||
| 21 天前 | ||
| 21 天前 | ||
| 21 天前 | ||
| 20 天前 | ||
| 20 天前 | ||
| 20 天前 | ||
| 20 天前 | ||
| 1 个月前 | ||
| 28 天前 | ||
| 20 天前 | ||
| 20 天前 | ||
| 1 个月前 | ||
| 1 个月前 | ||
| 30 天前 | ||
| 23 天前 | ||
| 24 天前 | ||
| 1 个月前 | ||
| 1 个月前 | ||
| 1 个月前 | ||
| 21 天前 | ||
| 21 天前 | ||
| 21 天前 | ||
| 30 天前 | ||
| 27 天前 | ||
| 20 天前 | ||
| 9 个月前 |