Skip to content

[XPU] UpdatePadding has already modified the value of pad #72618

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
May 8, 2025

Conversation

zhouquan32
Copy link
Contributor

PR Category

Execute Infrastructure

PR Types

Bug fixes

Description

The UpdatePadding function has been designed to adjust the padding appropriately, regardless of whether ceil_mode is set to True or False in the Pool2D operation, however, the additional code that attempts to adjust the padding can lead to error, so remove this redundant part of the code.

Copy link

paddle-bot bot commented May 8, 2025

你的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.

@paddle-bot paddle-bot bot added the XPU label May 8, 2025
paddings[1] += (in_h_ceil - in_h);
paddings[3] += (in_w_ceil - in_w);
}

Copy link
Contributor

Choose a reason for hiding this comment

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

删掉就能不出错了吗,是否有算法说明

Copy link
Contributor Author

Choose a reason for hiding this comment

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

UpdatePadding已经更新了padding,这个计算反而导致结果出错,目前修复后,结果已经和CUDA对齐

Copy link
Contributor

Choose a reason for hiding this comment

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

这里删掉了一些代码,没有修改单测,流水线为什么是可以通过的呢?是原先有漏测么?

Copy link
Contributor

@cqulilujia cqulilujia left a comment

Choose a reason for hiding this comment

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

LGTM

@QingshuChen QingshuChen merged commit c7761d7 into PaddlePaddle:develop May 8, 2025
47 of 48 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants