jaxlie._se3
Module Contents
Classes
Special Euclidean group for proper rigid transforms in 3D. Broadcasting |
- class jaxlie._se3.SE3(parameters)[source]
Bases:
jaxlie.SEBase[jaxlie.SO3]
Special Euclidean group for proper rigid transforms in 3D. Broadcasting rules are the same as for numpy.
Internal parameterization is
(qw, qx, qy, qz, x, y, z). Tangent parameterization is(vx, vy, vz, omega_x, omega_y, omega_z). .. py:attribute:: wxyz_xyz- type:
jax.Array
Internal parameters. wxyz quaternion followed by xyz translation. Shape should be
(*, 7).- classmethod from_rotation_and_translation(rotation, translation)[source]
Construct a rigid transform from a rotation and a translation.
- Parameters:
rotation (jaxlie.SO3) – Rotation term.
translation (jaxlie.hints.Array) – translation term.
- Returns:
Constructed transformation.
- Return type:
- classmethod identity(batch_axes=())[source]
Returns identity element.
- Parameters:
batch_axes (jax_dataclasses.Static[Tuple[int, Ellipsis]]) – Any leading batch axes for the output transform.
- Returns:
Identity element.
- Return type:
- classmethod from_matrix(matrix)[source]
Get group member from matrix representation.
- Parameters:
matrix (jaxlie.hints.Array) – Matrix representaiton.
- Returns:
Group member.
- Return type:
- as_matrix()[source]
Get transformation as a matrix. Homogeneous for SE groups.
- Return type:
jax.Array
- classmethod exp(tangent)[source]
Computes
expm(wedge(tangent)).- Parameters:
tangent (jaxlie.hints.Array) – Tangent vector to take the exponential of.
- Returns:
Output.
- Return type:
- log()[source]
Computes
vee(logm(transformation matrix)).- Returns:
Output. Shape should be
(tangent_dim,).- Return type:
jax.Array
- adjoint()[source]
Computes the adjoint, which transforms tangent vectors between tangent spaces.
More precisely, for a transform
GroupType:GroupType @ exp(omega) = exp(Adj_T @ omega) @ GroupType
In robotics, typically used for transforming twists, wrenches, and Jacobians across different reference frames.
- Returns:
Output. Shape should be
(tangent_dim, tangent_dim).- Return type:
jax.Array
- jlog()[source]
Computes the Jacobian of the logarithm of the group element when a local perturbation is applied.
This is equivalent to the inverse of the right Jacobian, or:
jax.jacrev(lambda x: (T @ exp(x)).log())(jnp.zeros(tangent_dim))
where
Tis the group element andexp(x)is the tangent vector.- Returns:
The Jacobian of the logarithm, having the dimensions
(tangent_dim, tangent_dim,)or batch of these Jacobians.- Return type:
jax.Array
- classmethod sample_uniform(key, batch_axes=())[source]
Draw a uniform sample from the group. Translations (if applicable) are in the range [-1, 1].
- Parameters:
key (jax.Array) – PRNG key, as returned by
jax.random.PRNGKey().batch_axes (jax_dataclasses.Static[Tuple[int, Ellipsis]]) – Any leading batch axes for the output transforms. Each sampled transform will be different.
- Returns:
Sampled group member.
- Return type: