align_vectors#
- align_vectors(base, target=(0, 0, 1), seq=None)[source]#
Compute the rotation matrix or Euler angles required to align an initial vector with a target vector.
- Parameters:
- baseNDArray
The basis vector.
- targetNDArray, optional
The vector to map base to, defaults to (0,0,1).
- seqstr, optional
Euler angle convention, None returns a rotation matrix instead.
- Returns:
- NDArray
Rotation matrix if seq is None otherwise Euler angles in desired convention