GestureRecognitionToolkit  Version: 0.2.0
The Gesture Recognition Toolkit (GRT) is a cross-platform, open-source, c++ machine learning library for real-time gesture recognition.
ANBC_Model.h
Go to the documentation of this file.
1 
31 #ifndef GRT_ANBC_MODEL_HEADER
32 #define GRT_ANBC_MODEL_HEADER
33 
34 #include "../../DataStructures/VectorFloat.h"
35 #include "../../DataStructures/MatrixFloat.h"
36 
37 GRT_BEGIN_NAMESPACE
38 
39 class GRT_API ANBC_Model{
40 public:
41  ANBC_Model(void){ N=0; classLabel = 0; gamma=2.0; threshold=0.0; trainingMu=0.0; trainingSigma=0.0;};
42  ~ANBC_Model(void){};
43 
44  bool train( const UINT classLabel, const MatrixDouble &trainingData, const VectorFloat &weightsVector );
45  Float predict( const VectorFloat &x );
46  Float predictUnnormed( const VectorFloat &x );
47  inline Float gauss(const Float x,const Float mu,const Float sigma);
48  inline Float unnormedGauss(const Float x,const Float mu,const Float sigma);
49  void recomputeThresholdValue(const Float gamma);
50 
51 public:
52  UINT N; //The number of dimensions in the problem
53  UINT classLabel; //The label of the class this model represents
54  Float threshold; //The classification threshold value
55  Float gamma; //The number of standard deviations to use for the threshold
56  Float trainingMu; //The average confidence value in the training data
57  Float trainingSigma; //The simga confidence value in the training data
58  VectorFloat mu; //A vector to hold the mean values for each dimension
59  VectorFloat sigma; //A vector to hold the sigma values for each dimension
60  VectorFloat weights; //A vector to hold the weights for each dimension
61 };
62 
63 GRT_END_NAMESPACE
64 
65 #endif //GRT_ANBC_MODEL_HEADER
66