Skip to content

brian-team/brian2modelfitting

Repository files navigation

brian2modelfitting

Model fitting toolbox for Brian 2 simulator.

DOI

The package brian2modelfitting allows the user to find the best fit of the unknown free parameters for recorded traces and spike trains. It also supports simulation-based inference, where instead of point-estimated parameter values, a full posterior distribution over the parameters is computed.

By default, the toolbox supports a range of global derivative-free optimization methods, that include popular methods for model fitting: differential evolution, particle swarm optimization and covariance matrix adaptation (provided by the Nevergrad, a gradient-free optimization platform) as well as Bayesian optimization for black box functions (provided by scikit-optimize, a sequential model-based optimization library). On the other hand, simulation-based inference is the process of finding parameters of a simulator from observations by taking a Bayesian approach via sequential neural posterior estimation, likelihood estimation or ration estimation (provided by the sbi), where neural densitiy estimator, a deep neural network allowing probabilistic association between the data and underlying parameter space, is trained. After the network is trained, the approximated posterior distribution is available.

Documentation

Documentation Status

The full documentation is available at http://brian2modelfitting.readthedocs.org.

Testing status

Build Status Coverage Status

Installation

Install brian2modelfitting from the Python package index via pip:

pip install brian2modelfitting

The basic install only supports the optimization methods provided by the Nevergrad library. To install additional algorithms, support for simulation-based inference, and other features, you can install the optional dependencies:

extra description install command
sbi simulation-based inference with sbi pip install 'brian2modelfitting[sbi]'
skopt optimization with sckikit-optimize pip install 'brian2modelfitting[skopt]'
algos additional algorithms for Nevergrad pip install 'brian2modelfitting[algos]'
efel FeatureMetric with eFEL electrophysiology features pip install 'brian2modelfitting[efel]'
test framework to run the test suite pip install 'brian2modelfitting[test]'
docs framework to build the documentation pip install 'brian2modelfitting[docs]'
all all of the above dependencies pip install 'brian2modelfitting[all]'


License
-------
The model fitting toolbox is released under the terms of the CeCILL 2.1 license and is available [here](https://github.com/brian-team/brian2modelfitting/blob/master/LICENSE).

Use
---
Please report issues at the GitHub [issue tracker](https://github.com/brian-team/brian2modelfitting/issues) or at the [Brian 2 discussion forum](https://brian.discourse.group).