GestureRecognitionToolkit  Version: 0.1.0
The Gesture Recognition Toolkit (GRT) is a cross-platform, open-source, c++ machine learning library for real-time gesture recognition.
GRT::TestInstanceResult Class Reference

Public Types

enum  TestMode { CLASSIFICATION_MODE =0, REGRESSION_MODE }
 

Public Member Functions

 TestInstanceResult ()
 
 TestInstanceResult (const TestInstanceResult &rhs)
 
 ~TestInstanceResult ()
 
TestInstanceResultoperator= (const TestInstanceResult &rhs)
 
bool setClassificationResult (const unsigned int testIteration, const unsigned int classLabel, const unsigned int predictedClassLabel, const unsigned int unProcessedPredictedClassLabel, const VectorFloat &classLikelihoods, const VectorFloat &classDistances)
 
bool setRegressionResult (const unsigned int testIteration, const VectorFloat &regressionData, const VectorFloat &targetData)
 
unsigned int getTestMode () const
 
unsigned int getTestIteration () const
 
unsigned int getClassLabel () const
 
unsigned int getPredictedClassLabel () const
 
Float getMaximumLikelihood () const
 
Float getSquaredError () const
 

Protected Attributes

unsigned int testMode
 
unsigned int testIteration
 
unsigned int classLabel
 
unsigned int predictedClassLabel
 
unsigned int unProcessedPredictedClassLabel
 
VectorFloat classLikelihoods
 
VectorFloat classDistances
 
VectorFloat regressionData
 
VectorFloat targetData
 

Detailed Description

Definition at line 36 of file TestInstanceResult.h.

Constructor & Destructor Documentation

GRT::TestInstanceResult::TestInstanceResult ( )
inline

Default Constructor.

Initializes the TrainingResult instance.

Definition at line 43 of file TestInstanceResult.h.

GRT::TestInstanceResult::TestInstanceResult ( const TestInstanceResult rhs)
inline

Copy Constructor.

Initializes this instance by copying the data from the rhs instance

Parameters
constTestInstanceResult &rhs: another instance of the TestInstanceResult class

Definition at line 58 of file TestInstanceResult.h.

GRT::TestInstanceResult::~TestInstanceResult ( )
inline

Default Destructor.

Definition at line 65 of file TestInstanceResult.h.

Member Function Documentation

unsigned int GRT::TestInstanceResult::getClassLabel ( ) const
inline

Gets the class label.

Returns
returns the class label

Definition at line 148 of file TestInstanceResult.h.

Float GRT::TestInstanceResult::getMaximumLikelihood ( ) const
inline

Gets the maximum likelihood.

Returns
returns the maximum likelihood

Definition at line 166 of file TestInstanceResult.h.

unsigned int GRT::TestInstanceResult::getPredictedClassLabel ( ) const
inline

Gets the predicted class label.

Returns
returns the predicted class label

Definition at line 157 of file TestInstanceResult.h.

Float GRT::TestInstanceResult::getSquaredError ( ) const
inline

Gets the squared error between the regressionData and the target data. This is only useful in REGRESSION_MODE.

Returns
returns the squared error between the regression estimate and the target data

Definition at line 181 of file TestInstanceResult.h.

unsigned int GRT::TestInstanceResult::getTestIteration ( ) const
inline

Gets the test iteration, this represents which test example the test results correspond to.

Returns
returns the test iteration

Definition at line 139 of file TestInstanceResult.h.

unsigned int GRT::TestInstanceResult::getTestMode ( ) const
inline

Gets the current test mode, this will be one of the TestMode enums.

Returns
returns the current test mode, this will be one of the TestMode enums

Definition at line 130 of file TestInstanceResult.h.

TestInstanceResult& GRT::TestInstanceResult::operator= ( const TestInstanceResult rhs)
inline

Defines the Equals Operator.

This copies the data from the rhs instance to this instance, returning a reference to the current instance.

Parameters
constTestInstanceResult &rhs: another instance of the TestInstanceResult class

Definition at line 76 of file TestInstanceResult.h.

bool GRT::TestInstanceResult::setClassificationResult ( const unsigned int  testIteration,
const unsigned int  classLabel,
const unsigned int  predictedClassLabel,
const unsigned int  unProcessedPredictedClassLabel,
const VectorFloat classLikelihoods,
const VectorFloat classDistances 
)
inline

Sets the training result for classification data. This will place the training mode into CLASSIFICATION_MODE.

Parameters
trainingIterationthe current training iteration (or epoch)
accuracythe accuracy for the current training iteration
Returns
returns true if the training result was set successfully

Definition at line 98 of file TestInstanceResult.h.

bool GRT::TestInstanceResult::setRegressionResult ( const unsigned int  testIteration,
const VectorFloat regressionData,
const VectorFloat targetData 
)
inline

Sets the training result for regression data. This will place the training mode into REGRESSION_MODE.

Parameters
trainingIterationthe current training iteration (or epoch)
totalSquaredTrainingErrorthe total squared training error for the current iteration
rootMeanSquaredTrainingErrorthe root mean squared training error for the current iteration
Returns
returns true if the training result was set successfully

Definition at line 117 of file TestInstanceResult.h.


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