31 #ifndef GRT_HMM_HEADER
32 #define GRT_HMM_HEADER
37 #include "../../CoreModules/Classifier.h"
55 HMM(
const UINT
hmmType=HMM_CONTINUOUS,
const UINT modelType=HMM_LEFTRIGHT,
const UINT delta=1,
const bool useScaling =
false,
const bool useNullRejection =
false);
132 virtual bool reset();
140 virtual bool clear();
142 virtual bool print()
const;
330 bool setAutoEstimateSigma(
const bool autoEstimateSigma);
342 bool predict_continuous(
VectorFloat &inputVector );
346 bool loadLegacyModelFromFile( std::fstream &file );
355 UINT numRandomTrainingIterations;
359 UINT downsampleFactor;
362 bool autoEstimateSigma;
370 #endif //GRT_HMM_HEADER
virtual bool saveModelToFile(std::fstream &file) const
virtual bool predict(VectorFloat inputVector)
virtual bool loadModelFromFile(std::fstream &file)
bool setHMMType(const UINT hmmType)
bool setDownsampleFactor(const UINT downsampleFactor)
virtual bool predict_(VectorFloat &inputVector)
This class acts as the main interface for using a Hidden Markov Model.
virtual bool train(ClassificationData trainingData)
virtual bool deepCopyFrom(const Classifier *classifier)
bool setNumRandomTrainingIterations(const UINT numRandomTrainingIterations)
bool setNumSymbols(const UINT numStates)
virtual bool train(ClassificationData trainingData)
Vector< DiscreteHiddenMarkovModel > getDiscreteModels() const
bool setModelType(const UINT modelType)
UINT getModelType() const
virtual bool print() const
HMM & operator=(const HMM &rhs)
UINT hmmType
Controls if this is a HMM_DISCRETE or a HMM_CONTINUOUS.
UINT getNumStates() const
bool setSigma(const Float sigma)
virtual bool train_(TimeSeriesClassificationData &trainingData)
HMM(const UINT hmmType=HMM_CONTINUOUS, const UINT modelType=HMM_LEFTRIGHT, const UINT delta=1, const bool useScaling=false, const bool useNullRejection=false)
virtual bool saveModelToFile(std::string filename) const
This class implements a continuous Hidden Markov Model.
UINT getNumSymbols() const
virtual bool loadModelFromFile(std::string filename)
bool setDelta(const UINT delta)
bool setCommitteeSize(const UINT committeeSize)
This class implements a discrete Hidden Markov Model.
UINT getNumRandomTrainingIterations() const
bool setNumStates(const UINT numStates)
Vector< ContinuousHiddenMarkovModel > getContinuousModels() const