org.encog.ml.hmm.train.bw
public abstract class BaseBaumWelch extends Object implements MLTrain
| Constructor and Description |
|---|
BaseBaumWelch(HiddenMarkovModel hmm,
MLSequenceSet training) |
| Modifier and Type | Method and Description |
|---|---|
void |
addStrategy(Strategy strategy)
Training strategies can be added to improve the training results.
|
boolean |
canContinue() |
protected double[][] |
estimateGamma(double[][][] xi,
ForwardBackwardCalculator fbc) |
abstract double[][][] |
estimateXi(MLDataSet sequence,
ForwardBackwardCalculator fbc,
HiddenMarkovModel hmm) |
void |
finishTraining()
Should be called once training is complete and no more iterations are
needed.
|
abstract ForwardBackwardCalculator |
generateForwardBackwardCalculator(MLDataSet sequence,
HiddenMarkovModel hmm) |
double |
getError() |
TrainingImplementationType |
getImplementationType() |
int |
getIteration() |
MLMethod |
getMethod()
Get the current best machine learning method from the training.
|
List<Strategy> |
getStrategies() |
MLDataSet |
getTraining() |
boolean |
isTrainingDone() |
void |
iteration()
Perform one iteration of training.
|
void |
iteration(int count)
Perform a number of training iterations.
|
TrainingContinuation |
pause()
Pause the training to continue later.
|
void |
resume(TrainingContinuation state)
Resume training.
|
void |
setError(double error) |
void |
setIteration(int iteration)
Set the current training iteration.
|
public BaseBaumWelch(HiddenMarkovModel hmm, MLSequenceSet training)
public void addStrategy(Strategy strategy)
MLTrainaddStrategy in interface MLTrainstrategy - The strategy to add.public boolean canContinue()
canContinue in interface MLTrainprotected double[][] estimateGamma(double[][][] xi,
ForwardBackwardCalculator fbc)
public abstract double[][][] estimateXi(MLDataSet sequence, ForwardBackwardCalculator fbc, HiddenMarkovModel hmm)
public void finishTraining()
MLTrainfinishTraining in interface MLTrainpublic abstract ForwardBackwardCalculator generateForwardBackwardCalculator(MLDataSet sequence, HiddenMarkovModel hmm)
public double getError()
getError in interface MLTrainpublic TrainingImplementationType getImplementationType()
getImplementationType in interface MLTrainpublic int getIteration()
getIteration in interface MLTrainpublic MLMethod getMethod()
MLTrainpublic List<Strategy> getStrategies()
getStrategies in interface MLTrainpublic MLDataSet getTraining()
getTraining in interface MLTrainpublic boolean isTrainingDone()
isTrainingDone in interface MLTrainpublic void iteration()
MLTrainpublic void iteration(int count)
MLTrainpublic TrainingContinuation pause()
MLTrainpublic void resume(TrainingContinuation state)
MLTrainpublic void setError(double error)
public void setIteration(int iteration)
MLTrainsetIteration in interface MLTrainiteration - Iteration.Copyright © 2014. All Rights Reserved.