-
Notifications
You must be signed in to change notification settings - Fork 0
Home
The MUSIC Spinnaker adapters are interfaces between the "MUSIC world" and SpiNNaker hardware. They are built on top of the SpiNNaker external devices library. The adapter spinnmusic-in
listens to "live output" of a SpiNNaker population and provides them in a MUSIC output port while the adapter spinnmusic-out
listens to spikes from a MUSIC input port and sends them to a "spike injector" through a SpynnakerLiveSpikesConnection.
A set of MUSIC-aware applications normally runs in "elastic time". A MUSIC input port blocks until the sender has provided the data which is needed to continue simulation. On the other end, there is no limit imposed by MUSIC, other than performance bottlenecks, for how fast a simulation can run or how fast data is sent. In contrast, SpiNNaker runs synchronized to wallclock time. If spikes from SpiNNaker comes faster than the spinnmusic-in-adapter is able to buffer and send them, they are simply dropped. Thus, it is important to run the software on the MUSIC side on sufficient resources or adjust the time scale in the SpiNNaker simulation. The spinnmusic-out-adapter sends spikes to SpiNNaker synchronized to wallclock time. This means that its MUSIC input port can block the MUSIC-aware application connected to it. In the case where spikes the spikes from the MUSIC port are late compared to wallclock time, they are simply dropped.
There are three main strategies to cope with the case where the MUSIC world is "slow":
- Scale SpiNNaker time or make sure that the MUSIC side runs "fast enough".
- Use buffering on the MUSIC ports to create some elasticity/slack.
- Synchronize with SpiNNaker on regular intervals. This is available as a command line option in the spinnmusic-out adapter.
This package has the following dependencies:
-
The SpiNNaker external devices library
The build system used is GNU autotools (aclocal, autoconf, automake, libtool).
To build and install, do:
./autogen.sh # generate autotools files
./configure
make
make install
This will install the adapters spinnmusic-in
and spinnmusic-out
.
For examples of communication between SpiNNaker hardware and a host, see the subdirectory 'examples'.
In the subdirectory examples/send
there is a MUSIC configuration file send.music
. It connects the MUSIC utility eventsource
to spinnmusic-out
. eventsource
sends the spikes in the file spikes0.dat through its MUSIC output port. They are received by spinnmusic-out
which forwards them to the SpiNNaker population created by the script spike_io.py (a synfire chain).
To run the example, first launch the SpiNNaker simulation in one terminal window:
python spike_io.py
Then launch MUSIC in another terminal window:
mpirun -np 2 music send.music
The resulting activity of the synfire chain is plotted in a window.
In the subdirectory examples/receive
there is a MUSIC configuration file receive.music
. It connects spinnmusic-in
to the MUSIC utility eventlogger
. The script spike-io.py
implements a synfirechain in SpiNNaker. spinnmusic-in
listens to spikes from this population and forwards them to eventlogger
which prints the spikes on the terminal.
To run the example, first launch the SpiNNaker simulation in one terminal window:
python spike_io.py
Then launch MUSIC in another terminal window:
mpirun -np 2 music receive.music
The resulting activity of the synfire chain is plotted in a window and printed by eventlogger
in the second terminal window.