Unlocking spiking neural networks for machine learning research
Lead Research Organisation:
University of Sussex
Department Name: Sch of Engineering and Informatics
Abstract
In the last decade there has been an explosion in artificial intelligence research in which artificial neural networks, emulating biological brains, are used to solve problems ranging from obstacle avoidance in self-driving cars to playing complex strategy games. This has been driven by mathematical advances and powerful new computer hardware which has allowed large 'deep networks' to be trained on huge amounts of data. For example, after training a deep network on 'ImageNet' - which consists of over 14 million manually annotated images - it can accurately identify the content of images. However, while these deep networks have been shown to learn similar patterns of connections to those found in the parts of our brains responsible for early visual processing, they differ from real brains in several important ways, especially in how the individual neurons communicate. Neurons in real brains exchange information using relatively infrequent electrical pulses known as 'spikes', whereas, in typical artificial neural network models, the spikes are abstracted away and values representing the 'rates' at which spikes would be emitted are continuously exchanged instead. However, neuroscientists believe that large amounts of information is transmitted in the precise times at which spikes are produced. Artificial 'spiking neural networks' can harness these properties, making them useful in applications which are challenging for current models such as real-world robotics and processing data with a temporal component, such as video. However, spiking neural networks can only be used effectively if suitable computer hardware and software is available. While there is existing software for simulating spiking neural networks, it has mostly been designed for studying real brains, rather than building AI systems. In this project, I am going to build a new software package which bridges this gap. It will use abstractions and processes familiar to machine learning researchers, but with techniques developed for brain simulation, allowing exciting new SNN models to be used by AI researchers. We will also explore how spiking models can be used with a special new type of sensors which directly outputs spikes rather than a stream of images.
In the first phase of the project, I will focus on using Graphics Processing Units to accelerate spiking neuron networks. These devices were originally developed to speed up 3D games but have evolved into general purpose devices, widely used to accelerate scientific and AI applications. However, while these devices have become incredibly powerful and are well-suited to processing lots of data simultaneously, they are less suited to 'live' applications such as when video must be processed as fast as possible. In these situations, Field Programmable Gate Arrays - devices where the hardware itself can be re-programmed - can be significantly faster and are already being used behind the scenes in data centres. In this project, by incorporating support for FPGAs into our new software, we will make these devices more accessible to AI researchers and unlock new possibilities of using biologically-inspired spiking neural networks to learn in real-time.
As well as working on these new research strands, I will also dedicate time during my fellowship to advocate for research software engineering as a valuable component of academic institutions, both via knowledge exchange and research funding. In the shorter term, I will work to develop a community of researchers involved in writing software at Sussex by organising an informal monthly 'surgery' as well as delivering specialised training on programming Graphics Processing Units and more fundamental computational and programming training for new PhD students. Finally, I will develop internship and career development opportunities for undergraduate students, to gain experience in research software engineering.
In the first phase of the project, I will focus on using Graphics Processing Units to accelerate spiking neuron networks. These devices were originally developed to speed up 3D games but have evolved into general purpose devices, widely used to accelerate scientific and AI applications. However, while these devices have become incredibly powerful and are well-suited to processing lots of data simultaneously, they are less suited to 'live' applications such as when video must be processed as fast as possible. In these situations, Field Programmable Gate Arrays - devices where the hardware itself can be re-programmed - can be significantly faster and are already being used behind the scenes in data centres. In this project, by incorporating support for FPGAs into our new software, we will make these devices more accessible to AI researchers and unlock new possibilities of using biologically-inspired spiking neural networks to learn in real-time.
As well as working on these new research strands, I will also dedicate time during my fellowship to advocate for research software engineering as a valuable component of academic institutions, both via knowledge exchange and research funding. In the shorter term, I will work to develop a community of researchers involved in writing software at Sussex by organising an informal monthly 'surgery' as well as delivering specialised training on programming Graphics Processing Units and more fundamental computational and programming training for new PhD students. Finally, I will develop internship and career development opportunities for undergraduate students, to gain experience in research software engineering.
Organisations
- University of Sussex (Lead Research Organisation)
- Forschungszentrum Jülich (Collaboration)
- Flinders Medical Centre (Collaboration)
- Graz University of Technology (Collaboration)
- iniVation (Project Partner)
- University of Zurich (Project Partner)
- Cyanapse (Project Partner)
- Opteran Technologies Ltd (Project Partner)
Publications
Aimone JB
(2023)
Editorial: Neuroscience, computing, performance, and benchmarks: Why it matters to neuroscience how fast we can compute.
in Frontiers in neuroinformatics
Fernandez-Hart T
(2024)
Posit and floating-point based Izhikevich neuron: A Comparison of arithmetic
in Neurocomputing
Jesusanmi OO
(2024)
Investigating visual navigation using spiking neural network models of the insect mushroom bodies.
in Frontiers in physiology
Knight J
(2022)
Efficient GPU training of LSNNs using eProp
Knight J
(2023)
Easy and efficient spike-based Machine Learning with mlGeNN
Ogawa Y
(2023)
Neural responses to reconstructed target pursuits
Ogawa Y
(2023)
Descending neurons of the hoverfly respond to pursuits of artificial targets.
in Current biology : CB
Description | Efficient spike-based machine learning on existing HPC hardware |
Amount | £17,215 (GBP) |
Funding ID | CPQ-2417168 |
Organisation | Oracle Corporation |
Sector | Private |
Country | United States |
Start | 03/2022 |
End | 04/2023 |
Title | Hoverfly (Eristalis tenax) descending neurons respond to pursuits of artificial targets |
Description | Many animals use motion vision information to control dynamic behaviors. Predatory animals, for example, show an exquisite ability to detect rapidly moving prey followed by pursuit and capture. Such target detection is not only used by predators but can also play an important role in conspecific interactions. Male hoverflies (Eristalis tenax), for example, vigorously defend their territories against conspecific intruders. Visual target detection is believed to be subserved by specialized target-tuned neurons that are found in a range of species, including vertebrates and arthropods. However, how these target-tuned neurons respond to actual pursuit trajectories is currently not well understood. To redress this, we recorded extracellularly from target selective descending neurons (TSDNs) in male Eristalis tenax hoverflies. We show that the neurons have dorso-frontal receptive fields, with a preferred direction up and away from the visual midline, with a clear division into a TSDNLeft and a TSDNRight cluster. We next reconstructed visual flow-fields as experienced during pursuits of artificial targets (black beads). We recorded TSDN responses to six reconstructed pursuits and found that each neuron responded consistently at remarkably specific time points, but that these time points differed between neurons. We found that the observed spike probability was correlated with the spike probability predicted from each neuron's receptive field and size tuning. Interestingly, however, the overall response rate was low, with individual neurons responding to only a small part of each reconstructed pursuit. In contrast, the TSDNLeft and TSDNRight populations responded to substantially larger proportions of the pursuits, but with lower probability. This large variation between neurons could be useful if different neurons control different parts of the behavioral output. |
Type Of Material | Database/Collection of data |
Year Produced | 2023 |
Provided To Others? | Yes |
Impact | Current biology paper |
URL | https://datadryad.org/stash/dataset/doi:10.5061/dryad.tdz08kq4d |
Title | Stanmer Park outdoor navigational data |
Description | This dataset contains omnidirectional 1440?1440 resolution images taken using a Kodak Pixpro SP360 camera paired with RTK GPS information obtained using a simple RTK2B - 4G NTRIP kit and fused yaw, pitch and roll data recorded from a BNO055 IMU. The data was collected using a 4 wheel ground robot that was manually controlled by a human operator. The robot was driven 15 times along a route at Stanmer Park (shown in map.png). The route consists mostly of open fields and a narrow path through a forest and is approximately 700m long. The recordings took place at various days and times starting in March 2021, with the date and time indicated by the filename. For example '20210420_135721.zip' corresponds to a route driven on 20/03/2021 starting at 13:57:21 GMT. During the recordings the weather varied from clear skies and sunny days to overcast and low light conditions. Each recording consists of an mp4 video of the camera footage for the route, and a database_entries.csv file with the following columns:Timestamp of video frame (in ms)X, Y and Z coordinate (in mm) and zone representing location in UTM coordinates from GPSHeading, pitch and roll (in degrees) from IMU. In some early routes, the IMU failed and when this occurs these values are recorded as "NaN".Speed and Steering angle commands being sent to robot at that timeGPS quality (1=GPS, 2=DGNSS, 4=RTK Fixed and 5=RTK Float)X, Y and Z coordinates (in mm) fitted to a degree one polynomial to smooth out GPS noiseHeading (in degrees) derived from smoothed GPS coordinatesIMU heading (in degrees) with discontinuities resulting from IMU issues fixedFor completeness, each folder also contains a database_entries_original.csv containing the data before pre-processing. The pre-processing is documented in more detail in pre_processing_notes.pdf. |
Type Of Material | Database/Collection of data |
Year Produced | 2024 |
Provided To Others? | Yes |
Impact | Conference paper in preparation |
URL | https://sussex.figshare.com/articles/dataset/Stanmer_Park_outdoor_navigational_data/25118383 |
Title | UoS campus and Stanmer park outdoor navigational data |
Description | This dataset contains omnidirectional 1440?1440 resolution images taken using a Kodak Pixpro SP360 camera paired with RTK GPS information obtained using a simple RTK2B - 4G NTRIP kit and fused yaw, pitch and roll data recorded from a BNO055 IMU. The data was collected using a 4 wheel ground robot (SuperDroid IG42-SB4-T) that was manually controlled by a human operator. The robot was driven 10 times along a route on the University of Sussex campus (shown in campus.png) and 10 times at the adjacent Stanmer Park (shown in stanmer.png). The first route is a mix of urban structures (university buildings), small patches of trees and paths populated by people and is approximately 700m long. The second route consists mostly of open fields and a narrow path through a forest and is approximately 600m long. The recordings took place at various days and times starting in May 2023, with the date and time indicated by the filename. For example 'campus_route5_2023_11_22_102925.zip' corresponds to the 5th route recorded on the Sussex campus on 22/11/2023 starting at 10:29:25 GMT. During the recordings the weather varied from clear skies and sunny days to overcast and low light conditions. Each recording consists of the .jpg files that make up the route, and a .csv file with the following columns:X, Y and Z coordinate (in mm) and zone representing location in UTM coordinates from GPSHeading, pitch and roll (in degrees) from IMU. In some early routes, the IMU failed and when this occurs these values are recorded as "NaN".Filename of corresponding camera imageLatitude (in decimal degrees west) and Longitude (in decimal degrees north) and Altitude (in m) from GPSGPS quality (1=GPS, 2=DGNSS, 4=RTK Fixed and 5=RTK Float) horizontal dilation (in mm)Timestamp (in ms) |
Type Of Material | Database/Collection of data |
Year Produced | 2023 |
Provided To Others? | Yes |
Impact | Conference paper in preparation |
URL | https://sussex.figshare.com/articles/dataset/UoS_campus_and_Stanmer_park_outdoor_navigational_data/2... |
Description | Collaboration with Professor Karin Nordstrom at Flinders Medical Centre |
Organisation | Flinders Medical Centre |
Country | Australia |
Sector | Hospitals |
PI Contribution | Helped refine analysis methods for experimental data and are working on providing computational models to validate hypotheses about neuroanatomy of hover flies. |
Collaborator Contribution | Providing experimental data and expertise to help develop computational models |
Impact | None as yet |
Start Year | 2022 |
Description | Structure to Function compute time agreement |
Organisation | Graz University of Technology |
Country | Austria |
Sector | Academic/University |
PI Contribution | We have provided our GeNN software |
Collaborator Contribution | * Julich Research Centre has provided compute time on their JUWELS and JUWELS booster supercomputing systems as well as expertise in analysis large spiking neural network models * TU Graz has provided expertise in implementing bio-inspired learning rule and working with large models of mouse cortex developed by Allen Institute |
Impact | "Efficient GPU training of LSNNs using eProp" publication Accepted conference paper in NICE 2023 workshop ArXiv preprint 2212.01232 |
Start Year | 2022 |
Description | Structure to Function compute time agreement |
Organisation | Julich Research Centre |
Country | Germany |
Sector | Academic/University |
PI Contribution | We have provided our GeNN software |
Collaborator Contribution | * Julich Research Centre has provided compute time on their JUWELS and JUWELS booster supercomputing systems as well as expertise in analysis large spiking neural network models * TU Graz has provided expertise in implementing bio-inspired learning rule and working with large models of mouse cortex developed by Allen Institute |
Impact | "Efficient GPU training of LSNNs using eProp" publication Accepted conference paper in NICE 2023 workshop ArXiv preprint 2212.01232 |
Start Year | 2022 |
Title | genn-team/genn: GeNN 4.8.0 |
Description | Release Notes for GeNN 4.8.0 This release adds a number of significant new features to GeNN as well as including a number of bug fixes that have been identified since the 4.7.1 release. User Side Changes Custom updates extended to work on
SynapseMatrixWeight::KERNEL weight update model variables (#524). Custom updates extended to perform reduction operations across neurons as well as batches (#539). PyGeNN can now automatically find Visual Studio build tools using functionality in
setuptools.msvc.msvc14_get_vc_env (#471) GeNN now comes with a fully-functional Docker image and releases will be distributed via
Dockerhub as well as existing channels. Special thanks to @Stevinson , @jamesturner246 and @bdevans for their help on this (see the
README for more information) (#548 and #550). Bug fixes Fixed bug relating to merging of synapse groups which perform presynaptic "revInSyn" updates (#520). Added missing parameter to PyGeNN. pygenn.genn_model.create_custom_postsynaptic_class function so postsynaptic models with extra global parameters can be created (#522). Correctly substitute 0 for \$(batch) when using single-threaded CPU backend (#523). Fixed issues building PyGeNN with Visual Studio 2017 (#533). Fixed bug where model might not be rebuilt if sparse connectivity initialisation snippet was changed (#547). Fixed longstanding bug in the
gen_input_structured tool -- used by some userprojects -- where data was written outside of array bounds (#551). Fixed issue with debug mode of
genn-buildmodel.bat when used with single-threaded CPU backend (#551). Fixed issue where, if custom update models were the only part of a model that required an RNG for initialisation, one might not be instantiated (#540). |
Type Of Technology | Software |
Year Produced | 2022 |
Open Source License? | Yes |
Impact | As well as ongoing impact of helping user community, specific advances used in both accepted conference paper at NICE 2023 and preprint arxiv ID 2212.01232v1 |
URL | https://zenodo.org/record/7267620 |
Title | genn-team/genn: GeNN 4.9.0 |
Description | Release Notes for GeNN 4.9.0 This release adds a number of significant new features to GeNN as well as including a number of bug fixes that have been identified since the 4.8.1 release. It is intended as the last release for GeNN 4.X.X. Fixes for serious bugs may be backported if requested but, otherwise, development will be switching to GeNN 5. User Side Changes Implemented
pygenn.GeNNModel.unload to manually unload GeNN models to improve control in scenarios such as parameter sweeping where multiple PyGeNN models need to be instantiated (#581). Added Extra Global Parameter references to custom updates (see Defining Custom Updates, Defining your own custom update model and Extra Global Parameter references (#583). Expose
$(num_pre) ,
$(num_post) ,
$(num_batches) to all user code strings (#576) Bug fixes Fixed handling of indices specified as sequences types other than numpy arrays in
pygenn.SynapseGroup.set_sparse_connections (#597). Fixed bug in CUDA constant cache estimation bug which could cause nvLink errors in models with learning rules which required previous spike times (#589). Fixed longstanding issue with setuptools that meant PyGeNN sometimes had to be built twice to obtain a functional version. Massive thanks to @erolm-a for contributing this fix (#591). Optimisations Reduced the number of layers and generally optimised Docker image. Massive thanks to @bdevans for his work on this (#601). |
Type Of Technology | Software |
Year Produced | 2023 |
Open Source License? | Yes |
Impact | As well as ongoing impact of helping user community, specific advances enable ongoing research |
URL | https://zenodo.org/record/8430715 |
Title | genn-team/genn: GeNN v4.7.0 |
Description | Release Notes for GeNN v4.7.0 This release adds a number of significant new features to GeNN as well as including a number of bug fixes that have been identified since the 4.6.0 release. User Side Changes While a wide range of convolutional type connectivity can be implemented using
SynapseMatrixConnectivity::PROCEDURAL , the performance is often worse than sparse connectivity.
SynapseMatrixConnectivity::TOEPLITZ provides a more efficient solution with
InitToeplitzConnectivitySnippet::Conv2D and
InitToeplitzConnectivitySnippet::AvgPoolConv2D implementing some typical connectivity patterns (#484). Shared weight kernels had to be previously provided as extra global parameters via the
InitVarSnippet::Kernel variable initialisation snippet. This meant kernels had to be manually allocated to the correct size and couldn't be initialised using standard functionality.
SynapseMatrixWeight::KERNEL allows kernels to be treated as standard state variables (#478). Some presynaptic updates need to update the state of presynaptic neurons as well as postsynaptic. These updates can now be made using the \$(addToPre,...) function from presynaptic update code and the destination additional input variable can be specified using
SynapseGroup::setPreTargetVar (#479). On Windows, all models in the same directory would build their generated code into DLLs with the same name, prevented the the caching system introduced in v4.5.0 working properly.
CodeGenerator::PreferencesBase::includeModelNameInDLL includes the name of the model in the DLL filename, resolving this problem. This is now the default behaviour in PyGeNN but, when using GeNN from C++, the flag must be manually set and MSBuild projects updated to link to the correct DLL (#476). Neuron code can now sample the binomial distribution using \$(gennrand_binomial) and this can be used to initialise variables with
InitVarSnippet::Binomial (#498). In the latest version of Windows Subsystem for Linux, CUDA is supported but libcuda is mounted in a non-standard location. GeNN's CUDA backend now adds this location to the linker paths (#500). Bug fixes: Fixed issues with some configurations of
InitSparseConnectivitySnippet::Conv2D when stride > 1 which caused incorrect connectivity to be instantiated as well as crashes when this snippet was used to generate sparse connectivity (#489, #491). Fixed issue where, if \$(addToInSynDelay) was used in spike-like event code, it was not detected and dendritic delay structures were not correctly created (#494). Fixed issue where precision wasn't being correctly applied to neuron additional input variable and sparse connectivity row build state variable initialisation meaning double precision code could unintentially be generated (#489). |
Type Of Technology | Software |
Year Produced | 2022 |
Open Source License? | Yes |
Impact | As well as ongoing impact of helping user community, specific advances were key to results in 10.1088/2634-4386/ac5ac5 and initial work towards preprint arxiv ID 2212.01232v1 |
URL | https://zenodo.org/record/6047460 |
Title | genn-team/ml_genn: mlGeNN 2.0 |
Description | As well as continuing to support the conversion of ANNs trained using TensorFlow to SNNs, this release adds a large amount of new functionality which enables SNNs to be defined from scratch in mlGeNN and trained directly using e-prop. User Side Changes New model description API for model description inspired by Keras (see documentation) Extensible Callback system allowing custom logic including for recording state to be triggered mid-simulation (see documentation) Extensible metrics system, allowing various metrics to be calculated efficiently (see documentation) Training using e-prop learning rule Conversion of ANNs trained in TensorFlow is now handled through the ml_genn_tf module (see documentation) Known issues The SpikeNorm algorithm for converting deep ANNs to rate-coded SNNs is currently broken - if you require this functionality please stick with mlGeNN 1.0 |
Type Of Technology | Software |
Year Produced | 2023 |
Impact | Enabled work on accepted conference paper at NICE 2023 |
URL | https://zenodo.org/record/7705308 |
Title | genn-team/ml_genn: mlGeNN 2.1 |
Description | This release adds a number of significant new features to mlGeNN including support for training models using EventProp, as well as including a number of bug fixes that have been identified since the 2.0 release. User Side Changes EventProp compiler for training models with EventProp (#57, #64, #70) System so compilers can define default settings for neuron models e.g. reset behaviour (#63) Support for time varying inputs as well as a wider range of input neuron types (#69) Spike-like event recording (#54) Spike count recording (#73) Bug fixes Fixed issues with manual training loops e.g. for augmentation (#74, #78) Fixed issue with management of callback state (#65) Fixed issue with loading and unloading compiled networks (#66) |
Type Of Technology | Software |
Year Produced | 2023 |
Impact | As well as ongoing impact of helping user community, training using EventProp and support for time-varying inputs have been vital for, as yet unpublished work on our Intel Neuromorphic Research Community grant |
URL | https://zenodo.org/record/8430906 |
Description | Co-organised tutorial on our GeNN software at CNS*2022 in Melbourne |
Form Of Engagement Activity | Participation in an activity, workshop or similar |
Part Of Official Scheme? | No |
Geographic Reach | International |
Primary Audience | Professional Practitioners |
Results and Impact | I co-organised a half day tutorial on using our GeNN software at CNS*2022 in Melbourne. Approximately 30 people attended and the content sparked questions and discussion on the day as well as increased interest in GeNN via email and github discussions afterwards |
Year(s) Of Engagement Activity | 2022 |
URL | https://www.cnsorg.org/cns-2022-tutorials#T6 |
Description | Co-organised workshop on Bio-inspired active AI at CNS*2022 in Melbourne |
Form Of Engagement Activity | Participation in an activity, workshop or similar |
Part Of Official Scheme? | No |
Geographic Reach | International |
Primary Audience | Professional Practitioners |
Results and Impact | We co-organised a one day workshop on Bio-inspired active AI at CNS*2022 in Melbourne with 10 invited speakers. This event strengthened existing collaborations and provided an excellent opportunity for networking. |
Year(s) Of Engagement Activity | 2022 |
URL | http://users.sussex.ac.uk/~tn41/CNS2022_workshop/ |
Description | Interview with Code for Thought podcast |
Form Of Engagement Activity | A broadcast e.g. TV/radio/film/podcast (other than news/press) |
Part Of Official Scheme? | No |
Geographic Reach | International |
Primary Audience | Professional Practitioners |
Results and Impact | Interview with 7 of the other new EPSRC fellows in the UK where we discussed our hopes, ideas and aspirations for our fellowships. |
Year(s) Of Engagement Activity | 2022 |
URL | https://codeforthought.buzzsprout.com/1326658/9859960-join-the-fellowship |
Description | Invited to panel on RSE fellowship scheme at SeptembRSE 2021 |
Form Of Engagement Activity | A formal working group, expert panel or dialogue |
Part Of Official Scheme? | No |
Geographic Reach | National |
Primary Audience | Professional Practitioners |
Results and Impact | I was invited to join other members of my RSE fellowship cohort on a panel at SeptembRSE 2021 discussing our fellowship plans. |
Year(s) Of Engagement Activity | 2021 |
URL | https://septembrse.github.io/#/event/L1005 |