Import a word using Word2Vec and show how it performs in terms of the similarity?

385    Asked by SnehaPandey in Data Science , Asked on Dec 24, 2019
Answered by Sneha Pandey

For Wordage, we need to import the library from the gen sim.


Here are some points

sentences: the list of split sentences.

size: the dimensionality of the embedding vector

window the number of context words you are looking at

mincount: tells the model to ignore words with total count less than this number.

workers: the number of threads being used

sg: whether to use skip-gram or CBOW

Let us see which word is similar to the word ‘man’


The output is given below


It seems that the words like ‘Woman’, ‘kid’, ‘guy’ are the most similar to the word ‘man’


Your Answer

Interviews

Parent Categories