An open-source Brian 2 interface for the neuromorphic computing framework Lava
Project description
Brian2Lava
Brian is an open-source Python package developed and used by the computational neuroscience community to simulate spiking neural networks. The goal of the Brian2Lava open-source project is to develop a Brian device interface for the neuromorphic computing framework Lava, in order to facilitate deployment of brain-inspired algorithms on Lava-supported hardware and emulator backends.
For more information, please see our website and the documentation.
For a rundown of the new features and bugfixes addressed in the latest version, see the Release Notes.
Getting started
Below you'll find information on how to quickly get Brian2Lava to run. For further information, please visit the documentation.
Note: Brian2Lava is still in its testing phase. Please feel free to report issues or feature requests.
Note: At the moment, due to legal restrictions, models for the
Loihi2backend may just be provided to members of the Intel Neuromorphic Research Community. Thus, the public version of Brian2Lava currently contains models for theCPUbackend only.
Installation
Brian2Lava can be easily installed via the Python Package Index (pip):
python3 -m pip install brian2lava
Note: conda support may be added at a later point.
For the latest source code, please visit gitlab.com/brian2lava/brian2lava. If you run from source code, make sure that you have added your path to the source code to PYTHONPATH, for example, via:
export PYTHONPATH=~/brian2lava
Prerequisites
Make sure that you have installed Brian 2 (recommended >= 2.7.1) and Lava (recommended >= 0.10.0, or lava_loihi-0.7.0).
Import package and set device
Using Brian2Lava within Brian 2 only requires two steps.
First, import the package:
import brian2lava
Second, set the lava device with the desired hardware backend and mode:
set_device('lava', hardware='CPU', mode = 'preset')
In principle, this can already run your Brian simulation on the Lava engine. However, you may have to use a few additional settings to specify how the code for the simulation is generated and executed. Please see the documentation for more information.
You may want to continue by considering the example code provided here.
Dependencies
Brian2Lava currently includes the library of preset models as an external dependency. To make sure that you have the latest version of the library in your installation, navigate to the Brian2Lava package folder and run
source update_submodules.sh
or manually execute
git init
git submodule foreach 'git pull origin main'
This will pull the latest version of the public library of preset models from a GitHub repository into your local Brian2Lava installation.
Further dependencies can be found in setup.py.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file brian2lava-1.0.0b2.tar.gz.
File metadata
- Download URL: brian2lava-1.0.0b2.tar.gz
- Upload date:
- Size: 157.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.8.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cc6da2e2da5268e18236fa5aaea2d61fd5cb10fa9b0b3815a722b52232966770
|
|
| MD5 |
2c0f4db9bce02e3c8d0f2dfd3a9964f7
|
|
| BLAKE2b-256 |
a2d4bd8e278ab7734c53a716b4a003ca581c5b41ca5c65db7dd233ac4aa750cf
|
File details
Details for the file brian2lava-1.0.0b2-py3-none-any.whl.
File metadata
- Download URL: brian2lava-1.0.0b2-py3-none-any.whl
- Upload date:
- Size: 336.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.8.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c1eae7b157b3ca6b29dd338779f890577633bce327fdb799ec43f3ba31649852
|
|
| MD5 |
9e75025bbaf7ae477e3eca3549df2103
|
|
| BLAKE2b-256 |
cc5efcad7f7797f4c956a1cdb062f0f5939a539840c16fc5ffb576151424b09d
|