language2pose
language2pose copied to clipboard
FileNotFoundError: [Errno 2] No such file or directory: 'sentences.txt'
Hi,
Thanks for your great work and the public code! After I met early stopping and restart training, an error occurred:
File "train_wordConditioned.py", line 285, in
argparseNloop(train) File "language2pose/src/argsUtils.py", line 137, in argparseNloop loop(args, i) File "train_wordConditioned.py", line 279, in train render_new_sentences(args, exp_num, data) File "language2pose/src/sample_wordConditioned_newSentence.py", line 213, in sample with open(args.view, 'r') as f: FileNotFoundError: [Errno 2] No such file or directory: 'sentences.txt'
Where can I find "sentences.txt"?
Thanks!
What command do you use to restart training?
It seems the model restart training by itself after showing the below sentences (I also attached the whole errors):
Validation Loss is increasing Saving Model by early stopping Loading the best model and running the sample loop
Results Loaded Data already loaded!! Yessss! Seq2Seq Model not found. Initialising randomly Loaded Word2Vec model Tokenization example Who was Jim Henson ? Jim Henson was a puppeteer ---> ['who', 'was', 'jim', '_UNK', '_UNK', 'jim', '_UNK', 'was', '_UNK', 'puppeteer'] Model Created Loading Model exp: 0, epch: 0, lr:None +------+--------+--------+--------+ | | train | dev | test | +------+--------+--------+--------+ | loss | 0.1877 | 0.2359 | 0.2234 | +------+--------+--------+--------+ Rendering New Sentences Traceback (most recent call last): File "train_wordConditioned.py", line 285, in
argparseNloop(train) File "language2pose/src/argsUtils.py", line 137, in argparseNloop loop(args, i) File "train_wordConditioned.py", line 279, in train render_new_sentences(args, exp_num, data) File "language2pose/src/sample_wordConditioned_newSentence.py", line 213, in sample with open(args.view, 'r') as f: FileNotFoundError: [Errno 2] No such file or directory: 'sentences.txt'
It seems we need to download the file "sentences.txt" first, but I cannot find it.
The sentences from the dataset are probably rendered as csv files. Let me know if you can't find them.
If you wish to render animations for new sentences, you can create a file called sentences.txt and run python sample_wordConditioned_newSentence.py
. Although, this model does not seem to work well if we don't have a good starting pose.
Thanks for your kind reply. But in the above error, it needs to load "sentences.txt" directly rather than csv files. The args.view is "sentences.txt." Do I need to change this argument?
File "language2pose/src/sample_wordConditioned_newSentence.py", line 213, in sample with open(args.view, 'r') as f: FileNotFoundError: [Errno 2] No such file or directory: 'sentences.txt'
the error is at lines 277-279 in the file train_wordConditioned.py
. These lines can generate animations for user input sentences. These sentences are to be stored in a file called sentences.txt. You can create an empty file called sentences.txt in your directory to prevent the error from showing up. Another way would be to comment out lines 277-279. Moreover, the samples from the test data have already been rendered in the save directory. You do not need to re-train the model again. Let me know if you have trouble finding the rendered files.