| Files | Last commit | Last update |
|---|---|---|
math仓英文合入 Co-authored-by: y60124828<yanglou1@h-partners.com> # message auto-generated for no-merge-commit merge: !6772 merge master into master math仓英文合入 Created-by: yanglu-1 Commit-by: y60124828 Merged-by: cann-robot Description: ## 描述 math仓master分支英文合入 ## 关联的Issue 关联issue:[4170](https://gitcode.com/cann/ops-math/issues/4170) ## 测试 <!--描述进行了哪些测试来验证你的改动。包括但不限于二级冒烟、算子泛化等。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: See merge request: cann/ops-math!6772 | 12 days ago | |
【master】【docs&examples】修改部分conversion算子的docs和examples目录下的调用示例的问题 Co-authored-by: t00935269<tangkaidi1@huawei.com> # message auto-generated for no-merge-commit merge: !5527 merge master into master 【master】【docs&examples】修改部分conversion算子的docs和examples目录下的调用示例的问题 Created-by: tangkaidi Commit-by: t00935269 Merged-by: cann-robot Description: ## 描述 【docs&examples】修改部分conversion算子的docs和examples目录下的调用示例的问题 [conversion/clip_by_value_v2/docs/aclnnHardtanh&aclnnInplaceHardtanh.md]:将代码围栏统一为 cpp,并把 Host 数据补足为 8 个元素以匹配 {4, 2} shape。 [conversion/npu_format_cast/docs/aclnnNpuFormatCast.md]:修正 C++ 类型转换语法以及 DHWCN=31、NHWC=1 的格式枚举值。 [conversion/split_v/docs/aclnnSplitTensor.md]:为 aclCreateTensorList 失败补充日志并返回明确的内部错误码,避免错误返回旧的 ret。 [conversion/split_v/docs/aclnnSplitWithSize.md]:统一 cpp 代码围栏、补齐步骤 3~5,并将释放对象说明修正为实际使用的 Tensor、IntArray 和 TensorList。 [conversion/transpose/docs/aclnnChannelShuffle.md]:将 groups 参数的数据类型修正为与其 int64_t 定义一致的 INT64。 [conversion/unfold_grad/docs/aclnnUnfoldGrad.md]:将 gradOutHostData 补足为 18 个元素以匹配 {3, 2, 3} shape。 [experimental/conversion/clip_by_value_v2/docs/aclnnHardtanh&aclnnInplaceHardtanh.md]:同步将代码围栏改为 cpp,并把 Host 数据补足为与 {4, 2} shape 匹配的 8 个元素。 [experimental/conversion/split_v/docs/aclnnSplitTensor.md]:同步为 TensorList 创建失败增加日志和明确的内部错误返回值。 [experimental/conversion/split_v/docs/aclnnSplitWithSize.md]:同步补齐步骤编号并修正资源释放说明。 同步修改涉及的example下的问题。 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue [Documentation|文档反馈]: 【master】修改部分conversion算子的docs和examples目录下的调用示例存在的问题 #3116 <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。--> <!-- 如果这个PR是为了解决特定的问题单,请在这里描述问题单单号。--> ## 测试 已经全部执行pre-commit检查并通过编译门禁。 <!--描述进行了哪些测试来验证你的改动。包括但不限于二级冒烟、算子泛化等。--> ## 文档更新 conversion/clip_by_value_v2/docs/aclnnHardtanh&aclnnInplaceHardtanh.md conversion/npu_format_cast/docs/aclnnNpuFormatCast.md conversion/split_v/docs/aclnnSplitTensor.md conversion/split_v/docs/aclnnSplitWithSize.md conversion/transpose/docs/aclnnChannelShuffle.md conversion/unfold_grad/docs/aclnnUnfoldGrad.md experimental/conversion/clip_by_value_v2/docs/aclnnHardtanh&aclnnInplaceHardtanh.md experimental/conversion/split_v/docs/aclnnSplitTensor.md experimental/conversion/split_v/docs/aclnnSplitWithSize.md <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: See merge request: cann/ops-math!5527 | 1 month ago | |
迁移开源TF插件--conversion Co-authored-by: nextyale<yaochen15@huawei.com> # message auto-generated for no-merge-commit merge: !4310 merge transfer-conversion into master 迁移开源TF插件--conversion Created-by: nextyale Commit-by: nextyale Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。--> <!-- 如果这个PR是为了解决特定的问题单,请在这里描述问题单单号。--> ## 测试 <!--描述进行了哪些测试来验证你的改动。包括但不限于二级冒烟、算子泛化等。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [x] 其他,请描述:迁移TF插件 See merge request: cann/ops-math!4310 | 2 months ago | |
fix: 修正参数校验失败时错误码误用,统一为 ACLNN_ERR_PARAM_INVALID Co-authored-by: cai-chengchao<caichengchao1@h-partners.com> # message auto-generated for no-merge-commit merge: !7072 merge error_code into master fix: 修正参数校验失败时错误码误用,统一为 ACLNN_ERR_PARAM_INVALID Created-by: cai-chengchao Commit-by: cai-chengchao Merged-by: cann-robot Description: ## 描述 修正多个 aclnn 算子在参数取值校验失败时日志错误码误用的问题:这些场景均为参数取值非法(如 dim 越界、splitSections 与维度大小不匹配、输入 shape 与广播 shape 不匹配、starts/ends 与 axes 长度不一致等),实际返回 ACLNN_ERR_PARAM_INVALID,但日志却记为 ACLNN_ERR_PARAM_NULLPTR,错误码语义不一致,误导问题定位。 涉及算子:aclnnSlice、aclnnSplitTensor(含 experimental)、aclnnSliceV2、aclnnFloorDivide(含 experimental)、aclnnAdd、aclnnEqTensor。 ### 改动原因 参数非法应使用 ACLNN_ERR_PARAM_INVALID;原代码误用空指针错误码 ACLNN_ERR_PARAM_NULLPTR。 ### 改动方法 将上述算子的 CheckShape / CheckArray / CheckInplace 参数校验分支中 OP_LOGE 的错误码由 ACLNN_ERR_PARAM_NULLPTR 替换为 ACLNN_ERR_PARAM_INVALID,错误信息文本与 return 值不变。 ## 关联的Issue - #4439 ## 测试 - 仅错误码修正,无算子行为变更。 ## 文档更新 - 无 ## 类型标签 - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: See merge request: cann/ops-math!7072 | 6 days ago | |
add transpose and pad series op to opensource new Co-authored-by: lu-yukun<luyukun4@h-partners.com> # message auto-generated for no-merge-commit merge: !891 merge xf_mem_as_new into master add transpose and pad series op to opensource new Created-by: lu-yukun Commit-by: lu-yukun Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> add transpose and pad series op to opensource new ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。--> <!-- 如果这个PR是为了解决特定的问题单,请在这里描述问题单单号。--> ## 测试 <!--描述进行了哪些测试来验证你的改动。包括但不限于二级冒烟、算子泛化等。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: See merge request: cann/ops-math!891 | 9 months ago | |
[feat]5162A芯片新增适配SplitV算子 Co-authored-by: DF_weiming<zhangyiheng21@huawei.com> # message auto-generated for no-merge-commit merge: !7207 merge master into master [feat]5162A芯片新增适配SplitV算子 Created-by: DF_weiming Commit-by: DF_weiming Merged-by: cann-robot Description: ## 描述 适配SplitV算子 ## 关联的Issue https://gitcode.com/cann/ops-math/issues/3593 ## 测试 <!--描述进行了哪些测试来验证你的改动。包括但不限于二级冒烟、算子泛化等。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: See merge request: cann/ops-math!7207 | 12 hours ago | |
[feat]5162A芯片新增适配strided_slice类算子提交 Co-authored-by: DF_weiming<zhangyiheng21@huawei.com> # message auto-generated for no-merge-commit merge: !7146 merge master into master [feat]5162A芯片新增适配strided_slice类算子提交 Created-by: DF_weiming Commit-by: DF_weiming Merged-by: cann-robot Description: ## 描述 5162A芯片新增适配strided_slice类算子提交 ## 关联的Issue https://gitcode.com/cann/ops-math/issues/3593 ## 测试 <!--描述进行了哪些测试来验证你的改动。包括但不限于二级冒烟、算子泛化等。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: See merge request: cann/ops-math!7146 | 4 days ago | |
SplitV AICPU kernel 内存优化 Co-authored-by: Ding_Jing<dingjing19@huawei.com> # message auto-generated for no-merge-commit merge: !5365 merge fix/splitv-aicpu-memory into master SplitV AICPU kernel 内存优化 Created-by: Ding_Jing Commit-by: Ding_Jing Merged-by: cann-robot Description: ## 描述 SplitV 原来为 shape、size_splits 和输出指针保留随输出数增长的 vector,传参时还会复制。修改后直接读取输入元数据,小 N 使用固定数组,其余路径按 64 个输出分块,并保留溢出、dtype、输出数量、零长度和 -1 推导校验。 最终验收基线统一为 canndev 官方 origin/master 48b986c13167bb717d667eab92ade582fc5842a0 的同名算子源码。候选为 ops-math v5、提交 a9790bf52e51e670dc803d428fd0ebdc7f6bd3a2。两版使用同一 AArch64 AICPU host-context 框架、同一生产编译参数和同一用例矩阵实测;没有复用此前 ops-math master 的精度、内存或性能数字。 | 验收项 | canndev 基线实测结果 | | --- | --- | | 精度 | 219/219 与独立参考及 canndev 基线一致 | | 辅助堆 | 219/219 无上升,残留均为 0 B | | 性能初筛 | R=0.648682–1.180998;中心>1.03 为36,区间全>1为1,均纳入焦点复测 | | 焦点复测 | 37 档、每档31轮ABBA;中心>1.03 为0,区间全>1为0,未消除异常为0 | | 干扰 | CPU11 同核 Mul 记录0,cgroup nr_throttled 增量0 | ### 实际内存变化 | 场景 | canndev基线堆 B | 候选堆 B | 下降 B | 降幅 | | --- | --- | --- | --- | --- | | legacy_axis0_n1_float | 672 | 432 | 240 | 35.71% | | legacy_axis0_n2_float | 672 | 432 | 240 | 35.71% | | legacy_axis0_n4_float | 704 | 432 | 272 | 38.64% | | legacy_axis0_n32_float | 1,224 | 432 | 792 | 64.71% | | legacy_axis0_n512_float | 16,584 | 432 | 16,152 | 97.40% | | legacy_axis0_n4096_float | 131,272 | 432 | 130,840 | 99.67% | | legacy_axis0_n10000_float | 320,200 | 432 | 319,768 | 99.87% | | legacy_axis0_n50000_float | 1,600,200 | 432 | 1,599,768 | 99.97% | | legacy_axis0_n100000_float | 3,200,200 | 432 | 3,199,768 | 99.99% | | 候选堆峰值 B | 覆盖档数 | | --- | --- | | 432 | 219 | 堆数据来自真实注册入口调用窗口的 malloc 族净峰值,输入、输出和 context 在窗口外构造;该值不等于 aclnn executor、RSS、workspace 或设备总显存。 ### 实际性能 | 组 | 档数 | R范围 | 区间全>1 | 中心R>1.03 | | --- | --- | --- | --- | --- | | legacy | 13 | 0.6487–0.8166 | 0 | 0 | | boundary | 9 | 0.6845–0.7859 | 0 | 0 | | dtype | 48 | 0.6763–0.8150 | 0 | 0 | | rank | 96 | 0.6818–1.1792 | 1 | 35 | | scale | 5 | 0.7307–1.1810 | 0 | 1 | | irregular | 48 | 0.6708–0.8163 | 0 | 0 | 每档预热10次、计时51次取中位数,完整矩阵4轮ABBA,每版8个样本;R=候选/canndev基线,区间为 [min(head)/max(base), max(head)/min(base)]。 ### 全部逐档内存与性能表 全部内存和性能行均来自当前候选,不填入旧 PR 数字。ns 为时间中位数,R 越小越好。 #### 原始 N 与 axis 扫描(13 档) | case 定义 | 输入参数 | | --- | --- | | axis0_n1 | shape=[1,4], axis=0, N=1 | | axis0_n2 | shape=[2,4], axis=0, N=2 | | axis0_n4 | shape=[4,4], axis=0, N=4 | | axis0_n32 | shape=[32,4], axis=0, N=32 | | axis0_n512 | shape=[512,4], axis=0, N=512 | | axis0_n4096 | shape=[4096,4], axis=0, N=4096 | | axis0_n10000 | shape=[10000,4], axis=0, N=10000 | | axis0_n50000 | shape=[50000,4], axis=0, N=50000 | | axis0_n100000 | shape=[100000,4], axis=0, N=100000 | | axis1_n2 | shape=[64,2,4], axis=1, N=2 | | axis1_n32 | shape=[64,32,4], axis=1, N=32 | | axis1_n512 | shape=[64,512,4], axis=1, N=512 | | axis1_n4096 | shape=[64,4096,4], axis=1, N=4096 | | case | dtype | 元素数 | base堆 B | 候选堆 B | 降幅 | 分配次数 | 残留 B | base ns | 候选 ns | R | 极差界 | 观测 | | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | | axis0_n1 | float | 4 | 672 | 432 | 35.71% | 29→23 | 0 | 1,690 | 1,380 | 0.8166 | [0.8118,0.8274] | 更快 | | axis0_n2 | float | 8 | 672 | 432 | 35.71% | 29→23 | 0 | 1,770 | 1,420 | 0.8023 | [0.8023,0.8068] | 更快 | | axis0_n4 | float | 16 | 704 | 432 | 38.64% | 29→23 | 0 | 1,840 | 1,490 | 0.8098 | [0.7914,0.8197] | 更快 | | axis0_n32 | float | 128 | 1,224 | 432 | 64.71% | 29→23 | 0 | 3,125 | 2,370 | 0.7584 | [0.7492,0.7717] | 更快 | | axis0_n512 | float | 2,048 | 16,584 | 432 | 97.40% | 29→23 | 0 | 25,465 | 17,920 | 0.7037 | [0.6984,0.7220] | 更快 | | axis0_n4096 | float | 16,384 | 131,272 | 432 | 99.67% | 29→23 | 0 | 266,973 | 198,372 | 0.7430 | [0.6200,0.9550] | 更快 | | axis0_n10000 | float | 40,000 | 320,200 | 432 | 99.87% | 29→23 | 0 | 844,373.5 | 547,730 | 0.6487 | [0.5525,0.8247] | 更快 | | axis0_n50000 | float | 200,000 | 1,600,200 | 432 | 99.97% | 29→23 | 0 | 4,780,258.5 | 3,208,332.5 | 0.6712 | [0.5157,0.9234] | 更快 | | axis0_n100000 | float | 400,000 | 3,200,200 | 432 | 99.99% | 29→23 | 0 | 11,019,271 | 7,929,934.5 | 0.7196 | [0.5111,1.0943] | 区间跨1 | | axis1_n2 | float | 512 | 688 | 432 | 37.21% | 30→23 | 0 | 4,290 | 3,235 | 0.7541 | [0.7471,0.7653] | 更快 | | axis1_n32 | float | 8,192 | 1,240 | 432 | 65.16% | 30→23 | 0 | 42,031 | 33,596 | 0.7993 | [0.7977,0.8115] | 更快 | | axis1_n512 | float | 131,072 | 16,600 | 432 | 97.40% | 30→23 | 0 | 652,401.5 | 504,000 | 0.7725 | [0.7189,0.7896] | 更快 | | axis1_n4096 | float | 1,048,576 | 131,288 | 432 | 99.67% | 30→23 | 0 | 5,624,391.5 | 4,508,395.5 | 0.8016 | [0.7775,0.8212] | 更快 | #### 小 N 和 64 项分块边界(9 档) | case 定义 | 输入参数 | | --- | --- | | n3 | shape=[3,3,2], axis=1, N=3 | | n4 | shape=[3,4,2], axis=1, N=4 | | n5 | shape=[3,5,2], axis=1, N=5 | | n63 | shape=[3,63,2], axis=1, N=63 | | n64 | shape=[3,64,2], axis=1, N=64 | | n65 | shape=[3,65,2], axis=1, N=65 | | n127 | shape=[3,127,2], axis=1, N=127 | | n128 | shape=[3,128,2], axis=1, N=128 | | n129 | shape=[3,129,2], axis=1, N=129 | | case | dtype | 元素数 | base堆 B | 候选堆 B | 降幅 | 分配次数 | 残留 B | base ns | 候选 ns | R | 极差界 | 观测 | | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | | n3 | double | 18 | 688 | 432 | 37.21% | 30→23 | 0 | 2,055 | 1,615 | 0.7859 | [0.7703,0.7990] | 更快 | | n4 | double | 24 | 720 | 432 | 40.00% | 30→23 | 0 | 2,170 | 1,705 | 0.7857 | [0.7717,0.7963] | 更快 | | n5 | double | 30 | 720 | 432 | 40.00% | 30→23 | 0 | 2,255 | 1,760 | 0.7805 | [0.7632,0.7902] | 更快 | | n63 | double | 378 | 2,200 | 432 | 80.36% | 30→23 | 0 | 7,460 | 5,275 | 0.7071 | [0.6992,0.7147] | 更快 | | n64 | double | 384 | 2,264 | 432 | 80.92% | 30→23 | 0 | 7,595.5 | 5,300.5 | 0.6978 | [0.6965,0.7037] | 更快 | | n65 | double | 390 | 2,264 | 432 | 80.92% | 30→23 | 0 | 7,665 | 5,505 | 0.7182 | [0.7122,0.7264] | 更快 | | n127 | double | 762 | 4,248 | 432 | 89.83% | 30→23 | 0 | 13,315.5 | 9,390 | 0.7052 | [0.7022,0.7086] | 更快 | | n128 | double | 768 | 4,312 | 432 | 89.98% | 30→23 | 0 | 13,440.5 | 9,345 | 0.6953 | [0.6920,0.6995] | 更快 | | n129 | double | 774 | 4,312 | 432 | 89.98% | 30→23 | 0 | 13,485 | 9,230 | 0.6845 | [0.6804,0.6895] | 更快 | #### 12 dtype × 4 N(48 档) | case 定义 | 输入参数 | | --- | --- | | n2 | shape=[3,2,4], axis=1, N=2 | | n4 | shape=[3,4,4], axis=1, N=4 | | n65 | shape=[3,65,4], axis=1, N=65 | | n129 | shape=[3,129,4], axis=1, N=129 | | case | dtype | 元素数 | base堆 B | 候选堆 B | 降幅 | 分配次数 | 残留 B | base ns | 候选 ns | R | 极差界 | 观测 | | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | | n2 | float16 | 24 | 688 | 432 | 37.21% | 30→23 | 0 | 2,000 | 1,630 | 0.8150 | [0.7970,0.8241] | 更快 | | n4 | float16 | 48 | 720 | 432 | 40.00% | 30→23 | 0 | 2,170 | 1,740 | 0.8018 | [0.7900,0.8186] | 更快 | | n65 | float16 | 780 | 2,264 | 432 | 80.92% | 30→23 | 0 | 7,960 | 5,680 | 0.7136 | [0.7110,0.7282] | 更快 | | n129 | float16 | 1,548 | 4,312 | 432 | 89.98% | 30→23 | 0 | 13,770 | 9,865 | 0.7164 | [0.7118,0.7205] | 更快 | | n2 | float | 24 | 688 | 432 | 37.21% | 30→23 | 0 | 1,990 | 1,560 | 0.7839 | [0.7750,0.7929] | 更快 | | n4 | float | 48 | 720 | 432 | 40.00% | 30→23 | 0 | 2,170 | 1,690 | 0.7788 | [0.7717,0.7917] | 更快 | | n65 | float | 780 | 2,264 | 432 | 80.92% | 30→23 | 0 | 7,840 | 5,505 | 0.7022 | [0.6938,0.7037] | 更快 | | n129 | float | 1,548 | 4,312 | 432 | 89.98% | 30→23 | 0 | 13,900 | 9,575.5 | 0.6889 | [0.6839,0.6935] | 更快 | | n2 | double | 24 | 688 | 432 | 37.21% | 30→23 | 0 | 1,975 | 1,560 | 0.7899 | [0.7828,0.8051] | 更快 | | n4 | double | 48 | 720 | 432 | 40.00% | 30→23 | 0 | 2,165 | 1,710 | 0.7898 | [0.7661,0.7996] | 更快 | | n65 | double | 780 | 2,264 | 432 | 80.92% | 30→23 | 0 | 7,855 | 5,660.5 | 0.7206 | [0.7107,0.7254] | 更快 | | n129 | double | 1,548 | 4,312 | 432 | 89.98% | 30→23 | 0 | 13,950 | 9,850 | 0.7061 | [0.6986,0.7111] | 更快 | | n2 | int8 | 24 | 688 | 432 | 37.21% | 30→23 | 0 | 2,000 | 1,570 | 0.7850 | [0.7662,0.7940] | 更快 | | n4 | int8 | 48 | 720 | 432 | 40.00% | 30→23 | 0 | 2,180 | 1,710 | 0.7844 | [0.7727,0.8047] | 更快 | | n65 | int8 | 780 | 2,264 | 432 | 80.92% | 30→23 | 0 | 8,120.5 | 5,515 | 0.6791 | [0.6707,0.6831] | 更快 | | n129 | int8 | 1,548 | 4,312 | 432 | 89.98% | 30→23 | 0 | 14,135 | 9,930 | 0.7025 | [0.6989,0.7059] | 更快 | | n2 | int16 | 24 | 688 | 432 | 37.21% | 30→23 | 0 | 1,985 | 1,570 | 0.7909 | [0.7750,0.7970] | 更快 | | n4 | int16 | 48 | 720 | 432 | 40.00% | 30→23 | 0 | 2,155 | 1,690 | 0.7842 | [0.7778,0.8084] | 更快 | | n65 | int16 | 780 | 2,264 | 432 | 80.92% | 30→23 | 0 | 7,925 | 5,530 | 0.6978 | [0.6943,0.7076] | 更快 | | n129 | int16 | 1,548 | 4,312 | 432 | 89.98% | 30→23 | 0 | 13,840.5 | 9,905 | 0.7157 | [0.7122,0.7207] | 更快 | | n2 | int32 | 24 | 688 | 432 | 37.21% | 30→23 | 0 | 1,970 | 1,560 | 0.7919 | [0.7789,0.8020] | 更快 | | n4 | int32 | 48 | 720 | 432 | 40.00% | 30→23 | 0 | 2,150 | 1,690 | 0.7860 | [0.7778,0.8037] | 更快 | | n65 | int32 | 780 | 2,264 | 432 | 80.92% | 30→23 | 0 | 7,810 | 5,360.5 | 0.6864 | [0.6824,0.6928] | 更快 | | n129 | int32 | 1,548 | 4,312 | 432 | 89.98% | 30→23 | 0 | 13,640 | 9,610 | 0.7045 | [0.6990,0.7098] | 更快 | | n2 | int64 | 24 | 688 | 432 | 37.21% | 30→23 | 0 | 1,995 | 1,550 | 0.7769 | [0.7662,0.7879] | 更快 | | n4 | int64 | 48 | 720 | 432 | 40.00% | 30→23 | 0 | 2,170 | 1,685 | 0.7765 | [0.7580,0.7824] | 更快 | | n65 | int64 | 780 | 2,264 | 432 | 80.92% | 30→23 | 0 | 7,855.5 | 5,515 | 0.7021 | [0.6971,0.7072] | 更快 | | n129 | int64 | 1,548 | 4,312 | 432 | 89.98% | 30→23 | 0 | 13,725.5 | 9,500.5 | 0.6922 | [0.6862,0.6993] | 更快 | | n2 | uint8 | 24 | 688 | 432 | 37.21% | 30→23 | 0 | 2,000 | 1,570 | 0.7850 | [0.7761,0.8081] | 更快 | | n4 | uint8 | 48 | 720 | 432 | 40.00% | 30→23 | 0 | 2,190 | 1,705 | 0.7785 | [0.7602,0.7890] | 更快 | | n65 | uint8 | 780 | 2,264 | 432 | 80.92% | 30→23 | 0 | 8,200 | 5,655 | 0.6896 | [0.6837,0.6984] | 更快 | | n129 | uint8 | 1,548 | 4,312 | 432 | 89.98% | 30→23 | 0 | 14,210.5 | 9,830 | 0.6917 | [0.6861,0.6968] | 更快 | | n2 | uint16 | 24 | 688 | 432 | 37.21% | 30→23 | 0 | 1,995 | 1,585 | 0.7945 | [0.7811,0.7990] | 更快 | | n4 | uint16 | 48 | 720 | 432 | 40.00% | 30→23 | 0 | 2,155 | 1,690 | 0.7842 | [0.7778,0.7944] | 更快 | | n65 | uint16 | 780 | 2,264 | 432 | 80.92% | 30→23 | 0 | 7,910 | 5,690 | 0.7193 | [0.7140,0.7278] | 更快 | | n129 | uint16 | 1,548 | 4,312 | 432 | 89.98% | 30→23 | 0 | 14,170 | 9,965.5 | 0.7033 | [0.6981,0.7074] | 更 See merge request: cann/ops-math!5365 | 1 month ago | |
修复错误的split_v UT用例 Co-authored-by: DF_weiming<zhangyiheng21@huawei.com> # message auto-generated for no-merge-commit merge: !7199 merge master into master 修复错误的split_v UT用例 Created-by: DF_weiming Commit-by: DF_weiming Merged-by: cann-robot Description: ## 描述 修正 SplitV 算子 UT 中构造错误的用例。conversion/split_v/tests/ut/op_host/test_split_v_infershape.cpp 中的 split_v_infershape_split_dim_not_const 用例原本通过 splitDimValue 常量数据将 split_dim 输入构造成常量,与其“split_dim 非常量”的测试意图矛盾;本次改动移除了该常量数据,使 split_dim 输入按普通(非常量)输入构造,从而让用例真正覆盖 split_dim 为非常量的 infershape 分支。 ## 关联的Issue https://gitcode.com/cann/ops-math/issues/4602 ## 测试 <!--描述进行了哪些测试来验证你的改动。包括但不限于二级冒烟、算子泛化等。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [x] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: See merge request: cann/ops-math!7199 | 3 days ago | |
[feat]5162A芯片新增适配strided_slice类算子提交 Co-authored-by: DF_weiming<zhangyiheng21@huawei.com> # message auto-generated for no-merge-commit merge: !7146 merge master into master [feat]5162A芯片新增适配strided_slice类算子提交 Created-by: DF_weiming Commit-by: DF_weiming Merged-by: cann-robot Description: ## 描述 5162A芯片新增适配strided_slice类算子提交 ## 关联的Issue https://gitcode.com/cann/ops-math/issues/3593 ## 测试 <!--描述进行了哪些测试来验证你的改动。包括但不限于二级冒烟、算子泛化等。--> ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [x] 新特性 - [ ] 性能优化 - [ ] 文档更新 - [ ] 其他,请描述: See merge request: cann/ops-math!7146 | 4 days ago | |
产品名变更 Co-authored-by: gitcode-chenjiao<chenjiao31@huawei.com> # message auto-generated for no-merge-commit merge: !5912 merge master into master 产品名变更 Created-by: gitcode-chenjiao Commit-by: gitcode-chenjiao Merged-by: cann-robot Description: ## 描述 <!--在这里详细描述你的改动,包括改动的原因和所采取的方法。--> AI处理器对应的产品型号名称更新 ## 关联的Issue <!-- 如果这个PR是为了解决特定的Issue,请在这里提供Issue链接。--> <!-- 如果这个PR是为了解决特定的问题单,请在这里描述问题单单号。--> [#3258](https://gitcode.com/cann/ops-math/issues/3258) ## 测试 <!--描述进行了哪些测试来验证你的改动。包括但不限于二级冒烟、算子泛化等。--> ok ## 文档更新 <!--如果这个PR包含文档的更新,请在这里指出。例如:更新了README.md文件。--> *.md ## 类型标签 <!-- [x] 表示选中 --> - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: See merge request: cann/ops-math!5912 | 1 month ago | |
docs: add English translations for markdown files Co-authored-by: jenny_xiang<jenny.xiang@huawei.com> # message auto-generated for no-merge-commit merge: !7113 merge docs/add-english-translations into master docs: add English translations for markdown files Created-by: jenny_xiang Commit-by: jenny_xiang Merged-by: cann-robot Description: ## 描述 新增仓库Markdown文档英文译稿(第二批,共409个文件):第一批(已合入)之外的其余全部译稿,覆盖conversion、examples、ge、math、random各类算子README译稿,以及CHANGELOG_en.md、.gitcode PR模板英文版等。 本批内全部仓内链接均指向master已有文件(含第一批已合入的21+2篇译稿),合入后本仓432篇英文文档全部就位,链接完整生效。 本批同时包含4篇基于最新源文档的增量更新(math/ada_cast、math/prod_force_se_a、math/sinkhorn、math/xlogy,对应上游近期文档变更)。 ## 关联的Issue 无 ## 测试 文档类变更,无需算子测试;已通过链接有效性校验(本批全部相对链接仅指向master已有文件,无指向本PR外未提交文件的链接),并完成逐篇翻译规范自查与语义校对(含支持状态表、限定词、术语、数值符号核对)。 ## 文档更新 新增409个英文译稿文件(*_en.md / .en-US.md),不修改任何现有文件。 ## 类型标签 - [ ] Bug修复 - [ ] 新特性 - [ ] 性能优化 - [x] 文档更新 - [ ] 其他,请描述: See merge request: cann/ops-math!7113 | 5 days ago |
SplitV
English | 简体中文
Product Support Status
| Product | Supported |
|---|---|
| Ascend 950PR&950DT products | √ |
| Atlas A3 products | √ |
| Atlas A2 products | √ |
| Atlas 200I/500 A2 inference products | √ |
| Atlas inference products | √ |
| Atlas training products | √ |
Function Description
- Operator function: splits a tensor into num_split smaller tensors along the dimension split_dim according to size_splits.
Parameter Description
| Parameter Name | Input/Output/Attribute | Description | Data Type | Data Format |
|---|---|---|---|---|
| x | Input | List of tensors to be split. | FLOAT16, FLOAT32, DOUBLE, INT64, INT32, UINT8, UINT16, UINT32, UINT64, INT8, INT16, BOOL, COMPLEX64, COMPLEX128 | ND |
| size_splits | Input | Specifies a list that contains the size of each output tensor along the split dimension. | INT32, INT64 | ND |
| split_dim | Input | Dimension along which the tensor is split. | INT32, INT64 | ND |
| num_split | Attribute | Number of tensors to be split. | INT | - |
| y | Output | Output result. | FLOAT16, FLOAT32, DOUBLE, INT64, INT32, UINT8, UINT16, UINT32, UINT64, INT8, INT16, BOOL, COMPLEX64, COMPLEX128 | ND |
- Atlas training products, Atlas inference products, Atlas 200I/500 A2 inference products, and Atlas 200/300/500 inference products: BFLOAT16 is not supported.
Constraint Description
- Each element in size_splits is greater than or equal to 1.
- The length of size_splits equals the value of num_split.
- The sum of the elements in size_splits equals the size of the dimension split_dim.
Invocation Description
| Invocation Method | Sample Code | Description |
|---|---|---|
| aclnn API | test_aclnn_split_tensor | Invokes the SplitV operator through the aclnnSplitTensor API. |
| aclnn API | test_aclnn_split_with_size | Invokes the SplitV operator through the aclnnSplitWithSize API. |