-
Notifications
You must be signed in to change notification settings - Fork 295
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Fix to "ValueError: could not convert string to float:" #6
Comments
I encountered the same question as you did. Could you please show me the way to solve this? |
Hi, |
I encounter the problem too, and the solution doesn't work for me~ I don't understand why reading the model_path is related to 'convert string to float'? |
I am facing the same problem |
change to : model_params = pickle.load(open(model_path, 'rb'), encoding='iso-8859-1') |
On what platform are you running this code。 |
The idea of loading pickle file is to load a binary coded file. since the models they have prepared are in string format you need to recreate the model files by loading the dictionaries out of the models by pickle.load and then dump it into another pickle file. or you can use different types of encoding on pickle.load |
|
When I try to run the code with Rule Agent's prams, I got this:
ValueError: could not convert string to float:
My solution is changing the file-pointer loading style from "rb" to "r", and it works for me.
Two place need to fix:
line 50 in nlu.py
line138 in nlg.py
I know someone may not encounter the error, and just could enjoy the code perfectly.
The text was updated successfully, but these errors were encountered: