arbor-sim / arbor

The Arbor multi-compartment neural network simulation library.
https://arbor-sim.org
BSD 3-Clause "New" or "Revised" License
105 stars 59 forks source link

Somatic Surface (2D) Reaction-Diffusion (RxD) Simulations, Preferably Running on GPU #2258

Closed utkuoguzman closed 2 months ago

utkuoguzman commented 4 months ago

Describe the feature you need I want Arbor to support the Reaction-Diffusion (RxD) simulations. It is especially important to me if Arbor supports surface-level (meaning 2D) Reaction-Diffusion simulations over the mesh of soma (acquired from, say, Brain Scaffold Builder), preferably running on GPU.

Explain what it is supposed to enable It can enable researchers to investigate the biological neuronal processes as a whole. This enourmous task includes not only considering the dendritic voltage and current levels as Arbor supports right now, but also the somatic membrane protein reactions. A neuron that can control the membrane proteins' numbers and positions can effectively add linear (diffusion) and nonlinear (reaction) computation elements after the work of dendrites. This, at least in theory, can provide every neuron a ANN-like learning capability, all neatly residing on the somatic membrane!

Additional context I'm doing a PhD in neuronal processes & representations, about which physical phenomenas of neurons can contain cell-level interpretable value-action representations, and how those cell-level representations can be combined to acquire a circuit-level representations. My take is that while dendrites do very important memory tasks, input-clustering tasks, nonlinear pattern recognition tasks and timing tasks; they don't really grant the cell the ability to decide when to exactly fire, they just sort/process the input in a very robust and useful way so that soma can handle it. However the FEM formulation to solve RxD PDEs over (somatic) meshes has all the ingredients to encode a full-fledged sparse ANN (Artificial Neural Network) just for every individual neuron. According to my hypothesis, if you think about how the RxD computation propagates over a mesh, the diffusion part of the RxD PDE takes care of the matmul part of the ANNs, the reaction part takes care of the nonlinear activation part of the ANNs, and since a diffusion PDE has local effect it mimics a regular but sparse (relatively small, about 1K parameters) ANN connectivity. So putting proteins strategically, in theory, should work like a ANN!

To conclude, to prove that RxD PDE over meshes can encode a whole ANN on the soma membrane, I need both the speed of Arbor calculating dendritic currents in GPUs, and (me) formulate the necessary plasticity rules, but most importantly I need Arbor to support 2D RxD simulations (preferably on GPUs).

Note: I know how to use Nvidia's warp.fem library module, a Python FEM library that JIT-compiles C++ CUDA code for GPU/CPU. Hence maybe I can be of service.

thorstenhater commented 4 months ago

Hi @utkuoguzman,

thanks for the input. RxD is an interesting feature that I'd love to see implemented. However, I see some problems here:

First, it is at the very boundary of scope for Arbor and quite possibly outside. I think the way forward here would be to use up two interlinked simulators; one handling the RxD part and Arbor.

Second, I'd imagine that the effort to implement such a feature is quite large, judging from Neuron's RxD feature. Currently, we do not have this or similar projects on our roadmap, which would mean pivoting to a new topic.

Having said that, I absolutely see the space and interest for a collaboration to implement a companion library that implements RxD and couples to Arbor. We have a similar interface --- possibly sufficient already --- for inserting externally defined ion channels, that is versioned and quite stable.

If you are interested, you can also ping me on Gitter.

Best, T