hxtorch.core.morphology.Morphology
-
class
hxtorch.core.morphology.Morphology Bases:
abc.ABCRepresents the internal structure of a neuron.
This neuron might be made up of several compartments and the compartments themselves can consist of several neuron circuits.
- Note
Currently spike and voltage recording is only supported in the first neuron circuit of the first compartment.
-
__init__() Initialize self. See help(type(self)) for accurate signature.
Methods
disable_leak(configs)Disable the leak for the given neuron.
disable_spiking(configs)Disable spiking for the given neuron.
enable_constant_current(configs[, current_type])Enable constant current input for the given neuron.
enable_madc_recording(configs, readout_source)Configure neuron such that traces can be recorded with the MADC.
format_to_CapMemCell_value(**kwargs)Helper function that can convert numbers (float or int) into hal.CapMemCell.Value type while issuing warnings, if bonds of the assignable value range are tried to surpass.
implement_morphology(coord, configs)Configure the atomic neurons in the given neuron block to represent this morphology.
set_adaptation_base_params(configs, tau_adap)Set all parameters related to the base of the adaptation term of the adaptive exponential leaky integrate-and-fire model (without subthreshold- or spike-triggered adaptation) on the given hw neuron.
set_exponential_params(configs, …)Set all parameters related to the exponential term of the adaptive exponential leaky integrate-and-fire model on the given hardware neuron.
set_spike_recording(enable, configs)Set whether spikes are forwarded digitally.
Set the hardware parameter for the spike-triggered adaptation increment on the given hw neuron.
Set the hardware parameter for the subthreshold adaptation strength on the given hw neuron.
Attributes
Unplaced coordinate of the logical neuron.
Base configuration of the logical neuron.
-
abstract property
compartments Unplaced coordinate of the logical neuron.
-
static
disable_leak(configs: Dict[pygrenade_common.CompartmentOnNeuron, List[pyhalco_hicann_dls_vx_v3.AtomicNeuronOnDLS]]) → None Disable the leak for the given neuron.
- Parameters
coord – Coordinate of the logical neuron for which the leak is disabled.
neuron_block – Neuron block in which the configuration of the atomic neurons is changed.
-
static
disable_spiking(configs: Dict[pygrenade_common.CompartmentOnNeuron, List[pyhalco_hicann_dls_vx_v3.AtomicNeuronOnDLS]]) → None Disable spiking for the given neuron.
Disable the threshold comparator and the digital spike output.
- Parameters
coord – Coordinate of the logical neuron for which spiking is disabled.
neuron_block – Neuron block in which the configuration of the atomic neurons is changed.
-
static
enable_constant_current(configs: Dict[pygrenade_common.CompartmentOnNeuron, List[pyhalco_hicann_dls_vx_v3.AtomicNeuronOnDLS]], current_type: pylola_vx_v3.AtomicNeuron.ConstantCurrent.Type = <Type.source: 0>) → None Enable constant current input for the given neuron.
- Parameters
coord – Coordinate of the logical neuron for which constant current input is enabled.
neuron_block – Neuron block in which the configuration of the atomic neurons is changed.
-
static
enable_madc_recording(configs: Dict[pygrenade_common.CompartmentOnNeuron, List[pyhalco_hicann_dls_vx_v3.AtomicNeuronOnDLS]], readout_source: pyhaldls_vx_v3.NeuronConfig.ReadoutSource) → None Configure neuron such that traces can be recorded with the MADC.
- Parameters
coord – Coordinate of the logical neuron for which the recording is enabled.
neuron_block – Neuron block in which the configuration of the atomic neurons is changed.
readout_source – Voltage which should be recorded.
-
static
format_to_CapMemCell_value(**kwargs) → Tuple[pyhaldls_vx_v3.CapMemCell.Value] Helper function that can convert numbers (float or int) into hal.CapMemCell.Value type while issuing warnings, if bonds of the assignable value range are tried to surpass.
- Parameters
kwargs – Dictionary that holds the values that are to be converted and their respective variable names (used for warnings)
- Returns
Tuple that holds the according hal.CapMemCell.Value for each passed value via kwargs
-
implement_morphology(coord: pyhalco_hicann_dls_vx_v3.LogicalNeuronOnDLS, configs: Dict[pygrenade_common.CompartmentOnNeuron, List[pyhalco_hicann_dls_vx_v3.AtomicNeuronOnDLS]]) → None Configure the atomic neurons in the given neuron block to represent this morphology.
- Parameters
coord – Coordinate of the logical neuron which should be configured.
neuron_block – The configuration of neurons at coord will be changed such that a neuron with the given morphology is implemented.
-
abstract property
logical_neuron Base configuration of the logical neuron.
Default constructed logical neuron, the connections between neuron circuits are configured such that the specified morphology is implemented.
-
static
set_adaptation_base_params(configs: Dict[pygrenade_common.CompartmentOnNeuron, List[pyhalco_hicann_dls_vx_v3.AtomicNeuronOnDLS]], tau_adap: Union[float, int]) → None Set all parameters related to the base of the adaptation term of the adaptive exponential leaky integrate-and-fire model (without subthreshold- or spike-triggered adaptation) on the given hw neuron.
- Parameters
coord – Coordinate of the logical neuron for which the parameters are to be set.
neuron_block – Neuron block in which the configuration of the atomic neurons is changed.
tau_adap – Parameter value to be set for the adaptation time constant.
-
static
set_exponential_params(configs: Dict[pygrenade_common.CompartmentOnNeuron, List[pyhalco_hicann_dls_vx_v3.AtomicNeuronOnDLS]], exponential_threshold: Union[float, int], exponential_slope: Union[float, int]) → None Set all parameters related to the exponential term of the adaptive exponential leaky integrate-and-fire model on the given hardware neuron.
- Parameters
coord – Coordinate of the logical neuron for which the parameters are to be set.
neuron_block – Neuron block in which the configuration of the atomic neurons is changed.
exponential_threshold – Parameter value to be set for the exponential threshold.
exponential_slope – Parameter value to be set for the exponential slope.
-
static
set_spike_recording(enable: bool, configs: Dict[pygrenade_common.CompartmentOnNeuron, List[pyhalco_hicann_dls_vx_v3.AtomicNeuronOnDLS]]) → None Set whether spikes are forwarded digitally.
- Parameters
enable – Enable/disable the digital routing of spikes.
coord – Coordinate of the logical neuron for which the recording is enabled.
neuron_block – Neuron block in which the configuration of the atomic neurons is changed.
-
static
set_spike_triggered_adaptation_increment(configs: Dict[pygrenade_common.CompartmentOnNeuron, List[pyhalco_hicann_dls_vx_v3.AtomicNeuronOnDLS]], backends: List[pyhaldls_vx_v3.CommonNeuronBackendConfig], spike_triggered_adaptation_increment: Union[float, int], clock_scale_adaptation_pulse: Tuple[int] = (5, 5)) → None Set the hardware parameter for the spike-triggered adaptation increment on the given hw neuron.
- Parameters
coord – Coordinate of the logical neuron for which the parameters are to be set.
neuron_block – Neuron block in which the configuration of the atomic neurons is changed.
spike_triggered_adaptation_increment – Parameter value to be set for the spike-triggered adaptation increment.
-
static
set_subthreshold_adaptation_strength(configs: Dict[pygrenade_common.CompartmentOnNeuron, List[pyhalco_hicann_dls_vx_v3.AtomicNeuronOnDLS]], subthreshold_adaptation_strength: Union[float, int], leak_adaptation: Optional[Union[float, int]]) → None Set the hardware parameter for the subthreshold adaptation strength on the given hw neuron.
- Parameters
coord – Coordinate of the logical neuron for which the parameters are to be set.
neuron_block – Neuron block in which the configuration of the atomic neurons is changed.
subthreshold_adaptation_strength – Parameter value to be set for the subthreshold adaptation strength.
leak_adaptation – Parameter value to be set for the leak potential from the membrane taken into account by the subthreshold adaptation mechanism on hardware.