| Files | Last commit | Last update |
|---|---|---|
refactor(build): Reuse the common compilation options from common cmake. Co-authored-by: Feiteng Zheng<zhengfeiteng1@h-partners.com> # message auto-generated for no-merge-commit merge: !5292 merge 20260728-intf-pub-2 into master refactor(build): Reuse the common compilation options from common cmake. Created-by: zhengfeiteng Commit-by: Feiteng Zheng Merged-by: cann-robot Description: 切换使用 cann/cmake 仓规定的 intf_pub。 - 通过CANN_GLIBCXX_USE_CXX11_ABI属性设置tile_fwk_calculator的_GLIBCXX_USE_CXX11_ABI Related Issue: #2650 See merge request: cann/pypto!5292 | 3 months ago | |
fix(machine): fix mismatch and incomplete error descriptions in machine and misc files Co-authored-by: chai-hw<chaizhengtong@huawei.com> # message auto-generated for no-merge-commit merge: !5806 merge pyptolog_fix3 into master fix(machine): fix mismatch and incomplete error descriptions in machine and misc files Created-by: chai-hw Commit-by: chai-hw Merged-by: cann-robot Description: machine 日志内容整改 See merge request: cann/pypto!5806 | 2 months ago | |
feat(build): Support packing whl into run Co-authored-by: DCGDDD<yangxu14@huawei.com> # message auto-generated for no-merge-commit merge: !4267 merge master into master feat(build): Support packing whl into run Created-by: DCGDDD Commit-by: DCGDDD Merged-by: cann-robot Description: ## 变更摘要 此 PR 为 PyPTO 项目新增了将 Python wheel ( .whl) 包打入 CANN .run 安装包的能力。通过引入 ENABLE_FEATURE_PACKING_WHL_INTO_RUN 特性开关,将构建产物(whl 包及脚本)整合到 CANN 标准的 run 包交付流程中,使 whl 包能随 run 包一起分发和安装。整体改动涵盖 CMake 构建体系扩展、安装/卸载脚本框架搭建、包描述 XML 配置以及 CI 构建入口适配。 ## 主要改动 - **新增 CMake 打包基础设施**:新增 cmake/package.cmake(安装 whl 及脚本到 run 包目录结构)、cmake/prepare.cmake(第三方路径初始化)、cmake/fetch_cann_cmake.cmake(自动下载 CANN 公共 cmake 脚本)、version.cmake(版本声明 9.1.0),均在 ENABLE_FEATURE_PACKING_WHL_INTO_RUN 开关控制下生效;cmake/config.cmake 中移除了部分不再需要的配置(-17 行)。 - **新增 run 包安装/卸载脚本体系**:在 scripts/package/pypto/scripts/ 下新增 10 个 Shell 脚本,包括 install.sh(安装入口)、uninstall.sh(卸载入口)、run_pypto_install.sh(文件拷贝调度及 whl 的 pip install 后处理)、run_pypto_uninstall.sh(卸载流程)、pypto_custom_install.sh/pypto_custom_uninstall.sh(自定义安装/卸载逻辑)、pypto_func.sh(公共函数库,492 行)、ver_check.sh(版本校验)、cleanup.sh 和 help.info,构成了完整的 run 包生命周期管理。 - **新增包描述 XML 配置**:新增 scripts/package/pypto/pypto.xml 作为 run 包的主配置文件(定义包名 pypto、安装脚本路径、版本信息、目录结构等),并在 scripts/package/module/ascend/ 下新增 5 个模块级 XML(EngineeringCommon.xml、EngineeringFiles.xml、PyptoBin.xml、PyptoInc.xml、PyptoSo.xml),用于描述不同子模块的安装路径和权限。 - **CI 构建入口 build_ci.py 适配**:大幅扩展 build_ci.py(+80/-32),使其支持打包 whl 到 run 包的新构建模式,整合新的 CMake 流程和参数配置。 See merge request: cann/pypto!4267 | 5 months ago | |
feat(build): Support packing whl into run Co-authored-by: DCGDDD<yangxu14@huawei.com> # message auto-generated for no-merge-commit merge: !4267 merge master into master feat(build): Support packing whl into run Created-by: DCGDDD Commit-by: DCGDDD Merged-by: cann-robot Description: ## 变更摘要 此 PR 为 PyPTO 项目新增了将 Python wheel ( .whl) 包打入 CANN .run 安装包的能力。通过引入 ENABLE_FEATURE_PACKING_WHL_INTO_RUN 特性开关,将构建产物(whl 包及脚本)整合到 CANN 标准的 run 包交付流程中,使 whl 包能随 run 包一起分发和安装。整体改动涵盖 CMake 构建体系扩展、安装/卸载脚本框架搭建、包描述 XML 配置以及 CI 构建入口适配。 ## 主要改动 - **新增 CMake 打包基础设施**:新增 cmake/package.cmake(安装 whl 及脚本到 run 包目录结构)、cmake/prepare.cmake(第三方路径初始化)、cmake/fetch_cann_cmake.cmake(自动下载 CANN 公共 cmake 脚本)、version.cmake(版本声明 9.1.0),均在 ENABLE_FEATURE_PACKING_WHL_INTO_RUN 开关控制下生效;cmake/config.cmake 中移除了部分不再需要的配置(-17 行)。 - **新增 run 包安装/卸载脚本体系**:在 scripts/package/pypto/scripts/ 下新增 10 个 Shell 脚本,包括 install.sh(安装入口)、uninstall.sh(卸载入口)、run_pypto_install.sh(文件拷贝调度及 whl 的 pip install 后处理)、run_pypto_uninstall.sh(卸载流程)、pypto_custom_install.sh/pypto_custom_uninstall.sh(自定义安装/卸载逻辑)、pypto_func.sh(公共函数库,492 行)、ver_check.sh(版本校验)、cleanup.sh 和 help.info,构成了完整的 run 包生命周期管理。 - **新增包描述 XML 配置**:新增 scripts/package/pypto/pypto.xml 作为 run 包的主配置文件(定义包名 pypto、安装脚本路径、版本信息、目录结构等),并在 scripts/package/module/ascend/ 下新增 5 个模块级 XML(EngineeringCommon.xml、EngineeringFiles.xml、PyptoBin.xml、PyptoInc.xml、PyptoSo.xml),用于描述不同子模块的安装路径和权限。 - **CI 构建入口 build_ci.py 适配**:大幅扩展 build_ci.py(+80/-32),使其支持打包 whl 到 run 包的新构建模式,整合新的 CMake 流程和参数配置。 See merge request: cann/pypto!4267 | 5 months ago | |
feat(docs): Fix docs error Co-authored-by: DCGDDD<yangxu14@huawei.com> # message auto-generated for no-merge-commit merge: !1483 merge interpreter into master feat(docs): Fix docs error Created-by: DCGDDD Commit-by: DCGDDD Merged-by: cann-robot Description: feat(docs): Fix docs error Related Issue: https://gitcode.com/cann/pypto/issues/544 Related Issue: https://gitcode.com/cann/pypto/issues/269 Related Issue: https://gitcode.com/cann/pypto/issues/205 Related Issue: https://gitcode.com/cann/pypto/issues/610 See merge request: cann/pypto!1483 | 8 months ago | |
统一pypto安装目录及文件权限 Co-authored-by: q00889097<qinhan10@huawei.com> # message auto-generated for no-merge-commit merge: !5842 merge master into master 统一pypto安装目录及文件权限 Created-by: qinhan123 Commit-by: q00889097 Merged-by: cann-robot Description: 统一pypto安装文件及目录权限,这些权限统一由cmake控制,删除安装脚本中一些影响权限规范的操作: 需要移除安装脚本 scripts/package/pypto/scripts/pypto_func.sh 中针对安装目录下各文件/目录的精细化权限锁定逻辑(chmod_recur、chmod_single_dir 等调用),使安装后的权限统一由既有逻辑(如 root 用户下的 chown 与 chmod 755 处理)接管,从而简化并统一权限设置流程。 See merge request: cann/pypto!5842 | 2 months ago | |
refactor(ci): Adapt common cmake build process. Co-authored-by: Feiteng Zheng<zhengfeiteng1@h-partners.com> # message auto-generated for no-merge-commit merge: !5145 merge 20260728-add-pre-package into master refactor(ci): Adapt common cmake build process. Created-by: zhengfeiteng Commit-by: Feiteng Zheng Merged-by: cann-robot Description: 适配通过cmake公共仓的build.sh拉起pypto编译,打出pypto的run包。该场景为“全量源码构建”的一个子场景。 - install命令添加COMPONENT参数,在通过cmake公共仓拉起多个子包编译时,用于区分不同子包的编译产物。 - add_pypto_device_project使用add_cann_device_project公共函数替换。 - ENABLE_UNIFIED_BUILD场景set_cann_cpack_config添加PRE_PKG参数,打包前调用pre_package.cmake脚本,打出whl包。 Related Issue: #2573 See merge request: cann/pypto!5145 | 3 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 | |
refactor(ci): Adapt common cmake build process. Co-authored-by: Feiteng Zheng<zhengfeiteng1@h-partners.com> # message auto-generated for no-merge-commit merge: !5145 merge 20260728-add-pre-package into master refactor(ci): Adapt common cmake build process. Created-by: zhengfeiteng Commit-by: Feiteng Zheng Merged-by: cann-robot Description: 适配通过cmake公共仓的build.sh拉起pypto编译,打出pypto的run包。该场景为“全量源码构建”的一个子场景。 - install命令添加COMPONENT参数,在通过cmake公共仓拉起多个子包编译时,用于区分不同子包的编译产物。 - add_pypto_device_project使用add_cann_device_project公共函数替换。 - ENABLE_UNIFIED_BUILD场景set_cann_cpack_config添加PRE_PKG参数,打包前调用pre_package.cmake脚本,打出whl包。 Related Issue: #2573 See merge request: cann/pypto!5145 | 3 months ago | |
feat(build): Support deb/rpm package in superbuild scene. Co-authored-by: Feiteng Zheng<zhengfeiteng1@h-partners.com> # message auto-generated for no-merge-commit merge: !5360 merge 20260728-intf-pub-2 into master feat(build): Support deb/rpm package in superbuild scene. Created-by: zhengfeiteng Commit-by: Feiteng Zheng Merged-by: cann-robot Description: 支持全量源码构建时,pypto编译deb/rpm包。 - cpack生成deb/rpm包时,打包路径与External不同,cmake/pre_package.cmake中要分别处理。 Related Issue: [#2573](https://gitcode.com/cann/pypto/issues/2573) See merge request: cann/pypto!5360 | 3 months ago | |
refactor(build): Remove third-party build scripts for unified build Co-authored-by: wangmingjun<wangmingjun13@huawei.com> # message auto-generated for no-merge-commit merge: !5215 merge refactor/unified-build-third-party into master refactor(build): Remove third-party build scripts for unified build Created-by: hwwangmingjun Commit-by: wangmingjun Merged-by: cann-robot Description: refactor(build): Remove third-party build scripts for unified build 适配 PyPTO 全量源码统一构建场景(ENABLE_UNIFIED_BUILD)。三方依赖(googletest、 libboundscheck、nlohmann_json)已由 cann/cmake 统一管理,仓库内的 ExternalProject 脚本与独立 build.sh 入口不再需要。 Changes: - 删除 build.sh 独立构建入口 - 删除 cmake/third_party 下 googletest、libboundscheck、nlohmann_json 构建脚本 - prepare.cmake 移除 third_party_path 默认回退;CANN_3RD_LIB_PATH 在未显式配置时回退到构建树 - build_ci.py 仅在显式提供时设置 PYPTO_THIRD_PARTY_PATH Related Issues: #2573 See merge request: cann/pypto!5215 | 3 months ago |
| Files | Last commit | Last update |
|---|---|---|
| 3 months ago | ||
| 2 months ago | ||
| 5 months ago | ||
| 5 months ago | ||
| 8 months ago | ||
| 2 months ago | ||
| 3 months ago | ||
| 2 months ago | ||
| 3 months ago | ||
| 3 months ago | ||
| 3 months ago |