This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
print("Odd word out:", word2vec.doesnt_match("banana apple grapes carrot".split())) | |
print("-"*10) | |
print("Cosine similarity between TV and HBO:", word2vec.similarity("tv", "hbo")) | |
print("-"*10) | |
print("Most similar words to Computers:", ", ".join(map(lambda x: x[0], word2vec.most_similar("computers")))) | |
print("-"*10) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment