Parameter scaler classes

class bluepyopt.ephys.parameterscalers.MissingFormatDict[source]

Bases: dict

Extend dict for string formatting with missing values

class bluepyopt.ephys.parameterscalers.NrnSegmentLinearScaler(name=None, multiplier=1.0, offset=0.0, comment='')[source]

Bases: bluepyopt.ephys.parameterscalers.ParameterScaler, bluepyopt.ephys.serializer.DictMixin

Linear scaler


  • name (str) – name of this object
  • multiplier (float) – slope of the linear scaler
  • offset (float) – intercept of the linear scaler
scale(value, segment=None, sim=None)[source]

Scale a value based on a segment

class bluepyopt.ephys.parameterscalers.NrnSegmentSomaDistanceScaler(name=None, distribution=None, comment='', dist_param_names=None)[source]

Bases: bluepyopt.ephys.parameterscalers.ParameterScaler, bluepyopt.ephys.serializer.DictMixin

Scaler based on distance from soma


  • name (str) – name of this object
  • distribution (str) – distribution of parameter dependent on distance from soma. string can contain distance and/or value as placeholders for the distance to the soma and parameter value respectivily
  • dist_params (list) – list of names of parameters that parametrise the distribution. These names will become attributes of this object. The distribution string should contain these names, and they will be replaced by values of the corresponding attributes
eval_dist(value, distance)[source]

Create the final dist string


The instantiated distribution

scale(value, segment, sim=None)[source]

Scale a value based on a segment

class bluepyopt.ephys.parameterscalers.ParameterScaler(name='', comment='')[source]

Bases: bluepyopt.ephys.base.BaseEPhys

Parameter scalers


Return formatted float string