Example #1
0
 def initNodes(self):
     """ DOCSTRING: """
     if (type(self.__networkParams['nodeType']) == type(co.pcoIntegrateFire())):
         self.__initNode_pcoIntegrateFire()
         self.__nodesInitialized = True
     else: 
         raise LookupError ('initNetworkNodes: nodeType invalid or not yet defined')
Example #2
0
import conedy as co

N = co.network()

co.set("samplingTime", 1000.0)

nodeNumber = N.addNode(co.pcoIntegrateFire())

N.observeTime("output/evolve2.py.series")
N.observe(nodeNumber, "output/evolve2.py.series")

for i in range(0, 100):  #observe the state of the node at times 0.3 * n
    N.evolve(0.03 * i, 0.03 * (i + 1))
co.set("pcoIntegrateFire_noiseFrequency", 0.0)
co.set("pcoIntegrateFire_timeDelay", 0.01)
co.set("pcoIntegrateFire_t_ref", 0.05)
co.set("pcoIntegrateFire_alpha", 0.9)


N = co.network()




rewiring = 0.5
coupling = 0.012

#n.useLatticePositioning(100,100);

N.torusNearestNeighbors(40,40,36.0, co.pcoIntegrateFire(), co.weightedEdge())

N.rewire(rewiring)

N.randomizeStates(co.pcoIntegrateFire(), co.uniform(0.0,1.0));
N.randomizeWeights(co.uniform(coupling,coupling));

N.saveAdjacencyList("output/nonconverging.py.graph");

N.observeTime("output/nonconverging.py.phaseCoherence");
N.observePhaseCoherence("output/nonconverging.py.phaseCoherence");
N.evolve(0.0,100.0);

Example #4
0
        """ DOCSTRING: """
        self.defaultDict_NetworkType.update(self.__networkParams)

        self.cycle(self.defaultDict_NetworkType['nodeCount'],
                   self.defaultDict_NetworkType['nearestNeighbours'],
                   self.defaultDict_NetworkType['nodeType'],  
                   self.defaultDict_NetworkType['edgeType']
                  )
        self.rewire(self.defaultDict_NetworkType['rewiringProbability'],
                    self.defaultDict_NetworkType['nodeType']
                   )
        self.randomizeStates(self.defaultDict_NetworkType['nodeType'],
                             self.defaultDict_NetworkType['distributionType']   
                            )
        self.__networkInitialized = True

    def __initScaleFree(self):
        raise IOError ('scaleFree creation not yet defined')
    
    def __initRandomGraph(self):
        raise IOError ('randomGraph creation not yet defined')        

newNet = Network()
newNet.updateNetworkParams({'networkType': 'smallWorld', 'edgeType': co.weightedEdge(0.01), 'nodeType': co.pcoIntegrateFire()})
newNet.initNetwork()
#newNet.initNodes()
#for i in range(0,10000):
#    print newNet.getParam(i,'pcoIntegrateFire_t_ref')


Example #5
0
import conedy as co

N = co.network()



co.set("samplingTime" , 1000.0)



nodeNumber = N.addNode(co.pcoIntegrateFire())


N.observeTime("output/evolve2.py.series")
N.observe(nodeNumber, "output/evolve2.py.series")


for i in range (0, 100):                  #observe the state of the node at times 0.3 * n
	N.evolve ( 0.03 * i, 0.03 *( i+1))