-
Notifications
You must be signed in to change notification settings - Fork 5.7k
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
[Fluid] move ftrl to phi #56270
[Fluid] move ftrl to phi #56270
Conversation
你的PR提交成功,感谢你对开源项目的贡献! |
…into move-ftrl-to-phi
@huangjiyi 佬能否有空帮忙看下,哪里写的有问题。CI的错误看不懂 |
暂时看不出问题在哪,但是报错的信息和维度相关,我帮你调试一下 |
谢谢 |
Paddle/test/legacy_test/test_ftrl_op.py Lines 180 to 193 in 662df29
因为 ftrl_op 存在输入可能是 DenseTensor 和 SelectedRows 2 种情况,你在 PR 里把这 2 种情况拆分成了 2 个 Kernel 没问题,但是单测里测试 TestSparseFTRLOp 中指定的 op 还是 ftrl ,所以这里用到的 Kernel 还是 DenseTensor 情况的 FTRLOpKernel ,没有跑到 FTRLOpSparseKernel 导致 CI 里的报错
按我的理解要解决上面这个问题的话需要另外实现一个 op |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
参考paddle/phi/ops/compat/adam_sig.cc
,添加一个ftrl_op_sig.cc
。现在输入的类型可能为DenseTensor
或者SelectedRows
,op无法确定应该用FTRLKernel
还是FTRLSparseKernel
,目前应该是都匹配到了FTRLKernel
。在本地跑test_ftrl_op.py
,把Sparse相关的单测注释掉,是不会报Dim
相关的错误的。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
收到
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
那 ops.yaml 需要把 ftrl 加上吗?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
目前看着只有静态图用了ftrl这个op,可以先不加
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
我参考adam_sig.cc改了,还是在test那报错。不懂错误提示的是什么
test/legacy_test/test_ftrl_op.py
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
删除空行。可以在本地先跑通这个单测。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
收到
Sorry to inform you that 697e221's CIs have passed for more than 7 days. To prevent PR conflicts, you need to re-run all CIs manually. |
PR types
Others
PR changes
Others
Description
move ftrl to phi