SimpleWeightUpdate Class Reference

Public Member Functions

void UpdateWeights (const VecType &trainingPoint, arma::mat &weights, arma::vec &biases, const size_t incorrectClass, const size_t correctClass, const double instanceWeight=1.0)
 This function is called to update the weightVectors matrix. More...


Detailed Description

Definition at line 30 of file simple_weight_update.hpp.

Member Function Documentation

◆ UpdateWeights()

void UpdateWeights ( const VecType &  trainingPoint,
arma::mat &  weights,
arma::vec &  biases,
const size_t  incorrectClass,
const size_t  correctClass,
const double  instanceWeight = 1.0 

This function is called to update the weightVectors matrix.

It decreases the weights of the incorrectly classified class while increasing the weight of the correct class it should have been classified to.

Template Parameters
Typeof vector (should be an Armadillo vector like arma::vec or arma::sp_vec or something similar).
trainingPointPoint that was misclassified.
weightsMatrix of weights.
biasesVector of biases.
incorrectClassIndex of class that the point was incorrectly classified as.
correctClassIndex of the true class of the point.
instanceWeightWeight to be given to this particular point during training (this is useful for boosting).

Definition at line 50 of file simple_weight_update.hpp.

The documentation for this class was generated from the following file:
  • /home/jenkins-mlpack/