r_tree_split.hpp
Go to the documentation of this file.
1 
13 #ifndef MLPACK_CORE_TREE_RECTANGLE_TREE_R_TREE_SPLIT_HPP
14 #define MLPACK_CORE_TREE_RECTANGLE_TREE_R_TREE_SPLIT_HPP
15 
16 #include <mlpack/prereqs.hpp>
17 
18 namespace mlpack {
19 namespace tree {
20 
27 {
28  public:
33  template<typename TreeType>
34  static void SplitLeafNode(TreeType *tree, std::vector<bool>& relevels);
35 
40  template<typename TreeType>
41  static bool SplitNonLeafNode(TreeType *tree, std::vector<bool>& relevels);
42 
43  private:
47  template<typename TreeType>
48  static void GetPointSeeds(const TreeType *tree, int& i, int& j);
49 
53  template<typename TreeType>
54  static void GetBoundSeeds(const TreeType *tree, int& i, int& j);
55 
59  template<typename TreeType>
60  static void AssignPointDestNode(TreeType* oldTree,
61  TreeType* treeOne,
62  TreeType* treeTwo,
63  const int intI,
64  const int intJ);
65 
69  template<typename TreeType>
70  static void AssignNodeDestNode(TreeType* oldTree,
71  TreeType* treeOne,
72  TreeType* treeTwo,
73  const int intI,
74  const int intJ);
75 
79  template<typename TreeType>
80  static void InsertNodeIntoTree(TreeType* destTree, TreeType* srcNode);
81 };
82 
83 } // namespace tree
84 } // namespace mlpack
85 
86 // Include implementation
87 #include "r_tree_split_impl.hpp"
88 
89 #endif
Linear algebra utility functions, generally performed on matrices or vectors.
The core includes that mlpack expects; standard C++ includes and Armadillo.
static void SplitLeafNode(TreeType *tree, std::vector< bool > &relevels)
Split a leaf node using the "default" algorithm.
static bool SplitNonLeafNode(TreeType *tree, std::vector< bool > &relevels)
Split a non-leaf node using the "default" algorithm.
A Rectangle Tree has new points inserted at the bottom.