Skip to content

hardtanh prelu softmax, test=develop #2425

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

Merged
merged 11 commits into from
Aug 21, 2020
Merged

hardtanh prelu softmax, test=develop #2425

merged 11 commits into from
Aug 21, 2020

Conversation

qili93
Copy link
Contributor

@qili93 qili93 commented Aug 19, 2020

Softmax

  • paddle.nn.Softmax(axis=-1, name=None) - 添加此 class
  • paddle.nn.functional.softmax(x, axis=-1, dtype=None, name=None - 完善文档和demo;input->x;添加dtype参数;当axis=-1 的时候,如果cudnn可用,就use_cudnn=True,其他情况下 use_cudnn=False;忽略 _stacklevel

PRelu

  • paddle.nn.PReLU(num_parameters=1, init=0.25, weight_attr=None, name=None) - 添加此class, num_parameter决定是scalar还是channel模式,不再支持elementwise
  • paddle.nn.functional.prelu(x, weight, name=None) - mode 保留, 支持float64

Hardtanh

  • paddle.nn.Hardtanh(min=-1.0, max=1.0, name=None) - 添加此class
  • paddle.nn.functional.hardtanh(x, min=-1, max=1, name=None) - 新增此function

class_Hardtanh
function_hardtanh
class_PRelu
function_prelu
class_Softmax
function_softmax

@qili93
Copy link
Contributor Author

qili93 commented Aug 20, 2020

Hardtanh Eng Doc

class_Hardtanh
function_hardtanh

@qili93
Copy link
Contributor Author

qili93 commented Aug 20, 2020

PReLU Eng Doc

class_PReLU
function_prelu

@qili93
Copy link
Contributor Author

qili93 commented Aug 20, 2020

Softmax Eng Doc

class_Softmax
function_softmax

Copy link
Contributor

@zhupengyang zhupengyang 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
Collaborator

@TCChenlong TCChenlong left a comment

Choose a reason for hiding this comment

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

LGTM

@zhupengyang zhupengyang merged commit 1311089 into PaddlePaddle:develop Aug 21, 2020
@qili93 qili93 deleted the 20_new_api branch August 21, 2020 05:23
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.

3 participants