[mlpack-svn] r16985 - mlpack/trunk/src/mlpack/methods/adaboost
fastlab-svn at coffeetalk-1.cc.gatech.edu
fastlab-svn at coffeetalk-1.cc.gatech.edu
Thu Aug 7 11:15:26 EDT 2014
Author: rcurtin
Date: Thu Aug 7 11:15:26 2014
New Revision: 16985
Log:
Change names of functions.
Modified:
mlpack/trunk/src/mlpack/methods/adaboost/adaboost.hpp
mlpack/trunk/src/mlpack/methods/adaboost/adaboost_impl.hpp
Modified: mlpack/trunk/src/mlpack/methods/adaboost/adaboost.hpp
==============================================================================
--- mlpack/trunk/src/mlpack/methods/adaboost/adaboost.hpp (original)
+++ mlpack/trunk/src/mlpack/methods/adaboost/adaboost.hpp Thu Aug 7 11:15:26 2014
@@ -59,7 +59,7 @@
* @param t The classification matrix to be built
* @param l The labels from which the classification matrix is to be built.
*/
- void buildClassificationMatrix(arma::mat& t, const arma::Row<size_t>& l);
+ void BuildClassificationMatrix(arma::mat& t, const arma::Row<size_t>& l);
/**
* This function helps in building the Weight Distribution matrix
@@ -71,7 +71,7 @@
* to be calculated.
* @param weights The output weight vector.
*/
- void buildWeightMatrix(const arma::mat& D, arma::rowvec& weights);
+ void BuildWeightMatrix(const arma::mat& D, arma::rowvec& weights);
// Stores the final classification of the Labels.
arma::Row<size_t> finalHypothesis;
Modified: mlpack/trunk/src/mlpack/methods/adaboost/adaboost_impl.hpp
==============================================================================
--- mlpack/trunk/src/mlpack/methods/adaboost/adaboost_impl.hpp (original)
+++ mlpack/trunk/src/mlpack/methods/adaboost/adaboost_impl.hpp Thu Aug 7 11:15:26 2014
@@ -66,10 +66,10 @@
// Build a classification matrix of the form D(i,l)
// where i is the ith instance
// l is the lth class.
- buildClassificationMatrix(yt, labels);
+ BuildClassificationMatrix(yt, labels);
// ht(x), to be loaded after a round of prediction every time the weak
- // learner is run, by using the buildClassificationMatrix function
+ // learner is run, by using the BuildClassificationMatrix function
arma::mat ht(predictedLabels.n_cols, numClasses);
// This matrix is a helper matrix used to calculate the final hypothesis.
@@ -97,14 +97,14 @@
zt = 0.0;
// Build the weight vectors
- buildWeightMatrix(D, weights);
+ BuildWeightMatrix(D, weights);
// call the other weak learner and train the labels.
WeakLearner w(other, tempData, weights, labels);
w.Classify(tempData, predictedLabels);
//Now from predictedLabels, build ht, the weak hypothesis
- buildClassificationMatrix(ht, predictedLabels);
+ BuildClassificationMatrix(ht, predictedLabels);
// Now, start calculation of alpha(t) using ht
@@ -174,7 +174,7 @@
* @param l The labels from which the classification matrix is to be built.
*/
template <typename MatType, typename WeakLearner>
-void Adaboost<MatType, WeakLearner>::buildClassificationMatrix(
+void Adaboost<MatType, WeakLearner>::BuildClassificationMatrix(
arma::mat& t, const arma::Row<size_t>& l)
{
int i, j;
@@ -202,7 +202,7 @@
* @param weights The output weight vector.
*/
template <typename MatType, typename WeakLearner>
-void Adaboost<MatType, WeakLearner>::buildWeightMatrix(
+void Adaboost<MatType, WeakLearner>::BuildWeightMatrix(
const arma::mat& D, arma::rowvec& weights)
{
int i, j;
More information about the mlpack-svn
mailing list