[mlpack-svn] r14178 - mlpack/trunk/src/mlpack/tests

fastlab-svn at coffeetalk-1.cc.gatech.edu fastlab-svn at coffeetalk-1.cc.gatech.edu
Wed Jan 30 12:32:43 EST 2013


Author: rcurtin
Date: 2013-01-30 12:32:43 -0500 (Wed, 30 Jan 2013)
New Revision: 14178

Modified:
   mlpack/trunk/src/mlpack/tests/tree_test.cpp
Log:
Armadillo 3.4 has some sparse bugs which cause this test to get stuck in an
infinite loop.  The bug is not present in Armadillo 3.6.  Therefore, don't run
this test on Armadillo 3.4.  If a user ever reports it, then they should move to
a newer version of Armadillo.


Modified: mlpack/trunk/src/mlpack/tests/tree_test.cpp
===================================================================
--- mlpack/trunk/src/mlpack/tests/tree_test.cpp	2013-01-30 04:44:58 UTC (rev 14177)
+++ mlpack/trunk/src/mlpack/tests/tree_test.cpp	2013-01-30 17:32:43 UTC (rev 14178)
@@ -1698,6 +1698,11 @@
 }
 
 #ifdef ARMA_HAS_SPMAT
+// Only run sparse tree tests if we are using Armadillo 3.6.  Armadillo 3.4 has
+// some bugs that cause the kd-tree splitting procedure to fail terribly.  Soon,
+// that version will be obsolete, though.
+#if !((ARMA_VERSION_MAJOR == 3) && (ARMA_VERSION_MINOR == 4))
+
 /**
  * Exhaustive sparse kd-tree test based on #125.
  *
@@ -1786,6 +1791,8 @@
   // Check the tree depth.
   BOOST_REQUIRE_EQUAL(root.TreeDepth(), 7);
 }
+
+#endif // Using Armadillo 3.4.
 #endif // ARMA_HAS_SPMAT
 
 template<typename TreeType>




More information about the mlpack-svn mailing list