noise_generator – Generate a Gaussian white noise current¶
Description¶
The noise_generator can be used to inject a Gaussian “white” noise current into a node.
The current is not truly white, but a piecewise constant current with a Gaussian distributed amplitude with mean \(\mu\) and standard deviation \(\sigma\). The current changes at a user-defined interval \(\delta\) and is given by
where \(N_j\) are Gaussian random numbers with unit standard deviation and \(t_0\) is the device onset time.
Additionally a sinusodially modulated term can be added to the standard deviation of the noise:
The effect of the noise current on a neuron depends on the switching interval \(\delta\). For a leaky integrate-and-fire neuron with time constant \(\tau_m\) and capacitance \(C_m\), the variance of the membrane potential is given by
for \(\delta \ll \tau_m\). For details, see the noise generator notebook.
All targets of a noise generator receive different currents, but the currents for all targets change at the same points in time. The interval \(\delta\) between changes must be a multiple of the time step.
Recording the generated current
You can use a multimeter to record the average current sent to all targets for each time step if simulating on a single thread; multiple MPI processes with one thread each also work. In this case, the recording interval of the multimeter should be equal to the simulation resolution to avoid confusing effects due to offset or drift between the recording times of the multimeter and the switching times of the noise generator. In multi-threaded mode, recording of noise currents is prohibited for technical reasons.
All stimulation devices share the parameters start
and stop
,
which control the stimulation period. The property origin
is a
global offset that shifts the stimulation period. All three values are
set as times in ms.
For spike-emitting devices, only spikes with times t that fulfill \(\mathrm{start} < t \leq \mathrm{stop}\) are emitted. Spikes that have timestamp of \(t = \mathrm{start}\) are not emitted.
For current-emitting devices, the current is activated and deactivated such that the current first affects the target dynamics during the update step \((\mathrm{start}, \mathrm{start}+h]\), that is, an effect can be recorded at the earliest at time \(\mathrm{start}+h\). The last interval during which the current affects the target’s dynamics is \((\textrm{stop}-h, \textrm{stop}]\).
The property stimulus_source
defaults to an empty string. It can
be set to the name of a stimulation backend, in which case it will
take its parameters from the configured backend instead of from the
internally stored values. More details on available backends and their
properties can be found in the guide to stimulating the network.
Parameters¶
- label
A string specifying an arbitrary textual label for the device. Stimulation backends might use the label to generate device specific identifiers like filenames and such. Default:
""
.- origin
A positive floating point number used as the reference time in ms for
start
andstop
. Default:0.0
.- start
A positive floating point number specifying the activation time in ms, relative to
origin
. Default:0.0
.- stimulus_source
A string specifying the name of the stimulation backend from which to get the data for updating the stimulus parameters of the device. By default, the device uses its internally stored parameters for updating the stimulus. Default:
""
.- stop
A floating point number specifying the deactivation time in ms, relative to
origin
. The value ofstop
must be greater than or equal tostart
. Default:infinity
.
- mean
The mean value \(\mu\) of the noise current (pA)
- std
The standard deviation \(\sigma\) of the noise current (pA)
- dt
The interval \(\delta\) between changes in current (ms; default: 10 * resolution)
- std_mod
The modulation \(\sigma_{\text{mod}}\) of the standard deviation of the noise current (pA)
- frequency
The frequency of the sine modulation (Hz)
- phase
The phase of sine modulation (0–360 deg)
Setting parameters from a stimulation backend¶
The parameters in this stimulation device can be updated with input coming from a stimulation backend. The data structure used for the update holds one value for each of the parameters mentioned above. The indexing is as follows:
mean
std
std_mod
frequency
phase
Sends¶
CurrentEvent
See also¶
step_current_generator