usage of PyNN to implement a SNN model for classification problems

139 views
Skip to first unread message

alexand...@gmail.com

unread,
Jul 28, 2020, 2:37:25 AM7/28/20
to SpiNNaker Users Group
Hello,

I would like to ask if there is any resource/documentation on how someone can use PyNN package to implement an SNN model that solves a classification problem and how it can be run on SpiNNaker. Thank you in advance.


Alexandros Andreou

Petrut Bogdan

unread,
Jul 28, 2020, 4:39:55 AM7/28/20
to SpiNNaker Users Group
Hey Alexandros,

As far as I am aware, there is no unified approach to doing this. I will try to direct you to several disparate places to hopefully show you what is possible for you to choose how you would like to do it.

Your experiment will have to have 3 components: a definition of the input, the network that receives this input, and the output.

Regarding the input: I recommend starting off with few examples to begin with to speed up your prototyping. You have a choice of using a SpikeSourceArray or SpikeSourcePoisson (http://neuralensemble.org/docs/PyNN/reference/neuronmodels.html?highlight=spikesource#spike-sources), but also a SpikeSourcePoissonVariable (this is sPyNNaker specific, a more technical term for this type of poisson spike source is an inhomogeneous Poisson distribution -- the firing rate changes over time). Spike rates are usually the encoding of choice for inputs (I'm not necessarily saying this is the correct thing to do).

Regarding the network: If you are not familiar with PyNN yet, I would suggest going through a few examples first: https://github.com/spinnakermanchester/pynn8examples
This whole section is up to you really. Many approaches exist. I don't know if it would be helpful, but I have done some classification of MNIST digits using structural plasticity in PyNN: https://data.mendeley.com/datasets/84pvnm3rj3/1 and some classification of moving bars https://data.mendeley.com/datasets/wpzxh93vhx/1

Regarding the output: I would suggest recording the spikes of your output layer (whatever that means in your network) and decoding the prediction offline. You will probably develop your own scripts for this. These packages could turn out useful: https://elephant.readthedocs.io/en/latest/ and https://scikit-learn.org/stable/

Running things on SpiNNaker: http://spinnakermanchester.github.io/latest/jupyter.html or http://spinnakermanchester.github.io/latest/hbp_portal.html unless of course you have access to  physical board. Full details at http://spinnakermanchester.github.io/

Cheers,
Peter
Reply all
Reply to author
Forward
0 new messages