Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
zhupengyang committed Aug 13, 2020
1 parent 5537638 commit c3d423f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions python/paddle/nn/layer/activation.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ class Hardshrink(layers.Layer):
paddle.disable_static()
x = paddle.to_variable(np.array([-1, 0.3, 2.5]))
hd = paddle.nn.Hardshrink()
out = hd(x) # [-1., 0., 2.5]
m = paddle.nn.Hardshrink()
out = m(x) # [-1., 0., 2.5]
"""

def __init__(self, threshold=0.5, name=None):
Expand Down

0 comments on commit c3d423f

Please sign in to comment.