[mlpack-svn] r15012 - mlpack/trunk/src/mlpack/core/tree/binary_space_tree
fastlab-svn at coffeetalk-1.cc.gatech.edu
fastlab-svn at coffeetalk-1.cc.gatech.edu
Sun May 5 22:11:19 EDT 2013
Author: rcurtin
Date: 2013-05-05 22:11:18 -0400 (Sun, 05 May 2013)
New Revision: 15012
Modified:
mlpack/trunk/src/mlpack/core/tree/binary_space_tree/binary_space_tree.hpp
Log:
Add RangeDistance() hooks to HRectBound.
Modified: mlpack/trunk/src/mlpack/core/tree/binary_space_tree/binary_space_tree.hpp
===================================================================
--- mlpack/trunk/src/mlpack/core/tree/binary_space_tree/binary_space_tree.hpp 2013-05-06 02:10:53 UTC (rev 15011)
+++ mlpack/trunk/src/mlpack/core/tree/binary_space_tree/binary_space_tree.hpp 2013-05-06 02:11:18 UTC (rev 15012)
@@ -326,6 +326,12 @@
return bound.MaxDistance(other->Bound());
}
+ //! Return the minimum and maximum distance to another node.
+ math::Range RangeDistance(const BinarySpaceTree* other) const
+ {
+ return bound.RangeDistance(other);
+ }
+
//! Return the minimum distance to another point.
double MinDistance(const arma::vec& point) const
{
@@ -338,6 +344,12 @@
return bound.MaxDistance(point);
}
+ //! Return the minimum and maximum distance to another point.
+ math::Range RangeDistance(const arma::vec& point) const
+ {
+ return bound.RangeDistance(point);
+ }
+
/**
* Returns the dimension this parent's children are split on.
*/
More information about the mlpack-svn
mailing list