warp.quat_twist_angle#

warp.quat_twist_angle(axis: vec3f, q: quatf) float#
  • Kernel

  • Differentiable

Return the twist magnitude of q around axis.

This returns an unsigned twist magnitude. For canonicalized quaternions (for example from quat_from_axis_angle() with angles in (-pi, pi)), both +theta and -theta map to |theta|.

Parameters:
  • axis – Twist axis (expected to be normalized).

  • q – Input quaternion.

Returns:

Twist angle in radians in [0, pi] for canonicalized inputs.

Return type:

float