Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make Vectors.most_similar super fast by loading from cache #88

Merged
merged 16 commits into from
Nov 21, 2019

Conversation

ines
Copy link
Member

@ines ines commented Nov 21, 2019

More reliable solution and also how we're going to do it for the updated demo 🎉 Using the 06_precompute_cache.py script, nearest-neighbor queries can be pre-computed and saved with the component. This makes the data larger, but the most_similar super fast. If a cache is available, it's loaded from disk/bytes and used. If not, most_similar falls back to using Vectors.most_similar.

Resolves #86.

@ines ines marked this pull request as ready for review November 21, 2019 01:52
@honnibal honnibal merged commit 0c0965f into master Nov 21, 2019
@ines ines deleted the feature/cache branch November 21, 2019 15:51
@svlandeg svlandeg added demo Online demo enhancement Feature requests and improvements labels Apr 14, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
demo Online demo enhancement Feature requests and improvements
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Possible to speed up most_similar?
3 participants