Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

334
Views
Finding k-nn with LSH when k > size of bucket

I've been reading up on the literature around locality sensitive hashing, and I think have a pretty good understanding of how it works. Considering the most simple case of a single hash table where each document is in only one bucket, my question is:

How do I find k nearest neighbours where k is greater than the number of documents in that bucket?

I've seen several methods to accomplish this. Some use a prefix tree. Others sort all the buckets by their hamming distance.

My constraints:

I have my document IDs stored in PostgreSQL alongside their respective buckets. A full table scan to calculate the hamming distance with each bucket is not feasible (I have hundreds of millions of documents). My bucket hash will likely be 24, or 32 bits (unless there is a suggestion against this). Does anyone have experience with, or suggested approaches on how to proceed?

over 4 years ago · Santiago Trujillo
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!