pender / chatbot-rnn

A toy chatbot powered by deep learning and trained on data from Reddit
MIT License
899 stars 370 forks source link

IndexError: index 0 is out of bounds for axis 0 with size 0 #17

Closed theskullcrusher closed 7 years ago

theskullcrusher commented 7 years ago

I get this error while trying to set custom rnn_size=50 and batch_size=10 to train my model ( set of .txt files) as suggested in one of the issues to solve the OOM error. I'm running a p2.xlarge instance and i've tried other combinations too.

File "/home/ubuntu/chatbot-rnn/utils.py", line 184, in _load_preprocessed ydata[-1] = xdata[0] IndexError: index 0 is out of bounds for axis 0 with size 0

theskullcrusher commented 7 years ago

I found that it was caused due to a problem in the input file when there's no data. Since the scripts were generating txt data in required format, it took time to check. You might want to check input training files in your _load_preprocessed function