braincore.util.MemScaling

braincore.util.MemScaling#

class braincore.util.MemScaling(scale, bias)[source]#

The scaling object for membrane potential.

The scaling object is used to transform the membrane potential range to a standard range. The scaling object can be used to transform the membrane potential to a standard range, and transform the standard range to the membrane potential.

__init__(scale, bias)[source]#

Methods

__init__(scale, bias)

clone()

Clone the scaling object.

offset(x[, bias])

Transform the membrane potential to the standard range.

rev_offset(x[, bias])

Reversely transform the standard range to the original membrane potential.

rev_scale(x[, scale])

Reversely transform the standard range to the original membrane potential.

rev_scale_offset(x[, bias, scale])

Reversely transform the standard range to the original membrane potential.

scale(x[, scale])

Transform the membrane potential to the standard range.

scale_offset(x[, bias, scale])

Transform the membrane potential to the standard range.

transform(oring_range[, target_range])

Transform the membrane potential range to a Scaling instance.