template class cvflann::AutotunedIndex
Overview
#include <autotuned_index.h> template <typename Distance> class AutotunedIndex: public cvflann::NNIndex { public: // typedefs typedef Distance::ResultType DistanceType; typedef Distance::ElementType ElementType; // structs struct CostData; // construction AutotunedIndex( const Matrix<ElementType>& inputData, const IndexParams& params = AutotunedIndexParams(), Distance d = Distance() ); AutotunedIndex(const AutotunedIndex&); // methods virtual void buildIndex(); virtual void findNeighbors( ResultSet<DistanceType>& result, const ElementType* vec, const SearchParams& searchParams ); virtual IndexParams getParameters() const; SearchParams getSearchParameters() const; float getSpeedup() const; virtual flann_algorithm_t getType() const; virtual void loadIndex(FILE* stream); AutotunedIndex& operator=(const AutotunedIndex&); virtual void saveIndex(FILE* stream); virtual size_t size() const; virtual int usedMemory() const; virtual size_t veclen() const; };
Inherited Members
public: // methods virtual void buildIndex() = 0; virtual void findNeighbors( ResultSet<DistanceType>& result, const ElementType* vec, const SearchParams& searchParams ) = 0; virtual IndexParams getParameters() const = 0; virtual flann_algorithm_t getType() const = 0; virtual void knnSearch( const Matrix<ElementType>& queries, Matrix<int>& indices, Matrix<DistanceType>& dists, int knn, const SearchParams& params ); virtual void loadIndex(FILE* stream) = 0; virtual int radiusSearch( const Matrix<ElementType>& query, Matrix<int>& indices, Matrix<DistanceType>& dists, float radius, const SearchParams& params ); virtual void saveIndex(FILE* stream) = 0; virtual size_t size() const = 0; virtual int usedMemory() const = 0; virtual size_t veclen() const = 0;
Detailed Documentation
Methods
virtual void buildIndex()
Method responsible with building the index.
virtual void findNeighbors( ResultSet<DistanceType>& result, const ElementType* vec, const SearchParams& searchParams )
Method that searches for nearest-neighbors
virtual IndexParams getParameters() const
Returns:
The index parameters
virtual flann_algorithm_t getType() const
Algorithm name
virtual void loadIndex(FILE* stream)
Loads the index from a stream
virtual void saveIndex(FILE* stream)
Saves the index to a stream
virtual size_t size() const
Number of features in this index.
virtual int usedMemory() const
The amount of memory (in bytes) this index uses.
virtual size_t veclen() const
The length of each vector in this index.