TrainEA
org.encog.ml.ea.train.basic

Class TrainEA

    • Constructor Detail

      • TrainEA

        public TrainEA(Population thePopulation,       CalculateScore theScoreFunction)
        Create a trainer for a score function.
        Parameters:
        thePopulation - The population.
        theScoreFunction - The score function.
      • TrainEA

        public TrainEA(Population thePopulation,       MLDataSet trainingData)
        Create a trainer for training data.
        Parameters:
        thePopulation - The population.
        trainingData - The training data.
    • Method Detail

      • setError

        public void setError(double error)
        Not used.
        Specified by:
        setError in interface MLTrain
        Parameters:
        error - Not used.
      • isTrainingDone

        public boolean isTrainingDone()
        Specified by:
        isTrainingDone in interface MLTrain
        Returns:
        True if training can progress no further.
      • iteration

        public void iteration(int count)
        Perform the specified number of training iterations. This is a basic implementation that just calls iteration the specified number of times. However, some training methods, particularly with the GPU, benefit greatly by calling with higher numbers than 1.
        Specified by:
        iteration in interface MLTrain
        Parameters:
        count - The number of training iterations.
      • resume

        public void resume(TrainingContinuation state)
        Resume training.
        Specified by:
        resume in interface MLTrain
        Parameters:
        state - The training continuation object to use to continue.
      • addStrategy

        public void addStrategy(Strategy strategy)
        Not supported, will throw an error.
        Specified by:
        addStrategy in interface MLTrain
        Parameters:
        strategy - Not used.
      • canContinue

        public boolean canContinue()
        Specified by:
        canContinue in interface MLTrain
        Returns:
        True if the training can be paused, and later continued.
      • getMethod

        public MLMethod getMethod()
        Description copied from interface: MLTrain
        Get the current best machine learning method from the training.
        Specified by:
        getMethod in interface MLTrain
        Returns:
        A network created for the best genome.
      • getTraining

        public MLDataSet getTraining()
        Returns null, does not use a training set, rather uses a score function.
        Specified by:
        getTraining in interface MLTrain
        Returns:
        null, not used.
      • getStrategies

        public List<Strategy> getStrategies()
        Returns an empty list, strategies are not supported.
        Specified by:
        getStrategies in interface MLTrain
        Returns:
        The strategies in use(none).

SCaVis 1.8 © jWork.org