-
Notifications
You must be signed in to change notification settings - Fork 5.7k
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
[phi]migrate increment addmm multinomial cholesky kernels to phi #39858
[phi]migrate increment addmm multinomial cholesky kernels to phi #39858
Conversation
const DenseTensor& x, | ||
int num_samples, | ||
bool replacement, | ||
DenseTensor* out); | ||
|
||
template <typename T> | ||
void MultinomialFunctor(int64_t* out_data, const T* in_data, |
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.
MultinomialFunctor 不要放到kernel 声明的头文件中,可以放到paddle/phi/kernels/funcs 下
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.
多谢,我在迁InferShape函数的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.
可以下个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
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 for overall,细节后续PR可以完善下
@@ -0,0 +1,28 @@ | |||
/* Copyright (c) 2021 PaddlePaddle Authors. All Rights Reserved. |
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.
2022?
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.
多谢
|
||
namespace phi { | ||
|
||
KernelSignature AddmmOpArgumentMapping(const ArgumentMappingContext& 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.
这个和opmaker的顺序一致,后面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.
了解,InferShape迁移中会移除。
|
||
namespace phi { | ||
|
||
KernelSignature CholeskyOpArgumentMapping(const ArgumentMappingContext& 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.
同上,应该也不需要写,默认生成的就可以用,这些ArgumentMapping函数之所以放到compat目录下,就是希望将来可以移除的,所以我们不写不必要的
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.
了解,InferShape迁移中会移除。
PR types
Others
PR changes
Others
Describe
Migrate increment addmm multinomial and cholesky kernel to phi.
TODO: migrate InferShape funcs. move MultinomialFunctor to paddle/phi/kernels/funcs.