未验证 提交 32c95f17 编写于 作者: Z zhaoyuchen2018 提交者: GitHub

Add StaticRNN.output code example (#18251)

refine StaticRNN api doc
test=develop
test=document_preview
上级 2f0d6826
...@@ -307,6 +307,7 @@ class StaticRNN(object): ...@@ -307,6 +307,7 @@ class StaticRNN(object):
hidden = fluid.layers.fc(input=[word, prev], size=hidden_size, act='relu') hidden = fluid.layers.fc(input=[word, prev], size=hidden_size, act='relu')
rnn.update_memory(prev, hidden) # set prev to hidden rnn.update_memory(prev, hidden) # set prev to hidden
rnn.step_output(hidden) rnn.step_output(hidden)
rnn.output(word)
result = rnn() result = rnn()
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册