tensorflow - Multi layer dynamic LSTM in tflearn -


i want feed imdb dataset multi layer dynamic lstm network seems next lstm layers couldn't parse previous layers output.

code:

net = tflearn.input_data([none, 100]) net = tflearn.embedding(net, input_dim=6819, output_dim=256) net = tflearn.lstm(net, 256, weights_init="xavier", dynamic=true, return_seq=true) net = tflearn.dropout(net, 0.8) net = tflearn.lstm(net, 256, weights_init="xavier", dynamic=true) net = tflearn.dropout(net, 0.8) net = tflearn.fully_connected(net, 2, activation='softmax') 

error:

traceback (most recent call last):   file "train.py", line 65, in <module>     model.fit(train_x, train_y, validation_set=(test_x, test_y), show_metric=true, batch_size=32)   file ".../tflearn/models/dnn.py", line 216, in fit     callbacks=callbacks)   file ".../tflearn/helpers/trainer.py", line 339, in fit     show_metric)   file ".../tflearn/helpers/trainer.py", line 818, in _train     feed_batch)   file ".../tensorflow/python/client/session.py", line 895, in run     run_metadata_ptr)   file ".../tensorflow/python/client/session.py", line 1100, in _run     % (np_val.shape, subfeed_t.name, str(subfeed_t.get_shape()))) valueerror: cannot feed value of shape (32, 2) tensor u'targetsdata/y:0', has shape '(100, 2)' 


Comments

Popular posts from this blog

ubuntu - PHP script to find files of certain extensions in a directory, returns populated array when run in browser, but empty array when run from terminal -

php - How can i create a user dashboard -

javascript - How to detect toggling of the fullscreen-toolbar in jQuery Mobile? -