13 #ifndef MLPACK_METHODS_NEIGHBOR_SEARCH_NEIGHBOR_SEARCH_STAT_HPP 14 #define MLPACK_METHODS_NEIGHBOR_SEARCH_NEIGHBOR_SEARCH_STAT_HPP 25 template<
typename SortPolicy>
49 firstBound(SortPolicy::WorstDistance()),
50 secondBound(SortPolicy::WorstDistance()),
51 auxBound(SortPolicy::WorstDistance()),
58 template<
typename TreeType>
60 firstBound(SortPolicy::WorstDistance()),
61 secondBound(SortPolicy::WorstDistance()),
62 auxBound(SortPolicy::WorstDistance()),
70 firstBound = SortPolicy::WorstDistance();
71 secondBound = SortPolicy::WorstDistance();
72 auxBound = SortPolicy::WorstDistance();
94 template<
typename Archive>
97 ar(CEREAL_NVP(firstBound));
98 ar(CEREAL_NVP(secondBound));
99 ar(CEREAL_NVP(auxBound));
100 ar(CEREAL_NVP(lastDistance));
void Reset()
Reset statistic parameters to initial values.
Definition: neighbor_search_stat.hpp:68
NeighborSearchStat(TreeType &)
Initialization for a fully initialized node.
Definition: neighbor_search_stat.hpp:59
double & AuxBound()
Modify the aux bound.
Definition: neighbor_search_stat.hpp:87
Linear algebra utility functions, generally performed on matrices or vectors.
Definition: cv.hpp:1
void serialize(Archive &ar, const uint32_t)
Serialize the statistic to/from an archive.
Definition: neighbor_search_stat.hpp:95
Extra data for each node in the tree.
Definition: neighbor_search_stat.hpp:26
The core includes that mlpack expects; standard C++ includes and Armadillo.
double AuxBound() const
Get the aux bound.
Definition: neighbor_search_stat.hpp:85
NeighborSearchStat()
Initialize the statistic with the worst possible distance according to our sorting policy...
Definition: neighbor_search_stat.hpp:48
double SecondBound() const
Get the second bound.
Definition: neighbor_search_stat.hpp:81
double & FirstBound()
Modify the first bound.
Definition: neighbor_search_stat.hpp:79
double & SecondBound()
Modify the second bound.
Definition: neighbor_search_stat.hpp:83
double LastDistance() const
Get the last distance calculation.
Definition: neighbor_search_stat.hpp:89
double FirstBound() const
Get the first bound.
Definition: neighbor_search_stat.hpp:77
double & LastDistance()
Modify the last distance calculation.
Definition: neighbor_search_stat.hpp:91