Skip to content

Conversation

@huangjiyi
Copy link
Member

PR types

Others

PR changes

Others

Describe

  • move sequence_padding from fluid to phi

@paddle-bot
Copy link

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

#ifdef PADDLE_WITH_XPU
template <typename T>
class UnpaddingLoDTensorFunctor<platform::XPUDeviceContext, T> {
class UnpaddingLoDTensorFunctor<paddle::platform::XPUDeviceContext, T> {
Copy link
Contributor

Choose a reason for hiding this comment

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

XPUDeviceContext替换成phi下的XPUContext

Copy link
Member Author

Choose a reason for hiding this comment

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

已处理

cpu_seq.set_lod(lod);
cpu_seq.mutable_data<T>(seq_dims, paddle::platform::CPUPlace());
auto *dev_ctx = static_cast<phi::CPUContext *>(
paddle::platform::DeviceContextPool::Instance().Get(phi::CPUPlace()));
Copy link
Contributor

Choose a reason for hiding this comment

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

这里不需要使用从全局单例里拿对象,可以试试参数传入的context行不行

Copy link
Member Author

Choose a reason for hiding this comment

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

这个改成参数传入的 context 之后 CI-Windows 上的 sequence_padding 单测没办通过,我也不太清楚原因:cry:

@huangjiyi huangjiyi force-pushed the decouple_sequence_padding branch from 8149f88 to 977527d Compare February 21, 2023 03:55
@YuanRisheng YuanRisheng merged commit 5f44360 into PaddlePaddle:develop Feb 21, 2023
@huangjiyi huangjiyi deleted the decouple_sequence_padding branch March 8, 2023 15:52
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.

2 participants