Merged
fix(bias): remove hardcoded SoC from GEIR example #6999
raoliang_sacAdd on 8 days ago
fix(bias): remove hardcoded SoC from GEIR example #6999
Merged
Pull Request has been successfully merged by CANN-robot.
(Thank you for raoliang_sac's contribution.)8 days ago Created pull request, commit 6ca3169f
atomgit-bot
8 days ago Comments:
8 days ago Comments:
变更摘要
本 PR 针对 Bias 图模式示例 test_geir_bias.cpp 中硬编码 SoC 版本导致 GE 初始化失败的问题,移除了传给 ge::GEInitialize 的全局配置项 ge.socVersion,改由 GE/Runtime 自动获取运行环境的实际 SoC 型号,使示例在不同昇腾型号设备上均可正常初始化并执行图。
主要改动
- 移除硬编码 SoC 配置项:删除
globalOptions中ge.socVersion对应Ascend950DT_9592的条目,避免实际设备型号与该值不一致时 GE 初始化失败。 - 保留其余 GE 全局配置:
ge.exec.deviceId(值为0)与ge.graphRunMode(值为1)仍作为传入ge::GEInitialize的初始化选项保留,示例原有图执行流程不变。 - 对齐仓库其他在线图模式示例:不再在示例侧指定 SoC 版本,改由 GE/Runtime 从运行环境获取实际 SoC,提升跨设备型号的兼容性。
🧩 本次 Review 已使用自定义 Skill:


Incorrect?
atomgit-bot
8 days ago Comments:
8 days ago Comments:


Incorrect?
8 days ago Added label: cann-cla/yes
CANN-robot
8 days ago Comments:
8 days ago Comments:
Thanks for your pull-request.
The full list of commands accepted by me can be found at here.
You can get sig-info at here.
You can self-configure the PR merge rules for this repository. For more details, please refer to Here.
For more, you also can visit HICANN.
PR Approval Progress
✅ Congratulations! All modules have met the lgtm and approve requirements.
Module Approval Details
| module | lgtm status | approve status |
|---|---|---|
| repo-cann/ops-math | ✅ 宋恺, 张磊 (2/2) | ✅ 宋恺, 张磊 (2/1) |
💡 Tip:
- Committer can comment
/approveor/lgtm- Commenting
/approveimplies both code review (lgtm) and intent to merge (approve)
CLA Signature Pass
raoliang_sac, thanks for your pull request. All authors of the commits have signed the CLA. 👍


8 days ago Set yue-ma,zhou-qilong,wangrui_,rxtfeng,loov1,zhangzijie,jia0liang,zl_hw,songkai111,chenxingyu18,pingchuantang,llimwang,gubaocheng,andong_hw,xuejinghui,onanfield,zhanw_coding,jiangjiawei,clinglai0517 as approver
8 days ago Set yue-ma,zhou-qilong,wangrui_,rxtfeng,loov1,zhangzijie,jia0liang,zl_hw,songkai111,chenxingyu18,pingchuantang,llimwang,gubaocheng,andong_hw,xuejinghui,onanfield,zhanw_coding,jiangjiawei,clinglai0517 as approver
8 days ago Set yue-ma,zhou-qilong,wangrui_,rxtfeng,loov1,zhangzijie,jia0liang,zl_hw,songkai111,chenxingyu18,pingchuantang,llimwang,gubaocheng,andong_hw,xuejinghui,onanfield,zhanw_coding,jiangjiawei,clinglai0517 as approver
8 days ago Set yue-ma,zhou-qilong,wangrui_,rxtfeng,loov1,zhangzijie,jia0liang,zl_hw,songkai111,chenxingyu18,pingchuantang,llimwang,gubaocheng,andong_hw,xuejinghui,onanfield,zhanw_coding,jiangjiawei,clinglai0517 as approver
8 days ago Modify description of pull request
raoliang_sac
8 days ago Comments:
8 days ago Comments:
compile


8 days ago Pre merge succeeded (commit_id: 53889bdb12e6cd739d3565d3cbeaace08fe30208)
CANN-robot
8 days ago Comments:
8 days ago Comments:
| 🚀 CI 流水线已启动 |
|---|
| 📋 执行详情: 点击查看流水线 |


8 days ago Added label: ci-pipeline-running
8 days ago Removed label: ci-pipeline-running
8 days ago Added label: ci-pipeline-passed
8 days ago Added label: approved
songkai111
8 days ago Comments:
8 days ago Comments:
/approve


8 days ago Added label: lgtm
8 days ago Closed associated issue
8 days ago Merged pull request
描述
Bias 图模式示例将
ge.socVersion固定为Ascend950DT_9592,在实际型号为Ascend950PR_9579的设备上会因型号不匹配导致 GE 初始化失败。移除这项硬编码配置,由 GE/Runtime 获取运行环境的实际 SoC,保持与仓库其他在线图模式示例一致。
关联的Issue
https://gitcode.com/cann/ops-math/issues/4400
测试
20260923_000324205(version.info:9.2.0),Python 3.12.9。bash build.sh --run_example bias graph --example_name=bias --soc=ascend950 -j8,退出码 0。Ascend950PR_9579,图执行成功,示例输出校验通过:Bias GEIR example run success, outputs=1。git diff --check通过。本次验证为示例构建与上板执行,未运行全量本地 CI。文档更新
无需更新。
类型标签