3

I use ANN to predict words from words. The input and output are all words vectors. I do not know how to get words from the output of ANN. By the way, it's gensim I am using

IonuČ› G. Stan
  • 176,118
  • 18
  • 189
  • 202
Hitomi
  • 53
  • 6

1 Answers1

1

You can find cosine similarity of the vector with all other word-vectors to find the nearest neighbors of your vector.

The nearest neighbor search on an n-dimensional space, can be brute force, or you can use libraries like FLANN, Annoy, scikit-kdtree to do it more efficiently.

update

Sharing a gist demonstrating the same: https://gist.github.com/kampta/139f710ca91ed5fabaf9e6616d2c762b

kampta
  • 4,748
  • 5
  • 31
  • 51