Closed kpratik2015 closed 6 years ago
I am having the same problem as well. May I know which version of Python you are using?
Python 35.5.2
Hi everyone, the repo was developed with Tensorflow 0.12 and Python 2.7. Unfortunately Tensorflow 1.0 broke many of the APIs that the model relied on. I have a build on my machine that updates the code to TF >1.0 and Python 3.5, but then the pretrained model no longer loads since the variable names have changed. At some point I will get around to either fixing the variable names in the pretrained model or retraining a new model... but for now it is broken, and retraining a model takes months of GPU time (at least with the best hyperparameters that I was able to find).
I'm sorry!
@pender I am willing to give it a try and train against my GPU, what are the best hyper parameters that you found if i may ask (IE: Learning rate, decay rate, num layers, etc..)?
Thanks!
@nichcuta Hey did you try training the model? If it worked, could you maybe upload it?
@pender Do you mind sharing the updated code which you have with Tensorflow > 1.0 and Python 3.5. I would like to train a model of movie subtitles from opensubtitles in my GPU. Also do share the hyperparameters which would make our job easier. Thanks
As @pender stated there are a few things you have to change to get the project running on tensorflow 1.x and python 3. This specific bug can be fixed by changing: https://github.com/pender/chatbot-rnn/blob/a60a56eeed8521145ce9395e5c4a9cca9516bb6a/utils.py#L148
to self.tensor = np.array(list(map(self.vocab.get, data)))
Otherwise you feed np.array() a generator (in python 3, map() returns a generator). I may issue a PR with all the changes you have to do to the project soon.
I've worked off of @zenixls2's update to TensorFlow 1.2 to update the project to Python 3.5. I have put the code here, https://github.com/Dankrushen/chatbot-rnn, and you should be able to do everything except parse the Reddit comments (I'm open if anyone can fix that, but you should just be able to run it on Python 2.7).
Hi, I pushed a significant update to TF 1.4 and Python3, so I am closing out old issues -- feel free to reopen if this is still a problem, and I will take a look. (reddit-parse.py
has also been updated to Python 3 now.)