Load and Run simple models

How to run these examples

Single Cubicle Compartmental Neuron

cubeMeshSigNeur.createSquid()[source]

Create a single compartment squid model.

cubeMeshSigNeur.main()[source]

A toy compartmental neuronal + chemical model in just a cubic volume !

Single Neuron Model

A toy compartmental neuronal + chemical model. The neuronal model geometry sets up the chemical volume to match the parent dendrite and five dendritic spines, each with a shaft and head. This volume mapping uses the NeuroMesh, SpineMesh and PsdMesh classes from MOOSE. There is a 3-compartment chemical model to go with this: one for the dendrite, one for the spine head, and one for the postsynaptic density. Note that the three mesh classes distribute the chemical model appropriately to all the respective spines, and set up the diffusion to the dendrite. The electrical model contributes the incoming calcium flux to the chemical model. This comes from the synaptic channels. The signalling here does two things to the electrical model. First, the amount of receptor in the chemical model controls the amount of glutamate receptor in the PSD. Second, there is a small kinase reaction that phosphorylates and inactivates the dendritic potassium channel.

testSigNeur.createSpine(parentCompt, parentObj, index, frac, length, dia, theta)[source]

Create spine of specified dimensions and index

testSigNeur.createSquid()[source]

Create a single compartment squid model.

testSigNeur.main()[source]

A toy compartmental neuronal + chemical model. The neuronal model geometry sets up the chemical volume to match the parent dendrite and five dendritic spines, each with a shaft and head. This volume mapping uses the NeuroMesh, SpineMesh and PsdMesh classes from MOOSE. There is a 3-compartment chemical model to go with this: one for the dendrite, one for the spine head, and one for the postsynaptic density. Note that the three mesh classes distribute the chemical model appropriately to all the respective spines, and set up the diffusion to the dendrite. The electrical model contributes the incoming calcium flux to the chemical model. This comes from the synaptic channels. The signalling here does two things to the electrical model. First, the amount of receptor in the chemical model controls the amount of glutamate receptor in the PSD. Second, there is a small kinase reaction that phosphorylates and inactivates the dendritic potassium channel.

Load neuron model from GENESIS

neuronFromDotp.main()[source]

Demonstrates how to load a simple neuronal model in GENESIS dotp format. The model has branches and a few spines.

It is adorned just with classic HH squid channels.

Gate equations have the form:

y(x) = (A + B * x) / (C + exp((x + D) / F))

where x is membrane voltage and y is the rate constant for gate closing or opening.

neuronFromDotp.makeChannelPrototypes()[source]

Create channel prototypes for readcell.

Integrate-and-fire models

Simulate current injection into various Integrate and Fire neurons.

All integrate and fire (IF) neurons are subclasses of compartment, so they have all the fields of a passive compartment. Multicompartmental neurons can be created. Even ion channels and synaptic channels can be added to them, say for sub-threshold behaviour.

The key addition is that they have a reset mechanism when the membrane potential Vm crosses a threshold. On each reset, a spikeOut message is generated, and the membrane potential is reset to Vreset. The threshold may be the spike generation threshold as for LIF and AdThreshIF, or it may be the peak of the spike as for QIF, ExIF, AdExIF, and IzhIF. The adaptive IFs have an extra adapting variable apart from membrane potential Vm.

Details of the IFs are given below. The fields of the MOOSE objects are named exactly as the parameters in the equations below.

LIF: Leaky Integrate and Fire:
Rm*Cm * dVm/dt = -(Vm-Em) + Rm*I
QIF: Quadratic LIF:
Rm*Cm * dVm/dt = a0*(Vm-Em)*(Vm-vCritical) + Rm*I
ExIF: Exponential leaky integrate and fire:
Rm*Cm * dVm/dt = -(Vm-Em) + deltaThresh * exp((Vm-thresh)/deltaThresh) + Rm*I
AdExIF: Adaptive Exponential LIF:

Rm*Cm * dVm/dt = -(Vm-Em) + deltaThresh * exp((Vm-thresh)/deltaThresh) + Rm*I - w,

tau_w * dw/dt = a0*(Vm-Em) - w,

At each spike, w -> w + b0 "

AdThreshIF: Adaptive threshold LIF:

Rm*Cm * dVm/dt = -(Vm-Em) + Rm*I,

tauThresh * d threshAdaptive / dt = a0*(Vm-Em) - threshAdaptive,

At each spike, threshAdaptive is increased by threshJump the spiking threshold adapts as thresh + threshAdaptive

IzhIF: Izhikevich:

d Vm /dt = a0 * Vm^2 + b0 * Vm + c0 - u + I/Cm,

d u / dt = a * ( b * Vm - u ),

At each spike, u -> u + d,

By default, a0 = 0.04e6/V/s, b0 = 5e3/s, c0 = 140 V/s are set to SI units, so use SI consistently, or change a0, b0, c0 also if you wish to use other units. Rm from Compartment is not used here, vReset is same as c in the usual formalism. At rest, u0 = b V0, and V0 = ( -(-b0-b) +/- sqrt((b0-b)^2 - 4*a0*c0)) / (2*a0).

IntegrateFireZoo.main()[source]

On the command-line, in moose-examples/snippets directory, run python IntegrateFireZoo.py. The script will ask you which neuron you want to simulate and you can choose and run what you want. Play with the parameters of the IF neurons in the source code.