Package org.encog.neural.flat.train.prop

Examples of org.encog.neural.flat.train.prop.TrainFlatNetworkResilient


    System.out.println("Starting Weights:");
    displayWeights(network);
    evaluate(network,trainingSet);

    final TrainFlatNetworkResilient train = new TrainFlatNetworkResilient(
        network, trainingSet);

    for (int iteration = 1; iteration <= ITERATIONS; iteration++) {
      train.iteration();

      System.out.println();
      System.out.println("*** Iteration #" + iteration);
      System.out.println("Error: " + train.getError());
      evaluate(network,trainingSet);
     
      System.out.println("LastGrad:"
          + Arrays.toString(train.getLastGradient()));
      System.out.println("Updates :"
          + Arrays.toString(train.getUpdateValues()));

      displayWeights(network);
    }
  }
View Full Code Here


    network.randomize();
   
    MLDataSet trainingSet = new BasicMLDataSet(XOR_INPUT, XOR_IDEAL);
   
   
    TrainFlatNetworkResilient train = new TrainFlatNetworkResilient(network,trainingSet);
   
    //Encog.getInstance().initCL();
    //train.setTargetDevice(Encog.getInstance().getCL().getDevices().get(0));
   
    int epoch = 1;

    do {
      train.iteration();
      System.out
          .println("Epoch #" + epoch + " Error:" + train.getError());
      epoch++;
    } while(train.getError() > 0.01 );

    double[] output = new double[1];
    // test the neural network
    System.out.println("Neural Network Results:");
    for(MLDataPair pair: trainingSet ) {
View Full Code Here

      final MLDataSet training, final double initialUpdate,
      final double maxStep) {

    super(network, training);

    final TrainFlatNetworkResilient rpropFlat = new TrainFlatNetworkResilient(
        network.getFlat(), getTraining(),
        RPROPConst.DEFAULT_ZERO_TOLERANCE, initialUpdate, maxStep);
    setFlatTraining(rpropFlat);
  }
View Full Code Here

TOP

Related Classes of org.encog.neural.flat.train.prop.TrainFlatNetworkResilient

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.