(quat, ordering='XYZ')
return rmat_to_euler(mat[0:3, 0:3], ordering=ordering)
Returns the euler angles corresponding to the provided quaternion.

  Args:
    quat: A quaternion [w, i, j, k].
    ordering: (str) Desired euler angle ordering.

  Returns:
    euler_vec: The euler angle rotations.
Returns the euler angles corresponding to the provided quaternion.
Returns the euler angles corresponding to the provided quaternion .
def quat_to_euler(quat, ordering='XYZ'):
  """Returns the euler angles corresponding to the provided quaternion.

  Args:
    quat: A quaternion [w, i, j, k].
    ordering: (str) Desired euler angle ordering.

  Returns:
    euler_vec: The euler angle rotations.
  """
  mat = quat_to_mat(quat)
  return rmat_to_euler(mat[0:3, 0:3], ordering=ordering)
def quat_to_euler ( quat , ordering = 'XYZ' ) : mat = quat_to_mat ( quat ) return rmat_to_euler ( mat [ 0 : 3 , 0 : 3 ] , ordering = ordering )