Preliminary documentation of the NEST connection generator interface
====================================================================

The ConnectionGenerator API is a standard interface supporting
efficient generation of network connectivity during model setup in
neuronal network simulators. It is intended as an abstraction
isolating both sides of the API: any simulator can use a given
connection generator and a given simulator can use any library
providing the ConnectionGenerator interface.

The API is part of the neurosim library hosted at INCF:

  http://software.incf.org/software/libneurosim

At the time of the current NEST release the above library was not yet
released and the API is shipped with this distribution as

  libnestutil/connection_generator.h
  libnestutil/connection_generator.cpp

The interface was presented as a poster at the 4th INCF Congress of
Neuroinformatics:

Jochen Eppler, Håkon Enger, Thomas Heiberg, Birgit Kriener, Hans
Plesser, Markus Diesmann and Mikael Djurfeldt (2011) "Evaluating the
Connection-Set Algebra for the neural simulator NEST", Conference
Abstract: 4th INCF Congress of Neuroinformatics, Front. Neuroinform.,
doi:10.3389/conf.fninf.2011.08.00085

As a demonstration of the interface, the current release supports
connection-set algebra connection generators:

  http://software.incf.org/software/csa

* Getting started

# import required libraries
import csa
import nest

# random connectivity with connect probability 0.1
cs = csa.random (0.1)

# create two neuron populations
pop1 = nest.LayoutNetwork("iaf_psc_alpha", [16])
pop2 = nest.LayoutNetwork("iaf_psc_alpha", [16])

# connect them using the connection generator cs
nest.CGConnect (pop0, pop1, cs)

See also the following example in the NEST distribution:

pynest/examples/csa_example.py

* High-level Python API

CGConnect (SOURCES, TARGETS, CG, [PARAMETER_MAP, [MODEL]])

Connect neurons from SOURCES to neurons from TARGETS using
connectivity specified by the connection generator CG. SOURCES and
TARGETS are either both lists containing 1 subnet, or lists of
gids. PARAMETER_MAP is a dictionary mapping names of values such as
weight and delay to value set positions. MODEL is the synapse model.
