Skip to content
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

[Zero-Dim] support input 0D Tensor for xpu compare kernel #47812

Merged
merged 1 commit into from Nov 10, 2022

Conversation

zhwesky2010
Copy link
Contributor

@zhwesky2010 zhwesky2010 commented Nov 9, 2022

PR types

New features

PR changes

APIs

Describe

为equal、not_equal、less_than、less_equal、greater_than、greater_equal 6个XPU算子支持0D Tensor输入

由于 xpu::broadcast_less_equal 等底层函数不支持输入shape为[],而shape为[]和[1]的计算逻辑是一致的,因此可使用shape为[1]传入到xpu底层API内部,但对于DenseTensor节点,则不能改变其shape和ddim,需保持原本正确的0D ddim: []

@paddle-bot
Copy link

paddle-bot bot commented Nov 9, 2022

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

@zhwesky2010 zhwesky2010 force-pushed the 0d_compare_xpu branch 2 times, most recently from 37ab7ce to e9d2c2d Compare November 9, 2022 12:52
zhangyk0314
zhangyk0314 previously approved these changes Nov 10, 2022
@houj04 houj04 merged commit d01109f into PaddlePaddle:develop Nov 10, 2022
@paddle-bot
Copy link

paddle-bot bot commented Nov 10, 2022

你的PR已合入Paddle库,请关注后续测试结果。
Your PR has been merged into the repository. An official integration test will be conducted later. Stay tuned.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants