arrlp.transform_parameters module
- arrlp.transform_parameters(matrix, shape=None, *, shears=None, angle=None, scales=None, stacks=False)[source]
Recover transform_matrix parameters from a 3x3 affine matrix.
One of shears, angle, or scales may be provided to make the inverse unique. If none is provided, shears=(0, 0) is assumed.
- Parameters:
matrix (np.ndarray) – 3x3 affine transformation matrix.
shape (int, tuple, np.ndarray, optional) – Same convention as transform_matrix.
shears (tuple, optional) – Known shears as (sheary, shearx).
angle (float, optional) – Known rotation angle in degrees.
scales (tuple, optional) – Known scales as (scaley, scalex).
- Return type:
shiftx, shifty, shearx, sheary, angle, scalex, scaley