Skip to content

Commit cde66ed

Browse files
Merge branch 'develop' of https://github.com/PaddlePaddle/FluidDoc into 1211-update-layers
2 parents a9b2445 + fc6df31 commit cde66ed

File tree

19 files changed

+408
-408
lines changed

19 files changed

+408
-408
lines changed

doc/fluid/advanced_usage/deploy/index_cn.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
预测部署
33
########
44

5-
- `原生预测引擎 <inference/index_cn.html>`_ :介绍了支持模型部署上线的Fluid C++ API
5+
- `服务器端部署 <inference/index_cn.html>`_ :介绍了支持模型部署上线的Fluid C++ API
66

77
- `移动端部署 <mobile/index_cn.html>`_:介绍了 PaddlePaddle组织下的嵌入式平台深度学习框架Paddle-Mobile
88

doc/fluid/advanced_usage/deploy/inference/windows_cpp_inference.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -48,33 +48,33 @@ Cmake可以在[官网进行下载](https://cmake.org/download/),并添加到
4848
执行完毕后,build 目录如图所示,打开箭头指向的 solution 文件:
4949

5050
<p align="center">
51-
<img src="https://raw.githubusercontent.com/PaddlePaddle/FluidDoc/develop/doc/fluid/user_guides/howto/inference/image/image3.png">
51+
<img src="https://raw.githubusercontent.com/PaddlePaddle/FluidDoc/develop/doc/fluid/advanced_usage/deploy/inference/image/image3.png">
5252
</p>
5353

5454
修改编译属性为 `/MT`
5555

5656
<p align="center">
57-
<img src="https://raw.githubusercontent.com/PaddlePaddle/FluidDoc/develop/doc/fluid/user_guides/howto/inference/image/image4.png">
57+
<img src="https://raw.githubusercontent.com/PaddlePaddle/FluidDoc/develop/doc/fluid/advanced_usage/deploy/inference/image/image4.png">
5858
</p>
5959

6060
<p align="center">
61-
<img src="https://raw.githubusercontent.com/PaddlePaddle/FluidDoc/develop/doc/fluid/user_guides/howto/inference/image/image5.png">
61+
<img src="https://raw.githubusercontent.com/PaddlePaddle/FluidDoc/develop/doc/fluid/advanced_usage/deploy/inference/image/image5.png">
6262
</p>
6363

6464
编译生成选项改成 `Release`
6565

6666
<p align="center">
67-
<img src="https://raw.githubusercontent.com/PaddlePaddle/FluidDoc/develop/doc/fluid/user_guides/howto/inference/image/image6.png">
67+
<img src="https://raw.githubusercontent.com/PaddlePaddle/FluidDoc/develop/doc/fluid/advanced_usage/deploy/inference/image/image6.png">
6868
</p>
6969

7070
<p align="center">
71-
<img src="https://raw.githubusercontent.com/PaddlePaddle/FluidDoc/develop/doc/fluid/user_guides/howto/inference/image/image7.png">
71+
<img src="https://raw.githubusercontent.com/PaddlePaddle/FluidDoc/develop/doc/fluid/advanced_usage/deploy/inference/image/image7.png">
7272
</p>
7373

7474
将提供的依赖包中,Release下的openblas和模型文件拷贝到编译生成的Release下。
7575

7676
<p align="center">
77-
<img src="https://raw.githubusercontent.com/PaddlePaddle/FluidDoc/develop/doc/fluid/user_guides/howto/inference/image/image8.png">
77+
<img src="https://raw.githubusercontent.com/PaddlePaddle/FluidDoc/develop/doc/fluid/advanced_usage/deploy/inference/image/image8.png">
7878
</p>
7979

8080
通过cmd进到Release目录执行:
@@ -88,6 +88,6 @@ Cmake可以在[官网进行下载](https://cmake.org/download/),并添加到
8888
`simple_on_word2vec.exe --dirname=.\word2vec.inference.model`
8989

9090
<p align="center">
91-
<img src="https://raw.githubusercontent.com/PaddlePaddle/FluidDoc/develop/doc/fluid/user_guides/howto/inference/image/image9.png">
91+
<img src="https://raw.githubusercontent.com/PaddlePaddle/FluidDoc/develop/doc/fluid/advanced_usage/deploy/inference/image/image9.png">
9292
</p>
9393

doc/fluid/api_cn/clip_cn.rst

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -108,12 +108,12 @@ GradientClipByNorm
108108

109109
.. code-block:: python
110110
111-
w_param_attrs = ParamAttr(name=None,
112-
initializer=UniformInitializer(low=-1.0, high=1.0, seed=0),
111+
w_param_attrs = fluid.ParamAttr(name=None,
112+
initializer=fluid.initializer.UniformInitializer(low=-1.0, high=1.0, seed=0),
113113
learning_rate=1.0,
114-
regularizer=L1Decay(1.0),
114+
regularizer=fluid.regularizer.L1Decay(1.0),
115115
trainable=True,
116-
clip=GradientClipByNorm(clip_norm=2.0))
116+
clip=fluid.clip.GradientClipByNorm(clip_norm=2.0))
117117
y_predict = fluid.layers.fc(input=x, size=1, param_attr=w_param_attrs)
118118
119119
@@ -147,12 +147,12 @@ GradientClipByValue
147147

148148
.. code-block:: python
149149
150-
w_param_attrs = ParamAttr(name=None,
151-
initializer=UniformInitializer(low=-1.0, high=1.0, seed=0),
150+
w_param_attrs = fluid.ParamAttr(name=None,
151+
initializer=fluid.initializer.UniformInitializer(low=-1.0, high=1.0, seed=0),
152152
learning_rate=1.0,
153-
regularizer=L1Decay(1.0),
153+
regularizer=fluid.regualrizer.L1Decay(1.0),
154154
trainable=True,
155-
clip=GradientClipByValue(-1.0, 1.0))
155+
clip=fluid.clip.GradientClipByValue(-1.0, 1.0))
156156
y_predict = fluid.layers.fc(input=x, size=1, param_attr=w_param_attrs)
157157
158158

doc/fluid/api_cn/executor_cn.rst

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -81,10 +81,11 @@ feed map为该program提供输入数据。fetch_list提供program训练结束后
8181
.. code-block:: python
8282
8383
84-
data = layers.data(name='X', shape=[1], dtype='float32')
85-
hidden = layers.fc(input=data, size=10)
86-
layers.assign(hidden, out)
87-
loss = layers.mean(out)
84+
data = fluid.layers.data(name='X', shape=[1], dtype='float32')
85+
out = fluid.layers.create_tensor(dtype='float32')
86+
hidden = fluid.layers.fc(input=data, size=10)
87+
fluid.layers.assign(hidden, out)
88+
loss = fluid.layers.mean(out)
8889
adam = fluid.optimizer.Adam()
8990
adam.minimize(loss)
9091
@@ -93,8 +94,8 @@ feed map为该program提供输入数据。fetch_list提供program训练结束后
9394
9495
9596
cpu = core.CPUPlace()
96-
exe = Executor(cpu)
97-
exe.run(default_startup_program())
97+
exe = fluid.Executor(cpu)
98+
exe.run(fluid.default_startup_program())
9899
99100
.. code-block:: python
100101

doc/fluid/api_cn/fluid_cn.rst

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1060,12 +1060,12 @@ name_scope
10601060

10611061
.. code-block:: python
10621062
1063-
with name_scope("encoder"):
1064-
...
1065-
with name_scope("decoder"):
1066-
...
1067-
with name_scope("attention"):
1068-
...
1063+
with name_scope("encoder"):
1064+
...
1065+
with name_scope("decoder"):
1066+
...
1067+
with name_scope("attention"):
1068+
...
10691069
10701070
10711071

doc/fluid/api_cn/index_cn.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ API
1616
io_cn.rst
1717
layers_cn.rst
1818
metrics_cn.rst
19-
net_cn.rst
19+
nets_cn.rst
2020
optimizer_cn.rst
2121
param_attr_cn.rst
2222
profiler_cn.rst

0 commit comments

Comments
 (0)