}
};
FunctionInput input = new FunctionInput("input", new Function[]{f}, Units.UNK);
// FunctionInput zero = new FunctionInput("zero", new Function[]{new ConstantFunction(1, 0f)}, Units.UNK);
Network network = new NetworkImpl();
network.addNode(input);
network.addNode(source);
network.addNode(dest);
source.addDecodedTermination("input", MU.I(1), .005f, false); //OK
BiasOrigin bo = source.addBiasOrigin(source.getOrigin(NEFEnsemble.X), 200, "interneurons", true); //should have -ve bias decoders
network.addNode(bo.getInterneurons()); //should be backwards response functions
//** bo.getInterneurons().addDecodedTermination("source", MU.I(1), .005f, false);
// Plotter.plot(bo.getInterneurons());
// Plotter.plot(bo.getInterneurons(), NEFEnsemble.X);
// DecodedTermination t = (DecodedTermination) dest.addDecodedTermination("source", MU.I(1), .005f, false);
//** BiasTermination[] bt = dest.addBiasTerminations(t, .002f, bo.getDecoders()[0][0], ((DecodedOrigin) source.getOrigin(NEFEnsemble.X)).getDecoders());
//** bt[1].setStaticBias(-1); //creates intrinsic current needed to counteract interneuron activity at 0
// float[][] weights = MU.prod(dest.getEncoders(), MU.transpose(((DecodedOrigin) source.getOrigin(NEFEnsemble.X)).getDecoders()));
//* float[][] biasEncoders = MU.transpose(new float[][]{bt[0].getBiasEncoders()});
//* float[][] biasDecoders = MU.transpose(bo.getDecoders());
//* float[][] weightBiases = MU.prod(biasEncoders, biasDecoders);
//* float[][] biasedWeights = MU.sum(weights, weightBiases);
// Plotter.plot(weights[0], "some weights");
// Plotter.plot(biasedWeights[0], "some biased weights");
// Plotter.plot(weights[1], "some more weights");
// Plotter.plot(bt[0].getBiasEncoders(), "bias decoders");
network.addProjection(input.getOrigin(FunctionInput.ORIGIN_NAME), source.getTermination("input"));
network.addProjection(source.getOrigin(NEFEnsemble.X), dest.getTermination("source"));
//* network.addProjection(bo, bo.getInterneurons().getTermination("source"));
//* network.addProjection(bo, bt[0]);
//* network.addProjection(bo.getInterneurons().getOrigin(NEFEnsemble.X), bt[1]);
// network.addProjection(zero.getOrigin(FunctionInput.ORIGIN_NAME), bt[1]);
// Probe sourceProbe = network.getSimulator().addProbe("source", NEFEnsemble.X, true);
// Probe destProbe = network.getSimulator().addProbe("dest", NEFEnsemble.X, true);
// Probe interProbe = network.getSimulator().addProbe("source_X_bias_interneurons", NEFEnsemble.X, true);
network.run(0, 2);
// Plotter.plot(sourceProbe.getData(), "source");
// Plotter.plot(destProbe.getData(), "dest");
// Plotter.plot(interProbe.getData(), "interneurons");
}