tencia / stocks_rnn

Stock price prediction with LSTMs in TensorFlow
Apache License 2.0
443 stars 192 forks source link

ImportError: This module is deprecated. Use tf.nn.rnn_* instead. #4

Open Chin-I opened 7 years ago

Chin-I commented 7 years ago

Can anyone provide a new version code?

(tensorflow) dhcp-v097-009:stocks_rnn-master Gene$ python train_stock_lstm.py Traceback (most recent call last): File "train_stocklstm.py", line 13, in from tensorflow.models.rnn import rnn File "/Users/Gene/anaconda2/envs/tensorflow/lib/python2.7/site-packages/tensorflow/models/rnn/rnn.py", line 21, in raise ImportError("This module is deprecated. Use tf.nn.rnn instead.") ImportError: This module is deprecated. Use tf.nn.rnn_ instead.

shawnliucmcm commented 7 years ago

Replace tensorflow.models.rnn with tensorflow.python.ops, and it should work.