-
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
[PTen]Elementwise_div Kernel Refactor #37418
[PTen]Elementwise_div Kernel Refactor #37418
Conversation
Thanks for your contribution! |
ASSERT_EQ(dense_out.meta().dtype, pten::DataType::FLOAT32); | ||
ASSERT_EQ(dense_out.meta().layout, pten::DataLayout::NCHW); |
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.
Maybe dense_out.dtype()
and dense_out.layout()
is better
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.
OK
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
@@ -114,6 +114,30 @@ void ElementwiseSub(const CPUContext& dev_ctx, | |||
} | |||
} | |||
|
|||
template <typename T> | |||
void ElementwiseDiv(const CPUContext& dev_ctx, |
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.
中间层kernel API和底层kernel API的命名是不是一致比较好,可以后续统一更改下
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.
好的,下个pr改一下
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
* elementwise_div refactor * fix compile bugs in windows ci
PR types
Others
PR changes
OPs
Describe
move elementwise_div kernel from fluid_dir to pten_dir and refactor it.