MotorNeuronPool#

class myogen.simulator.MotorNeuronPool(recruitment_thresholds, diameter_soma_min=77.5, diameter_soma_max=82.5, y_min=18.0, y_max=36.0, diameter_dend_min=41.5, diameter_dend_max=62.5, x_min=-5500, x_max=-6789, vt_min=12.35, vt_max=20.9, kf_cond_min=4, kf_cond_max=0.5, CV=0.01)[source]#

Bases: object

Motor neuron pool with specified parameters

Parameters:
  • recruitment_thresholds (numpy.ndarray) – Array of recruitment thresholds for the motor neurons

  • diameter_soma_min (float) – Minimum diameter of the soma

  • diameter_soma_max (float)

  • y_min (float) – Minimum y coordinate of the soma

  • y_max (float) – Maximum y coordinate of the soma

  • diameter_dend_min (float) – Minimum diameter of the dendrite

  • diameter_dend_max (float) – Maximum diameter of the dendrite

  • x_min (float) – Minimum x coordinate of the dendrite

  • x_max (float) – Maximum x coordinate of the dendrite

  • vt_min (float) – Minimum voltage threshold of the neuron

  • vt_max (float) – Maximum voltage threshold of the neuron

  • kf_cond_min (float) – Minimum conductance density of the potassium fast channel

  • kf_cond_max (float) – Maximum conductance density of the potassium fast channel

  • CV (float) – Coefficient of variation of the noise

Returns:

Motor neuron pool with specified parameters

Return type:

MotorNeuronPool

Methods

__init__

generate_spike_trains

Generate the spike trains for as many neuron pools as input currents there are

generate_spike_trains(input_current__matrix, timestep__ms=0.05, noise_mean__nA=30, noise_stdev__nA=30, what_to_record=[{'locations': ['dendrite', 'soma'], 'variables': ['v']}])[source]#

Generate the spike trains for as many neuron pools as input currents there are

Each motor neuron pools have each “neurons_per_pool” neurons. The input currents are injected into each pool, and the spike trains are recorded.

Parameters:
  • input_current__matrix (INPUT_CURRENT__MATRIX) – Matrix of shape (n_pools, t_points) containing current values Each row represents the current for one pool

  • timestep__ms (float) – Simulation timestep__ms in ms

  • noise_mean__nA (float) – Mean of the noise current in nA

  • noise_stdev__nA (float) – Standard deviation of the noise current in nA

  • what_to_record (list[dict['variables', 'to_file', 'sampling_interval', 'locations'], Any]) –

    List of dictionaries specifying what to record.

    Each dictionary contains the following keys:
    • variables: list of strings specifying the variables to record

    • to_file: bool specifying whether to save the recorded data to a file

    • sampling_interval: int specifying the sampling interval in ms

    • locations: list of strings specifying the locations to record from

    See pyNN documentation for more details: https://pynn.readthedocs.io/en/stable/recording.html.

    Spike trains are recorded by default.

Returns:

  • spike_trains (SPIKE_TRAIN__MATRIX) – Matrix of shape (n_pools, neurons_per_pool, t_points) containing spike trains Each row represents the spike train for one pool Each column represents the spike train for one neuron Each element represents whether the neuron spiked at that time point

  • active_neuron_indices (list[numpy.ndarray]) – List of arrays of indices of the active neurons in each pool

  • data (list[neo.core.segment.Segment]) – List of neo segments containing the recorded data

Return type:

tuple[Annotated[ndarray[tuple[int, …], dtype[bool]], beartype.vale.Is[lambda x: x.ndim == 3]], list[ndarray], list[Segment]]