Skip to content

Commit

Permalink
Fix DiskANN LRU Set Invalid Medoid (#97)
Browse files Browse the repository at this point in the history
Signed-off-by: Patrick Weizhi Xu <[email protected]>
  • Loading branch information
PwzXxm committed Sep 19, 2023
1 parent e0a3769 commit 555c56d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion thirdparty/DiskANN/src/pq_flash_index.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1452,7 +1452,7 @@ namespace diskann {
}
}
}
if (k_search > 0) {
if (k_search > 0 && indices[0] != -1) {
lru_cache.put(vec_hash, indices[0]);
}

Expand Down

0 comments on commit 555c56d

Please sign in to comment.