|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.encog.ml.train.BasicTraining
org.encog.neural.networks.training.pnn.TrainBasicPNN
public class TrainBasicPNN
Train a PNN.
Field Summary | |
---|---|
static double |
DEFAULT_MAX_ERROR
The default max error. |
static double |
DEFAULT_MIN_IMPROVEMENT
The default minimum improvement before stop. |
static int |
DEFAULT_NUM_SIGMAS
The default number of sigmas to evaluate between the low and high. |
static double |
DEFAULT_SIGMA_HIGH
The default sigma high value. |
static double |
DEFAULT_SIGMA_LOW
THe default sigma low value. |
Constructor Summary | |
---|---|
TrainBasicPNN(BasicPNN network,
MLDataSet training)
Train a BasicPNN. |
Method Summary | |
---|---|
double |
calcErrorWithMultipleSigma(double[] x,
double[] der1,
double[] der2,
boolean der)
Calculate the error with multiple sigmas. |
double |
calcErrorWithSingleSigma(double sig)
Calculate the error using a common sigma. |
double |
calculateError(MLDataSet training,
boolean deriv)
Calculate the error for the entire training set. |
boolean |
canContinue()
|
MLData |
computeDeriv(MLData input,
MLData target)
Compute the derivative for target data. |
double |
getMaxError()
|
MLMethod |
getMethod()
Get the current best machine learning method from the training. |
double |
getMinImprovement()
|
int |
getNumSigmas()
|
double |
getSigmaHigh()
|
double |
getSigmaLow()
|
void |
iteration()
Perform one iteration of training. |
TrainingContinuation |
pause()
Pause the training to continue later. |
void |
resume(TrainingContinuation state)
Resume training. |
void |
setMaxError(double maxError)
|
void |
setMinImprovement(double minImprovement)
|
void |
setNumSigmas(int numSigmas)
|
void |
setSigmaHigh(double sigmaHigh)
|
void |
setSigmaLow(double sigmaLow)
|
Methods inherited from class org.encog.ml.train.BasicTraining |
---|
addStrategy, finishTraining, getError, getImplementationType, getIteration, getStrategies, getTraining, isTrainingDone, iteration, postIteration, preIteration, setError, setIteration, setTraining |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final double DEFAULT_MAX_ERROR
public static final double DEFAULT_MIN_IMPROVEMENT
public static final double DEFAULT_SIGMA_LOW
public static final double DEFAULT_SIGMA_HIGH
public static final int DEFAULT_NUM_SIGMAS
Constructor Detail |
---|
public TrainBasicPNN(BasicPNN network, MLDataSet training)
network
- The network to train.training
- The training data.Method Detail |
---|
public double calcErrorWithMultipleSigma(double[] x, double[] der1, double[] der2, boolean der)
calcErrorWithMultipleSigma
in interface CalculationCriteria
x
- The data.der1
- The first derivative.der2
- The 2nd derivatives.der
- Calculate the derivative.
public double calcErrorWithSingleSigma(double sig)
calcErrorWithSingleSigma
in interface CalculationCriteria
sig
- The sigma to use.
public double calculateError(MLDataSet training, boolean deriv)
training
- Training set to use.deriv
- Should we find the derivative.
public boolean canContinue()
canContinue
in interface MLTrain
public MLData computeDeriv(MLData input, MLData target)
input
- The input.target
- The target data.
public double getMaxError()
public MLMethod getMethod()
getMethod
in interface MLTrain
public double getMinImprovement()
public int getNumSigmas()
public double getSigmaHigh()
public double getSigmaLow()
public void iteration()
iteration
in interface MLTrain
public TrainingContinuation pause()
pause
in interface MLTrain
public void resume(TrainingContinuation state)
resume
in interface MLTrain
state
- The training continuation object to use to continue.public void setMaxError(double maxError)
maxError
- the maxError to setpublic void setMinImprovement(double minImprovement)
minImprovement
- the minImprovement to setpublic void setNumSigmas(int numSigmas)
numSigmas
- the numSigmas to setpublic void setSigmaHigh(double sigmaHigh)
sigmaHigh
- the sigmaHigh to setpublic void setSigmaLow(double sigmaLow)
sigmaLow
- the sigmaLow to set
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |