You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I run this code on python3, and I get a error,plaese help me.
Traceback (most recent call last):
File "G:/postgradute_learn/01code/text-to-image-master/generate_thought_vectors.py", line 33, in
main()
File "G:/postgradute_learn/01code/text-to-image-master/generate_thought_vectors.py", line 23, in main
model = skipthoughts.load_model()
File "G:\postgradute_learn\01code\text-to-image-master\skipthoughts.py", line 64, in load_model
utable, btable = load_tables()
File "G:\postgradute_learn\01code\text-to-image-master\skipthoughts.py", line 87, in load_tables
utable = numpy.load(path_to_tables + 'utable.npy', encoding='latin1')
File "C:\Users\Administrator\Anaconda3\lib\site-packages\numpy\lib\npyio.py", line 406, in load
pickle_kwargs=pickle_kwargs)
File "C:\Users\Administrator\Anaconda3\lib\site-packages\numpy\lib\format.py", line 637, in read_array
array = pickle.load(fp, **pickle_kwargs)
EOFError: Ran out of input
I am sorry, I don't think you're running the same code version as the one I posted here.
This is a slightly modified skipthought.py which should be able to run in python3.
The original one (master branch) can only run in python2.
I think you should start a new issue.
I think you should check what the variable 'path_to_tables' really is, perhaps print the variable out.
Also check whether the file path_to_tables + 'utable.npy' exists or not.
Thank you for your reply.
I have found the couse of the error. because utable.npy file has gone bad,so load have an error. I download it again, it can work.
Anyway, thank you for your contribution.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.