LengthDelay#
- class brainpy.math.LengthDelay(delay_target, delay_len, initial_delay_data=None, name=None, batch_axis=None, update_method='rotation')[source]#
Delay variable which has a fixed delay length.
- Parameters:
delay_target (
Union[Array,Array]) – The initial delay data.delay_len (
int) – The maximum delay length.initial_delay_data (
Union[float,int,bool,Array,Array,Callable]) –The delay data. It can be a Python number, like float, int, boolean values. It can also be arrays. Or a callable function or instance of
Connector. A callable will be invoked asinitial_delay_data(shape, dtype=...)when its signature accepts adtypekeyword (e.g.Initializer/Connectorinstances), and asinitial_delay_data(shape)otherwise (e.g. a plainlambda shape: ...). Note thatinitial_delay_datashould be arranged as the following way:delay = 1 [ data delay = 2 data ... .... ... .... delay = delay_len-1 data delay = delay_len data ]
Changed in version 2.2.3.2: The data in the previous version of
LengthDelayis:delay = delay_len [ data delay = delay_len-1 data ... .... ... .... delay = 2 data delay = 1 data ]
- namestr
The delay object name.
- batch_axisint
The batch axis. If not provided, it will be inferred from the delay_target.
- update_methodstr
The method used for updating delay.
See also
- property delay_shape#
The data shape of this delay variable.
- property delay_target_shape#
The data shape of the delay target.