Package org.encog.neural.networks.training

Examples of org.encog.neural.networks.training.TrainingError


   *            the currentFold to set
   */
  public final void setCurrentFold(final int theCurrentFold) {

    if (this.owner != null) {
      throw new TrainingError(
          "Can't set the fold on a non-top-level set.");
    }

    if (currentFold >= this.numFolds) {
      throw new TrainingError(
    "Can't set the current fold to be greater than "
          + "the number of folds.");
    }
    this.currentFold = theCurrentFold;
    this.currentFoldOffset = this.foldSize * this.currentFold;
 
View Full Code Here


   *            The training data to use. Must be indexable.
   */
  public SVDTraining(final RBFNetwork network, final MLDataSet training) {
    super(TrainingImplementationType.OnePass);
    if (network.getOutputCount() != 1) {
      throw new TrainingError(
          "SVD requires an output layer with a single neuron.");
    }

    setTraining(training);
    this.network = network;
View Full Code Here

   *            The training state to return to.
   */
  @Override
  public final void resume(final TrainingContinuation state) {
    if (!isValidResume(state)) {
      throw new TrainingError("Invalid training resume data length");
    }

    final double[] lastGradient = (double[]) state
        .get(QuickPropagation.LAST_GRADIENTS);

View Full Code Here

   *            The training state to return to.
   */
  @Override
  public final void resume(final TrainingContinuation state) {
    if (!isValidResume(state)) {
      throw new TrainingError("Invalid training resume data length");
    }

    ((TrainFlatNetworkBackPropagation) getFlatTraining())
        .setLastDelta((double[]) state.get(Backpropagation.LAST_DELTA));

View Full Code Here

  public LevenbergMarquardtTraining(final BasicNetwork network,
      final MLDataSet training) {
    super(TrainingImplementationType.Iterative);
    ValidateNetwork.validateMethodToData(network, training);
    if (network.getOutputCount() != 1) {
      throw new TrainingError(
          "Levenberg Marquardt requires an output layer with a single neuron.");
    }

    setTraining(training);
    this.indexableTraining = getTraining();
View Full Code Here

   *            The training state to return to.
   */
  @Override
  public final void resume(final TrainingContinuation state) {
    if (!isValidResume(state)) {
      throw new TrainingError("Invalid training resume data length");
    }
    final double[] lastGradient = (double[]) state
        .get(ResilientPropagation.LAST_GRADIENTS);
    final double[] updateValues = (double[]) state
        .get(ResilientPropagation.UPDATE_VALUES);
View Full Code Here

        break;
      case iRPROPm:
        weightChange = updateiWeightMinus(gradients,lastGradient,index);
        break;
      default:
        throw new TrainingError("Unknown RPROP type: " + this.rpropType);
    }
   
    this.lastWeightChange[index] = weightChange;
    return weightChange;
  }
View Full Code Here

   */
  public final MLTrain create(final MLMethod method,
      final MLDataSet training, final String argsStr) {

    if (!(method instanceof BasicNetwork)) {
      throw new TrainingError(
          "Invalid method type, requires BasicNetwork");
    }

    final CalculateScore score = new TrainingSetScore(training);

View Full Code Here

   */
  public final MLTrain create(final MLMethod method,
      final MLDataSet training, final String argsStr) {

    if (!(method instanceof BasicNetwork)) {
      throw new TrainingError(
          "Invalid method type, requires BasicNetwork");
    }

    final CalculateScore score = new TrainingSetScore(training);

View Full Code Here

   */
  public MLTrain create(final MLMethod method,
      final MLDataSet training, final String argsStr) {

    if (!(method instanceof BasicNetwork)) {
      throw new TrainingError(
          "Invalid method type, requires BasicNetwork");
    }

    final CalculateScore score = new TrainingSetScore(training);

View Full Code Here

TOP

Related Classes of org.encog.neural.networks.training.TrainingError

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.