org.encog.neural.networks.training
Class TrainingSetScore

java.lang.Object
  extended by org.encog.neural.networks.training.TrainingSetScore
All Implemented Interfaces:
CalculateScore

public class TrainingSetScore
extends Object
implements CalculateScore

Calculate a score based on a training set. This class allows simulated annealing or genetic algorithms just as you would any other training set based training method. The method must support regression (MLRegression).


Constructor Summary
TrainingSetScore(MLDataSet training)
          Construct a training set score calculation.
 
Method Summary
 double calculateScore(MLMethod method)
          Calculate the score for the network.
 boolean requireSingleThreaded()
           
 boolean shouldMinimize()
          A training set based score should always seek to lower the error, as a result, this method always returns true.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TrainingSetScore

public TrainingSetScore(MLDataSet training)
Construct a training set score calculation.

Parameters:
training - The training data to use.
Method Detail

calculateScore

public double calculateScore(MLMethod method)
Calculate the score for the network.

Specified by:
calculateScore in interface CalculateScore
Parameters:
method - The network to calculate for.
Returns:
The score.

shouldMinimize

public boolean shouldMinimize()
A training set based score should always seek to lower the error, as a result, this method always returns true.

Specified by:
shouldMinimize in interface CalculateScore
Returns:
Returns true.

requireSingleThreaded

public boolean requireSingleThreaded()
Specified by:
requireSingleThreaded in interface CalculateScore
Returns:
True, if this score function cannot be done in parallel.


Copyright © 2014. All Rights Reserved.