saurabhmathur96 / Neural-Chatbot

A Neural Network based Chatbot
GNU General Public License v3.0
68 stars 27 forks source link

AttributeError: 'GRU' object has no attribute 'get_initial_states' #5

Closed akhilgentoo closed 7 years ago

akhilgentoo commented 7 years ago

Creating model with configuration: ModelConfig(sequence_length=8, vocabulary_size=2048, hidden_size=256, weights_path='models/seq2seq_weights.h5') Traceback (most recent call last): File "src/model/sample.py", line 16, in model = seq2seq_attention(sequence_length, vocabulary_size, hidden_size) File "/home/infinitylabs/Documents/Neural-Chatbot-master/src/model/models.py", line 60, in seq2seq_attention x = AttentionDecoder(hidden_size, activation=activation, return_sequences=True, bidirectional=bidirectional_decoder, use_gru=use_gru)(x, attention) File "/home/infinitylabs/Documents/Neural-Chatbot-master/src/model/sequence_blocks.py", line 172, in _decoder go_backwards=False), attention, single_attention_param=True)(x) File "build/bdist.linux-x86_64/egg/keras/engine/topology.py", line 587, in call File "/home/infinitylabs/Documents/Neural-Chatbot-master/src/model/sequence_blocks.py", line 102, in call initial_states = self.layer.get_initial_states(x) AttributeError: 'GRU' object has no attribute 'get_initial_states'

saurabhmathur96 commented 7 years ago

It seems you are using the incorrect version of Keras. Follow the instructions under Getting Started in README.md.

akhilgentoo commented 7 years ago

Thank you,let me see to it Will keep you posted

akhilgentoo commented 7 years ago

so,what version do you prefer?,i have seen this version issue before being raised?

saurabhmathur96 commented 7 years ago

see requirements.txt

akhilgentoo commented 7 years ago

should i install everything inside the requirements.txt??

https://paste.debian.net/980770/

gokulgsachu commented 7 years ago

python train.py Using TensorFlow backend. Traceback (most recent call last): File "train.py", line 10, in from batch_utils import BatchIterator ImportError: No module named batch_utils

Error occur while train data

akhilgentoo commented 7 years ago

same error i have

akhilgentoo commented 7 years ago

Thank you ,above issue has be solved.Problem was the version of keras and excecution path was wrong...