GestureRecognitionToolkit  Version: 1.0 Revision: 04-03-15
The Gesture Recognition Toolkit (GRT) is a cross-platform, open-source, c++ machine learning library for real-time gesture recognition.
RadialBasisFunction.h
Go to the documentation of this file.
1 
33 #ifndef GRT_RADIAL_BASIC_FUNCTION_HEADER
34 #define GRT_RADIAL_BASIC_FUNCTION_HEADER
35 
36 #include "WeakClassifier.h"
37 
38 namespace GRT{
39 
41 public:
54  RadialBasisFunction(UINT numSteps=100,double positiveClassificationThreshold=0.9,double minAlphaSearchRange=0.001,double maxAlphaSearchRange=1.0);
55 
59  virtual ~RadialBasisFunction();
60 
65 
70 
77  virtual bool deepCopyFrom(const WeakClassifier *weakClassifer);
78 
86  virtual bool train(ClassificationData &trainingData, VectorDouble &weights);
87 
95  virtual double predict(const VectorDouble &x);
96 
103  virtual bool saveModelToFile(fstream &file) const;
104 
111  virtual bool loadModelFromFile(fstream &file);
112 
116  virtual void print() const;
117 
123  UINT getNumSteps() const;
124 
132  double getPositiveClassificationThreshold() const;
133 
139  double getAlpha() const;
140 
146  double getMinAlphaSearchRange() const;
147 
153  double getMaxAlphaSearchRange() const;
154 
160  VectorDouble getRBFCentre() const;
161 
162 protected:
163  double rbf(const VectorDouble &a,const VectorDouble &b);
164 
165  UINT numSteps;
166  double positiveClassificationThreshold;
167  double alpha;
168  double gamma;
169  double minAlphaSearchRange;
170  double maxAlphaSearchRange;
171  VectorDouble rbfCentre;
172 
174 };
175 
176 } //End of namespace GRT
177 
178 #endif // GRT_DECISION_STUMP_HEADER
static RegisterWeakClassifierModule< RadialBasisFunction > registerModule
This is used to register the DecisionStump with the WeakClassifier base class.
virtual bool deepCopyFrom(const WeakClassifier *weakClassifer)
virtual bool train(ClassificationData &trainingData, VectorDouble &weights)
Definition: AdaBoost.cpp:25
virtual void print() const
This is the main base class for all GRT WeakClassifiers.
VectorDouble getRBFCentre() const
RadialBasisFunction & operator=(const RadialBasisFunction &rhs)
RadialBasisFunction(UINT numSteps=100, double positiveClassificationThreshold=0.9, double minAlphaSearchRange=0.001, double maxAlphaSearchRange=1.0)
double getMinAlphaSearchRange() const
double getPositiveClassificationThreshold() const
virtual bool saveModelToFile(fstream &file) const
virtual double predict(const VectorDouble &x)
double getMaxAlphaSearchRange() const
virtual bool loadModelFromFile(fstream &file)