Package com.github.neuralnetworks.architecture.types

Examples of com.github.neuralnetworks.architecture.types.Autoencoder.removeLayer()


  // training
  t.train();

  // the output layer is removed, thus making the hidden layer the new output
  ae.removeLayer(ae.getOutputLayer());

  // testing
  t.test();

  assertEquals(0, t.getOutputError().getTotalNetworkError(), 0);
View Full Code Here


      Environment.getInstance().setExecutionMode(EXECUTION_MODE.SEQ);

      bae.train();

      // the output layer is needed only during the training phase...
      ae.removeLayer(ae.getOutputLayer());

      bae.test();

      // 2 of the iris classes are linearly not separable - an error of 1/3 illustrates that
      assertEquals(0, bae.getOutputError().getTotalNetworkError(), 1/3f);
View Full Code Here

      bae.addEventListener(new LogTrainingListener(Thread.currentThread().getStackTrace()[1].getMethodName()));

      bae.train();

      // the output layer is needed only during the training phase...
      ae.removeLayer(ae.getOutputLayer());

      bae.test();

      // 2 of the iris classes are linearly not separable - an error of 1/3 illustrates that
      assertEquals(0, bae.getOutputError().getTotalNetworkError(), 2/3f);
View Full Code Here

  Trainer<?> t = TrainerFactory.backPropagationAutoencoder(nn, trainInputProvider, testInputProvider,  new MultipleNeuronsOutputError(), new NNRandomInitializer(new MersenneTwisterRandomInitializer(-0.01f, 0.01f)), 0.01f, 0.5f, 0f, 0f, 0f);

  t.addEventListener(new LogTrainingListener(Thread.currentThread().getStackTrace()[1].getMethodName(), false, true));
  Environment.getInstance().setExecutionMode(EXECUTION_MODE.CPU);
  t.train();
  nn.removeLayer(nn.getOutputLayer());
  t.test();

  assertEquals(0, t.getOutputError().getTotalNetworkError(), 0.1);
    }
View Full Code Here

  // training
  t.train();

  // the output layer is removed, thus making the hidden layer the new output
  ae.removeLayer(ae.getOutputLayer());

  // testing
  t.test();

  assertEquals(0, t.getOutputError().getTotalNetworkError(), 0);
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.