get_active_scale#

deeptrack.backend.units.get_active_scale() tuple[float, float, float]#

Get the active scale between optical and simulation pixel units.

This function computes the scaling factors along the x, y, and z axes that relate optical pixel units (xpx, ypx, zpx) to simulation pixel units (sxpx, sypx, szpx). The result can be used to convert between the two domains.

Returns#

tuple[float, float, float]

The scaling factors (x, y, z) such that: optical pixel = scale × simulation pixel

Examples#

>>> from deeptrack.backend.units import get_active_scale

Get the scale factors from simulation to optical domain: >>> get_active_scale() (1.0, 1.0, 1.0)