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

[OpCompat] add cast and repeat_interleave in op_compat.yaml #55467

Merged
merged 2 commits into from
Jul 18, 2023

Conversation

gouzil
Copy link
Member

@gouzil gouzil commented Jul 17, 2023

PR types

Others

PR changes

Others

Description

添加 cast 和 repeat_interleave 的算子参数映射

@paddle-bot
Copy link

paddle-bot bot commented Jul 17, 2023

你的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 contributor External developers status: proposed labels Jul 17, 2023
@luotao1 luotao1 added the HappyOpenSource 快乐开源活动issue与PR label Jul 17, 2023
@luotao1
Copy link
Contributor

luotao1 commented Jul 17, 2023

@kangguangli Coverage应该是随机挂,可以review了

- op : cast
inputs :
x : X

Copy link
Contributor

Choose a reason for hiding this comment

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

需要给output也添加映射

  outputs :
    out : Out

Copy link
Member Author

Choose a reason for hiding this comment

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

legacy_ops.yaml这里需不需要把

- op : cast
  args : (Tensor x, DataType dtype)
  output : Tensor

修改为

- op : cast
  args : (Tensor x, DataType dtype)
  output : Tensor(out)

Copy link
Contributor

Choose a reason for hiding this comment

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

应该不需要, @heavyrain-lzy 麻烦帮忙确认下

Copy link
Contributor

Choose a reason for hiding this comment

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

自动生成静态图代码中,如果output如果只有一个且不配置,默认为是out,不影响静态图代码自动生成;如果在new IR也可以这样使用默认配置的话,这里就可以不用修改

@kangguangli
Copy link
Contributor

@gouzil 这两个Op可能特殊点,可以注意比较下它们的xxx_op.cc文件和它们在legacy_ops.yaml中的定义,按上面的评论补充下

Copy link
Contributor

@kangguangli kangguangli left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@heavyrain-lzy heavyrain-lzy left a comment

Choose a reason for hiding this comment

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

LGTM

- op : cast
inputs :
x : X

Copy link
Contributor

Choose a reason for hiding this comment

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

自动生成静态图代码中,如果output如果只有一个且不配置,默认为是out,不影响静态图代码自动生成;如果在new IR也可以这样使用默认配置的话,这里就可以不用修改

@kangguangli kangguangli merged commit 922d248 into PaddlePaddle:develop Jul 18, 2023
cqulilujia pushed a commit to cqulilujia/Paddle that referenced this pull request Jul 24, 2023
wz1qqx pushed a commit to wz1qqx/Paddle that referenced this pull request Jul 31, 2023
@gouzil gouzil deleted the add_cast_in_compat branch April 23, 2024 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contributor External developers HappyOpenSource 快乐开源活动issue与PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants