Skip to content

[PIR Unittest] fix 4 pir uts test_elementwise_(add_op,div_op,nn_grad,sub_op) #67403

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 15, 2024

Conversation

ooooo-create
Copy link
Contributor

PR Category

Execute Infrastructure

PR Types

Others

Description

同 (#67399) 存在 OpTest 的 check_ouput 中 check_inplace_output_with_place 对 PIR 的跳过逻辑

  • test_elementwise_nn_grad.py 中梯度检查 triple_grad_check ,应该是对于 (x) -op - (y) 的单算子的检查,但是 pir 下 paddle.tensor.math._add_with_axis 是多个 op 的,使用加上 OldIrGuard()
    图片
    不然中间 op 的 stop_gradinet 为 True,base.gradients 得到 None
  • 给一些 旧 iR 下的用法,加上 OldIrGuard

Copy link

paddle-bot bot commented Aug 14, 2024

你的PR提交成功,感谢你对开源项目的贡献!
请关注后续CI自动化测试结果,详情请参考Paddle-CI手册
Your PR has been submitted. Thanks for your contribution!
Please wait for the result of CI firstly. See Paddle CI Manual for details.

Copy link
Contributor

@wanghuancoder wanghuancoder left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@paddle-bot paddle-bot bot added the contributor External developers label Aug 14, 2024
@luotao1 luotao1 merged commit ff57d6f into PaddlePaddle:develop Aug 15, 2024
28 checks passed
@ooooo-create ooooo-create deleted the pir_ut_elementwise_op branch March 8, 2025 04:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contributor External developers
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants