|
static bool | SplitNode (const BoundType &, MatType &data, const size_t begin, const size_t count, SplitInfo &splitInfo) |
| Split the node according to the mean value in the dimension with maximum width. More...
|
|
static size_t | PerformSplit (MatType &data, const size_t begin, const size_t count, const SplitInfo &splitInfo) |
| Perform the split process according to the information about the split. More...
|
|
static size_t | PerformSplit (MatType &data, const size_t begin, const size_t count, const SplitInfo &splitInfo, std::vector< size_t > &oldFromNew) |
| Perform the split process according to the information about the split and return the list of changed indices. More...
|
|
template<typename VecType > |
static bool | AssignToLeftNode (const VecType &point, const SplitInfo &splitInfo) |
| Indicates that a point should be assigned to the left subtree. More...
|
|
template<typename BoundType, typename MatType = arma::mat>
class mlpack::tree::RPTreeMeanSplit< BoundType, MatType >
This class splits a binary space tree.
This class provides two different kinds of split. The mean split (i.e. all points are split by the median of their distance to the mean point) is performed if the average distance between points multiplied by a constant is greater than the diameter of the node. Otherwise, the median split (i.e. the node is split by a random hyperplane) is performed.
template<typename BoundType , typename MatType = arma::mat>
Perform the split process according to the information about the split.
This will order the dataset such that points that belong to the left subtree are on the left of the split column, and points from the right subtree are on the right side of the split column.
- Parameters
-
data | The dataset used by the binary space tree. |
begin | Index of the starting point in the dataset that belongs to this node. |
count | Number of points in this node. |
splitInfo | The information about the split. |
template<typename BoundType , typename MatType = arma::mat>
static size_t mlpack::tree::RPTreeMeanSplit< BoundType, MatType >::PerformSplit |
( |
MatType & |
data, |
|
|
const size_t |
begin, |
|
|
const size_t |
count, |
|
|
const SplitInfo & |
splitInfo, |
|
|
std::vector< size_t > & |
oldFromNew |
|
) |
| |
|
inlinestatic |
Perform the split process according to the information about the split and return the list of changed indices.
This will order the dataset such that points that belong to the left subtree are on the left of the split column, and points from the right subtree are on the right side of the split column.
- Parameters
-
data | The dataset used by the binary space tree. |
begin | Index of the starting point in the dataset that belongs to this node. |
count | Number of points in this node. |
splitInfo | The information about the split. |
oldFromNew | Vector which will be filled with the old positions for each new point. |