mlpack::tree::CoverTree< MetricType, RootPointPolicy, StatisticType >::DualTreeTraverser< RuleType > Class Template Reference

List of all members.

Public Member Functions

 DualTreeTraverser (RuleType &rule)
 Initialize the dual tree traverser with the given rule type.
size_t NumBaseCases () const
size_t & NumPrunes ()
 Modify the number of pruned nodes.
size_t NumPrunes () const
 Get the number of pruned nodes.
size_t NumScores () const
size_t NumVisited () const
void Traverse (CoverTree &queryNode, std::map< int, std::vector< DualCoverTreeMapEntry< MetricType, RootPointPolicy, StatisticType > > > &referenceMap)
 Helper function for traversal of the two trees.
void Traverse (CoverTree &queryNode, CoverTree &referenceNode)
 Traverse the two specified trees.

Private Member Functions

void PruneMap (CoverTree &queryNode, std::map< int, std::vector< DualCoverTreeMapEntry< MetricType, RootPointPolicy, StatisticType > > > &referenceMap, std::map< int, std::vector< DualCoverTreeMapEntry< MetricType, RootPointPolicy, StatisticType > > > &childMap)
 Prepare map for recursion.
void ReferenceRecursion (CoverTree &queryNode, std::map< int, std::vector< DualCoverTreeMapEntry< MetricType, RootPointPolicy, StatisticType > > > &referenceMap)

Private Attributes

size_t numPrunes
 The number of pruned nodes.
RuleType & rule
 The instantiated rule set for pruning branches.

Detailed Description

template<typename MetricType = metric::LMetric<2, true>, typename RootPointPolicy = FirstPointIsRoot, typename StatisticType = EmptyStatistic>
template<typename RuleType>
class mlpack::tree::CoverTree< MetricType, RootPointPolicy, StatisticType >::DualTreeTraverser< RuleType >

Definition at line 37 of file dual_tree_traverser.hpp.


Constructor & Destructor Documentation

template<typename MetricType = metric::LMetric<2, true>, typename RootPointPolicy = FirstPointIsRoot, typename StatisticType = EmptyStatistic>
template<typename RuleType >
mlpack::tree::CoverTree< MetricType, RootPointPolicy, StatisticType >::DualTreeTraverser< RuleType >::DualTreeTraverser ( RuleType &  rule  ) 

Initialize the dual tree traverser with the given rule type.


Member Function Documentation

template<typename MetricType = metric::LMetric<2, true>, typename RootPointPolicy = FirstPointIsRoot, typename StatisticType = EmptyStatistic>
template<typename RuleType >
size_t mlpack::tree::CoverTree< MetricType, RootPointPolicy, StatisticType >::DualTreeTraverser< RuleType >::NumBaseCases (  )  const [inline]

Definition at line 70 of file dual_tree_traverser.hpp.

template<typename MetricType = metric::LMetric<2, true>, typename RootPointPolicy = FirstPointIsRoot, typename StatisticType = EmptyStatistic>
template<typename RuleType >
size_t& mlpack::tree::CoverTree< MetricType, RootPointPolicy, StatisticType >::DualTreeTraverser< RuleType >::NumPrunes (  )  [inline]

Modify the number of pruned nodes.

Definition at line 64 of file dual_tree_traverser.hpp.

template<typename MetricType = metric::LMetric<2, true>, typename RootPointPolicy = FirstPointIsRoot, typename StatisticType = EmptyStatistic>
template<typename RuleType >
size_t mlpack::tree::CoverTree< MetricType, RootPointPolicy, StatisticType >::DualTreeTraverser< RuleType >::NumPrunes (  )  const [inline]

Get the number of pruned nodes.

Definition at line 62 of file dual_tree_traverser.hpp.

template<typename MetricType = metric::LMetric<2, true>, typename RootPointPolicy = FirstPointIsRoot, typename StatisticType = EmptyStatistic>
template<typename RuleType >
size_t mlpack::tree::CoverTree< MetricType, RootPointPolicy, StatisticType >::DualTreeTraverser< RuleType >::NumScores (  )  const [inline]

Definition at line 69 of file dual_tree_traverser.hpp.

template<typename MetricType = metric::LMetric<2, true>, typename RootPointPolicy = FirstPointIsRoot, typename StatisticType = EmptyStatistic>
template<typename RuleType >
size_t mlpack::tree::CoverTree< MetricType, RootPointPolicy, StatisticType >::DualTreeTraverser< RuleType >::NumVisited (  )  const [inline]

Definition at line 68 of file dual_tree_traverser.hpp.

template<typename MetricType = metric::LMetric<2, true>, typename RootPointPolicy = FirstPointIsRoot, typename StatisticType = EmptyStatistic>
template<typename RuleType >
void mlpack::tree::CoverTree< MetricType, RootPointPolicy, StatisticType >::DualTreeTraverser< RuleType >::PruneMap ( CoverTree queryNode,
std::map< int, std::vector< DualCoverTreeMapEntry< MetricType, RootPointPolicy, StatisticType > > > &  referenceMap,
std::map< int, std::vector< DualCoverTreeMapEntry< MetricType, RootPointPolicy, StatisticType > > > &  childMap 
) [private]

Prepare map for recursion.

template<typename MetricType = metric::LMetric<2, true>, typename RootPointPolicy = FirstPointIsRoot, typename StatisticType = EmptyStatistic>
template<typename RuleType >
void mlpack::tree::CoverTree< MetricType, RootPointPolicy, StatisticType >::DualTreeTraverser< RuleType >::ReferenceRecursion ( CoverTree queryNode,
std::map< int, std::vector< DualCoverTreeMapEntry< MetricType, RootPointPolicy, StatisticType > > > &  referenceMap 
) [private]
template<typename MetricType = metric::LMetric<2, true>, typename RootPointPolicy = FirstPointIsRoot, typename StatisticType = EmptyStatistic>
template<typename RuleType >
void mlpack::tree::CoverTree< MetricType, RootPointPolicy, StatisticType >::DualTreeTraverser< RuleType >::Traverse ( CoverTree queryNode,
std::map< int, std::vector< DualCoverTreeMapEntry< MetricType, RootPointPolicy, StatisticType > > > &  referenceMap 
)

Helper function for traversal of the two trees.

template<typename MetricType = metric::LMetric<2, true>, typename RootPointPolicy = FirstPointIsRoot, typename StatisticType = EmptyStatistic>
template<typename RuleType >
void mlpack::tree::CoverTree< MetricType, RootPointPolicy, StatisticType >::DualTreeTraverser< RuleType >::Traverse ( CoverTree queryNode,
CoverTree referenceNode 
)

Traverse the two specified trees.

Parameters:
queryNode Root of query tree.
referenceNode Root of reference tree.

Member Data Documentation

template<typename MetricType = metric::LMetric<2, true>, typename RootPointPolicy = FirstPointIsRoot, typename StatisticType = EmptyStatistic>
template<typename RuleType >
size_t mlpack::tree::CoverTree< MetricType, RootPointPolicy, StatisticType >::DualTreeTraverser< RuleType >::numPrunes [private]

The number of pruned nodes.

Definition at line 77 of file dual_tree_traverser.hpp.

template<typename MetricType = metric::LMetric<2, true>, typename RootPointPolicy = FirstPointIsRoot, typename StatisticType = EmptyStatistic>
template<typename RuleType >
RuleType& mlpack::tree::CoverTree< MetricType, RootPointPolicy, StatisticType >::DualTreeTraverser< RuleType >::rule [private]

The instantiated rule set for pruning branches.

Definition at line 74 of file dual_tree_traverser.hpp.


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

Generated on 29 Sep 2016 for MLPACK by  doxygen 1.6.1