mlpack  master
Public Member Functions | Private Attributes | List of all members
mlpack::tree::Octree< MetricType, StatisticType, MatType >::SingleTreeTraverser< RuleType > Class Template Reference

A single-tree traverser; see single_tree_traverser.hpp. More...

Public Member Functions

 SingleTreeTraverser (RuleType &rule)
 Instantiate the traverser with the given rule set. More...
 
size_t NumPrunes () const
 Get the number of pruned nodes. More...
 
size_t & NumPrunes ()
 Modify the number of pruned nodes. More...
 
void Traverse (const size_t queryIndex, Octree &referenceNode)
 Traverse the reference tree with the given query point. More...
 

Private Attributes

size_t numPrunes
 The number of reference nodes that have been pruned. More...
 
RuleType & rule
 The instantiated rule. More...
 

Detailed Description

template<typename MetricType = metric::EuclideanDistance, typename StatisticType = EmptyStatistic, typename MatType = arma::mat>
template<typename RuleType>
class mlpack::tree::Octree< MetricType, StatisticType, MatType >::SingleTreeTraverser< RuleType >

A single-tree traverser; see single_tree_traverser.hpp.

Definition at line 35 of file octree.hpp.

Constructor & Destructor Documentation

template<typename MetricType = metric::EuclideanDistance, typename StatisticType = EmptyStatistic, typename MatType = arma::mat>
template<typename RuleType >
mlpack::tree::Octree< MetricType, StatisticType, MatType >::SingleTreeTraverser< RuleType >::SingleTreeTraverser ( RuleType &  rule)

Instantiate the traverser with the given rule set.

Member Function Documentation

template<typename MetricType = metric::EuclideanDistance, typename StatisticType = EmptyStatistic, typename MatType = arma::mat>
template<typename RuleType >
size_t mlpack::tree::Octree< MetricType, StatisticType, MatType >::SingleTreeTraverser< RuleType >::NumPrunes ( ) const
inline

Get the number of pruned nodes.

Definition at line 41 of file single_tree_traverser.hpp.

template<typename MetricType = metric::EuclideanDistance, typename StatisticType = EmptyStatistic, typename MatType = arma::mat>
template<typename RuleType >
size_t& mlpack::tree::Octree< MetricType, StatisticType, MatType >::SingleTreeTraverser< RuleType >::NumPrunes ( )
inline

Modify the number of pruned nodes.

Definition at line 43 of file single_tree_traverser.hpp.

template<typename MetricType = metric::EuclideanDistance, typename StatisticType = EmptyStatistic, typename MatType = arma::mat>
template<typename RuleType >
void mlpack::tree::Octree< MetricType, StatisticType, MatType >::SingleTreeTraverser< RuleType >::Traverse ( const size_t  queryIndex,
Octree referenceNode 
)

Traverse the reference tree with the given query point.

This does not reset the number of pruned nodes.

Parameters
queryIndexIndex of query point.
referenceNodeNode in reference tree.

Member Data Documentation

template<typename MetricType = metric::EuclideanDistance, typename StatisticType = EmptyStatistic, typename MatType = arma::mat>
template<typename RuleType >
size_t mlpack::tree::Octree< MetricType, StatisticType, MatType >::SingleTreeTraverser< RuleType >::numPrunes
private

The number of reference nodes that have been pruned.

Definition at line 49 of file single_tree_traverser.hpp.

template<typename MetricType = metric::EuclideanDistance, typename StatisticType = EmptyStatistic, typename MatType = arma::mat>
template<typename RuleType >
RuleType& mlpack::tree::Octree< MetricType, StatisticType, MatType >::SingleTreeTraverser< RuleType >::rule
private

The instantiated rule.

Definition at line 47 of file single_tree_traverser.hpp.


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