[mlpack-svn] r16900 - in mlpack/tags/mlpack-1.0.9/src/mlpack: methods/emst methods/perceptron tests
fastlab-svn at coffeetalk-1.cc.gatech.edu
fastlab-svn at coffeetalk-1.cc.gatech.edu
Mon Jul 28 13:37:55 EDT 2014
Author: rcurtin
Date: Mon Jul 28 13:37:54 2014
New Revision: 16900
Log:
Fix some warnings.
Modified:
mlpack/tags/mlpack-1.0.9/src/mlpack/methods/emst/dtb_impl.hpp
mlpack/tags/mlpack-1.0.9/src/mlpack/methods/perceptron/perceptron_impl.hpp
mlpack/tags/mlpack-1.0.9/src/mlpack/tests/emst_test.cpp
Modified: mlpack/tags/mlpack-1.0.9/src/mlpack/methods/emst/dtb_impl.hpp
==============================================================================
--- mlpack/tags/mlpack-1.0.9/src/mlpack/methods/emst/dtb_impl.hpp (original)
+++ mlpack/tags/mlpack-1.0.9/src/mlpack/methods/emst/dtb_impl.hpp Mon Jul 28 13:37:54 2014
@@ -283,7 +283,7 @@
// Check components of points.
for (size_t i = 0; i < tree->NumPoints(); ++i)
- if (connections.Find(tree->Point(i)) != component)
+ if (connections.Find(tree->Point(i)) != int(component))
return;
// If we made it this far, all components are the same.
Modified: mlpack/tags/mlpack-1.0.9/src/mlpack/methods/perceptron/perceptron_impl.hpp
==============================================================================
--- mlpack/tags/mlpack-1.0.9/src/mlpack/methods/perceptron/perceptron_impl.hpp (original)
+++ mlpack/tags/mlpack-1.0.9/src/mlpack/methods/perceptron/perceptron_impl.hpp Mon Jul 28 13:37:54 2014
@@ -84,7 +84,7 @@
arma::mat tempLabelMat;
arma::uword maxIndexRow, maxIndexCol;
- for (int i = 0; i < test.n_cols; i++)
+ for (size_t i = 0; i < test.n_cols; i++)
{
tempLabelMat = weightVectors.submat(0, 1, weightVectors.n_rows - 1,
weightVectors.n_cols - 1) *
@@ -138,7 +138,7 @@
void Perceptron<LearnPolicy, WeightInitializationPolicy, MatType>::Train(
const arma::rowvec& D)
{
- int j, i = 0;
+ size_t j, i = 0;
bool converged = false;
size_t tempLabel;
arma::uword maxIndexRow, maxIndexCol;
Modified: mlpack/tags/mlpack-1.0.9/src/mlpack/tests/emst_test.cpp
==============================================================================
--- mlpack/tags/mlpack-1.0.9/src/mlpack/tests/emst_test.cpp (original)
+++ mlpack/tags/mlpack-1.0.9/src/mlpack/tests/emst_test.cpp Mon Jul 28 13:37:54 2014
@@ -274,8 +274,7 @@
// naive mode.
DualTreeBoruvka<> bst(inputData, true);
// Ball tree.
- DualTreeBoruvka<EuclideanDistance,
- BinarySpaceTree<BallBound<>, DTBStat> > ballt(inputData);
+ DualTreeBoruvka<EuclideanDistance, TreeType> ballt(inputData);
arma::mat bstResults;
arma::mat ballResults;
More information about the mlpack-svn
mailing list