nabo_experimental.h
Go to the documentation of this file.
1 /*
2 
3 Copyright (c) 2010--2011, Stephane Magnenat, ASL, ETHZ, Switzerland
4 You can contact the author at <stephane at magnenat dot net>
5 
6 All rights reserved.
7 
8 Redistribution and use in source and binary forms, with or without
9 modification, are permitted provided that the following conditions are met:
10  * Redistributions of source code must retain the above copyright
11  notice, this list of conditions and the following disclaimer.
12  * Redistributions in binary form must reproduce the above copyright
13  notice, this list of conditions and the following disclaimer in the
14  documentation and/or other materials provided with the distribution.
15  * Neither the name of the <organization> nor the
16  names of its contributors may be used to endorse or promote products
17  derived from this software without specific prior written permission.
18 
19 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
20 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
21 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22 DISCLAIMED. IN NO EVENT SHALL ETH-ASL BE LIABLE FOR ANY
23 DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
25 LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
26 ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 
30 */
31 
32 #ifndef __NABO_EXPERIMENTAL_H
33 #define __NABO_EXPERIMENTAL_H
34 
35 #include "../nabo/nabo_private.h"
36 #include "../nabo/index_heap.h"
37 
38 namespace Nabo
39 {
40  // KDTree, balanced, points in nodes
41  template<typename T, typename CloudType>
42  struct KDTreeBalancedPtInNodes:public NearestNeighbourSearch<T, CloudType>
43  {
48 
49  protected:
50  struct BuildPoint
51  {
53  size_t index;
54  BuildPoint(const Vector& pos = Vector(), const size_t index = 0): pos(pos), index(index) {}
55  };
56  typedef std::vector<BuildPoint> BuildPoints;
57  typedef typename BuildPoints::iterator BuildPointsIt;
58  typedef typename BuildPoints::const_iterator BuildPointsCstIt;
59 
60  struct CompareDim
61  {
62  size_t dim;
63  CompareDim(const size_t dim):dim(dim){}
64  bool operator() (const BuildPoint& p0, const BuildPoint& p1) { return p0.pos(dim) < p1.pos(dim); }
65  };
66 
67  struct Node
68  {
70  int dim; // -1 == leaf, -2 == invalid
72  Node(const Vector& pos = Vector(), const int dim = -2, const Index index = 0):pos(pos), dim(dim), index(index) {}
73  };
74  typedef std::vector<Node> Nodes;
75 
77 
78  inline size_t childLeft(size_t pos) const { return 2*pos + 1; }
79  inline size_t childRight(size_t pos) const { return 2*pos + 2; }
80  inline size_t parent(size_t pos) const { return (pos-1)/2; }
81  size_t getTreeSize(size_t size) const;
83  void buildNodes(const BuildPointsIt first, const BuildPointsIt last, const size_t pos);
84  void dump(const Vector minValues, const Vector maxValues, const size_t pos) const;
85 
86  protected:
88  };
89 
90  // KDTree, balanced, points in nodes, priority queue
91  template<typename T, typename CloudType>
93  {
100 
105 
106  protected:
108  {
109  size_t index;
111 
112  SearchElement(const size_t index, const T minDist): index(index), minDist(minDist) {}
113  // invert test as std::priority_queue shows biggest element at top
114  friend bool operator<(const SearchElement& e0, const SearchElement& e1) { return e0.minDist > e1.minDist; }
115  };
116 
117  public:
119  virtual IndexVector knn(const Vector& query, const Index k, const T epsilon, const unsigned optionFlags);
120  };
121 
122  // KDTree, balanced, points in nodes, stack
123  template<typename T, typename CloudType>
125  {
132 
137 
139 
140  protected:
141  void recurseKnn(const Vector& query, const size_t n, T rd, Heap& heap, Vector& off, const T maxError, const bool allowSelfMatch);
142 
143  public:
145  virtual IndexVector knn(const Vector& query, const Index k, const T epsilon, const unsigned optionFlags);
146  };
147 
148 
149  // KDTree, balanced, points in leaves, stack
150  template<typename T, typename CloudType>
152  {
157 
162 
163  protected:
164  struct BuildPoint
165  {
167  size_t index;
168  BuildPoint(const Vector& pos = Vector(), const size_t index = 0): pos(pos), index(index) {}
169  };
170  typedef std::vector<BuildPoint> BuildPoints;
171  typedef typename BuildPoints::iterator BuildPointsIt;
172  typedef typename BuildPoints::const_iterator BuildPointsCstIt;
173 
174  struct CompareDim
175  {
176  size_t dim;
177  CompareDim(const size_t dim):dim(dim){}
178  bool operator() (const BuildPoint& p0, const BuildPoint& p1) { return p0.pos(dim) < p1.pos(dim); }
179  };
180 
182 
183  struct Node
184  {
185  int dim; // -1 == invalid, <= -2 = index of pt
187  Node(const int dim = -1, const T cutVal = 0):
188  dim(dim), cutVal(cutVal) {}
189  };
190  typedef std::vector<Node> Nodes;
191 
193 
194  inline size_t childLeft(size_t pos) const { return 2*pos + 1; }
195  inline size_t childRight(size_t pos) const { return 2*pos + 2; }
196  inline size_t parent(size_t pos) const { return (pos-1)/2; }
197  size_t getTreeSize(size_t size) const;
198  void buildNodes(const BuildPointsIt first, const BuildPointsIt last, const size_t pos, const Vector minValues, const Vector maxValues, const bool balanceVariance);
199  void recurseKnn(const Vector& query, const size_t n, T rd, Heap& heap, Vector& off, const T maxError, const bool allowSelfMatch);
200 
201  public:
202  KDTreeBalancedPtInLeavesStack(const CloudType& cloud, const bool balanceVariance);
203  virtual IndexVector knn(const Vector& query, const Index k, const T epsilon, const unsigned optionFlags);
204  };
205 
206  // KDTree, unbalanced, points in leaves, stack, implicit bounds, ANN_KD_SL_MIDPT
207  template<typename T, typename Heap, typename CloudType>
209  {
215 
220 
221  protected:
222  struct BuildPoint
223  {
225  size_t index;
226  BuildPoint(const Vector& pos = Vector(), const size_t index = 0): pos(pos), index(index) {}
227  };
228  typedef std::vector<BuildPoint> BuildPoints;
229  typedef typename BuildPoints::iterator BuildPointsIt;
230  typedef typename BuildPoints::const_iterator BuildPointsCstIt;
231 
232  struct CompareDim
233  {
234  size_t dim;
235  CompareDim(const size_t dim):dim(dim){}
236  bool operator() (const BuildPoint& p0, const BuildPoint& p1) { return p0.pos(dim) < p1.pos(dim); }
237  };
238 
239  struct Node
240  {
241  enum
242  {
243  INVALID_CHILD = 0xffffffff,
244  INVALID_PT = 0xffffffff
245  };
246  unsigned dim;
247  unsigned rightChild;
248  union
249  {
251  unsigned ptIndex;
252  };
253 
254  Node(const int dim, const T cutVal, unsigned rightChild):
256  Node(const unsigned ptIndex = INVALID_PT):
258  };
259  typedef std::vector<Node> Nodes;
260 
262 
263  unsigned buildNodes(const BuildPointsIt first, const BuildPointsIt last, const Vector minValues, const Vector maxValues);
264  void recurseKnn(const Vector& query, const unsigned n, T rd, Heap& heap, Vector& off, const T maxError, const bool allowSelfMatch);
265 
266  public:
268  virtual IndexVector knn(const Vector& query, const Index k, const T epsilon, const unsigned optionFlags);
269  virtual IndexMatrix knnM(const Matrix& query, const Index k, const T epsilon, const unsigned optionFlags);
270  };
271 
272  // KDTree, unbalanced, points in leaves, stack, explicit bounds, ANN_KD_SL_MIDPT
273  template<typename T, typename CloudType>
275  {
280 
281 
286 
287  protected:
288  struct BuildPoint
289  {
291  size_t index;
292  BuildPoint(const Vector& pos = Vector(), const size_t index = 0): pos(pos), index(index) {}
293  };
294  typedef std::vector<BuildPoint> BuildPoints;
295  typedef typename BuildPoints::iterator BuildPointsIt;
296  typedef typename BuildPoints::const_iterator BuildPointsCstIt;
297 
298  struct CompareDim
299  {
300  size_t dim;
301  CompareDim(const size_t dim):dim(dim){}
302  bool operator() (const BuildPoint& p0, const BuildPoint& p1) { return p0.pos(dim) < p1.pos(dim); }
303  };
304 
306 
307  struct Node
308  {
309  int dim; // <= -1 = index of pt
310  unsigned rightChild;
314  Node(const int dim = -1, const T cutVal = 0, const T lowBound = 0, const T highBound = 0, unsigned rightChild = 0):
316  };
317  typedef std::vector<Node> Nodes;
318 
320 
321  unsigned buildNodes(const BuildPointsIt first, const BuildPointsIt last, const Vector minValues, const Vector maxValues);
322  void recurseKnn(const Vector& query, const size_t n, T rd, Heap& heap, const T maxError, const bool allowSelfMatch);
323 
324  public:
326  virtual IndexVector knn(const Vector& query, const Index k, const T epsilon, const unsigned optionFlags);
327  };
328 }
329 
330 #endif // __NABO_H
Nabo::KDTreeBalancedPtInLeavesStack::BuildPoints
std::vector< BuildPoint > BuildPoints
Definition: nabo_experimental.h:170
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::CompareDim
Definition: nabo_experimental.h:298
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::BuildPoint::pos
Vector pos
Definition: nabo_experimental.h:224
Nabo
Namespace for Nabo.
Definition: experimental/kdtree_cpu.cpp:40
Nabo::KDTreeBalancedPtInLeavesStack::Node::cutVal
T cutVal
Definition: nabo_experimental.h:186
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::BuildPointsIt
BuildPoints::iterator BuildPointsIt
Definition: nabo_experimental.h:229
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::recurseKnn
void recurseKnn(const Vector &query, const size_t n, T rd, Heap &heap, const T maxError, const bool allowSelfMatch)
Definition: experimental/kdtree_cpu.cpp:866
Nabo::KDTreeBalancedPtInLeavesStack
Definition: nabo_experimental.h:151
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::Vector
NearestNeighbourSearch< T, CloudType >::Vector Vector
Definition: nabo_experimental.h:210
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::Node
Definition: nabo_experimental.h:307
Nabo::KDTreeBalancedPtInNodes::BuildPoint
Definition: nabo_experimental.h:50
Nabo::KDTreeBalancedPtInNodesPQ
Definition: nabo_experimental.h:92
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack
Definition: nabo_experimental.h:208
Nabo::KDTreeBalancedPtInNodes::Node::dim
int dim
Definition: nabo_experimental.h:70
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::knn
virtual IndexVector knn(const Vector &query, const Index k, const T epsilon, const unsigned optionFlags)
Definition: experimental/kdtree_cpu.cpp:846
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::CompareDim::CompareDim
CompareDim(const size_t dim)
Definition: nabo_experimental.h:235
Nabo::KDTreeBalancedPtInNodes::BuildPoint::pos
Vector pos
Definition: nabo_experimental.h:52
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::Vector
NearestNeighbourSearch< T, CloudType >::Vector Vector
Definition: nabo_experimental.h:276
Nabo::KDTreeBalancedPtInNodes::nodes
Nodes nodes
Definition: nabo_experimental.h:76
Nabo::KDTreeBalancedPtInLeavesStack::Heap
IndexHeapSTL< Index, T > Heap
Definition: nabo_experimental.h:181
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::Node::Node
Node(const int dim=-1, const T cutVal=0, const T lowBound=0, const T highBound=0, unsigned rightChild=0)
Definition: nabo_experimental.h:314
Nabo::KDTreeBalancedPtInNodesStack::Index
NearestNeighbourSearch< T, CloudType >::Index Index
Definition: nabo_experimental.h:128
Nabo::KDTreeBalancedPtInNodes::Node::Node
Node(const Vector &pos=Vector(), const int dim=-2, const Index index=0)
Definition: nabo_experimental.h:72
Index
NNSNabo::Index Index
Definition: python/nabo.cpp:11
Nabo::KDTreeBalancedPtInNodesStack::Nodes
KDTreeBalancedPtInNodes< T, CloudType >::Nodes Nodes
Definition: nabo_experimental.h:131
Nabo::KDTreeBalancedPtInLeavesStack::Node::dim
int dim
Definition: nabo_experimental.h:185
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::BuildPointsCstIt
BuildPoints::const_iterator BuildPointsCstIt
Definition: nabo_experimental.h:296
Nabo::KDTreeBalancedPtInNodes::IndexVector
NearestNeighbourSearch< T, CloudType >::IndexVector IndexVector
Definition: nabo_experimental.h:47
Nabo::KDTreeBalancedPtInNodesStack::knn
virtual IndexVector knn(const Vector &query, const Index k, const T epsilon, const unsigned optionFlags)
Definition: experimental/kdtree_cpu.cpp:291
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::Node
Definition: nabo_experimental.h:239
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::CompareDim
Definition: nabo_experimental.h:232
Nabo::NearestNeighbourSearch< T, CloudType >::cloud
const CloudType & cloud
the reference to the data-point cloud, which must remain valid during the lifetime of the NearestNeig...
Definition: nabo.h:274
Nabo::KDTreeBalancedPtInLeavesStack::knn
virtual IndexVector knn(const Vector &query, const Index k, const T epsilon, const unsigned optionFlags)
Definition: experimental/kdtree_cpu.cpp:472
Nabo::NearestNeighbourSearch< T, CloudType >::CloudType
CloudType CloudType
a column-major Eigen matrix in which each column is a point; this matrix has dim rows
Definition: nabo.h:265
Nabo::KDTreeBalancedPtInLeavesStack::Matrix
NearestNeighbourSearch< T, CloudType >::Matrix Matrix
Definition: nabo_experimental.h:154
Nabo::KDTreeBalancedPtInNodesPQ::SearchElement
Definition: nabo_experimental.h:107
Nabo::KDTreeBalancedPtInNodes::KDTreeBalancedPtInNodes
KDTreeBalancedPtInNodes(const CloudType &cloud)
Definition: experimental/kdtree_cpu.cpp:171
Nabo::KDTreeBalancedPtInNodes::Node::pos
Vector pos
Definition: nabo_experimental.h:69
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::knnM
virtual IndexMatrix knnM(const Matrix &query, const Index k, const T epsilon, const unsigned optionFlags)
Definition: experimental/kdtree_cpu.cpp:655
Nabo::KDTreeBalancedPtInNodesPQ::SearchElement::minDist
T minDist
Definition: nabo_experimental.h:110
Nabo::KDTreeBalancedPtInLeavesStack::Node::Node
Node(const int dim=-1, const T cutVal=0)
Definition: nabo_experimental.h:187
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::CompareDim::operator()
bool operator()(const BuildPoint &p0, const BuildPoint &p1)
Definition: nabo_experimental.h:236
Nabo::KDTreeBalancedPtInNodes::CompareDim::CompareDim
CompareDim(const size_t dim)
Definition: nabo_experimental.h:63
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::BuildPoint
Definition: nabo_experimental.h:222
Nabo::KDTreeBalancedPtInNodesPQ::Nodes
KDTreeBalancedPtInNodes< T, CloudType >::Nodes Nodes
Definition: nabo_experimental.h:99
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::Node::INVALID_CHILD
@ INVALID_CHILD
Definition: nabo_experimental.h:243
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::BuildPoint
Definition: nabo_experimental.h:288
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::BuildPoint::BuildPoint
BuildPoint(const Vector &pos=Vector(), const size_t index=0)
Definition: nabo_experimental.h:226
Nabo::KDTreeBalancedPtInNodesPQ::IndexVector
NearestNeighbourSearch< T, CloudType >::IndexVector IndexVector
Definition: nabo_experimental.h:97
Nabo::KDTreeBalancedPtInLeavesStack::Index
NearestNeighbourSearch< T, CloudType >::Index Index
Definition: nabo_experimental.h:155
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::IndexVector
NearestNeighbourSearch< T, CloudType >::IndexVector IndexVector
Definition: nabo_experimental.h:213
Nabo::KDTreeBalancedPtInNodes::buildNodes
void buildNodes(const BuildPointsIt first, const BuildPointsIt last, const size_t pos)
Definition: experimental/kdtree_cpu.cpp:87
Nabo::KDTreeBalancedPtInNodes::BuildPoint::index
size_t index
Definition: nabo_experimental.h:53
Nabo::KDTreeBalancedPtInNodesPQ::Node
KDTreeBalancedPtInNodes< T, CloudType >::Node Node
Definition: nabo_experimental.h:98
Nabo::KDTreeBalancedPtInLeavesStack::BuildPoint::BuildPoint
BuildPoint(const Vector &pos=Vector(), const size_t index=0)
Definition: nabo_experimental.h:168
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::IndexMatrix
NearestNeighbourSearch< T, CloudType >::IndexMatrix IndexMatrix
Definition: nabo_experimental.h:214
Nabo::KDTreeBalancedPtInNodes::Nodes
std::vector< Node > Nodes
Definition: nabo_experimental.h:74
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::nodes
Nodes nodes
Definition: nabo_experimental.h:319
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::CompareDim::CompareDim
CompareDim(const size_t dim)
Definition: nabo_experimental.h:301
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::Heap
IndexHeapSTL< Index, T > Heap
Definition: nabo_experimental.h:305
Nabo::KDTreeBalancedPtInNodesStack::Heap
IndexHeapSTL< Index, T > Heap
Definition: nabo_experimental.h:138
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::Node::dim
int dim
Definition: nabo_experimental.h:309
Nabo::KDTreeBalancedPtInLeavesStack::CompareDim::operator()
bool operator()(const BuildPoint &p0, const BuildPoint &p1)
Definition: nabo_experimental.h:178
Nabo::KDTreeBalancedPtInNodesStack
Definition: nabo_experimental.h:124
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::knn
virtual IndexVector knn(const Vector &query, const Index k, const T epsilon, const unsigned optionFlags)
Definition: experimental/kdtree_cpu.cpp:634
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::BuildPointsIt
BuildPoints::iterator BuildPointsIt
Definition: nabo_experimental.h:295
Nabo::KDTreeBalancedPtInNodes::BuildPoint::BuildPoint
BuildPoint(const Vector &pos=Vector(), const size_t index=0)
Definition: nabo_experimental.h:54
Nabo::KDTreeBalancedPtInNodesPQ::Vector
NearestNeighbourSearch< T, CloudType >::Vector Vector
Definition: nabo_experimental.h:94
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::BuildPoint::BuildPoint
BuildPoint(const Vector &pos=Vector(), const size_t index=0)
Definition: nabo_experimental.h:292
Nabo::KDTreeBalancedPtInLeavesStack::nodes
Nodes nodes
Definition: nabo_experimental.h:192
Nabo::NearestNeighbourSearch
Nearest neighbour search interface, templatized on scalar type.
Definition: nabo.h:258
Nabo::KDTreeBalancedPtInNodes::BuildPointsCstIt
BuildPoints::const_iterator BuildPointsCstIt
Definition: nabo_experimental.h:58
Nabo::KDTreeBalancedPtInNodes::dump
void dump(const Vector minValues, const Vector maxValues, const size_t pos) const
Definition: experimental/kdtree_cpu.cpp:137
Nabo::KDTreeBalancedPtInNodesStack::KDTreeBalancedPtInNodesStack
KDTreeBalancedPtInNodesStack(const CloudType &cloud)
Definition: experimental/kdtree_cpu.cpp:285
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::Index
NearestNeighbourSearch< T, CloudType >::Index Index
Definition: nabo_experimental.h:278
Nabo::KDTreeBalancedPtInNodes::Matrix
NearestNeighbourSearch< T, CloudType >::Matrix Matrix
Definition: nabo_experimental.h:45
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::KDTreeUnbalancedPtInLeavesExplicitBoundsStack
KDTreeUnbalancedPtInLeavesExplicitBoundsStack(const CloudType &cloud)
Definition: experimental/kdtree_cpu.cpp:824
Nabo::KDTreeBalancedPtInLeavesStack::recurseKnn
void recurseKnn(const Vector &query, const size_t n, T rd, Heap &heap, Vector &off, const T maxError, const bool allowSelfMatch)
Definition: experimental/kdtree_cpu.cpp:493
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::Node::cutVal
T cutVal
Definition: nabo_experimental.h:250
Nabo::KDTreeBalancedPtInNodes::childLeft
size_t childLeft(size_t pos) const
Definition: nabo_experimental.h:78
Nabo::KDTreeBalancedPtInNodesPQ::SearchElement::index
size_t index
Definition: nabo_experimental.h:109
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::BuildPointsCstIt
BuildPoints::const_iterator BuildPointsCstIt
Definition: nabo_experimental.h:230
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::Node::cutVal
T cutVal
Definition: nabo_experimental.h:311
Nabo::KDTreeBalancedPtInLeavesStack::Node
Definition: nabo_experimental.h:183
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::CompareDim::operator()
bool operator()(const BuildPoint &p0, const BuildPoint &p1)
Definition: nabo_experimental.h:302
Nabo::KDTreeBalancedPtInLeavesStack::childRight
size_t childRight(size_t pos) const
Definition: nabo_experimental.h:195
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::BuildPoints
std::vector< BuildPoint > BuildPoints
Definition: nabo_experimental.h:294
Nabo::KDTreeBalancedPtInLeavesStack::Nodes
std::vector< Node > Nodes
Definition: nabo_experimental.h:190
Nabo::KDTreeBalancedPtInLeavesStack::buildNodes
void buildNodes(const BuildPointsIt first, const BuildPointsIt last, const size_t pos, const Vector minValues, const Vector maxValues, const bool balanceVariance)
Definition: experimental/kdtree_cpu.cpp:388
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::Node::Node
Node(const int dim, const T cutVal, unsigned rightChild)
Definition: nabo_experimental.h:254
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::BuildPoint::pos
Vector pos
Definition: nabo_experimental.h:290
Nabo::KDTreeBalancedPtInLeavesStack::CompareDim
Definition: nabo_experimental.h:174
Nabo::KDTreeBalancedPtInLeavesStack::Vector
NearestNeighbourSearch< T, CloudType >::Vector Vector
Definition: nabo_experimental.h:153
Nabo::KDTreeBalancedPtInNodes::getTreeSize
size_t getTreeSize(size_t size) const
Definition: experimental/kdtree_cpu.cpp:61
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::Node::INVALID_PT
@ INVALID_PT
Definition: nabo_experimental.h:244
Nabo::KDTreeBalancedPtInLeavesStack::CompareDim::dim
size_t dim
Definition: nabo_experimental.h:176
Nabo::IndexHeapSTL
balanced-tree implementation of heap
Definition: index_heap.h:52
Nabo::KDTreeBalancedPtInLeavesStack::getTreeSize
size_t getTreeSize(size_t size) const
Definition: experimental/kdtree_cpu.cpp:368
Nabo::KDTreeBalancedPtInNodes::Vector
NearestNeighbourSearch< T, CloudType >::Vector Vector
Definition: nabo_experimental.h:44
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::nodes
Nodes nodes
Definition: nabo_experimental.h:261
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::Node::lowBound
T lowBound
Definition: nabo_experimental.h:312
Nabo::KDTreeBalancedPtInLeavesStack::childLeft
size_t childLeft(size_t pos) const
Definition: nabo_experimental.h:194
Nabo::KDTreeBalancedPtInNodesPQ::KDTreeBalancedPtInNodesPQ
KDTreeBalancedPtInNodesPQ(const CloudType &cloud)
Definition: experimental/kdtree_cpu.cpp:196
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::Node::Node
Node(const unsigned ptIndex=INVALID_PT)
Definition: nabo_experimental.h:256
Nabo::KDTreeBalancedPtInNodes::CompareDim::dim
size_t dim
Definition: nabo_experimental.h:62
Nabo::KDTreeBalancedPtInNodesPQ::SearchElement::operator<
friend bool operator<(const SearchElement &e0, const SearchElement &e1)
Definition: nabo_experimental.h:114
Nabo::KDTreeBalancedPtInLeavesStack::IndexVector
NearestNeighbourSearch< T, CloudType >::IndexVector IndexVector
Definition: nabo_experimental.h:156
Nabo::KDTreeBalancedPtInNodesPQ::SearchElement::SearchElement
SearchElement(const size_t index, const T minDist)
Definition: nabo_experimental.h:112
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::CompareDim::dim
size_t dim
Definition: nabo_experimental.h:234
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::Node::dim
unsigned dim
Definition: nabo_experimental.h:246
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::Nodes
std::vector< Node > Nodes
Definition: nabo_experimental.h:317
Nabo::KDTreeBalancedPtInNodesPQ::Matrix
NearestNeighbourSearch< T, CloudType >::Matrix Matrix
Definition: nabo_experimental.h:95
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::Index
NearestNeighbourSearch< T, CloudType >::Index Index
Definition: nabo_experimental.h:212
Nabo::KDTreeBalancedPtInLeavesStack::parent
size_t parent(size_t pos) const
Definition: nabo_experimental.h:196
Nabo::KDTreeBalancedPtInNodes
Definition: nabo_experimental.h:42
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::Node::highBound
T highBound
Definition: nabo_experimental.h:313
Nabo::KDTreeBalancedPtInNodes::BuildPointsIt
BuildPoints::iterator BuildPointsIt
Definition: nabo_experimental.h:57
Nabo::KDTreeBalancedPtInLeavesStack::BuildPointsCstIt
BuildPoints::const_iterator BuildPointsCstIt
Definition: nabo_experimental.h:172
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::BuildPoint::index
size_t index
Definition: nabo_experimental.h:291
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::Nodes
std::vector< Node > Nodes
Definition: nabo_experimental.h:259
Nabo::KDTreeBalancedPtInLeavesStack::BuildPointsIt
BuildPoints::iterator BuildPointsIt
Definition: nabo_experimental.h:171
Nabo::KDTreeBalancedPtInNodesPQ::Index
NearestNeighbourSearch< T, CloudType >::Index Index
Definition: nabo_experimental.h:96
Nabo::KDTreeBalancedPtInNodesStack::Vector
NearestNeighbourSearch< T, CloudType >::Vector Vector
Definition: nabo_experimental.h:126
Nabo::KDTreeBalancedPtInLeavesStack::BuildPoint::pos
Vector pos
Definition: nabo_experimental.h:166
Nabo::KDTreeBalancedPtInNodes::CompareDim::operator()
bool operator()(const BuildPoint &p0, const BuildPoint &p1)
Definition: nabo_experimental.h:64
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::Node::ptIndex
unsigned ptIndex
Definition: nabo_experimental.h:251
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::buildNodes
unsigned buildNodes(const BuildPointsIt first, const BuildPointsIt last, const Vector minValues, const Vector maxValues)
Definition: experimental/kdtree_cpu.cpp:550
Nabo::KDTreeBalancedPtInNodesStack::IndexVector
NearestNeighbourSearch< T, CloudType >::IndexVector IndexVector
Definition: nabo_experimental.h:129
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::recurseKnn
void recurseKnn(const Vector &query, const unsigned n, T rd, Heap &heap, Vector &off, const T maxError, const bool allowSelfMatch)
Definition: experimental/kdtree_cpu.cpp:690
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::Matrix
NearestNeighbourSearch< T, CloudType >::Matrix Matrix
Definition: nabo_experimental.h:277
Nabo::KDTreeBalancedPtInNodes::cloudIndexesFromNodesIndexes
IndexVector cloudIndexesFromNodesIndexes(const IndexVector &indexes) const
Definition: experimental/kdtree_cpu.cpp:78
Nabo::KDTreeBalancedPtInLeavesStack::BuildPoint::index
size_t index
Definition: nabo_experimental.h:167
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::Node::rightChild
unsigned rightChild
Definition: nabo_experimental.h:247
Nabo::KDTreeBalancedPtInNodes::Node
Definition: nabo_experimental.h:67
Nabo::KDTreeBalancedPtInLeavesStack::KDTreeBalancedPtInLeavesStack
KDTreeBalancedPtInLeavesStack(const CloudType &cloud, const bool balanceVariance)
Definition: experimental/kdtree_cpu.cpp:450
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::KDTreeUnbalancedPtInLeavesImplicitBoundsStack
KDTreeUnbalancedPtInLeavesImplicitBoundsStack(const CloudType &cloud)
Definition: experimental/kdtree_cpu.cpp:612
Nabo::KDTreeBalancedPtInLeavesStack::BuildPoint
Definition: nabo_experimental.h:164
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::buildNodes
unsigned buildNodes(const BuildPointsIt first, const BuildPointsIt last, const Vector minValues, const Vector maxValues)
Definition: experimental/kdtree_cpu.cpp:761
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::IndexVector
NearestNeighbourSearch< T, CloudType >::IndexVector IndexVector
Definition: nabo_experimental.h:279
Nabo::KDTreeBalancedPtInNodes::CompareDim
Definition: nabo_experimental.h:60
Nabo::KDTreeBalancedPtInNodes::childRight
size_t childRight(size_t pos) const
Definition: nabo_experimental.h:79
Nabo::KDTreeBalancedPtInNodesPQ::knn
virtual IndexVector knn(const Vector &query, const Index k, const T epsilon, const unsigned optionFlags)
Definition: experimental/kdtree_cpu.cpp:202
Nabo::KDTreeBalancedPtInNodes::parent
size_t parent(size_t pos) const
Definition: nabo_experimental.h:80
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack
Definition: nabo_experimental.h:274
Nabo::KDTreeBalancedPtInNodesStack::recurseKnn
void recurseKnn(const Vector &query, const size_t n, T rd, Heap &heap, Vector &off, const T maxError, const bool allowSelfMatch)
Definition: experimental/kdtree_cpu.cpp:313
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::BuildPoints
std::vector< BuildPoint > BuildPoints
Definition: nabo_experimental.h:228
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::CompareDim::dim
size_t dim
Definition: nabo_experimental.h:300
Nabo::KDTreeBalancedPtInNodesStack::Matrix
NearestNeighbourSearch< T, CloudType >::Matrix Matrix
Definition: nabo_experimental.h:127
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::Matrix
NearestNeighbourSearch< T, CloudType >::Matrix Matrix
Definition: nabo_experimental.h:211
Nabo::KDTreeBalancedPtInNodes::BuildPoints
std::vector< BuildPoint > BuildPoints
Definition: nabo_experimental.h:56
Nabo::KDTreeBalancedPtInLeavesStack::CompareDim::CompareDim
CompareDim(const size_t dim)
Definition: nabo_experimental.h:177
Nabo::KDTreeUnbalancedPtInLeavesExplicitBoundsStack::Node::rightChild
unsigned rightChild
Definition: nabo_experimental.h:310
Nabo::KDTreeUnbalancedPtInLeavesImplicitBoundsStack::BuildPoint::index
size_t index
Definition: nabo_experimental.h:225
Nabo::KDTreeBalancedPtInNodesStack::Node
KDTreeBalancedPtInNodes< T, CloudType >::Node Node
Definition: nabo_experimental.h:130
Nabo::KDTreeBalancedPtInNodes::Index
NearestNeighbourSearch< T, CloudType >::Index Index
Definition: nabo_experimental.h:46
Nabo::KDTreeBalancedPtInNodes::Node::index
Index index
Definition: nabo_experimental.h:71


mp2p_icp
Author(s):
autogenerated on Wed Oct 23 2024 02:45:40