Skip to content

Commit 9aa65bb

Browse files
committed
add tab format.
1 parent 5e0bc13 commit 9aa65bb

File tree

1 file changed

+15
-15
lines changed
  • python/paddle/fluid/layers

1 file changed

+15
-15
lines changed

python/paddle/fluid/layers/nn.py

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -6843,8 +6843,8 @@ def elu(x, alpha=1.0, name=None):
68436843
68446844
.. code-block:: python
68456845
6846-
x = fluid.layers.data(name="x", shape=[3,10,32,32], dtype="float32")
6847-
y = fluid.layers.elu(x, alpha=0.2)
6846+
x = fluid.layers.data(name="x", shape=[3,10,32,32], dtype="float32")
6847+
y = fluid.layers.elu(x, alpha=0.2)
68486848
"""
68496849
helper = LayerHelper('elu', **locals())
68506850
out = helper.create_variable_for_type_inference(dtype=x.dtype)
@@ -6873,8 +6873,8 @@ def relu6(x, threshold=6.0, name=None):
68736873
68746874
.. code-block:: python
68756875
6876-
x = fluid.layers.data(name="x", shape=[3,10,32,32], dtype="float32")
6877-
y = fluid.layers.relu6(x, threshold=6.0)
6876+
x = fluid.layers.data(name="x", shape=[3,10,32,32], dtype="float32")
6877+
y = fluid.layers.relu6(x, threshold=6.0)
68786878
"""
68796879
helper = LayerHelper('relu6', **locals())
68806880
out = helper.create_variable_for_type_inference(dtype=x.dtype)
@@ -6903,8 +6903,8 @@ def pow(x, factor=1.0, name=None):
69036903
69046904
.. code-block:: python
69056905
6906-
x = fluid.layers.data(name="x", shape=[3,10,32,32], dtype="float32")
6907-
y = fluid.layers.pow(x, factor=2.0)
6906+
x = fluid.layers.data(name="x", shape=[3,10,32,32], dtype="float32")
6907+
y = fluid.layers.pow(x, factor=2.0)
69086908
"""
69096909
helper = LayerHelper('pow', **locals())
69106910
out = helper.create_variable_for_type_inference(dtype=x.dtype)
@@ -6934,8 +6934,8 @@ def stanh(x, scale_a=2.0 / 3.0, scale_b=1.7159, name=None):
69346934
69356935
.. code-block:: python
69366936
6937-
x = fluid.layers.data(name="x", shape=[3,10,32,32], dtype="float32")
6938-
y = fluid.layers.stanh(x, scale_a=0.6667, scale_b=1.7159)
6937+
x = fluid.layers.data(name="x", shape=[3,10,32,32], dtype="float32")
6938+
y = fluid.layers.stanh(x, scale_a=0.6667, scale_b=1.7159)
69396939
"""
69406940
helper = LayerHelper('stanh', **locals())
69416941
out = helper.create_variable_for_type_inference(dtype=x.dtype)
@@ -6966,8 +6966,8 @@ def hard_sigmoid(x, slope=0.2, offset=0.5, name=None):
69666966
69676967
.. code-block:: python
69686968
6969-
x = fluid.layers.data(name="x", shape=[3,10,32,32], dtype="float32")
6970-
y = fluid.layers.hard_sigmoid(x, slope=0.3, offset=0.8)
6969+
x = fluid.layers.data(name="x", shape=[3,10,32,32], dtype="float32")
6970+
y = fluid.layers.hard_sigmoid(x, slope=0.3, offset=0.8)
69716971
"""
69726972
helper = LayerHelper('hard_sigmoid', **locals())
69736973
out = helper.create_variable_for_type_inference(dtype=x.dtype)
@@ -6997,8 +6997,8 @@ def swish(x, beta=1.0, name=None):
69976997
69986998
.. code-block:: python
69996999
7000-
x = fluid.layers.data(name="x", shape=[3,10,32,32], dtype="float32")
7001-
y = fluid.layers.swish(x, beta=2.0)
7000+
x = fluid.layers.data(name="x", shape=[3,10,32,32], dtype="float32")
7001+
y = fluid.layers.swish(x, beta=2.0)
70027002
"""
70037003
helper = LayerHelper('swish', **locals())
70047004
out = helper.create_variable_for_type_inference(dtype=x.dtype)
@@ -7034,9 +7034,9 @@ def prelu(x, mode, param_attr=None, name=None):
70347034
70357035
.. code-block:: python
70367036
7037-
x = fluid.layers.data(name="x", shape=[10,10], dtype="float32")
7038-
mode = 'channel'
7039-
output = fluid.layers.prelu(x,mode)
7037+
x = fluid.layers.data(name="x", shape=[10,10], dtype="float32")
7038+
mode = 'channel'
7039+
output = fluid.layers.prelu(x,mode)
70407040
"""
70417041
helper = LayerHelper('prelu', **locals())
70427042
if mode not in ['all', 'channel', 'element']:

0 commit comments

Comments
 (0)