Package org.encog.mathutil.randomize

Examples of org.encog.mathutil.randomize.FanInRandomizer


  public static void main(final String args[]) {

    RangeRandomizer rangeRandom = new RangeRandomizer(-1, 1);
    NguyenWidrowRandomizer nwrRandom = new NguyenWidrowRandomizer(-1, 1);
    FanInRandomizer fanRandom = new FanInRandomizer();
    GaussianRandomizer gaussianRandom = new GaussianRandomizer(0, 1);

    System.out.println("Error improvement, higher is better.");
    BasicMLDataSet training = new BasicMLDataSet(XOR_INPUT,
        XOR_IDEAL);
View Full Code Here


  public void testFanIn()
  {   
    BasicNetwork network = EncogUtility.simpleFeedForward(5,10,15,20, true);
    double[] weights = network.getStructure().getFlat().getWeights();
    EngineArray.fill(weights, 100);
    (new FanInRandomizer()).randomize(network);
    System.out.println(network.dumpWeights());
    for(int i=0;i<weights.length;i++ )
    {
      Assert.assertTrue(weights[i]<10);
    }
View Full Code Here

          network, new PilotScore(), 10, 2, 100);
    }
    else
    {
      train = new NeuralGeneticAlgorithm(
          network, new FanInRandomizer(),
          new PilotScore(),500, 0.1, 0.25);
    }
   
    int epoch = 1;
View Full Code Here

    case 1: // Nguyen-Widrow
      r = new NguyenWidrowRandomizer(dialog.getLow().getValue(), dialog
          .getHigh().getValue());
      break;
    case 2: // Fan in
      r = new FanInRandomizer(dialog.getLow().getValue(), dialog
          .getHigh().getValue(), false);
      break;
    }

    if (r != null) {
View Full Code Here

  public void testFanIn()
  {   
    BasicNetwork network = EncogUtility.simpleFeedForward(5,10,15,20, true);
    double[] weights = network.getStructure().getFlat().getWeights();
    EngineArray.fill(weights, 100);
    (new FanInRandomizer()).randomize(network);
    System.out.println(network.dumpWeights());
    for(int i=0;i<weights.length;i++ )
    {
      Assert.assertTrue(weights[i]<10);
    }
View Full Code Here

TOP

Related Classes of org.encog.mathutil.randomize.FanInRandomizer

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.