brainmodels.neurons.AdQuaIF

class brainmodels.neurons.AdQuaIF(size, V_rest=- 65.0, V_reset=- 68.0, V_th=- 30.0, V_c=- 50.0, a=1.0, b=0.1, c=0.07, tau=10.0, tau_w=10.0, method='euler', **kwargs)[source]

Adaptive quadratic integrate-and-fire neuron model.

Model Descriptions

The adaptive quadratic integrate-and-fire neuron model 1 is given by:

\begin{split}\begin{aligned} \tau_m \frac{d V}{d t}&=c(V-V_{rest})(V-V_c) - w + I(t), \\ \tau_w \frac{d w}{d t}&=a(V-V_{rest}) - w, \end{aligned}\end{split}

once the membrane potential reaches the spike threshold,

$\begin{split}V \rightarrow V_{reset}, \\ w \rightarrow w+b.\end{split}$

Model Examples

>>> import brainpy as bp
>>> import brainmodels
>>> group = brainmodels.neurons.AdQuaIF(1, monitors=['V', 'w'])
>>> group.run(300, inputs=('input', 30.))
>>> fig, gs = bp.visualize.get_figure(2, 1, 3, 8)
>>> fig.add_subplot(gs[0, 0])
>>> bp.visualize.line_plot(group.mon.ts, group.mon.V, ylabel='V')
>>> fig.add_subplot(gs[1, 0])
>>> bp.visualize.line_plot(group.mon.ts, group.mon.w, ylabel='w', show=True)

Model Parameters

 Parameter Init Value Unit Explanation V_rest -65 mV Resting potential. V_reset -68 mV Reset potential after spike. V_th -30 mV Threshold potential of spike and reset. V_c -50 mV Critical voltage for spike initiation. Must be larger than $$V_{rest}$$. a 1 The sensitivity of the recovery variable $$u$$ to the sub-threshold fluctuations of the membrane potential $$v$$ b .1 The increment of $$w$$ produced by a spike. c .07 Coefficient describes membrane potential update. Larger than 0. tau 10 ms Membrane time constant. tau_w 10 ms Time constant of the adaptation current.

Model Variables

 Variables name Initial Value Explanation V 0 Membrane potential. w 0 Adaptation current. input 0 External and synaptic input current. spike False Flag to mark whether the neuron is spiking. t_last_spike -1e7 Last spike time stamp.

References

1

Izhikevich, E. M. (2004). Which model to use for cortical spiking neurons?. IEEE transactions on neural networks, 15(5), 1063-1070.

2

Touboul, Jonathan. “Bifurcation analysis of a general class of nonlinear integrate-and-fire neurons.” SIAM Journal on Applied Mathematics 68, no. 4 (2008): 1045-1079.

__init__(size, V_rest=- 65.0, V_reset=- 68.0, V_th=- 30.0, V_c=- 50.0, a=1.0, b=0.1, c=0.07, tau=10.0, tau_w=10.0, method='euler', **kwargs)[source]

Methods

 __init__(size[, V_rest, V_reset, V_th, V_c, ...]) build_inputs([inputs, show_code]) build_monitors([show_code]) cpu() cuda() derivative(V, w, t, Iext) ints([method]) Collect all integrators in this node and the children nodes. load_states(filename[, verbose, check]) Load the model states. nodes([method, _paths]) Collect all children nodes. register_constant_delay(key, size, delay[, ...]) Register a constant delay. run(duration[, dt, report, inputs, extra_func]) The running function. save_states(filename[, all_vars]) Save the model states. step(t_and_dt, **kwargs) to(devices) tpu() train_vars([method]) The shortcut for retrieving all trainable variables. unique_name([name, type]) Get the unique name for this object. update(_t, _dt) The function to specify the updating rule. vars([method]) Collect all variables in this node and the children nodes.

Attributes

 implicit_nodes Used to wrap the implicit children nodes which cannot be accessed by self.xxx implicit_vars Used to wrap the implicit variables which cannot be accessed by self.xxx target_backend Used to specify the target backend which the model to run.