scipp.spatial#

Transformations of vectors.

Functions in this module can be used to construct, deconstruct, and modify variables with transformations on vectors.

Despite the name, transformations in this module can be applied to 3-vectors in any vector space and coordinate system, not just the physical space. The user has to ensure that transformations are applied to the correct vectors.

See also

scipp.vector

Construct a scalar variable holding a 3-vector.

scipp.vectors

Construct an array variable holding 3-vectors.

Functions

affine_transform(*[, unit])

Initializes a single affine transformation from the provided affine matrix coefficients.

affine_transforms(*, dims[, unit])

Initializes affine transformations from the provided affine matrix coefficients.

as_vectors(x, y, z)

Return inputs combined into vectors.

inv(var)

Return the inverse of a spatial transformation.

linear_transform(*[, unit])

Constructs a zero dimensional Variable holding a single 3x3 matrix.

linear_transforms(*, dims[, unit])

Constructs a Variable with given dimensions holding an array of 3x3 matrices.

rotation(*, value)

Creates a rotation-type variable from the provided quaternion coefficients.

rotation_as_rotvec(rotation, *[, unit])

Represent a rotation matrix (or matrices) as rotation vector(s).

rotations(*, dims, values)

Creates a rotation-type variable from the provided quaternion coefficients.

rotations_from_rotvecs(rotation_vectors)

Creates rotation transformations from rotation vectors.

scaling_from_vector(*, value)

Creates a scaling transformation from a provided 3-vector.

scalings_from_vectors(*, dims, values)

Creates scaling transformations from corresponding to the provided 3-vectors.

translation(*[, unit])

Creates a translation transformation from a single provided 3-vector.

translations(*, dims[, unit])

Creates translation transformations from multiple 3-vectors.