knncolle_annoy
Annoy nearest neighbors in knncolle
Loading...
Searching...
No Matches
Public Member Functions | List of all members
knncolle_annoy::AnnoySearcher< Distance_, Dim_, Index_, Float_, InternalIndex_, InternalData_ > Class Template Reference

Searcher on an Annoy index. More...

#include <knncolle_annoy.hpp>

Inheritance diagram for knncolle_annoy::AnnoySearcher< Distance_, Dim_, Index_, Float_, InternalIndex_, InternalData_ >:
knncolle::Searcher< Index_, Float_ >

Public Member Functions

void search (Index_ i, Index_ k, std::vector< Index_ > *output_indices, std::vector< Float_ > *output_distances)
 
void search (const Float_ *query, Index_ k, std::vector< Index_ > *output_indices, std::vector< Float_ > *output_distances)
 
- Public Member Functions inherited from knncolle::Searcher< Index_, Float_ >
virtual bool can_search_all () const
 
virtual Index_ search_all (Index_ i, Float_ distance, std::vector< Index_ > *output_indices, std::vector< Float_ > *output_distances)
 
virtual Index_ search_all (const Float_ *query, Float_ distance, std::vector< Index_ > *output_indices, std::vector< Float_ > *output_distances)
 

Detailed Description

template<class Distance_, typename Dim_, typename Index_, typename Float_, typename InternalIndex_, typename InternalData_>
class knncolle_annoy::AnnoySearcher< Distance_, Dim_, Index_, Float_, InternalIndex_, InternalData_ >

Searcher on an Annoy index.

Instances of this class are usually constructed using AnnoyPrebuilt::initialize().

Template Parameters
Distance_An Annoy class to compute the distance between vectors, e.g., Annoy::Euclidean.
Dim_Integer type for the number of dimensions.
Index_Integer type for the indices.
Float_Floating point type for the query data and output distances.
InternalIndex_Integer type for the internal indices in Annoy.
InternalData_Floating point type for the internal data in Annoy.

Member Function Documentation

◆ search() [1/2]

void knncolle_annoy::AnnoySearcher< Distance_, Dim_, Index_, Float_, InternalIndex_, InternalData_ >::search ( const Float_ query,
Index_  k,
std::vector< Index_ > *  output_indices,
std::vector< Float_ > *  output_distances 
)
inlinevirtual

◆ search() [2/2]

void knncolle_annoy::AnnoySearcher< Distance_, Dim_, Index_, Float_, InternalIndex_, InternalData_ >::search ( Index_  i,
Index_  k,
std::vector< Index_ > *  output_indices,
std::vector< Float_ > *  output_distances 
)
inlinevirtual

The documentation for this class was generated from the following file: