Skip to content

Add Identity OP#34420

Merged
jzhang533 merged 10 commits intoPaddlePaddle:developfrom
shiyutang:develop
Aug 2, 2021
Merged

Add Identity OP#34420
jzhang533 merged 10 commits intoPaddlePaddle:developfrom
shiyutang:develop

Conversation

@shiyutang
Copy link
Contributor

@shiyutang shiyutang commented Jul 27, 2021

PR types

New features

PR changes

OPs

Describe

Add Identity op which have the same functionality as torch.nn.Identity, if we define the "m" as the identity layer, it creates following results.
Ineut-tensor - poddle to-tensorCmrpy rondon rondnC1z, 20))

@paddle-bot-old
Copy link

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

@CLAassistant
Copy link

CLAassistant commented Jul 27, 2021

CLA assistant check
All committers have signed the CLA.

@shiyutang shiyutang requested a review from ZHUI July 28, 2021 08:00
@shiyutang shiyutang changed the title Identity OP Add Identity OP Jul 28, 2021
michaelowenliu
michaelowenliu previously approved these changes Jul 28, 2021
Copy link

@michaelowenliu michaelowenliu 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

@ZHUI ZHUI left a comment

Choose a reason for hiding this comment

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

LGTM

class Identity(Layer):
r"""

A placeholder identity operator that is argument-insensitive. For each input :math:`X` ,
Copy link
Contributor

Choose a reason for hiding this comment

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

只支持一个输入,一个输出吧。
这里用for each,感觉是支持多个输入的。

@jzhang533 jzhang533 merged commit 80f7f7e into PaddlePaddle:develop Aug 2, 2021
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.

5 participants