- Type Parameters:
K
- the type of keys.
V
- the type of associated objects.
- All Known Implementing Classes:
- CoverTree, KDTree, LinearSearch, LSH, MPLSH, MutableLSH
public interface NearestNeighborSearch<K,V>
Nearest neighbor search, also known as proximity search, similarity search
or closest point search, is an optimization problem for finding closest
points in metric spaces. The problem is: given a set S of points in a metric
space M and a query point q ∈ M, find the closest point in S to q.
In machine learning, we often build a nearest neighbor search data structure,
and then search with object in the same dataset. The object itsef is of course
the nearest one with distance 0. But this is meaningless and we therefore do
the reference check during the search and excludes the query object from the
results.