#include <stlrecogniserinterface.h>
Inheritance diagram for StlRecogniserInterface:

Public Member Functions | |
| virtual | ~StlRecogniserInterface () |
| virtual const std::string & | key () const=0 |
| virtual const std::string & | title () const=0 |
| virtual const std::string & | description () const=0 |
| virtual const std::map< std::string, std::string > & | defaultParams () const=0 |
| virtual bool | initTraining (const std::list< std::string > &featureKeys, const std::map< std::string, std::string > ¶ms)=0 |
| virtual bool | examineSample (const StlFeatureVec &featureVec, const std::set< int > &classes)=0 |
| virtual bool | finaliseTraining ()=0 |
| virtual bool | writeModelFile (const std::string &fileName)=0 |
| virtual bool | readModelFile (const std::string &fileName)=0 |
| virtual StlStroke | flatten (const StlStrokeList &strokes) |
| virtual StlClassProbabilities | classify (const StlFeatureVec &featureVec)=0 |
Note that this class does not call "using namespace std", as that may not be wanted by the recogniser implementer. Hence, in the places where STL containers are used, they are prefixed with "std::".
| virtual StlRecogniserInterface::~StlRecogniserInterface | ( | ) | [inline, virtual] |
| virtual const std::string& StlRecogniserInterface::key | ( | ) | const [pure virtual] |
Implemented in LinearRecogniser, and StlRecogniser.
| virtual const std::string& StlRecogniserInterface::title | ( | ) | const [pure virtual] |
Implemented in LinearRecogniser, and StlRecogniser.
| virtual const std::string& StlRecogniserInterface::description | ( | ) | const [pure virtual] |
Implemented in LinearRecogniser, and StlRecogniser.
| virtual const std::map<std::string, std::string>& StlRecogniserInterface::defaultParams | ( | ) | const [pure virtual] |
Implemented in LinearRecogniser, and StlRecogniser.
| virtual bool StlRecogniserInterface::initTraining | ( | const std::list< std::string > & | featureKeys, | |
| const std::map< std::string, std::string > & | params | |||
| ) | [pure virtual] |
| virtual bool StlRecogniserInterface::examineSample | ( | const StlFeatureVec & | featureVec, | |
| const std::set< int > & | classes | |||
| ) | [pure virtual] |
| virtual bool StlRecogniserInterface::finaliseTraining | ( | ) | [pure virtual] |
Implemented in LinearRecogniser, and StlRecogniser.
| virtual bool StlRecogniserInterface::writeModelFile | ( | const std::string & | fileName | ) | [pure virtual] |
| virtual bool StlRecogniserInterface::readModelFile | ( | const std::string & | fileName | ) | [pure virtual] |
| StlStroke StlRecogniserInterface::flatten | ( | const StlStrokeList & | strokes | ) | [inline, virtual] |
This is used to flatten/link/join/merge a (potentially) multi-stroke gesture before feature extraction is performed (and thus examination or classification).
If any filtering needs to be performed on the stroke(s), then it should be done by this method. This includes smoothing the stroke(s) or even reducing the number of points in them.
This default implementation simply joins all of the strokes together. It does not join strokes together based on the location of their start and end points.
Note: This is non-const, as the recogniser may need to examine the stroke's structure and record information about it, ready for use by either classify() or examineSample().
Reimplemented in LinearRecogniser, and StlRecogniser.
| virtual StlClassProbabilities StlRecogniserInterface::classify | ( | const StlFeatureVec & | featureVec | ) | [pure virtual] |
Implemented in LinearRecogniser, and StlRecogniser.
1.5.2