mlpack  master
Static Public Member Functions | Static Private Member Functions | List of all members
mlpack::tree::HilbertRTreeSplit< splitOrder > Class Template Reference

The splitting procedure for the Hilbert R tree. More...

Static Public Member Functions

template<typename TreeType >
static void SplitLeafNode (TreeType *tree, std::vector< bool > &relevels)
 Split a leaf node using the "default" algorithm. More...
 
template<typename TreeType >
static bool SplitNonLeafNode (TreeType *tree, std::vector< bool > &relevels)
 Split a non-leaf node using the "default" algorithm. More...
 

Static Private Member Functions

template<typename TreeType >
static bool FindCooperatingSiblings (TreeType *parent, const size_t iTree, size_t &firstSibling, size_t &lastSibling)
 Try to find splitOrder cooperating siblings in order to redistribute their children evenly. More...
 
template<typename TreeType >
static void RedistributeNodesEvenly (const TreeType *parent, const size_t firstSibling, const size_t lastSibling)
 Redistribute the children of the cooperating siblings evenly among them. More...
 
template<typename TreeType >
static void RedistributePointsEvenly (TreeType *parent, const size_t firstSibling, const size_t lastSibling)
 Redistribute the points of the cooperating siblings evenly among them. More...
 

Detailed Description

template<size_t splitOrder = 2>
class mlpack::tree::HilbertRTreeSplit< splitOrder >

The splitting procedure for the Hilbert R tree.

The template parameter splitOrder is the order of the splitting policy. The Hilbert R tree splits a node on overflow, turning splitOrder nodes into (splitOrder + 1) nodes.

Template Parameters
splitOrderNumber of nodes to split.

Definition at line 29 of file hilbert_r_tree_split.hpp.

Member Function Documentation

template<size_t splitOrder = 2>
template<typename TreeType >
static bool mlpack::tree::HilbertRTreeSplit< splitOrder >::FindCooperatingSiblings ( TreeType *  parent,
const size_t  iTree,
size_t &  firstSibling,
size_t &  lastSibling 
)
staticprivate

Try to find splitOrder cooperating siblings in order to redistribute their children evenly.

Returns true on success.

Parameters
parentThe parent of of the overflowing node.
iTreeThe number of the overflowing node.
firstSiblingThe first cooperating sibling.
lastSiblingThe last cooperating sibling.
template<size_t splitOrder = 2>
template<typename TreeType >
static void mlpack::tree::HilbertRTreeSplit< splitOrder >::RedistributeNodesEvenly ( const TreeType *  parent,
const size_t  firstSibling,
const size_t  lastSibling 
)
staticprivate

Redistribute the children of the cooperating siblings evenly among them.

Parameters
parentThe parent of of the overflowing node.
firstSiblingThe first cooperating sibling.
lastSiblingThe last cooperating sibling.
template<size_t splitOrder = 2>
template<typename TreeType >
static void mlpack::tree::HilbertRTreeSplit< splitOrder >::RedistributePointsEvenly ( TreeType *  parent,
const size_t  firstSibling,
const size_t  lastSibling 
)
staticprivate

Redistribute the points of the cooperating siblings evenly among them.

Parameters
parentThe parent of of the overflowing node.
firstSiblingThe first cooperating sibling.
lastSiblingThe last cooperating sibling.
template<size_t splitOrder = 2>
template<typename TreeType >
static void mlpack::tree::HilbertRTreeSplit< splitOrder >::SplitLeafNode ( TreeType *  tree,
std::vector< bool > &  relevels 
)
static

Split a leaf node using the "default" algorithm.

If necessary, this split will propagate upwards through the tree.

Parameters
nodeThe node that is being split.
relevelsNot used.
template<size_t splitOrder = 2>
template<typename TreeType >
static bool mlpack::tree::HilbertRTreeSplit< splitOrder >::SplitNonLeafNode ( TreeType *  tree,
std::vector< bool > &  relevels 
)
static

Split a non-leaf node using the "default" algorithm.

If this is a root node, the tree increases in depth.

Parameters
nodeThe node that is being split.
relevelsNot used.

The documentation for this class was generated from the following file: