Skip to content

Commit 370ae0b

Browse files
authored
fix BasicLSTMCell for TF1.0
BasicLSTMCell should be tf.contrib.rnn.BasicLSTMCell in TF1.0
1 parent b783c27 commit 370ae0b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

docs/user/tutorial.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1086,7 +1086,7 @@ To understand the PTB tutorial, you can also read `TensorFlow PTB tutorial
10861086
if is_training:
10871087
network = tl.layers.DropoutLayer(network, keep=keep_prob, name='drop1')
10881088
network = tl.layers.RNNLayer(network,
1089-
cell_fn=tf.nn.rnn_cell.BasicLSTMCell,
1089+
cell_fn=tf.contrib.rnn.BasicLSTMCell,
10901090
cell_init_args={'forget_bias': 0.0},
10911091
n_hidden=hidden_size,
10921092
initializer=tf.random_uniform_initializer(-init_scale, init_scale),
@@ -1097,7 +1097,7 @@ To understand the PTB tutorial, you can also read `TensorFlow PTB tutorial
10971097
if is_training:
10981098
network = tl.layers.DropoutLayer(network, keep=keep_prob, name='drop2')
10991099
network = tl.layers.RNNLayer(network,
1100-
cell_fn=tf.nn.rnn_cell.BasicLSTMCell,
1100+
cell_fn=tf.contrib.rnn.BasicLSTMCell,
11011101
cell_init_args={'forget_bias': 0.0},
11021102
n_hidden=hidden_size,
11031103
initializer=tf.random_uniform_initializer(-init_scale, init_scale),

0 commit comments

Comments
 (0)