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

fused_multi_transformer/fused_bias_dropout_residual_layer_norm to phi #62049

Merged
merged 18 commits into from
Mar 4, 2024

Conversation

0x45f
Copy link
Contributor

@0x45f 0x45f commented Feb 25, 2024

PR types

Others

PR changes

Others

Description

Pcard-67164

算子迁移参考:#51743
适配PIR参考:#57655
前期实验:#61529

Copy link

paddle-bot bot commented Feb 25, 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.

@zrr1999 zrr1999 changed the title test op fused_multi_transformer/fused_multi_transformer_int8 to phi Feb 28, 2024
@zrr1999 zrr1999 changed the title fused_multi_transformer/fused_multi_transformer_int8 to phi fused_multi_transformer/fused_multi_transformer_int8/fused_bias_dropout_residual_layer_norm to phi Feb 28, 2024
@0x45f
Copy link
Contributor Author

0x45f commented Feb 28, 2024

先只适配 fused_multi_transformer/fused_bias_dropout_residual_layer_norm 这两个op吧,int8这个op没有python端的api,先不用适配~

paddle/phi/api/yaml/fused_backward.yaml Show resolved Hide resolved
paddle/phi/api/yaml/fused_ops.yaml Outdated Show resolved Hide resolved
@zrr1999
Copy link
Member

zrr1999 commented Feb 28, 2024

先只适配 fused_multi_transformer/fused_bias_dropout_residual_layer_norm 这两个op吧,int8这个op没有python端的api,先不用适配~

好的,已修改

@0x45f 0x45f changed the title fused_multi_transformer/fused_multi_transformer_int8/fused_bias_dropout_residual_layer_norm to phi fused_multi_transformer/fused_bias_dropout_residual_layer_norm to phi Feb 28, 2024
paddle/fluid/pir/dialect/operator/ir/ops.yaml Outdated Show resolved Hide resolved
paddle/phi/api/yaml/legacy_ops.yaml Outdated Show resolved Hide resolved
@0x45f
Copy link
Contributor Author

0x45f commented Mar 1, 2024

编译的问题应该是fused_bias_dropout_residual_layer_norm_grad之前迁移时参数顺序有问题,这里需要修改

  • paddle/phi/api/yaml/fused_backward.yaml中fused_bias_dropout_residual_layer_norm_grad定义中args项的参数顺序,需要将y_grad放到dropout_mask_out之后
  • FusedBiasDropoutResidualLnGradInferMeta参数也需要同步修复
  • FusedBiasDropoutResidualLnGradKernel参数顺序也需要同步修复

Copy link
Contributor

@sunzhongkai588 sunzhongkai588 left a comment

Choose a reason for hiding this comment

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

LGTM, no docs change

Copy link
Contributor

@XiaoguangHu01 XiaoguangHu01 left a comment

Choose a reason for hiding this comment

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

LGTM

@0x45f 0x45f merged commit 437293b into PaddlePaddle:develop Mar 4, 2024
30 checks passed
@0x45f 0x45f deleted the op-test branch March 4, 2024 11:03
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.

6 participants