Examples of MLDataSet


Examples of org.encog.ml.data.MLDataSet

    network.addLayer(new BasicLayer(2));
    network.addLayer(new BasicLayer(1));
    network.getStructure().finalizeStructure();
    network.reset();

    MLDataSet trainingSet = new BasicMLDataSet(XOR_INPUT, XOR_IDEAL);

    // train the neural network
    final MLTrain train = new ResilientPropagation(network, trainingSet);

    do {
View Full Code Here

Examples of org.encog.ml.data.MLDataSet

  public void loadAndEvaluate() {
    System.out.println("Loading network");

    BasicNetwork network = (BasicNetwork)EncogDirectoryPersistence.loadObject(new File(FILENAME));

    MLDataSet trainingSet = new BasicMLDataSet(XOR_INPUT, XOR_IDEAL);
    double e = network.calculateError(trainingSet);
    System.out
        .println("Loaded network's error is(should be same as above): "
            + e);
  }
View Full Code Here

Examples of org.encog.ml.data.MLDataSet

    network.addLayer(new BasicLayer(2));
    network.addLayer(new BasicLayer(1));
    network.getStructure().finalizeStructure();
    network.reset();

    MLDataSet trainingSet = new BasicMLDataSet(XOR_INPUT, XOR_IDEAL);

    // train the neural network
    final MLTrain train = new ResilientPropagation(network, trainingSet);

    do {
View Full Code Here

Examples of org.encog.ml.data.MLDataSet

  }

  public void loadAndEvaluate() throws IOException, ClassNotFoundException {
    System.out.println("Loading network");
    BasicNetwork network = (BasicNetwork) SerializeObject.load(new File(FILENAME));
    MLDataSet trainingSet = new BasicMLDataSet(XOR_INPUT, XOR_IDEAL);
    double e = network.calculateError(trainingSet);
    System.out
        .println("Loaded network's error is(should be same as above): "
            + e);
  }
View Full Code Here

Examples of org.encog.ml.data.MLDataSet

  }

  public static void main(final String args[]) {
   
    final TemporalXOR temp = new TemporalXOR();
    final MLDataSet trainingSet = temp.generate(120);

    final BasicNetwork elmanNetwork = ElmanXOR.createElmanNetwork();
    final BasicNetwork feedforwardNetwork = ElmanXOR
        .createFeedforwardNetwork();
View Full Code Here

Examples of org.encog.ml.data.MLDataSet

public class TestTrainingContinuation extends TestCase {
  public void testContRPROP()
  {
    BasicNetwork network1 = NetworkUtil.createXORNetworkUntrained();
    BasicNetwork network2 = NetworkUtil.createXORNetworkUntrained();
    MLDataSet trainingData = new BasicMLDataSet(XOR.XOR_INPUT,XOR.XOR_IDEAL);
   
    // train network 1, no continue
    ResilientPropagation rprop1 = new ResilientPropagation(network1,trainingData);
    rprop1.iteration();
    rprop1.iteration();
View Full Code Here

Examples of org.encog.ml.data.MLDataSet

 
  public void testContBackprop()
  {
    BasicNetwork network1 = NetworkUtil.createXORNetworkUntrained();
    BasicNetwork network2 = NetworkUtil.createXORNetworkUntrained();
    MLDataSet trainingData = new BasicMLDataSet(XOR.XOR_INPUT,XOR.XOR_IDEAL);
   
    // train network 1, no continue
    Backpropagation rprop1 = new Backpropagation(network1,trainingData,0.4,0.4);
    rprop1.iteration();
    rprop1.iteration();
View Full Code Here

Examples of org.encog.ml.data.MLDataSet

    BasicNetwork network2 = (BasicNetwork)network1.clone();
    BasicNetwork network3 = (BasicNetwork)network1.clone();
    network2.setBiasActivation(-1);
    network3.setBiasActivation(0.5);
   
    MLDataSet trainingData = new BasicMLDataSet(XOR.XOR_INPUT,XOR.XOR_IDEAL);
   
    MLTrain rprop1 = new ResilientPropagation(network1, trainingData);
    MLTrain rprop2 = new ResilientPropagation(network2, trainingData);
    MLTrain rprop3 = new ResilientPropagation(network3, trainingData);
View Full Code Here

Examples of org.encog.ml.data.MLDataSet

public class TrainComplete extends TestCase {
 
  public void testCompleteTrain()
  {
    MLDataSet trainingData = new BasicMLDataSet(XOR.XOR_INPUT,XOR.XOR_IDEAL);
   
    BasicNetwork network = EncogUtility.simpleFeedForward(2, 5, 7, 1, true);
    Randomizer randomizer = new ConsistentRandomizer(-1, 1, 19);
    //randomizer.randomize(network);
    System.out.println(network.dumpWeights());
View Full Code Here

Examples of org.encog.ml.data.MLDataSet

*/
public class EvaluateNuguyenWidrow {

   public static void main( String[] args ) {
  
     MLDataSet trainingData1 = new BasicMLDataSet( XOR.XOR_INPUT, XOR.XOR_IDEAL );
     MLDataSet trainingData2 = new BasicMLDataSet( XOR.XOR_INPUT, XOR.XOR_IDEAL );
     MLDataSet trainingData3 = new BasicMLDataSet( XOR.XOR_INPUT, XOR.XOR_IDEAL );
      
       for ( int i = 0; i < 1; i++ ) {
          

          
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.