VisionLearningGroup / caption-guided-saliency

Supplementary material to "Top-down Visual Saliency Guided by Captions" (CVPR 2017)
https://visionlearninggroup.github.io/caption-guided-saliency/
BSD 2-Clause "Simplified" License
107 stars 35 forks source link

Error while running training script #2

Closed kshitid20 closed 7 years ago

kshitid20 commented 7 years ago

Hi,

Firstly I would like to point out a small modification in README file. For training, your instruction says to run the preprocessing script "python preprocessing.py --dataset {MSR-VTT|Flickr30k} ", while it should be runs2vt.py.

While running the training script, I face following issue in s2vt_model.py:

line 24, in init self.lstm_cell = tf.contrib.rnn.LSTMCell(num_units = dim_hidden, AttributeError: 'module' object has no attribute 'LSTMCell'

kshitid20 commented 7 years ago

Replaced i.)tf.contrib.rnn.LSTMCell by tf.nn.rnn_cell.LSTMCell and similarly ii.)tf.contrib.rnn.DropoutWrapper by tf.nn.rnn_cell.DropoutWrapper

and it works. There was also an issue with tf.concat() where I got the following error:

TypeError: Expected int32, got list containing Tensors of type '_Message' instead.

Can be solved by swapping the order of parameters.

Thanks.

ramanishka commented 7 years ago

Hi,

Thanks for reporting the issue with README!

tf.nn.rnn_cell.LSTMCell was moved to tf.contrib.rnn.LSTMCell recently. The same with the order of parameters for concat: it was changed to be more similar to numpy. You are using TensoFlow version <1.0