mlpack
Public Types | Public Member Functions | List of all members
mlpack::adaboost::AdaBoostModel Class Reference

The model to save to disk. More...

#include <adaboost_model.hpp>

Public Types

enum  WeakLearnerTypes { DECISION_STUMP, PERCEPTRON }
 

Public Member Functions

 AdaBoostModel ()
 Create an empty AdaBoost model.
 
 AdaBoostModel (const arma::Col< size_t > &mappings, const size_t weakLearnerType)
 Create the AdaBoost model with the given mappings and type.
 
 AdaBoostModel (const AdaBoostModel &other)
 Copy constructor.
 
 AdaBoostModel (AdaBoostModel &&other)
 Move constructor.
 
AdaBoostModeloperator= (const AdaBoostModel &other)
 Copy assignment operator.
 
AdaBoostModeloperator= (AdaBoostModel &&other)
 Move assignment operator.
 
 ~AdaBoostModel ()
 Clean up memory.
 
const arma::Col< size_t > & Mappings () const
 Get the mappings.
 
arma::Col< size_t > & Mappings ()
 Modify the mappings.
 
size_t WeakLearnerType () const
 Get the weak learner type.
 
size_t & WeakLearnerType ()
 Modify the weak learner type.
 
size_t Dimensionality () const
 Get the dimensionality of the model.
 
size_t & Dimensionality ()
 Modify the dimensionality of the model.
 
void Train (const arma::mat &data, const arma::Row< size_t > &labels, const size_t numClasses, const size_t iterations, const double tolerance)
 Train the model, treat the data is all of the numeric type. More...
 
void Classify (const arma::mat &testData, arma::Row< size_t > &predictions)
 Classify test points.
 
void Classify (const arma::mat &testData, arma::Row< size_t > &predictions, arma::mat &probabilities)
 Classify test points.
 
template<typename Archive >
void serialize (Archive &ar, const uint32_t)
 Serialize the model.
 

Detailed Description

The model to save to disk.

Member Function Documentation

◆ Train()

void AdaBoostModel::Train ( const arma::mat &  data,
const arma::Row< size_t > &  labels,
const size_t  numClasses,
const size_t  iterations,
const double  tolerance 
)

Train the model, treat the data is all of the numeric type.

Train the model.


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