You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[0-size Tensor No.2、3、13、14、15、17、30、36、37、68、189、211、217、219、224、228、245、254、258、260、264、265、272、273、288、291、295、305、327、331、332、333、334、336、337、340] Add 0-size Tensor support for a lot of activation function APIs.
#72821
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.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
修复了一个比较共性的问题,涉及到如下API: acos acosh asin asinh atan atanh ceil cos cosh floor rsqrt sin sinh sqrt square tan tanh relu sigmoid silu softsign TanhShrink log_sigmoid
这类api的kernel通常使用宏来快速定义,因此只需要修复对应的宏即可。具体的修改方法(以CPU为例)如下:
你的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.
DanielSun11
changed the title
[0-size Tensor No.xxx] Add 0-size Tensor support for a lot of activation function API.
[0-size Tensor No.2、3、13、14、15、17、30、36、37、68、189、211、217、219、224、228、245、254、258、260、264、265、272、273、288、291、295、305、327、331、332、333、334、336、337、340] Add 0-size Tensor support for a lot of activation function APIs.
May 20, 2025
DanielSun11
changed the title
[0-size Tensor No.2、3、13、14、15、17、30、36、37、68、189、211、217、219、224、228、245、254、258、260、264、265、272、273、288、291、295、305、327、331、332、333、334、336、337、340] Add 0-size Tensor support for a lot of activation function APIs.
[WIP][0-size Tensor No.2、3、13、14、15、17、30、36、37、68、189、211、217、219、224、228、245、254、258、260、264、265、272、273、288、291、295、305、327、331、332、333、334、336、337、340] Add 0-size Tensor support for a lot of activation function APIs.
May 21, 2025
DanielSun11
changed the title
[WIP][0-size Tensor No.2、3、13、14、15、17、30、36、37、68、189、211、217、219、224、228、245、254、258、260、264、265、272、273、288、291、295、305、327、331、332、333、334、336、337、340] Add 0-size Tensor support for a lot of activation function APIs.
[0-size Tensor No.2、3、13、14、15、17、30、36、37、68、189、211、217、219、224、228、245、254、258、260、264、265、272、273、288、291、295、305、327、331、332、333、334、336、337、340] Add 0-size Tensor support for a lot of activation function APIs.
May 26, 2025
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR Category
Execute Infrastructure
PR Types
Improvements
Description
修复了一个比较共性的问题,涉及到如下API:
acos acosh asin asinh atan atanh ceil cos cosh floor rsqrt sin sinh sqrt square tan tanh relu sigmoid silu softsign TanhShrink log_sigmoid
这类api的kernel通常使用宏来快速定义,因此只需要修复对应的宏即可。具体的修改方法(以CPU为例)如下:
添加了
除此之外,这类api较为常见,因此需要在gpu xpu sparse对应的kernel中一并修改。修改方法类似。
由于
test_activation_op.py
里面代码太长而且有较多遗留问题,因此新增单测文件:Paddle/test/legacy_test/test_activation_op_zero_size.py
Pcard-67164