Package org.encog.mathutil.randomize

Examples of org.encog.mathutil.randomize.NguyenWidrowRandomizer


  public final void reset() {

    if (getLayerCount() < 3) {
      (new RangeRandomizer(-1, 1)).randomize(this);
    } else {
      (new NguyenWidrowRandomizer(-1, 1)).randomize(this);
    }
  }
View Full Code Here


  }

  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,
View Full Code Here

        network.addLayer(new BasicLayer(null,true,2));
        network.addLayer(new BasicLayer(new ActivationSigmoid(),true,3));
        network.addLayer(new BasicLayer(new ActivationSigmoid(),false,3));
        network.addLayer(new BasicLayer(null,false,1));
        network.getStructure().finalizeStructure();
        (new NguyenWidrowRandomizer(-1,1)).randomize( network );
       
        return network;
    }
View Full Code Here

    case 0: // Random
      r = new RangeRandomizer(dialog.getLow().getValue(), dialog
          .getHigh().getValue());
      break;
    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);
View Full Code Here

    if (getLayerCount() < 3) {
      useNWR = false;
    }
   
    if (useNWR) {
      return new NguyenWidrowRandomizer();
    } else {
      return new RangeRandomizer(-1,1);
    }
  }
View Full Code Here

        network.addLayer(new BasicLayer(null,true,2));
        network.addLayer(new BasicLayer(new ActivationSigmoid(),true,3));
        network.addLayer(new BasicLayer(new ActivationSigmoid(),false,3));
        network.addLayer(new BasicLayer(null,false,1));
        network.getStructure().finalizeStructure();
        (new NguyenWidrowRandomizer()).randomize( network );
       
        return network;
    }
View Full Code Here

     * the same topology as this network.
     * @param trainingSet The training set.
     */
    public NeuralPSO(BasicNetwork network, MLDataSet trainingSet)       
    {  
      this(network, new NguyenWidrowRandomizer(), new TrainingSetScore(trainingSet), 20);
    }
View Full Code Here

    final int particles = holder.getInt(
        MLTrainFactory.PROPERTY_PARTICLES, false, 20);
   
    CalculateScore score = new TrainingSetScore(training);
    Randomizer randomizer = new NguyenWidrowRandomizer();
   
    final MLTrain train = new NeuralPSO((BasicNetwork)method,randomizer,score,particles);
   
    return train;
  }
View Full Code Here

TOP

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

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.