已合并
修复 matmul 相关算子的日志规范问题 #8995
yangyang016创建于 15 天前
修复 matmul 相关算子的日志规范问题 #8995
已合并
yangyang016创建于 15 天前
yangyang016成员
15 天前

描述

本 PR 统一修复 matmul 相关算子的日志规范问题:

  • 修复 quant_batch_matmul_v3 日志中的拼写错误:
    • faild 修改为 failed
    • deminsion 修改为 dimension
  • quant_batch_matmul_v3/tests 中含中文字符、中英文混杂的运行时日志统一为英文。
  • 删除 sparse4to2quant_matmul/op_host/op_api 中直接使用的 std::cout 调试输出,保留规范的 OP_LOGE 错误日志。
  • 按仓库格式要求整理相关 C++ 文件。

本次修改仅涉及日志文本、调试输出及代码格式,不改变算子计算逻辑。

关联的Issue

https://gitcode.com/cann/ops-nn/issues/4964

测试

  • 扫描 quant_batch_matmul_v3,确认不存在 failddeminsion
  • 扫描测试运行时日志,确认不存在中文字符。
  • 扫描 sparse4to2quant_matmul/op_host/op_api,确认不存在直接使用的 std::cout
  • git diff --check --cached 检查通过。

文档更新

不涉及。

类型标签

AI/Agent生成声明

likedislike
Pull Request已成功合入, 合并人@CANN-robot
(感谢 yangyang016 的贡献)
Yyangyang016成员
15 天前 创建了 pull request,commit ac5b371a
atomgit-bot
atomgit-bot
15 天前 评论:

变更摘要

该 PR(标题 "fix log")主要针对 quant_batch_matmul_v3 算子相关模块的日志与报错信息进行清理和修正:统一修正英文拼写错误(如 faildfaileddeminsiondimension)、将测试用例中的中文日志改为英文并优化格式,同时移除 sparse4to2quant_matmul 中的调试输出语句。整体为日志/信息文案层面的修复,不涉及业务逻辑变更。

主要改动

  • 修正 quant_batch_matmul_v3 执行与 tiling 报错拼写: 在 quant_batch_matmul_v3_fallback.cppOP_LOGEquant_batch_matmul_v3_tiling.cppCUBE_INNER_ERR_REPORT 中,将错误信息中的 faild 更正为 failed,提升日志可读性。
  • 修正 quant_batch_matmul_v3_tiling_base.cpp 报错文案与代码格式: 将 CheckShapeInRangeForMandtoryInputs 中的 deminsion 更正为 dimension,并清理 AnalyzeInputs 中的行尾空白、调整 AnalyzeMxGroupInfo 中多行表达式(如 mxPertokenMSizemxPertokenKSizemxScaleNSize 的取值)的换行缩进格式,无逻辑变化。
  • 测试用例日志中英文化: 在 executor_aclnnQuantMatmulV4.py 中,将各场景(Scenario 0~5)的 logging.info/logging.error 中文信息统一改为英文(如 "Case ID"、"Scenario N: pertoken - no, bias - no"),并对部分超长日志进行分行格式化,便于日志检索与统一。
  • 移除调试输出并补充文件结尾换行: 在 aclnn_trans_sparse4to2_para.cppProcessWeightBlock 中删除两条 std::cout 调试打印(权重 pattern 值输出),并在文件末尾补充换行符,避免调试信息污染输出。
likedislike
atomgit-bot
atomgit-bot
15 天前 评论:

代码审查

✅ 未发现问题

likedislike
CANN-robotCANN-robot成员
15 天前 添加了label:cann-cla/yes
CANN-robot
CANN-robot成员
15 天前 评论:

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.
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
matmul 陈琦, 王子韬 (2/2) 陈琦, 王子韬 (2/1)

💡 Tip:

  • Committer can comment /approve or /lgtm
  • Commenting /approve implies both code review (lgtm) and intent to merge (approve)

CLA Signature Pass

yangyang016, thanks for your pull request. All authors of the commits have signed the CLA. 👍

likedislike
此处折叠了42条消息 查看更多
CANN-robotCANN-robot成员
15 天前 添加了label:approved
wangzitao
wangzitao成员
15 天前 评论:

/lgtm
/approve

likedislike
CANN-robotCANN-robot成员
15 天前 添加了label:lgtm
CANN-robotCANN-robot成员
15 天前 关闭了关联的issue
CANN-robotCANN-robot成员
15 天前 合入了pull request