Package ca.nengo.model.nef.impl

Examples of ca.nengo.model.nef.impl.NEFEnsembleFactoryImpl.make()


   */
  protected void setUp() throws Exception {
    super.setUp();
   
    NEFEnsembleFactoryImpl ef = new NEFEnsembleFactoryImpl();
    NEFEnsemble ensemble = ef.make("test", 100, 1);
    myOrigin = (DecodedOrigin) ensemble.getOrigin(NEFEnsemble.X);
//    Plotter.plot(ensemble, NEFEnsemble.X);
  }

  /**
 
View Full Code Here


  }
 
  public void testKillNeurons() throws StructuralException
  {
    NEFEnsembleFactoryImpl ef = new NEFEnsembleFactoryImpl();
    NEFEnsembleImpl nef1 = (NEFEnsembleImpl)ef.make("nef1", 1000, 1);
    NEFEnsembleImpl nef2 = (NEFEnsembleImpl)ef.make("nef2", 1000, 1);
    NEFEnsembleImpl nef3 = (NEFEnsembleImpl)ef.make("nef3", 1, 1);
    NetworkImpl net = new NetworkImpl();
   
    net.addNode(nef1);
View Full Code Here

 
  public void testKillNeurons() throws StructuralException
  {
    NEFEnsembleFactoryImpl ef = new NEFEnsembleFactoryImpl();
    NEFEnsembleImpl nef1 = (NEFEnsembleImpl)ef.make("nef1", 1000, 1);
    NEFEnsembleImpl nef2 = (NEFEnsembleImpl)ef.make("nef2", 1000, 1);
    NEFEnsembleImpl nef3 = (NEFEnsembleImpl)ef.make("nef3", 1, 1);
    NetworkImpl net = new NetworkImpl();
   
    net.addNode(nef1);
    myNetwork.addNode(net);
View Full Code Here

  public void testKillNeurons() throws StructuralException
  {
    NEFEnsembleFactoryImpl ef = new NEFEnsembleFactoryImpl();
    NEFEnsembleImpl nef1 = (NEFEnsembleImpl)ef.make("nef1", 1000, 1);
    NEFEnsembleImpl nef2 = (NEFEnsembleImpl)ef.make("nef2", 1000, 1);
    NEFEnsembleImpl nef3 = (NEFEnsembleImpl)ef.make("nef3", 1, 1);
    NetworkImpl net = new NetworkImpl();
   
    net.addNode(nef1);
    myNetwork.addNode(net);
    myNetwork.addNode(nef2);
View Full Code Here

    NetworkImpl b = new NetworkImpl();
    b.setName("b");
    myNetwork.addNode(b);
   
    NEFEnsembleFactoryImpl ef = new NEFEnsembleFactoryImpl();
    NEFEnsembleImpl c = (NEFEnsembleImpl)ef.make("c", 10, 1);
    b.addNode(c);
    b.getSimulator().addProbe("c", "X", true);
   
    b.exposeOrigin(c.getOrigin("X"), "exposed");
   
View Full Code Here

  }
 
  public void testExposeOrigin() throws StructuralException
  {
    NEFEnsembleFactoryImpl ef = new NEFEnsembleFactoryImpl();
    NEFEnsembleImpl a = (NEFEnsembleImpl)ef.make("a", 10, 1);
   
    myNetwork.addNode(a);
   
    myNetwork.exposeOrigin(a.getOrigin("X"), "test");
   
View Full Code Here

  }
 
  public void testHideOrigin() throws StructuralException
  {
    NEFEnsembleFactoryImpl ef = new NEFEnsembleFactoryImpl();
    NEFEnsembleImpl a = (NEFEnsembleImpl)ef.make("a", 10, 1);
   
    myNetwork.addNode(a);
   
    myNetwork.exposeOrigin(a.getOrigin("X"), "test");
   
View Full Code Here

   
    if(net.getNodeTerminations().size() != 0)
      fail("Network has terminations when it shouldn't");
   
    NEFEnsembleFactoryImpl ef = new NEFEnsembleFactoryImpl();
    NEFEnsembleImpl a = (NEFEnsembleImpl)ef.make("a", 10, 1);
    float[][] tmp = new float[1][1];
    tmp[0][0] = 1;
    a.addDecodedTermination("in", tmp, 0.007f, false);
   
    net.addNode(a);
View Full Code Here

   
    if(net.getNodeOrigins().size() != 0)
      fail("Network has origins when it shouldn't");
   
    NEFEnsembleFactoryImpl ef = new NEFEnsembleFactoryImpl();
    NEFEnsembleImpl a = (NEFEnsembleImpl)ef.make("a", 10, 1);
   
    net.addNode(a);
   
    if(net.getNodeOrigins().size() != a.getOrigins().length)
      fail("Network hasn't found node origin");
View Full Code Here

  public void testReset() throws StructuralException, SimulationException
  {
    NetworkImpl net = new NetworkImpl();
   
    NEFEnsembleFactoryImpl ef = new NEFEnsembleFactoryImpl();
    NEFEnsembleImpl a = (NEFEnsembleImpl)ef.make("a", 10, 1);
    a.addDecodedTermination("input", new float[][]{new float[]{1}}, 0.01f, false);
   
    net.addNode(a);
   
    FunctionInput fin = new FunctionInput("fin", new Function[]{new ConstantFunction(1,0)}, Units.UNK);
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.