scale_forward_scalar

sofia_redux.toolkit.resampling.scale_forward_scalar(coordinate, scale, offset)[source]

Applies the function f(x) = (x - offset) / scale to a single coordinate.

This is a numba jit compiled function.

Parameters:
coordinatenumpy.ndarray (N,)

An array where N is the number of dimensions.

scalenumpy.ndarray (N,)

The scaling factor to apply to each dimension.

offsetnumpy.ndarray (N,)

The offset to apply to each dimension.

Returns:
numpy.ndarray of numpy.float64 (N,)

The scaled coordinates array.