mlpack  2.2.5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
traits.hpp
Go to the documentation of this file.
1 
12 #ifndef MLPACK_CORE_TREE_RECTANGLE_TREE_TRAITS_HPP
13 #define MLPACK_CORE_TREE_RECTANGLE_TREE_TRAITS_HPP
14 
16 
17 namespace mlpack {
18 namespace tree {
19 
26 template<typename MetricType,
27  typename StatisticType,
28  typename MatType,
29  typename SplitType,
30  typename DescentType,
31  template<typename> class AuxiliaryInformationType>
32 class TreeTraits<RectangleTree<MetricType, StatisticType, MatType, SplitType, DescentType, AuxiliaryInformationType>>
33 {
34  public:
38  static const bool HasOverlappingChildren = true;
39 
43  static const bool HasDuplicatedPoints = false;
44 
48  static const bool FirstPointIsCentroid = false;
49 
53  static const bool HasSelfChildren = false;
54 
60  static const bool RearrangesDataset = false;
61 
65  static const bool BinaryTree = false;
66 
71  static const bool UniqueNumDescendants = true;
72 };
73 
78 template<typename MetricType,
79  typename StatisticType,
80  typename MatType,
81  typename SplitPolicyType,
82  template<typename> class SweepType,
83  typename DescentType,
84  template<typename> class AuxiliaryInformationType>
85 class TreeTraits<RectangleTree<MetricType,
86  StatisticType,
87  MatType,
88  RPlusTreeSplit<SplitPolicyType,
89  SweepType>,
90  DescentType,
91  AuxiliaryInformationType>>
92 {
93  public:
97  static const bool HasOverlappingChildren = false;
98 
102  static const bool HasDuplicatedPoints = false;
103 
107  static const bool FirstPointIsCentroid = false;
108 
112  static const bool HasSelfChildren = false;
113 
119  static const bool RearrangesDataset = false;
120 
124  static const bool BinaryTree = false;
125 
130  static const bool UniqueNumDescendants = true;
131 };
132 
133 } // namespace tree
134 } // namespace mlpack
135 
136 #endif
The RPlusTreeSplit class performs the split process of a node on overflow.
static const bool BinaryTree
This is true if the tree always has only two children.
static const bool HasSelfChildren
This is true if the points contained in the first child of a node (Child(0)) are also contained in th...
static const bool RearrangesDataset
This is true if the tree rearranges points in the dataset when it is built.
static const bool HasDuplicatedPoints
This is true if a point can be included in more than one node.
Definition: tree_traits.hpp:89
A rectangle type tree tree, such as an R-tree or X-tree.
static const bool FirstPointIsCentroid
This is true if the first point of each node is the centroid of its bound.
Definition: tree_traits.hpp:94
The TreeTraits class provides compile-time information on the characteristics of a given tree type...
Definition: tree_traits.hpp:77
static const bool HasOverlappingChildren
This is true if the subspaces represented by the children of a node can overlap.
Definition: tree_traits.hpp:84
static const bool UniqueNumDescendants
This is true if the NumDescendants() method doesn&#39;t include duplicated points.