kavgan / nlp-in-practice

Starter code to solve real world text data problems. Includes: Gensim Word2Vec, phrase embeddings, Text Classification with Logistic Regression, word count with pyspark, simple text preprocessing, pre-trained embeddings and more.
http://kavita-ganesan.com/kavitas-tutorials/#.WvIizNMvyog
1.14k stars 785 forks source link

model name is incorrect #8

Open shantanuo opened 4 years ago

shantanuo commented 4 years ago

There is a typo in the script. The name of the model is model_glove_twitter and not just model in this code:

for p in phrases:
    tokens_1=[t for t in p.split() if t in model.wv.vocab]
    tokens_2=[t for t in query.split() if t in model.wv.vocab]

https://github.com/kavgan/nlp-in-practice/blob/master/pre-trained-embeddings/Pre-trained%20embeddings.ipynb