A computational platform for studying spiking neural circuits developed by Dr. Pulin Gong's group at University of Sydney.
SpikeNet is a computational platform for studying spiking neural circuits. As a software, it has three stand-alone components.
The design of SpikeNet provides the following four main features.
Configurability SpikeNet supports any user-defined structure of synaptic connectivity topologies, coupling strengths and conduction delays. It can be easily extended by developers to support any variations of integrate-and-fire neuron and synapse models.
Performance Simulation of spiking neuronal network quickly becomes computationally intensive if the number of neurons in the network exceeds a few thousand. To achieve superior performance, various measures have been taken at both algorithmic and implementation level.
User-friendly interface In SpikeNet, although c++ is used for heavy-duty computation, its user-interface is written in high-level programming language (Matlab) for user-friendliness and fast prototyping. This means SpikeNet does not require non-developer users to be familiar with c++.
Scalability The design of the SpikeNet c++ simulator readily supports parallel computing using Message Passing Interface (MPI). Additionally, the HDF5-based I/O file format provides big data handling capability. Also Portable Batch System (PBS) scripts for array jobs are provided if the you have access to a cluster.
brew install Homebrew/homebrew-science/HDF5
Q: What if I am using Windows?
A: Sorry, you are on your own.
Q: What if I do not have Matlab or simply hate it?
A: You can either request I/O interface in Python from us or contribute to the project by translating the existing Matlab I/O interface into Python or other langangues.
mkdir tmp
cd tmp
git clone https://github.com/BrainDynamicsUSYD/SpikeNet
cd SpikeNet
autoconf
./configure
make
make clean
cd ..
Now you should see the simulator in the current directory, with which you can run simulations by creating input files using the Matlab user interface.
Following are the steps to use the Matlab user interface.
mkdir tmp_data
cd SpikeNet
addpath(genpath(cd))
cd ../tmp_data
main_demo
cd tmp_data
../simulator *in.h5
cd ../tmp_data
PostProcessYG()
d = dir('*RYG.mat')
R = load(d(1).name)
raster_plot(R,1)
For those who have access to a high-performance computing cluster with PBS, SpikeNet also provides bash script that fully automates the above Matlab —> c++ —> Matlab workflow for PBS job array submission.
The script all_in_one.sh has the following features:
Following are the steps to use the PBS script to run your arry jobs.
cp SpikeNet/shell_scripts/all*bak all_in_one.sh
chmod +x all_in_one.sh
MATLAB_SOURCE_PATH_2=`your_path'
MATLAB_PRE_PROCESS_FUNC=`your_functions'
mkdir PBSout
Submit the PBS array job
qsub -t 1-X -q queue_name all_in_one.sh
If your version PBS system uses -J
instead of -t
for array job, you also need to change $PBS_ARRAYID
into $PBS_ARRAY_INDEX
in the all_in_one.sh script.
Once the array job is finished, you can collect the data from the array job for post-analysis, for example (in matlab)
cd tmp_data
[mean_firing_rate, arrayID] = CollectVectorYG('Analysis','mean(Analysis.rate{1})');
plot(arrayID, mean_firing_rate);
The typical workflow of SpikeNet is as shown in the following flowchart.
Notes:
For MPI jobs with SpikeNet, please contact Yifan Gu for more technical details.
Also the full documentation is available here.
Guozhang Chen has a video to introduce SpikeNet but unfortunately, it missed the first 15 min.
To reproduce the dynamics reported in Gu et al, 2019, please submit the PBS script ./shell_scripts/YG_all_in_one.sh.
To reproduce the dynamics reported in Chen & Gong, 2019, please submit the PBS script ./shell_scripts/GC_all_in_one.sh.
See also the list of contributors who participated in this project.
If you find this code useful in your research, please cite:
@article{10.1371/journal.pcbi.1006902,
author = {Gu, Yifan AND Qi, Yang AND Gong, Pulin},
journal = {PLOS Computational Biology},
publisher = {Public Library of Science},
title = {Rich-club connectivity, diverse population coupling, and dynamical activity patterns emerging from local cortical circuits},
year = {2019},
month = {04},
volume = {15},
url = {https://doi.org/10.1371/journal.pcbi.1006902},
pages = {1-34},
number = {4},
doi = {10.1371/journal.pcbi.1006902}
}
```
@article{
author = {Chen, Guozhang AND Gong, Pulin},
journal = {Nature communications},
title = {Computing by modulating spontaneous cortical activity patterns as a mechanism of active visual processing},
year = {2019},
month = {10},
volume = {10},
url = {https://www.nature.com/articles/s41467-019-12918-8#citeas},
doi = {10.1038/s41467-019-12918-8}
}
This project is licensed under the Apache License 2.0 - see the LICENSE.md file for details.