OpenNMT-py
OpenNMT-py copied to clipboard
StopIteration
I was trying to create glove embeddings using the following command ./tools/embeddings_to_torch.py -emb_file_both /OpenNMT-py/glove_dir/glove.6B.100d.txt -dict_file "data/data.vocab.pt" -output_file "data/embeddings"
but I'm getting:
Saving embedding as:
* enc: data/embeddings.enc.pt
* dec: data/embeddings.dec.pt
Traceback (most recent call last):
File "./tools/embeddings_to_torch.py", line 160, in
Can someone help?
This StopIteration
means that it reached the end of the iterator.
This means your src_vectors
is probably empty or in the wrong format.
Thanks for the reply! What could be causing this error? I am using the same format as src-train-case.txt except that I am using two features.