Neural Networks for Neuroscience Research
Project description
NN4N: Neural Networks for Neuroscience
Some of the most commonly used neural networks in neuroscience research are included in this project to ease the implementation process.
Table of contents
Install
Install using pip
pip install nn4n
Install from GitHub
git clone https://github.com/zhaozewang/NN4Neurosci.git
Install using command line
cd NN4Neurosci/
python setup.py install
Install using pip
cd NN4Neurosci/
pip install .
Model
CTRNN
The implementation of standard continuous-time RNN (CTRNN). This implementation supports enforcing sparsity constraint (i.e. preventing new synapses from being created) and E/I constraints (i.e. enforcing Dale's law).
Structure
The detailed structure (e.g. whether its modular or hierarchical etc.) of any standard 3-layer RNN (as shown in figure above) can be specified using masks in our model
module implementation. Easy implementations of a few RNN structures is included in the structure
module.
Multi-Area
The HiddenLayer of a RNN is often defined using a connectivity matrix, depicting a somewhat 'random' connectivity between neurons. The connectivity matrix is often designed to imitate the connectivity of a certain brain area or a few brain areas. When modeling a single brain area, the connectivity matrix is often a fully connected matrix.
However, to model multiple brain areas, it would be more reasonable to use a connectivity matrix with multiple areas. In each areas is densely connected within itself and sparsely connected between areas. The MultiArea
class in the structure
module is designed to implement such a connectivity matrix.
Multi-Area with E/I constraints
On top of modeling brain with multi-area hidden layer, another critical constraint would be the Dale's law, as proposed in the paper Training Excitatory-Inhibitory Recurrent Neural Networks for Cognitive Tasks: A Simple and Flexible Framework by Song et al. 2016. The MultiAreaEI
class in the structure
module is designed to implement such a connectivity matrix.
This class allows for a much easier implementation of the E/I constraints particularly when there are multiple areas in the hidden layer. It provides flexible control over the excitatory-excitatory, excitatory-inhibitory, inhibitory-excitatory, and inhibitory-inhibitory connections on top of the basic MultiArea
features.
Random Input
Neurons's dynamic receiving input will be heavily driven by the inputting signal. Injecting signal to only part of the neuron will result in more versatile and hierarchical dynamics. See A Versatile Hub Model For Efficient Information Propagation And Feature Selection
- Example to be added
Criterion
RNNLoss
The loss function is modularized. The RNNLoss
class is designed in modular fashion and included the most commonly used loss functions in neuroscience research.
Others
For similar projects:
Acknowledgements
Immense thanks to Christopher J. Cueva for his mentorship in developing this project. This project can't be done without his invaluable help.
Project details
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
File details
Details for the file nn4n-1.0.2.tar.gz
.
File metadata
- Download URL: nn4n-1.0.2.tar.gz
- Upload date:
- Size: 20.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.11
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 654a1d8fcd5df0f8f5539ec0a6269848cf1a892ae8fa65daad9cfa21da6f0621 |
|
MD5 | dd1914309249411fbbce8cdcd4a433cc |
|
BLAKE2b-256 | 59b24e761a3b678d6b4b7f39e5cae58c36b17cad343a75ba21582a181d052620 |
File details
Details for the file nn4n-1.0.2-py3-none-any.whl
.
File metadata
- Download URL: nn4n-1.0.2-py3-none-any.whl
- Upload date:
- Size: 21.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.11
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 09300cb816df408b7297941bfeed5c7e797d4b5be6a20713069b1aa0009d37c0 |
|
MD5 | 2d606a904b5fab6206da5187504e87ad |
|
BLAKE2b-256 | 5b4121feb75eca1bef004eba660aa3bf9c1e5f490303f355bc9b3a75617ef8ca |