hnn_core.optimization.optimize_evoked

hnn_core.optimization.optimize_evoked(params, target_dpl, initial_dpl, maxiter=50, timing_range_multiplier=3.0, sigma_range_multiplier=50.0, synweight_range_multiplier=500.0, decay_multiplier=1.6, scale_factor=1.0, smooth_window_len=None)[source]

Optimize drives to generate evoked response.

Parameters
paramsdict

The initial params

target_dplinstance of Dipole

The target experimental dipole.

initial_dplinstance of Dipole

The initial dipole to start the optimization.

maxiterint

The maximum number of simulations to run for optimizing one “chunk”.

timing_range_multiplierfloat

The scale of timing values to sweep over.

sigma_range_multiplierfloat

The scale of sigma values to sweep over.

synweight_range_multiplierfloat

The scale of input synaptic weights to sweep over.

decay_multiplierfloat

The decay multiplier.

scale_factorfloat

Scales the simulated dipoles by scale_factor to match target_dpl.

smooth_window_lenint

The length of the hamming window (in samples) to smooth the simulated dipole waveform in each optimization step.

Returns
paramsdict

The optimized params dictionary.

Notes

This optimization protocol utilizes the Constrained Optimization By Linear Approximation (COBYLA) method: https://docs.scipy.org/doc/scipy/reference/generated/scipy.optimize.fmin_cobyla.html # noqa

Examples using hnn_core.optimization.optimize_evoked