laika.lib package

Submodules

laika.lib.coordinates module

class laika.lib.coordinates.LocalCoord(init_geodetic, init_ecef)[source]

Bases: object

Allows conversions to local frames. In this case NED. That is: North East Down from the start position in meters.

ecef2ned(ecef)[source]
classmethod from_ecef(init_ecef)[source]
classmethod from_geodetic(init_geodetic)[source]
geodetic2ned(geodetic)[source]
ned2ecef(ned)[source]
ned2geodetic(ned)[source]
laika.lib.coordinates.ecef2geodetic(ecef, radians=False)[source]

Convert ECEF coordinates to geodetic using ferrari’s method

laika.lib.coordinates.geodetic2ecef(geodetic, radians=False)[source]

laika.lib.orientation module

laika.lib.orientation.ecef2car(car_ecef, psi, theta, points_ecef, ned_converter)[source]

TODO: add roll rotation Converts an array of points in ecef coordinates into x-forward, y-left, z-up coordinates Parameters ———- psi: yaw, radian theta: pitch, radian Returns ——- [x, y, z] coordinates in car frame

laika.lib.orientation.ecef_euler_from_ned(ned_ecef_init, ned_pose)[source]

Got it from here: Using Rotations to Build Aerospace Coordinate Systems -Don Koks

laika.lib.orientation.euler2quat(eulers)[source]
laika.lib.orientation.euler2rot(eulers)[source]
laika.lib.orientation.euler_from_quat(quats)
laika.lib.orientation.euler_from_rot(rots)
laika.lib.orientation.ned_euler_from_ecef(ned_ecef_init, ecef_poses)[source]

Got the math from here: Using Rotations to Build Aerospace Coordinate Systems -Don Koks

Also accepts array of ecef_poses and array of ned_ecef_inits. Where each row is a pose and an ecef_init.

laika.lib.orientation.quat2euler(quats)[source]
laika.lib.orientation.quat2rot(quats)[source]
laika.lib.orientation.quat_from_euler(eulers)

Random helpers below

laika.lib.orientation.quat_from_rot(rots)
laika.lib.orientation.quat_product(q, r)[source]
laika.lib.orientation.quats_from_rotations(rots)
laika.lib.orientation.rot(axis, angle)[source]
laika.lib.orientation.rot2euler(rots)[source]
laika.lib.orientation.rot2quat(rots)[source]
laika.lib.orientation.rot_from_euler(eulers)
laika.lib.orientation.rot_from_quat(quats)
laika.lib.orientation.rot_matrix(roll, pitch, yaw)[source]
laika.lib.orientation.rotations_from_quats(quats)

Module contents