Navigation Menu

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

[New API] add new api paddle.mode and paddle.Tensor.mode #38446

Merged
merged 5 commits into from Dec 30, 2021

Conversation

zoooo0820
Copy link
Contributor

@zoooo0820 zoooo0820 commented Dec 24, 2021

PR types

New features

PR changes

OPs

Describe

add new api paddle.mode and paddle.Tensor.mode

mode-API文档-PaddlePaddle深度学习平台 - 10 136 157 23

mode-API Document-PaddlePaddle Deep Learning Platform - 10 136 157 23

@paddle-bot-old
Copy link

Thanks for your contribution!
Please wait for the result of CI firstly. See Paddle CI Manual for details.

@zoooo0820 zoooo0820 changed the title Mode api [New API] add new api paddle.mode and paddle.Tensor.mode Dec 27, 2021
}

template <typename DeviceContext, typename T>
class ModeCPUKernel : public framework::OpKernel<T> {
Copy link
Contributor

Choose a reason for hiding this comment

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

shall we define ModeCPUKernel and ModeOpCUDAKernel in one class template?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This will be fixed later

framework::DDim trans_out_dims(in_dims);

for (size_t i = 0; i < trans.size(); i++) {
trans_dims[i] = in_dims[trans[i]];
Copy link
Contributor

Choose a reason for hiding this comment

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

the variable name of trans/trans_dims is ambiguous, trans_axis or trans_shape may be clear ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

Copy link
Contributor

@jeff41404 jeff41404 left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@XiaoguangHu01 XiaoguangHu01 left a comment

Choose a reason for hiding this comment

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

LG API

@jeff41404 jeff41404 merged commit 3777779 into PaddlePaddle:develop Dec 30, 2021
@zoooo0820 zoooo0820 deleted the mode_api branch June 16, 2022 09:29
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.

None yet

4 participants