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

Unify REGISTER_OP and REGISTER_OPERATOR #9911

Merged
merged 5 commits into from
Apr 18, 2018

Conversation

tonyyang-svail
Copy link

fix #7158

wangkuiyi
wangkuiyi previously approved these changes Apr 14, 2018
@tonyyang-svail tonyyang-svail changed the title [WIP] unify REGISTER_OP and REGISTER_OPERATOR Unify REGISTER_OP and REGISTER_OPERATOR Apr 17, 2018
@@ -558,95 +558,126 @@ Swish Activation Operator.

namespace ops = paddle::operators;

REGISTER_OP(sigmoid, ops::ActivationOp, ops::SigmoidOpMaker, sigmoid_grad,
ops::ActivationOpGrad);
REGISTER_OPERATOR(sigmoid, ops::ActivationOp, ops::SigmoidOpMaker,
Copy link
Member

Choose a reason for hiding this comment

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

one suggestion, add ; at the end of the register macro.

Copy link
Author

Choose a reason for hiding this comment

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

I will do it in a separate PR, where I will grep all the op files.

Copy link
Member

@jacquesqiao jacquesqiao left a comment

Choose a reason for hiding this comment

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

LGTM! Please add ; in another PR

@chengduoZH
Copy link
Contributor

Awsome! It is helpful to optimize memory usage and prevent hanging when running parallel_exe program in some degree.

@luotao1 luotao1 merged commit d84cdb7 into PaddlePaddle:develop Apr 18, 2018
This was referenced Apr 18, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

unify REGISTER_OP and REGISTER_OPERATOR
5 participants