Package tv.floe.metronome.deeplearning.rbm.visualization

Examples of tv.floe.metronome.deeplearning.rbm.visualization.RBMRenderer


    String strCE = String.valueOf(CE).substring(0, 5);
   
   

    RBMRenderer rbm_hbias_test = new RBMRenderer();
    rbm_hbias_test.renderHiddenBiases(100, 100, rbm.hiddenBiasNeurons, "/tmp/Metronome/RBM/" + UUIDForRun + "/hbias_" + strCE + "_ce.png");
   
   
  }   
View Full Code Here


    // Matrix hbiasMean = network.getInput().mmul(network.getW()).addRowVector(network.gethBias());
   
    Matrix hbiasMean = MatrixUtils.sigmoid( MatrixUtils.addRowVector( rbm.getInput().times( rbm.connectionWeights ), rbm.getHiddenBias().viewRow(0) ) );

    RBMRenderer renderer = new RBMRenderer();
    //rbm_hbias_test.renderHiddenBiases(100, 100, hbiasMean, "/tmp/Metronome/RBM/" + UUIDForRun + "/activations_" + strCE + "_ce.png");
   
    renderer.renderActivations(100, 100, hbiasMean, "/tmp/Metronome/RBM/" + UUIDForRun + "/activations_" + strCE + "_ce.png", 1);
   
  }
View Full Code Here

   
    //Matrix hbiasMean = MatrixUtils.addRowVector( rbm.getInput().times( rbm.connectionWeights ), rbm.getHiddenBias().viewRow(0) );
    //Matrix hbiasMean = MatrixUtils.sigmoid( MatrixUtils.addRowVector( rbm.getInput().times( rbm.connectionWeights ), rbm.getHiddenBias().viewRow(0) ) );


    RBMRenderer renderer = new RBMRenderer();
    //rbm_hbias_test.renderHiddenBiases(100, 100, hbiasMean, "/tmp/Metronome/RBM/" + UUIDForRun + "/activations_" + strCE + "_ce.png");
   
    // "/tmp/Metronome/RBM/" + UUIDForRun + "/activations_" + strCE + "_ce.png"
    renderer.renderHistogram( rbm.connectionWeights, "/tmp/Metronome/RBM/" + UUIDForRun + "/weight_histogram_" + strCE + "_ce.png", 10 );
   
 
View Full Code Here

    if (CE.equals("init") == false) {
      strCE = String.valueOf(CE).substring(0, 5);
    }
   

    RBMRenderer renderer = new RBMRenderer();
   
    //renderer.renderHistogram( rbm.connectionWeights, "/tmp/Metronome/unit_test/RBMRenderer/weight_histogram_" + strCE + "_ce.png", 10 );
    renderer.renderFilters(rbm.connectionWeights, "/tmp/Metronome/RBM/" + UUIDForRun + "/filters_" + strCE + "_ce.png", 28, 28 );
   
  }   
View Full Code Here

   
    //Matrix hbiasMean = MatrixUtils.addRowVector( rbm.getInput().times( rbm.connectionWeights ), rbm.getHiddenBias().viewRow(0) );
    Matrix hbiasMean = MatrixUtils.sigmoid( MatrixUtils.addRowVector( rbm.getInput().times( rbm.connectionWeights ), rbm.getHiddenBias().viewRow(0) ) );


    RBMRenderer renderer = new RBMRenderer();
    //rbm_hbias_test.renderHiddenBiases(100, 100, hbiasMean, "/tmp/Metronome/RBM/" + UUIDForRun + "/activations_" + strCE + "_ce.png");
   
    renderer.renderActivations(100, 100, hbiasMean, "/tmp/Metronome/unit_test/RBMRenderer/activations_" + strCE + "_ce.png", scale );
   
  }
View Full Code Here

   
    //Matrix hbiasMean = MatrixUtils.addRowVector( rbm.getInput().times( rbm.connectionWeights ), rbm.getHiddenBias().viewRow(0) );
    //Matrix hbiasMean = MatrixUtils.sigmoid( MatrixUtils.addRowVector( rbm.getInput().times( rbm.connectionWeights ), rbm.getHiddenBias().viewRow(0) ) );


    RBMRenderer renderer = new RBMRenderer();
    //rbm_hbias_test.renderHiddenBiases(100, 100, hbiasMean, "/tmp/Metronome/RBM/" + UUIDForRun + "/activations_" + strCE + "_ce.png");
   
    renderer.renderHistogram( rbm.connectionWeights, "/tmp/Metronome/unit_test/RBMRenderer/weight_histogram_" + strCE + "_ce.png", 10 );
   
 
View Full Code Here

 
  private static void renderFiltersToDisk( RestrictedBoltzmannMachine rbm, String CE ) throws Exception {
   
    String strCE = String.valueOf(CE).substring(0, 5);

    RBMRenderer renderer = new RBMRenderer();
   
    //renderer.renderHistogram( rbm.connectionWeights, "/tmp/Metronome/unit_test/RBMRenderer/weight_histogram_" + strCE + "_ce.png", 10 );
    renderer.renderFilters(rbm.connectionWeights, "/tmp/Metronome/unit_test/RBMRenderer/filter_unit_test.png", 28, 28 );
   
 
View Full Code Here

  }
 
  @Test
  public void testComputeHistogramBucketIndex() {
   
    RBMRenderer renderer = new RBMRenderer();

    int bin = renderer.computeHistogramBucketIndex( -0.2, 0.05, -0.1, 10 );
   
    System.out.println("bin: " + bin);
   
    assertEquals( 2, bin );
   
View Full Code Here

   
   
    Matrix input = new DenseMatrix(data_simple2);   
   
   
    RBMRenderer renderer = new RBMRenderer();
/*   
    Map<Integer, Pair<String, Integer>> map = renderer.generateHistogramBuckets( input, 2 );
   
    for (Map.Entry<Integer, Pair<String, Integer>> entry : map.entrySet()) {
     
      Integer key = entry.getKey();
      Pair<String, Integer> value = entry.getValue();

      System.out.println(key + " => " + value.getFirst() + ",  " + value.getSecond());
       
    }
*/   
    Map<Integer, Integer> map = renderer.generateHistogramBuckets( input, 2 );

    for (Map.Entry<Integer, Integer> entry : map.entrySet()) {
     
      Integer key = entry.getKey();
      Integer val = entry.getValue();
View Full Code Here

        };
   
    Matrix input = new DenseMatrix(data_simple);   
   
   
    RBMRenderer renderer = new RBMRenderer();
   
    //Map<Integer, Pair<String, Integer>> map = renderer.generateHistogramBuckets( input, 2 );
    Map<Integer, Integer> map = renderer.generateHistogramBuckets( input, 2 );
   
//    for (Map.Entry<Integer, Pair<String, Integer>> entry : map.entrySet()) {
    for (Map.Entry<Integer, Integer> entry : map.entrySet()) {
     
      Integer key = entry.getKey();
      Integer val = entry.getValue();
      //Pair<String, Integer> value = entry.getValue();

      //System.out.println(key + " => " + value.getFirst() + ",  " + value.getSecond());
      System.out.println(key + " => " + key + ",  " + val );
       
    }
   
    Integer val_key_0 = map.get(0);
    Integer val_key_1 = map.get(1);
   
   
    assertEquals( 10, val_key_0.intValue() );
    assertEquals( 5, val_key_1.intValue() );
   
   
    renderer.renderHistogram(input, "/tmp/debug_render_rbm_histogram.png", 2);
   
   
 
View Full Code Here

TOP

Related Classes of tv.floe.metronome.deeplearning.rbm.visualization.RBMRenderer

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.