Connection generator interface

Availability

This connection rule is only available if NEST was compiled with support for libneurosim.

To allow the generation of connectivity by means of an external library, NEST supports the connection generator interface [2]. For more details on this interface, see the git repository of libneurosim.

In contrast to the other rules for creating connections, this rule relies on a Connection Generator object to describe the connectivity pattern in a library-specific way. The connection generator is handed to Connect() under the key cg of the connection specification dictionary and evaluated internally. If the connection generator provides values for connection weights and delays, their respective indices can be specified under the key params_map. Alternatively, all synapse parameters can be specified using the synapse specification argument to Connect().

The following listing shows an example for using CSA (Connection Set Algebra [1]) in NEST via the connection generator interface and randomly connects 10% of the neurons from A to the neurons in B, each connection having a weight of 10000.0 pA and a delay of 1.0 ms:

import csa

A = nest.Create('iaf_psc_alpha', 100)
B = nest.Create('iaf_psc_alpha', 100)

# Create the Connection Generator object
cg = csa.cset(csa.random(0.1), 10000.0, 1.0)

# Map weight and delay indices to values from cg
params_map = {'weight': 0, 'delay': 1}

conn_spec = {'rule': 'conngen', 'cg': cg, 'params_map': params_map}
nest.Connect(A, B, conn_spec)

References