facebookresearch / MUSE

A library for Multilingual Unsupervised or Supervised word Embeddings
Other
3.18k stars 544 forks source link

Assertion Error in supervised.py and unsupervised.py (get_word_pairs) #122

Closed ldmichel closed 5 years ago

ldmichel commented 5 years ago

Help! I keep getting the same Assertion Error in running supervised.py and unsupervised.py.

I'm trying to map English as source with German as target language.

At first I thought it's because of FAISS being not installed in my Windows. But after successfully downloading FAISS in my Windows Subsystem for Linux, I see the same error.

Please see error message below:

Traceback (most recent call last): File "supervised.py", line 101, in evaluator.all_eval(to_log) File "/mnt/c/Users/Leah/Documents/MUSE-master/src/evaluation/evaluator.py", line 215, in all_eval self.monolingual_wordsim(to_log) File "/mnt/c/Users/Leah/Documents/MUSE-master/src/evaluation/evaluator.py", line 44, in monolingual_wordsim self.mapping(self.src_emb.weight).data.cpu().numpy() File "/mnt/c/Users/Leah/Documents/MUSE-master/src/evaluation/wordsim.py", line 105, in get_wordsim_scores coeff, found, not_found = get_spearman_rho(word2id, embeddings, filepath, lower) File "/mnt/c/Users/Leah/Documents/MUSE-master/src/evaluation/wordsim.py", line 69, in get_spearman_rho word_pairs = get_word_pairs(path) File "/mnt/c/Users/Leah/Documents/MUSE-master/src/evaluation/wordsim.py", line 36, in get_word_pairs assert len(line) > 3 AssertionError

IreneZihuiLi commented 5 years ago

I had the same error, did you solve it?

simlaharma commented 5 years ago

I had the same too!