提交 f24dec71 编写于 作者: W wanghaoshuang

Change 'layers' to 'fluid.layers'

上级 c43edffb
...@@ -1004,7 +1004,7 @@ def array_read(array, i): ...@@ -1004,7 +1004,7 @@ def array_read(array, i):
tmp = fluid.layers.zeros(shape=[10], dtype='int32') tmp = fluid.layers.zeros(shape=[10], dtype='int32')
i = fluid.layers.fill_constant(shape=[1], dtype='int64', value=10) i = fluid.layers.fill_constant(shape=[1], dtype='int64', value=10)
arr = layers.array_read(tmp, i=i) arr = fluid.layers.array_read(tmp, i=i)
""" """
helper = LayerHelper('array_read', **locals()) helper = LayerHelper('array_read', **locals())
......
...@@ -2916,9 +2916,9 @@ def warpctc(input, label, blank=0, norm_by_times=False): ...@@ -2916,9 +2916,9 @@ def warpctc(input, label, blank=0, norm_by_times=False):
.. code-block:: python .. code-block:: python
label = layers.data(shape=[11, 8], dtype='float32', lod_level=1) label = fluid.layers.data(shape=[11, 8], dtype='float32', lod_level=1)
predict = layers.data(shape=[11, 1], dtype='float32') predict = fluid.layers.data(shape=[11, 1], dtype='float32')
cost = layers.warpctc(input=predict, label=label) cost = fluid.layers.warpctc(input=predict, label=label)
""" """
helper = LayerHelper('warpctc', **locals()) helper = LayerHelper('warpctc', **locals())
...@@ -2982,7 +2982,7 @@ def sequence_reshape(input, new_dim): ...@@ -2982,7 +2982,7 @@ def sequence_reshape(input, new_dim):
.. code-block:: python .. code-block:: python
x = fluid.layers.data(shape=[5, 20], dtype='float32', lod_level=1) x = fluid.layers.data(shape=[5, 20], dtype='float32', lod_level=1)
x_reshaped = layers.sequence_reshape(input=x, new_dim=10) x_reshaped = fluid.layers.sequence_reshape(input=x, new_dim=10)
""" """
helper = LayerHelper('sequence_reshape', **locals()) helper = LayerHelper('sequence_reshape', **locals())
out = helper.create_tmp_variable(helper.input_dtype()) out = helper.create_tmp_variable(helper.input_dtype())
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册