nnmt.lif.exp._external_rates_for_fixed_input¶
-
nnmt.lif.exp.
_external_rates_for_fixed_input
(mu_set, sigma_set, J, K, V_0_rel, V_th_rel, tau_m, tau_r, tau_s, J_ext, K_ext, I_ext=None, C=None, method='shift')[source]¶ Calculate external rates needed to get fixed mean and std input.
Uses least square method to find best fitting solution for external rates such that the mean and standard deviation of the input to the neuronal populations is as close as possible to
mu_set
andsigma_set
.Generalization of equation E1 of Helias et al. [2013] and the corrected version in appendix F of Senk et al. [2020].
Parameters: - mu_set[float | np.array]
Mean neuron activity in V.
- sigma_set[float | np.array]
Standard deviation of neuron activity in V.
- Jnp.array
Weight matrix in V.
- Knp.array
Indegree matrix.
- V_th_rel[float | np.array]
Relative threshold potential in V.
- V_0_rel[float | np.array]
Relative reset potential in V.
- tau_m[float | 1d array]
Membrane time constant of post-synatic neuron in s.
- tau_r[float | 1d array]
Refractory time in s.
- tau_sfloat
Pre-synaptic time constant in s.
- J_extnp.array
External weight matrix in V.
- K_extnp.array
Numbers of external input neurons to each population.
- methodstr
Method used to calculate the target rates. Options: ‘shift’, ‘taylor’. Default is ‘shift’.
Returns: - np.ndarray
External rates in Hz.