openai / generating-reviews-discovering-sentiment

Code for "Learning to Generate Reviews and Discovering Sentiment"
https://arxiv.org/abs/1704.01444
MIT License
1.51k stars 379 forks source link

Does not work with TensorFlow 1.0 #16

Closed hckr closed 7 years ago

hckr commented 7 years ago

I tried to run example, but it does not work due to changes in TensorFlow 1.0. Why don't you use the newest version?

https://www.tensorflow.org/install/migration

$ python -c 'import tensorflow as tf; print(tf.__version__)' 
1.0.1
$ python encoder.py 
Traceback (most recent call last):
  File "encoder.py", line 209, in <module>
    mdl = Model()
  File "encoder.py", line 143, in __init__
    cells, states, logits = model(X, S, M, reuse=False)
  File "encoder.py", line 90, in model
    cstart, hstart = tf.unpack(S, num=hps.nstates)
AttributeError: module 'tensorflow' has no attribute 'unpack'
hckr commented 7 years ago

Just noticed it's a duplicate of #4.