sPyNNaker neural_modelling 7.1.1
Loading...
Searching...
No Matches
Data Structures | Functions
neuron_model_lif_impl.h File Reference

Leaky Integrate and Fire neuron type. More...

#include "neuron_model.h"

Go to the source code of this file.

Data Structures

struct  neuron_params_t
 definition of neuron parameters More...
 
struct  neuron_t
 definition for LIF neuron state More...
 

Functions

static int32_t lif_ceil_accum (REAL value)
 Performs a ceil operation on an accum.
 
static void neuron_model_initialise (neuron_t *state, neuron_params_t *params, uint32_t n_steps_per_timestep)
 
static void neuron_model_save_state (neuron_t *state, neuron_params_t *params)
 
static void lif_neuron_closed_form (neuron_t *neuron, REAL V_prev, input_t input_this_timestep)
 simple Leaky I&F ODE
 
static state_t neuron_model_state_update (uint16_t num_excitatory_inputs, const input_t *exc_input, uint16_t num_inhibitory_inputs, const input_t *inh_input, input_t external_bias, REAL current_offset, neuron_t *restrict neuron)
 primary function called in timer loop after synaptic updates
 
static void neuron_model_has_spiked (neuron_t *restrict neuron)
 Indicates that the neuron has spiked.
 
static state_t neuron_model_get_membrane_voltage (const neuron_t *neuron)
 get the neuron membrane voltage for a given neuron parameter set
 
static void neuron_model_print_state_variables (const neuron_t *neuron)
 
static void neuron_model_print_parameters (const neuron_t *neuron)
 

Detailed Description

Leaky Integrate and Fire neuron type.

Definition in file neuron_model_lif_impl.h.


Data Structure Documentation

◆ neuron_params_t

struct neuron_params_t

definition of neuron parameters

The state parameters of an Izhekevich model neuron.

definition for LIF neuron parameters

Definition at line 47 of file neuron_impl_stoc_exp.h.

Data Fields
UREAL tau_ms The tau value of the neuron.
UREAL time_step The timestep of the neuron being used.

The time step in milliseconds.

current timestep in ms

REAL bias The bias value.
uint32_t refract_init The initial refractory timer.
mars_kiss64_seed_t random_seed Random seed to use.
REAL v_init The initial membrane voltage.
REAL v_reset The reset membrane voltage after a spike.
UREAL tau The tau value of the neuron, multiplied by 2^v to get probability.
UREAL tau_refract The refractory period of the neuron in milliseconds.

The refractory period of the neuron, in ms.

REAL alpha The alpha value of the neuron prob = (2^(-2^(alpha x voltage)))
REAL V_init membrane voltage [mV]
REAL c_m membrane capacitance [nF]
REAL tau_m membrane decay time constant
REAL I_offset offset current [nA]
REAL V_reset post-spike reset membrane voltage [mV]
REAL T_refract_ms refractory time of neuron [ms]
int32_t refract_timer_init initial refractory timer value (saved)
REAL time_step The time step in milliseconds.

current timestep in ms

REAL A
REAL B
REAL C
REAL D
REAL V
REAL U
REAL next_h next value of this_h (saved)
REAL V_rest membrane resting voltage [mV]

◆ neuron_t

struct neuron_t

definition for LIF neuron state

The state variables of an Izhekevich model neuron.

Definition at line 53 of file neuron_model_if_trunc.h.

Data Fields
REAL V_membrane membrane voltage [mV]
REAL R_membrane membrane resistance [MOhm]
REAL I_offset offset current [nA]
int32_t refract_timer countdown to end of next refractory period [timesteps]
REAL V_reset post-spike reset membrane voltage [mV]
int32_t T_refract refractory time of neuron [timesteps]
REAL A
REAL B
REAL C
REAL D
REAL V
REAL U
REAL this_h current timestep
REAL reset_h timestep to reset to when not just spiked
REAL V_rest membrane resting voltage [mV]
REAL exp_TC

'fixed' computation parameter - time constant multiplier for closed-form solution exp(-(machine time step in ms)/(R * C)) [.]

Function Documentation

◆ lif_ceil_accum()

static int32_t lif_ceil_accum ( REAL  value)
inlinestatic

Performs a ceil operation on an accum.

Parameters
[in]valueThe value to ceil
Returns
The ceil of the value

Definition at line 87 of file neuron_model_lif_impl.h.

◆ neuron_model_initialise()

static void neuron_model_initialise ( neuron_t state,
neuron_params_t params,
uint32_t  n_steps_per_timestep 
)
inlinestatic

Definition at line 97 of file neuron_model_lif_impl.h.

◆ neuron_model_save_state()

static void neuron_model_save_state ( neuron_t state,
neuron_params_t params 
)
inlinestatic

Definition at line 110 of file neuron_model_lif_impl.h.

◆ lif_neuron_closed_form()

static void lif_neuron_closed_form ( neuron_t neuron,
REAL  V_prev,
input_t  input_this_timestep 
)
inlinestatic

simple Leaky I&F ODE

Parameters
[in,out]neuronThe neuron to update
[in]V_prevprevious voltage
[in]input_this_timestepThe input to apply

Definition at line 119 of file neuron_model_lif_impl.h.

◆ neuron_model_state_update()

static state_t neuron_model_state_update ( uint16_t  num_excitatory_inputs,
const input_t exc_input,
uint16_t  num_inhibitory_inputs,
const input_t inh_input,
input_t  external_bias,
REAL  current_offset,
neuron_t *restrict  neuron 
)
inlinestatic

primary function called in timer loop after synaptic updates

Parameters
[in]num_excitatory_inputsNumber of excitatory receptor types.
[in]exc_inputPointer to array of inputs per receptor type received this timer tick that produce a positive reaction within the neuron in terms of stimulation.
[in]num_inhibitory_inputsNumber of inhibitory receptor types.
[in]inh_inputPointer to array of inputs per receptor type received this timer tick that produce a negative reaction within the neuron in terms of stimulation.
[in]external_biasThis is the intrinsic plasticity which could be used for ac, noisy input etc etc. (general purpose input)
[in,out]neuronthe pointer to a neuron parameter struct which contains all the parameters for a specific neuron
Returns
the value to be compared with a threshold value to determine if the neuron has spiked

Definition at line 142 of file neuron_model_lif_impl.h.

◆ neuron_model_has_spiked()

static void neuron_model_has_spiked ( neuron_t *restrict  neuron)
inlinestatic

Indicates that the neuron has spiked.

Parameters
[in,out]neuronpointer to a neuron parameter struct which contains all the parameters for a specific neuron

Definition at line 174 of file neuron_model_lif_impl.h.

◆ neuron_model_get_membrane_voltage()

static state_t neuron_model_get_membrane_voltage ( const neuron_t neuron)
inlinestatic

get the neuron membrane voltage for a given neuron parameter set

Parameters
[in]neurona pointer to a neuron parameter struct which contains all the parameters for a specific neuron
Returns
the membrane voltage for a given neuron with the neuron parameters specified in neuron

Definition at line 187 of file neuron_model_lif_impl.h.

◆ neuron_model_print_state_variables()

static void neuron_model_print_state_variables ( const neuron_t neuron)
inlinestatic

Definition at line 191 of file neuron_model_lif_impl.h.

◆ neuron_model_print_parameters()

static void neuron_model_print_parameters ( const neuron_t neuron)
inlinestatic

Definition at line 196 of file neuron_model_lif_impl.h.