Skip to content

Some nearest neighbor algos in python, using only Numpy (for reference)

License

Notifications You must be signed in to change notification settings

o19s/vector-search

Repository files navigation

(A reference project)

Just some code toying with nearest neighbors algorithms in Python. Numpy is the major dependency (note numpy is much faster if you install openblas).

Demos use 400k vocab, 300 dimensional Glove vectors

Exact Nearest Neighbors

Will find nearest neighbors of provided terms

python3 exact_nn.py cat bunny kitty

Simple Random Projections

Test 300 projection vectors to hash each vector, then compare recall to exact_nn:

python3 rand_proj.py 300

About

Some nearest neighbor algos in python, using only Numpy (for reference)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages