27 #include "kd_search.h"
113 for (
int i = 0; i < k; i++) {
124 void ANNkd_split::ann_search(
ANNdist box_dist)
133 child[
ANN_LO]->ann_search(box_dist);
139 box_dist = (
ANNdist) ANN_SUM(box_dist,
140 ANN_DIFF(ANN_POW(box_diff), ANN_POW(cut_diff)));
143 if (box_dist * ANNkdMaxErr < ANNkdPointMK->max_key())
144 child[
ANN_HI]->ann_search(box_dist);
148 child[
ANN_HI]->ann_search(box_dist);
154 box_dist = (
ANNdist) ANN_SUM(box_dist,
155 ANN_DIFF(ANN_POW(box_diff), ANN_POW(cut_diff)));
158 if (box_dist * ANNkdMaxErr < ANNkdPointMK->max_key())
159 child[
ANN_LO]->ann_search(box_dist);
172 void ANNkd_leaf::ann_search(
ANNdist box_dist)
183 for (
int i = 0; i < n_pts; i++) {
193 t = *(qq++) - *(pp++);
195 if( (dist = ANN_SUM(dist, ANN_POW(t))) > min_dist) {
void annkSearch(ANNpoint q, int k, ANNidxArray nn_idx, ANNdistArray dd, double eps=0.0)
McOptionsValues::McOptionsValues(#ifdef QUESO_USES_SEQUENCE_STATISTICAL_OPTIONS const SsOptionsValues *alternativePSsOptionsValues, const SsOptionsValues *alternativeQSsOptionsValues#endif if)(m_alternativeQSsOptionsValues=*alternativeQSsOptionsValues)
ANNdist annBoxDistance(const ANNpoint q, const ANNpoint lo, const ANNpoint hi, int dim)
void annError(const char *msg, ANNerr level)
const ANNbool ANN_ALLOW_SELF_MATCH