-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
【Hackathon 6th No.50】 support backward for pylayer op #63319
【Hackathon 6th No.50】 support backward for pylayer op #63319
Conversation
add utility func
你的PR提交成功,感谢你对开源项目的贡献! |
add vjp handler in `call_vjp` interface
fix bugs for segmentation error
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.
Great work
for (size_t index = 0; index < num_operands(); ++index) { | ||
input_values.push_back(operand_source(index)); | ||
} | ||
return input_values; |
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.
Op是派生自OpBase,可以直接使用 return this->operation()->operands_source();
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.
直接使用 operand_source() 效果应该是一样的?
} | ||
|
||
PythonCallableRegistrar &PythonCallableRegistrar::GetInstance() { | ||
static PythonCallableRegistrar instance; |
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.
static PythonCallableRegistrar instance; | |
thread_local static PythonCallableRegistrar instance; |
Sorry to inform you that 3e6eae1's CIs have passed for more than 7 days. To prevent PR conflicts, you need to re-run all CIs manually. |
Sorry to inform you that a129b5f's CIs have passed for more than 7 days. To prevent PR conflicts, you need to re-run all CIs manually. |
@MarioLulab 需要解决下冲突 |
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.
LGTM
…3319) * create manual_pylayer_op files and add utility func * add instance for py_callable, add vjp handler in `call_vjp` interface * add backward testcases and fix bugs for segmentation error * update testcases and fix bugs * legacy_test/test_static_pylayer.py -> pir * code polish * pre-commit * remove redundant combine op * update dy2graph utils * add dy2st support * code polish * phi::errors -> common::erros * code polist * pre-commit * pre-commit
PR Category
Others
PR Types
New features
Description
manual_pylayer_op.cc
andmanual_pylayer_op.h
Pcard-80565