@Test
public void testRandomInitializer() {
Environment.getInstance().setUseWeightsSharedMemory(true);
NeuralNetworkImpl nn = NNFactory.mlp(new int[] { 3, 2 }, true);
NNRandomInitializer rand = new NNRandomInitializer(new MersenneTwisterRandomInitializer(-0.1f, 0.1f), 0.5f);
rand.initialize(nn);
for (Layer l : nn.getLayers()) {
if (Util.isBias(l)) {
Tensor t = ((FullyConnected) l.getConnections().get(0)).getWeights();
float[] elements = t.getElements();