org.encog.ml.train
public abstract class BasicTraining extends Object implements MLTrain
Constructor and Description |
---|
BasicTraining()
Used for serialization.
|
BasicTraining(TrainingImplementationType implementationType) |
Modifier and Type | Method and Description |
---|---|
void |
addStrategy(Strategy strategy)
Training strategies can be added to improve the training results.
|
void |
finishTraining()
Should be called after training has completed and the iteration method
will not be called any further.
|
double |
getError() |
TrainingImplementationType |
getImplementationType() |
int |
getIteration() |
List<Strategy> |
getStrategies() |
MLDataSet |
getTraining() |
boolean |
isTrainingDone() |
void |
iteration(int count)
Perform the specified number of training iterations.
|
void |
postIteration()
Call the strategies after an iteration.
|
void |
preIteration()
Call the strategies before an iteration.
|
void |
setError(double error) |
void |
setIteration(int iteration)
Set the current training iteration.
|
void |
setTraining(MLDataSet training)
Set the training object that this strategy is working with.
|
public BasicTraining()
public BasicTraining(TrainingImplementationType implementationType)
public void addStrategy(Strategy strategy)
addStrategy
in interface MLTrain
strategy
- The strategy to add.public void finishTraining()
finishTraining
in interface MLTrain
public double getError()
getError
in interface MLTrain
public int getIteration()
getIteration
in interface MLTrain
public List<Strategy> getStrategies()
getStrategies
in interface MLTrain
public MLDataSet getTraining()
getTraining
in interface MLTrain
public boolean isTrainingDone()
isTrainingDone
in interface MLTrain
public void iteration(int count)
public void postIteration()
public void preIteration()
public void setError(double error)
public void setIteration(int iteration)
MLTrain
setIteration
in interface MLTrain
iteration
- the iteration to setpublic void setTraining(MLDataSet training)
training
- The training object.public TrainingImplementationType getImplementationType()
getImplementationType
in interface MLTrain
Copyright © 2014. All Rights Reserved.