calix.hagen.neuron_leak_bias.MembraneTimeConstCalibReset

class calix.hagen.neuron_leak_bias.MembraneTimeConstCalibReset(target: quantities.quantity.Quantity = array(60.) * us, neuron_configs: Optional[List[pyhaldls_vx_v3.NeuronConfig]] = None)

Bases: calix.common.madc_base.Calib

Measure neuron reset with the MADC to calibrate the membrane time constant.

Due to the MADC’s high sample rate, an exponential fit on the decaying potential after a reset is used to determine the membrane time constant. Leak bias currents are tweaked to reach the desired value.

The leak and reset potentials are altered to ensure a good amplitude for the fit between the two potentials. The membrane time constant at a (different) desired leak potential may be slightly different. For target membrane time constants above some 3 us, a step current stimulus can be used instead of a reset, therefore not changing the potentials. See MembraneTimeConstCalibOffset for this method.

This calibration decides whether leak division or multiplication is required during prelude. The given neuron configs are therefore altered.

Requirements: - None -

Variables

neuron_configs – List of desired neuron configurations. Necessary to enable leak division/multiplication.

__init__(target: quantities.quantity.Quantity = array(60.) * us, neuron_configs: Optional[List[pyhaldls_vx_v3.NeuronConfig]] = None)
Parameters

neuron_configs – List of neuron configurations. If None, the hagen-mode default neuron config is used for all neurons.

Methods

__init__([target, neuron_configs])

param neuron_configs

List of neuron configurations. If None, the

configure_parameters(builder, parameters)

Configure the given array of leak bias currents.

evaluate(samples)

Evaluates the obtained MADC samples.

neuron_config_disabled(neuron_coord)

Return a neuron config with readout disabled.

neuron_config_readout(neuron_coord)

Return a neuron config with readout enabled.

postlude(connection)

Restore original readout configuration.

prelude(connection)

Prepares chip for calibration.

stimulate(builder, neuron_coord, …)

Reset the neuron membrane potential to a low voltage.

configure_parameters(builder: calix.common.base.WriteRecordingPlaybackProgramBuilder, parameters: numpy.ndarray)calix.common.base.WriteRecordingPlaybackProgramBuilder

Configure the given array of leak bias currents.

Parameters
  • builder – Builder to append configuration instructions to.

  • parameters – Array of bias currents to set up.

Returns

Builder with configuration appended.

evaluate(samples: List[numpy.ndarray])numpy.ndarray

Evaluates the obtained MADC samples.

To each neuron’s MADC samples, an exponential decay is fitted, and the resulting time constant is returned. This should make for a very precise measurement.

Parameters

samples – MADC samples obtained for each neuron.

Returns

Numpy array of fitted synaptic input time constants.

neuron_config_disabled(neuron_coord: pyhalco_hicann_dls_vx_v3.NeuronConfigOnDLS)pyhaldls_vx_v3.NeuronConfig

Return a neuron config with readout disabled.

Parameters

neuron_coord – Coordinate of neuron to get config for.

Returns

Neuron config with readout disabled.

neuron_config_readout(neuron_coord: pyhalco_hicann_dls_vx_v3.NeuronConfigOnDLS)pyhaldls_vx_v3.NeuronConfig

Return a neuron config with readout enabled.

Parameters

neuron_coord – Coordinate of neuron to get config for.

Returns

Neuron config with readout enabled.

postlude(connection: pyhxcomm_vx.ConnectionHandle)

Restore original readout configuration.

The base class postlude is overwritten to _not_ restore the original neuron configuration, as leak division and multiplication may be altered by this routine.

Parameters

connection – Connection to the chip to calibrate.

prelude(connection: pyhxcomm_vx.ConnectionHandle)

Prepares chip for calibration.

Sets reset potential low and leak high in order to observe a large decay back to the leak potential.

Also measures the membrane time constant at low and high bias currents to decide whether leak multiplication or division is required to reach the given targets.

Parameters

connection – Connection to the chip to calibrate.

stimulate(builder: calix.common.base.WriteRecordingPlaybackProgramBuilder, neuron_coord: pyhalco_hicann_dls_vx_v3.NeuronConfigOnDLS, stimulation_time: pyhaldls_vx_v3.Timer.Value)calix.common.base.WriteRecordingPlaybackProgramBuilder

Reset the neuron membrane potential to a low voltage.

Parameters
  • builder – Builder to append reset instructions to.

  • neuron_coord – Coordinate of neuron which is currently recorded.

  • stimulation_time – Timer value at beginning of stimulation.

Returns

Builder with neuron resets appended.