| docs(feat): Add pypto-doc-reviewer Co-authored-by: lyz0328<liyanzhen@huawei.com> # message auto-generated for no-merge-commit merge: !6895 merge master into master docs(feat): Add pypto-doc-reviewer Created-by: lyz0328 Commit-by: lyz0328 Merged-by: cann-robot Description: 新增文档质检skill,用于文档自检和PR审核 See merge request: cann/pypto!6895 | 1 month ago |
| feat(config): Add issue template for experience Co-authored-by: songle1<songle1@huawei.com> # message auto-generated for no-merge-commit merge: !6810 merge dev_1006 into master feat(config): Add issue template for experience Created-by: songle1 Commit-by: songle1 Merged-by: cann-robot Description: 添加新的issue模板,针对用户体验问题,覆盖多个不同的旅程和组件。 为不同的旅程和组件提供简要的统一模板描述,便于问题分类和跟踪。 体验活动所处阶段提供5个类别; 体验改进触点提供5个类别。 See merge request: cann/pypto!6810 | 1 month ago |
| fix(agent): Use "opened" PR state in code-merge-agent Co-authored-by: xiaoyueyueyueyue<liuxiaoxiao11@huawei.com> # message auto-generated for no-merge-commit merge: !5916 merge fix/agent-use-opened-state into master fix(agent): Use "opened" PR state in code-merge-agent Created-by: xiaoyueyueyueyue Commit-by: xiaoyueyueyueyue Merged-by: cann-robot Description: GitCode/GitLab uses "opened" as the open PR state; "open" would never match. Changes: - Minimal one-spot fix. Validation: - No Issue linked. See merge request: cann/pypto!5916 | 2 months ago |
| fix(build): Flush gcov data for pytest-forked subprocess coverage Co-authored-by: chengding888<chengding1@hisilicon.com> # message auto-generated for no-merge-commit merge: !6148 merge master into master fix(build): Flush gcov data for pytest-forked subprocess coverage Created-by: chengding888 Commit-by: chengding888 Merged-by: cann-robot Description: ## 背景 Python UT 通过 --forked(pytest-forked)并行执行用例,子进程以 os._exit() 退出,会跳过 atexit 钩子,导致 gcov 的 __gcov_exit 不被调用、.gcda 覆盖率数据不落盘。因此 --gcov 无法统计到由 Python UT 触发的 C++ 覆盖率(issue #2705)。 ## 解决方案 1. **python/tests/ut/conftest.py**:新增 pytest_runtest_teardown 钩子,当环境变量 PYPTO_GCOV_FLUSH=1 时手动调用 __gcov_dump(),把内存中的计数器写入 .gcda;并补充 duration_estimate 装饰器。 2. **build_ci.py**:--gcov 时注入 PYPTO_GCOV_FLUSH=1。 3. **cmake/intf.cmake**:gcov 模式追加链接选项 -Wl,--export-dynamic,-u,__gcov_dump,--whole-archive,-lgcov,--no-whole-archive。仅加 -u,__gcov_dump 时 _gcov_dump.o 不会被 lgcov.a 拉入,__gcov_dump 保持未定义,ctypes.CDLL(None) 找不到该符号,必须用 --whole-archive 强制拉入。 4. **cmake/scripts/gen_coverage.py**:lcov >= 2.0 时追加 --ignore-errors inconsistent,将 lcov 2.3.1 对 pybind11.cpp 的 mismatched end line 由 ERROR 降级为 WARNING,避免覆盖率生成失败。 5. **tools/scripts/pre_commit_check.sh**: - 修正覆盖率开关(--py_cov → --gcov)、clang 失败退出码、GTEST_FILTER 保存/恢复、覆盖率标签等; - 移除本地增量覆盖率门禁:本地 gen_coverage.py --increment 与 CI 的 get_ai_inc_cov.py(addlcov) 是两套独立实现,增量覆盖率无法保证与 CI 一致,门禁统一由 CI 兜底。 ## 验证 - bash tools/scripts/pre_commit_check.sh --full 全部通过(gnu / clang+ASan / Python / costmodel 仿真,耗时约 4779s)。 - 确认 Python UT 触发场景下 C++ 覆盖率数据(.gcda)可正常落盘并被 --gcov 统计。 Related Issue: #2705 See merge request: cann/pypto!6148 | 2 months ago |
| Sync PyPTO Pro API annotations and docs Co-authored-by: gcw_bTlukKC6<xuxinlei1@huawei.com> # message auto-generated for no-merge-commit merge: !6873 merge docs-pro-sync-0902 into master Sync PyPTO Pro API annotations and docs Created-by: gcw_bTlukKC6 Commit-by: gcw_bTlukKC6 Merged-by: cann-robot Description: PR 应该避免没有描述信息,描述信息的最重要的作用是描述修改意图,应该清晰明了。例如:标题中包含了 fix 标签,如果没有描述信息,就需要Review人员猜测PR具体修复了哪些内容,或者怀疑修改的必要性。如果PR和特定的Issue相关,可以单独包含一行 Related Issue: 放到描述信息最后。 下面是一个典型的PR描述信息: The origin issue template brings too many noise, it's not suitable for git message. eg: comments are not removed, labels are redundant as the PR tile already contains the tag. The guide gives a clear suggestion on how to write the PR body. Related Issue: #1234,#5678 更多描述信息见:[Commit Message 规范](../docs/zh/contribute/pull-request.md#commit-message) See merge request: cann/pypto!6873 | 1 month ago |
| Fix basic operations CLI commands in the examples guides Co-authored-by: KaranocaVe<karanocave@qq.com> # message auto-generated for no-merge-commit merge: !6719 merge fix/2026-09-24-pypto-basic-ops-cli-doc-01 into master Fix basic operations CLI commands in the examples guides Created-by: KaranocaVe Commit-by: KaranocaVe Merged-by: cann-robot Description: # Fix basic operations CLI commands in the examples guides The top-level Chinese and English examples guides currently show two commands that examples/01_beginner/basic/basic_ops.py does not accept: text python3 examples/01_beginner/basic/basic_ops.py matmul::test_matmul python3 examples/01_beginner/basic/basic_ops.py --list The script accepts --tests/-t with matmul as one of its choices, and uses --help to display the available choices. This change updates both guides to use: text python3 examples/01_beginner/basic/basic_ops.py --tests matmul python3 examples/01_beginner/basic/basic_ops.py --help The change is documentation-only. At commit 289942aa3e0c0c0bc9e054c72bafb199200e392f, argparse accepts the corrected selector and rejects the two documented commands with exit code 2. The corrected commands were checked against the script's help output and parser controls. ## Files - examples/README.md - examples/README_en.md 关联 Issue: https://gitcode.com/cann/pypto/issues/3452 See merge request: cann/pypto!6719 | 1 month ago |
| refactor(machine): Remove unused DevicePerf::RunPrepare Co-authored-by: Jie Yin<yinjie27@huawei.com> # message auto-generated for no-merge-commit merge: !6924 merge pgo-framework into master refactor(machine): Remove unused DevicePerf::RunPrepare Created-by: yinjie27_ Commit-by: Jie Yin Merged-by: cann-robot Description: DevicePerf::RunPrepare has no production caller: its only call site was removed together with the legacy DeviceRunner launch path in 34770d5bd ("Unify C++ launch path to use KernelBinary and LaunchKernel"). The per-launch refresh of the perf data pointers is already handled by DeviceLauncher::SetDevPerfAddr -> DevicePerf::SetDebugEnable, which runs on every launch (device_launcher.cpp), so RunPrepare is dead code. Changes: - Remove the unused DevicePerf::RunPrepare definition and declaration - Remove the DevicePerfTest.RunPrepare_DebugMode unit test - Remove the include that became unused after the deletion Verification: - device_perf.cpp syntax-checked with the project's own compile flags (build/compile_commands.json), UT file checked with the same flags + gtest - pre-commit checks passed on commit See merge request: cann/pypto!6924 | 1 month ago |
| Sync PyPTO Pro API annotations and docs Co-authored-by: gcw_bTlukKC6<xuxinlei1@huawei.com> # message auto-generated for no-merge-commit merge: !6873 merge docs-pro-sync-0902 into master Sync PyPTO Pro API annotations and docs Created-by: gcw_bTlukKC6 Commit-by: gcw_bTlukKC6 Merged-by: cann-robot Description: PR 应该避免没有描述信息,描述信息的最重要的作用是描述修改意图,应该清晰明了。例如:标题中包含了 fix 标签,如果没有描述信息,就需要Review人员猜测PR具体修复了哪些内容,或者怀疑修改的必要性。如果PR和特定的Issue相关,可以单独包含一行 Related Issue: 放到描述信息最后。 下面是一个典型的PR描述信息: The origin issue template brings too many noise, it's not suitable for git message. eg: comments are not removed, labels are redundant as the PR tile already contains the tag. The guide gives a clear suggestion on how to write the PR body. Related Issue: #1234,#5678 更多描述信息见:[Commit Message 规范](../docs/zh/contribute/pull-request.md#commit-message) See merge request: cann/pypto!6873 | 1 month ago |
| perf(pre-commit): Speed up the log spec check hook Co-authored-by: chai-hw<chaizhengtong@huawei.com> # message auto-generated for no-merge-commit merge: !6862 merge log_test into master perf(pre-commit): Speed up the log spec check hook Created-by: chai-hw Commit-by: chai-hw Merged-by: cann-robot Description: 本地pre-commit中的日志规范性检查,修改为单次 agent 调用; 新增行无日志特征时直接跳过; 进度改为分步进行; 精简 skill(删除出处、重复说明与"依据条款"列,不影响判定)。 See merge request: cann/pypto!6862 | 1 month ago |
| feat(exported_custom_op): Add the custom-op export and deploy library under tools Co-authored-by: Nikita Larichev<nikita.larichev@h-partners.com> # message auto-generated for no-merge-commit merge: !6780 merge v6_glue_tools into master feat(exported_custom_op): Add the custom-op export and deploy library under tools Created-by: Nikita17 Commit-by: Nikita Larichev Merged-by: cann-robot Description: Consolidates #6769, #6770, #6771, #6772, #6773 and #6774 — all split out of https://gitcode.com/cann/pypto/merge_requests/5158 for reviewability — into one PR, and moves the library they introduce out of the examples tree into tools/exported_custom_op/. Those six carried disjoint file sets that were only meaningful together, so reviewing them one at a time meant reviewing a single library a subpackage at a time. The library is not an example: it is the machinery an example uses. Demos import it as the exported_custom_op package, with <repo root>/tools on sys.path. Nothing outside tools/ is touched. Changes: - Add tools/exported_custom_op/ with four subpackages: common/ (pypto custom-op node discovery), export/ (the ONNX export session), deploy/ (the C++ codegen and the CMake build that produces libcust_opapi.so, with the bundled C++ under deploy/vendors/) and run/ (the shared demo run CLI) - Add the unit suite under tools/exported_custom_op/tests/ut/ — 68 files, 275 tests, covering the generated C++ and its text goldens, the embedded kernel loader, node discovery, the op-declaration gate and the export consistency check - Against the six superseded PRs the content is unchanged apart from the import renames (lib.* to exported_custom_op.*), the path anchors the move required, and the prose that explained why the library sat beside the examples - pytest.ini's testpaths covers python/tests only, so this suite is not part of the default CI collection. Adding the example and tool suites to testpaths is a separate change, tracked with the demo tier Related Issues: [#2869](https://gitcode.com/cann/pypto/issues/2869), [#5158](https://gitcode.com/cann/pypto/merge_requests/5158) See merge request: cann/pypto!6780 | 1 month ago |
| style(config): Update .clang-format and .pre-commit-config.yaml rules Co-authored-by: junjieHuang<huangjunjie38@h-partners.com> # message auto-generated for no-merge-commit merge: !4877 merge style-config-ci into master style(config): Update .clang-format and .pre-commit-config.yaml rules Created-by: junjieHuang Commit-by: junjieHuang Merged-by: cann-robot Description: Update .clang-format and .pre-commit-config.yaml rules See merge request: cann/pypto!4877 | 4 months ago |
| fix(docs): Add the index files Co-authored-by: lyz0328<liyanzhen@huawei.com> # message auto-generated for no-merge-commit merge: !5184 merge master into master fix(docs): Add the index files Created-by: lyz0328 Commit-by: lyz0328 Merged-by: cann-robot Description: 1、将pypto.isnan、pypto.pack、pypto.unpack接口文档写入目录文件index_hiascend.md 2、pypto.isnan、pypto.pack、pypto.unpack接口支持910DT,增加相关描述,并补充芯片标签。 3、删除目录中不存在的内容引用:pypto-copysign 4、图片lfs跟踪文件统一到仓库根目录下 Related Issue: [#2814](https://gitcode.com/cann/pypto/issues/2814) See merge request: cann/pypto!5184 | 3 months ago |
| style(config): Update .clang-format and .pre-commit-config.yaml rules Co-authored-by: junjieHuang<huangjunjie38@h-partners.com> # message auto-generated for no-merge-commit merge: !4877 merge style-config-ci into master style(config): Update .clang-format and .pre-commit-config.yaml rules Created-by: junjieHuang Commit-by: junjieHuang Merged-by: cann-robot Description: Update .clang-format and .pre-commit-config.yaml rules See merge request: cann/pypto!4877 | 4 months ago |
| feat(pre-commit): Add the log spec check hook Co-authored-by: chai-hw<chaizhengtong@huawei.com> # message auto-generated for no-merge-commit merge: !6751 merge log_check_skill into master feat(pre-commit): Add the log spec check hook Created-by: chai-hw Commit-by: chai-hw Merged-by: cann-robot Description: 新增一个本地 pre-commit 项,通过本地 agent CLI 调用 pypto-log-check skill,检查本次提交新增的日志语句。 仅扫描 framework/include、framework/src、python/pypto、python/pypto_pro 和 python/src 五个目录。 命中致命或严重级别问题会阻断提交;未安装受支持的 agent CLI 时自动跳过检查。 See merge request: cann/pypto!6751 | 1 month ago |
| docs(feat): Add pypto-doc-reviewer Co-authored-by: lyz0328<liyanzhen@huawei.com> # message auto-generated for no-merge-commit merge: !6895 merge master into master docs(feat): Add pypto-doc-reviewer Created-by: lyz0328 Commit-by: lyz0328 Merged-by: cann-robot Description: 新增文档质检skill,用于文档自检和PR审核 See merge request: cann/pypto!6895 | 1 month ago |
| feat(operation): kirin support operation dtype specification and softmax Co-authored-by: GBowen666<libowen58@huawei.com> # message auto-generated for no-merge-commit merge: !6074 merge master into master feat(operation): kirin support operation dtype specification and softmax Created-by: GBowen666 Commit-by: GBowen666 Merged-by: cann-robot Description: Related Issue: [[Requirement|需求建议]:kirin支持GetSupportedDataTypesByArch数据类型校验,kirin支持softmax/rmsnorm fp16计算 ](https://gitcode.com/cann/pypto/issues/3270) 1、feat(operation): kirin support operation dtype specification and softmax See merge request: cann/pypto!6074 | 2 months ago |
| style(all): Fix ruff-check lint errors across the codebase Co-authored-by: junjieHuang<huangjunjie38@h-partners.com> # message auto-generated for no-merge-commit merge: !4934 merge style-python-format into master style(all): Fix ruff-check lint errors across the codebase Created-by: junjieHuang Commit-by: junjieHuang Merged-by: cann-robot Description: Fix ruff-check lint errors across the codebase See merge request: cann/pypto!4934 | 4 months ago |
| style(all): Fix ruff-check lint errors across the codebase Co-authored-by: junjieHuang<huangjunjie38@h-partners.com> # message auto-generated for no-merge-commit merge: !4934 merge style-python-format into master style(all): Fix ruff-check lint errors across the codebase Created-by: junjieHuang Commit-by: junjieHuang Merged-by: cann-robot Description: Fix ruff-check lint errors across the codebase See merge request: cann/pypto!4934 | 4 months ago |
| Initial commit | 10 months ago |
| 修复dump 数据bug Co-authored-by: s00454010<suntao37@huawei.com> # message auto-generated for no-merge-commit merge: !5436 merge bug/dumpdata into master 修复dump 数据bug Created-by: u010986451 Commit-by: s00454010 Merged-by: cann-robot Description: 修复dump 数据bug See merge request: cann/pypto!5436 | 3 months ago |
| feat(interface): Support getinputdata for all integral types Co-authored-by: tsungl4<lidongsheng4@huawei.com> # message auto-generated for no-merge-commit merge: !2224 merge refactor/deadcode into master feat(interface): Support getinputdata for all integral types Created-by: tsungl4 Commit-by: tsungl4 Merged-by: cann-robot Description: 1. startArgsSymbolHandlerList of devProg does not used any more 2. Support getinputdata for all integral types Related Issue: [#408](https://gitcode.com/cann/pypto/issues/408) See merge request: cann/pypto!2224 | 7 months ago |
| fix(docs): Add the zh/en link of README Co-authored-by: lyz0328<liyanzhen@huawei.com> # message auto-generated for no-merge-commit merge: !6255 merge master into master fix(docs): Add the zh/en link of README Created-by: lyz0328 Commit-by: lyz0328 Merged-by: cann-robot Description: 1. 文档国际化要求,需要在README文件中增加中英文文件跳转链接 2. 部分文档低错修改,如AICore>AI Core See merge request: cann/pypto!6255 | 2 months ago |
| fix(docs): Add the zh/en link of README Co-authored-by: lyz0328<liyanzhen@huawei.com> # message auto-generated for no-merge-commit merge: !6255 merge master into master fix(docs): Add the zh/en link of README Created-by: lyz0328 Commit-by: lyz0328 Merged-by: cann-robot Description: 1. 文档国际化要求,需要在README文件中增加中英文文件跳转链接 2. 部分文档低错修改,如AICore>AI Core See merge request: cann/pypto!6255 | 2 months ago |
| fix(docs): Precision tools do not have a recompilation scenario Co-authored-by: lyz0328<liyanzhen@huawei.com> # message auto-generated for no-merge-commit merge: !4153 merge master into master fix(docs): Precision tools do not have a recompilation scenario Created-by: lyz0328 Commit-by: lyz0328 Merged-by: cann-robot Description: 1、仓库文档国际化,新增英文readme文件,skill和docs暂不翻译 2、精度工具文档陈旧内容修改:1)删除精度工具重编译步骤 2)更新msaccucmp.py执行命令,明确执行路径、不带版本信息,便于用户在不同版本通用执行 3、webide安装方式的安装界面截图变更 Related Issue: #2345 See merge request: cann/pypto!4153 | 5 months ago |
| fix(docs): Precision tools do not have a recompilation scenario Co-authored-by: lyz0328<liyanzhen@huawei.com> # message auto-generated for no-merge-commit merge: !4153 merge master into master fix(docs): Precision tools do not have a recompilation scenario Created-by: lyz0328 Commit-by: lyz0328 Merged-by: cann-robot Description: 1、仓库文档国际化,新增英文readme文件,skill和docs暂不翻译 2、精度工具文档陈旧内容修改:1)删除精度工具重编译步骤 2)更新msaccucmp.py执行命令,明确执行路径、不带版本信息,便于用户在不同版本通用执行 3、webide安装方式的安装界面截图变更 Related Issue: #2345 See merge request: cann/pypto!4153 | 5 months ago |
| fix(interpreter): Fix tile_fwk_calculator compiler error in g++ 13.3.0 Co-authored-by: DCGDDD<yangxu14@huawei.com> # message auto-generated for no-merge-commit merge: !1453 merge interpreter into master fix(interpreter): Fix tile_fwk_calculator compiler error in g++ 13.3.0 Created-by: DCGDDD Commit-by: DCGDDD Merged-by: cann-robot Description: Fix tile_fwk_calculator compiler error in g++ 13.3.0 See merge request: cann/pypto!1453 | 8 months ago |
| feat(gcov): Support gcov of python scene Co-authored-by: DCGDDD<yangxu14@huawei.com> # message auto-generated for no-merge-commit merge: !3250 merge master into master feat(gcov): Support gcov of python scene Created-by: DCGDDD Commit-by: DCGDDD Merged-by: cann-robot Description: 为 Python 前端用例增加 gcov 覆盖率统计能力。 主要修改: - 新增 gen_coverage_config.py 在 CMake POST_BUILD 阶段生成覆盖率配置 - setup.py 写入 build_dir 标记文件供 build_ci.py 定位配置文件 - build_ci.py 新增 py_generate_coverage 函数生成覆盖率报告 - 修复 CMake VERBATIM 问题,处理生成器表达式展开后的分号分隔路径(同时修复 C++ 覆盖率场景) See merge request: cann/pypto!3250 | 6 months ago |
| fix(build): Flush gcov data for pytest-forked subprocess coverage Co-authored-by: chengding888<chengding1@hisilicon.com> # message auto-generated for no-merge-commit merge: !6148 merge master into master fix(build): Flush gcov data for pytest-forked subprocess coverage Created-by: chengding888 Commit-by: chengding888 Merged-by: cann-robot Description: ## 背景 Python UT 通过 --forked(pytest-forked)并行执行用例,子进程以 os._exit() 退出,会跳过 atexit 钩子,导致 gcov 的 __gcov_exit 不被调用、.gcda 覆盖率数据不落盘。因此 --gcov 无法统计到由 Python UT 触发的 C++ 覆盖率(issue #2705)。 ## 解决方案 1. **python/tests/ut/conftest.py**:新增 pytest_runtest_teardown 钩子,当环境变量 PYPTO_GCOV_FLUSH=1 时手动调用 __gcov_dump(),把内存中的计数器写入 .gcda;并补充 duration_estimate 装饰器。 2. **build_ci.py**:--gcov 时注入 PYPTO_GCOV_FLUSH=1。 3. **cmake/intf.cmake**:gcov 模式追加链接选项 -Wl,--export-dynamic,-u,__gcov_dump,--whole-archive,-lgcov,--no-whole-archive。仅加 -u,__gcov_dump 时 _gcov_dump.o 不会被 lgcov.a 拉入,__gcov_dump 保持未定义,ctypes.CDLL(None) 找不到该符号,必须用 --whole-archive 强制拉入。 4. **cmake/scripts/gen_coverage.py**:lcov >= 2.0 时追加 --ignore-errors inconsistent,将 lcov 2.3.1 对 pybind11.cpp 的 mismatched end line 由 ERROR 降级为 WARNING,避免覆盖率生成失败。 5. **tools/scripts/pre_commit_check.sh**: - 修正覆盖率开关(--py_cov → --gcov)、clang 失败退出码、GTEST_FILTER 保存/恢复、覆盖率标签等; - 移除本地增量覆盖率门禁:本地 gen_coverage.py --increment 与 CI 的 get_ai_inc_cov.py(addlcov) 是两套独立实现,增量覆盖率无法保证与 CI 一致,门禁统一由 CI 兜底。 ## 验证 - bash tools/scripts/pre_commit_check.sh --full 全部通过(gnu / clang+ASan / Python / costmodel 仿真,耗时约 4779s)。 - 确认 Python UT 触发场景下 C++ 覆盖率数据(.gcda)可正常落盘并被 --gcov 统计。 Related Issue: #2705 See merge request: cann/pypto!6148 | 2 months ago |
| fix(machine): fix log quality issues in machine module. Co-authored-by: chai-hw<chaizhengtong@huawei.com> # message auto-generated for no-merge-commit merge: !5679 merge pyptolog_fix into master fix(machine): fix log quality issues in machine module. Created-by: chai-hw Commit-by: chai-hw Merged-by: cann-robot Description: PyPTO machine 模块日志整改 See merge request: cann/pypto!5679 | 3 months ago |
| fix(function):gcc升级15版本兼容问题修改 Co-authored-by: hsqnb<heshouqi@h-partners.com> # message auto-generated for no-merge-commit merge: !5862 merge master into master fix(function):gcc升级15版本兼容问题修改 Created-by: hsqnb Commit-by: hsqnb Merged-by: cann-robot Description: fix(interface): gcc升级15版本兼容问题修改 Related Issue: #3172 See merge request: cann/pypto!5862 | 2 months ago |
| feat(exported_custom_op): Add kernel-source introspection and the runtime compile contract Co-authored-by: Nikita Larichev<nikita.larichev@h-partners.com> # message auto-generated for no-merge-commit merge: !5599 merge v3_02_compile into master feat(exported_custom_op): Add kernel-source introspection and the runtime compile contract Created-by: Nikita17 Commit-by: Nikita Larichev Merged-by: cann-robot Description: Split out of https://gitcode.com/cann/pypto/merge_requests/5158 for reviewability. First functional piece of the exported custom-op subsystem: everything downstream needs a way to recover a kernel's source and to compile it under a stable contract. **API surface map for this whole series — every def with its signature, introducing PR and callers:** https://claude.ai/code/artifact/a42e70ca-5cf9-4a67-8eb3-b7d3c8e17f1a Changes: - Add kernel-source introspection for decorated kernel functions: source recovery, annotation-span editing, scope classification, and the authoring helpers that read a DIRECT kernel's declared shape/dtype constants and classify a factory's signature - Define the runtime compile contract: CompileEntry(jit_kernel=… | factory=…, num_inputs=, num_outputs=, factory_signature=), called as entry(shapes, dtypes, attrs, soc_version) -> compiled-kernel path, result cached per key. Construction accepts exactly one kernel form and rejects an unknown factory_signature or a non-positive input/output count; each call requires soc_version and checks the shape/dtype count against num_inputs - infer_shape / infer_dtype are read/write properties, rejecting a non-callable at assignment rather than deep in dispatch; without a hook every output takes the first input's shape and dtype - Enforce author-declared annotations at compile: a pinned dtype that disagrees with the runtime dtype raises, a pinned shape warns - Wire build_kernel through the frontend parser (single-object contract stated in its error), register the package in pyproject.toml - Add the kernel compile samples and the unit tests over the contract, the declared annotations and the warning paths Related Issues: [#2869](https://gitcode.com/cann/pypto/issues/2869), [#5158](https://gitcode.com/cann/pypto/merge_requests/5158) See merge request: cann/pypto!5599 | 2 months ago |
| fix(test): cleanup log level and test configuration Co-authored-by: chai-hw<chaizhengtong@huawei.com> # message auto-generated for no-merge-commit merge: !5773 merge fixlogbug into master fix(test): cleanup log level and test configuration Created-by: chai-hw Commit-by: chai-hw Merged-by: cann-robot Description: 删除models目录后,将对应pytest文件中关于models的内容删除 由于framework/src/adapter/manager/cann_adapter.h中空指针不会影响后续执行,改回info级别日志,调整日志信息 See merge request: cann/pypto!5773 | 2 months ago |
| fix(build_ci): auto-derive job_num from CPU count and cgroup memory Co-authored-by: chen_chenn<chenchen167@huawei.com> # message auto-generated for no-merge-commit merge: !5721 merge fix_build_ci_job_num into master fix(build_ci): auto-derive job_num from CPU count and cgroup memory Created-by: chen_chenn Commit-by: chen_chenn Merged-by: cann-robot Description: 修复 1. build_ci默认并发度过高导致高核低内存环境编译OOM 2. [文档] 编译(pip install .)未说明内存/并行度要求,默认并行在 32Gi 内存仍 OOM(exit 137) See merge request: cann/pypto!5721 | 3 months ago |
| fix(all): Fix spelling errors in source comments and diagnostic messages Co-authored-by: wangmingjun<wangmingjun13@huawei.com> # message auto-generated for no-merge-commit merge: !5392 merge fix/spelling-errors-2908 into master fix(all): Fix spelling errors in source comments and diagnostic messages Created-by: hwwangmingjun Commit-by: wangmingjun Merged-by: cann-robot Description: fix(all): Fix spelling errors in source comments and diagnostic messages 修复源码注释、错误信息和调试日志中多处英文拼写错误,避免阅读诊断输出时产生误解。 Changes: - device_error_code.h:defalut -> default - codegen_vector.cpp:occured/unsupport -> occurred/unsupported - operation_impl.cpp:interger -> integer - device_task_context.cpp:Inital -> Initial - directed_graph_util.h:lenght -> length - tune_sync_for_vf.cpp:falied -> failed(4 处) - graph_utils.h / expand_function.cpp:seperate -> separate - cube_process.cpp:invlid -> invalid - pil2ir.py:funtion -> function - test_dynamic_mm.cpp:intput -> input(4 处) Related Issues: #2908 See merge request: cann/pypto!5392 | 3 months ago |