Package org.apache.commons.math3.random

Examples of org.apache.commons.math3.random.MersenneTwister


    DataSet first = fetcher.next();
    int numIns = first.getFirst().numCols();
    int numLabels = first.getSecond().numCols();

    int n_layers = hiddenLayerSizes.length;
    RandomGenerator rng = new MersenneTwister(123);
   
   
    DeepBeliefNetwork dbn = new DeepBeliefNetwork( numIns, hiddenLayerSizes, numLabels, n_layers, rng ); //, Matrix input, Matrix labels);
       
    int recordsProcessed = 0;
View Full Code Here


 
  @Test
  public void testMNISTRenderPath() throws Exception {
   
    MnistDataSetIterator fetcher = new MnistDataSetIterator(100,200);
    MersenneTwister rand = new MersenneTwister(123);

    double learningRate = 0.001;
   
    int[] batchSteps = { 250, 200, 150, 100, 50, 25, 5 };
   
View Full Code Here

   
  }
 
  public static Matrix matrixRand( int rows, int cols ) {
   
    RandomGenerator rnd = new MersenneTwister(1234);
    //rnd.nextDouble();
   
    Matrix res = new DenseMatrix( rows, cols );
   
    for ( int r = 0; r < res.numRows(); r++ ) {
     
      for ( int c = 0; c < res.numCols(); c++ ) {
       
        res.set(r,  c, rnd.nextDouble());
        //System.out.println( "next: " + rnd.nextDouble() );
       
      }
     
    }
View Full Code Here





    RandomGenerator rng = new MersenneTwister(123);

    double preTrainLr = 0.0001;
    int preTrainEpochs = 1000;
    int k = 1;
    int nIns = 2,nOuts = 2;
View Full Code Here





    RandomGenerator rng = new MersenneTwister(123);

    double preTrainLr = 0.01;
    int preTrainEpochs = 1000;
    int k = 1;
   
View Full Code Here

*/




    RandomGenerator rng = new MersenneTwister(123);

    double preTrainLr = 0.001;
    int preTrainEpochs = 100;
    int k = 1;
    int nIns = 2,nOuts = 2;
View Full Code Here

   
   



    RandomGenerator rng = new MersenneTwister(123);

    double preTrainLr = 0.001;
    int preTrainEpochs = 100;
    int k = 1;
    int nIns = 2,nOuts = 2;
View Full Code Here

 
  @Test
  public void testParameterAveragingCode() {
   

    RandomGenerator rng = new MersenneTwister(123);

    double preTrainLr = 0.001;
    int preTrainEpochs = 100;
    int k = 1;
    int nIns = 2,nOuts = 2;
View Full Code Here

   
  }
 
  public static Matrix matrixRand( int rows, int cols ) {
   
    RandomGenerator rnd = new MersenneTwister(1234);
    //rnd.nextDouble();
   
    Matrix res = new DenseMatrix( rows, cols );
   
    for ( int r = 0; r < res.numRows(); r++ ) {
     
      for ( int c = 0; c < res.numCols(); c++ ) {
       
        res.set(r,  c, rnd.nextDouble());
        //System.out.println( "next: " + rnd.nextDouble() );
       
      }
     
    }
View Full Code Here





    RandomGenerator rng = new MersenneTwister(123);

    double preTrainLr = 0.0001;
    int preTrainEpochs = 1000;
    int k = 1;
    int nIns = 2,nOuts = 2;
View Full Code Here

TOP

Related Classes of org.apache.commons.math3.random.MersenneTwister

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.