# Multi-compartmental modeling in Brian 2

Marcel Stimberg, Dan F M Goodman, Romain Brette

► To cite this version:

Marcel Stimberg, Dan F M Goodman, Romain Brette. Multi-compartmental modeling in Brian 2. BMC Neuroscience, 2015, 16 (Suppl 1), pp.P19. 10.1186/1471-2202-16-S1-P19. hal-01250230

HAL Id: hal-01250230

https://hal.sorbonne-universite.fr/hal-01250230

Submitted on 4 Jan 2016

HAL is a multi-disciplinary open access
archive for the deposit and dissemination of sci-
entific research documents, whether they are pub-
lished or not. The documents may come from
teaching and research institutions in France or
abroad, or from public or private research centers.

L'archive ouverte pluridisciplinaire HAL, est
destinée au dépôt et à la diffusion de documents
scientifiques de niveau recherche, publiés ou non,
émanant des établissements d'enseignement et de
recherche français ou étrangers, des laboratoires
publics ou privés.

<figure><img src="image_1.png" /></figure>

Distributed under a Creative Commons Attribution 4.0 International License
# Multi-compartmental modeling in Brian 2

Marcel Stimberg<fnref n="1" />,²,³*, Dan F M Goodman⁴, Romain Brette<fnref n="1" />,²,³

From 24th Annual Computational Neuroscience Meeting: CNS*2015
Prague, Czech Republic. 18-23 July 2015

Brian 2 is a fundamental rewrite of the popular Brian [1,2] simulator for spiking neural networks. It is written in the Python programming language and focuses on simplicity and extensibility: neuronal and synaptic models can be described using mathematical formulae and with the use of physical units [3].

Brian has been traditionally used to simulate networks of single-compartment neurons; complex morphologies, modeled as multi-compartment neurons, were not supported. We have recently added support for such models: a neuron's morphology can be either created from a file (in the SWC format [4]) or be created iteratively in the simulation script itself, using a convenient syntax. The flexibility of the Brian simulator applies to multi-compartment models in the same way as to single-compartment models: the model dynamics are governed by arbitrary user-provided differential equations, models can be flexibly parameterized over all the compartments and all variables describing the internal state of the model (voltages, currents, conductances, etc) are accessible to the user.

The simulation of multi-compartment models is more complex than that of non-electrically coupled single-compartment models: in addition to the numerical integration of the differential equations governing the change of the membrane potential in a single compartment, the currents flowing across neighboring compartments have to be taken into account. To this end, Brian employs a domain-decomposition method which corrects an initial solution valid for uncoupled compartments, taking the actual coupling into account. This method has the advantage that it is easy to parallelize, since most of computations are performed independently for each compartment. We demonstrate the advantage of this by parallelizing the computation over multiple processor cores using the OpenMP framework. For the future, we are planning to

further accelerate the simulation speed by making use of the massively-parallel processing capabilities of graphical processing units.

With this addition, we have significantly enlarged the range of research questions that can be investigated using Brian.

Brian is made available under a free software license and all development takes place in public code repositories.

**Acknowledgements**

This work was partly supported by grant ANR-14-CE13-0003.

**Authors' details**

¹Sorbonne Universités, UPMC Univ. Paris 06, UMR_S 968, Institut de la Vision, Paris, F-75012, France. ²INSERM, U968, Paris, F-75012, France. ³CNRS, UMR_7210, Paris, F-75012, France. ⁴Department of Electrical and Electronic Engineering, Imperial College London, London, UK.

Published: 18 December 2015

**References**

1. Goodman DFM, Brette R: The Brian Simulator. *Frontiers in Neuroscience* 2009, 3(2):192-197.

2. The Brian spiking neural network simulator. [http://briansimulator.org], accessed 21-02-2015.

3. Stimberg M, Goodman DFM, Benichoux V, Brette R: Equation-oriented specification of neural models for simulations. *Frontiers in Neuroinformatics* 2014, 8:6.

4. Turner DA, Pyapali GK, Wheal HV: An on-line archive of reconstructed hippocampal neurons. *Journal of Neuroscience Methods* 1998, 84(1-2):49-54.

doi:10.1186/1471-2202-16-S1-P19

Cite this article as: Stimberg et al.: Multi-compartmental modeling in Brian 2. BMC Neuroscience 2015 16(Suppl 1):P19.

<footnote>* Correspondence: marcel.stimberg@inserm.fr</footnote>

<footnote n="1">¹Sorbonne Universités, UPMC Univ. Paris 06, UMR_S 968, Institut de la Vision, Paris, F-75012, France</footnote>

<footnote>Full list of author information is available at the end of the article</footnote>