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

[JIT]Layer supports eager dygraph mode and Polish Function interface #44283

Merged
merged 3 commits into from
Jul 13, 2022

Conversation

Aurelius84
Copy link
Contributor

@Aurelius84 Aurelius84 commented Jul 13, 2022

PR types

New features

PR changes

Others

Describe

[JIT]Layer support eager dygraph mode and polish Function interface

  • Python端的接口支持了新动态图,不再支持老动态图
  • 移除了BaseFunction中 vector 接口形态,修改为 vector,以适配Phi的形态
  • 新增vector 接口形态,更有利于C++的开发

@paddle-bot
Copy link

paddle-bot bot commented Jul 13, 2022

你的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.

for (auto &out_name : names) {

std::vector<DenseTensor> ToDenseTensors(const std::vector<Tensor> &tensors) {
std::vector<DenseTensor> ret;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

这里也许用 std::vector<DenseTensor*> ret 更高效

@@ -28,39 +28,21 @@ namespace py = pybind11;
namespace paddle {
namespace pybind {

PyTypeObject *g_executor_function_pytype = nullptr;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

后续PR会把PEFunction也暴露出来,并添加一个FLAGS控制Load函数加载进来时默认的BaseFunction类型

Copy link
Contributor

@pangyoki pangyoki left a comment

Choose a reason for hiding this comment

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

LGTM for removing enable_legacy_mode

Copy link
Contributor

@0x45f 0x45f left a comment

Choose a reason for hiding this comment

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

LGTM

@Aurelius84 Aurelius84 merged commit 05d5bbf into PaddlePaddle:develop Jul 13, 2022
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.

3 participants