I successfully install the sent2vec python module globally. However, while I tried to predict the vector using the wiki_unigram model, the output is a 600 dim vector with all element 0. Does anyone know what's wrong with it ? Thanks a lot! Meanwhile, when I tried the cml,
./fasttext print-sentence-vectors wiki_unigrams.bin < test.txt,
There was an assertion error:
Assertion failed: (counts.size() == osz_), function setTargetCounts, file src/model.cc, line 226. Abort trap: 6
Code below:
import sent2vecmodel = sent2vec.Sent2vecModel()model.load_model('wiki_unigrams.bin'print(model)emb = model.embed_sentence(" I do not know why you said so . ") print(emb)
I successfully install the sent2vec python module globally. However, while I tried to predict the vector using the wiki_unigram model, the output is a 600 dim vector with all element 0. Does anyone know what's wrong with it ? Thanks a lot! Meanwhile, when I tried the cml,
./fasttext print-sentence-vectors wiki_unigrams.bin < test.txt
, There was an assertion error:Assertion failed: (counts.size() == osz_), function setTargetCounts, file src/model.cc, line 226. Abort trap: 6
Code below:
import sent2vec
model = sent2vec.Sent2vecModel()
model.load_model('wiki_unigrams.bin'
print(model)
emb = model.embed_sentence(" I do not know why you said so . ")
print(emb)
output: `[[0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 0.