Warning
This page was created from a pull request (#250).
pypose.rxso3¶
- pypose.rxso3 = functools.partial(<class 'pypose.lietensor.lietensor.LieTensor'>, ltype=<pypose.lietensor.lietensor.rxso3Type object>)¶
Alias of rxso3 type
LieTensor
.- Parameters:
data (
Tensor
, orlist
, or ‘int
…’) –A
Tensor
object, or constructing aTensor
object fromlist
, which defines tensor data (see below), or from ‘int
…’, which defines tensor shape.The shape of
Tensor
object must be(*, 4)
, where*
is empty, one, or more batched dimensions (thelshape
of this LieTensor), otherwise error will be raised.
Internally, rxso3 LieTensors are stored by concatenating the axis-angle representation of the rotation with the log scale:
\[\mathrm{data}[*, :] = [\delta_x, \delta_y, \delta_z, \log s], \]where \(\begin{pmatrix} \delta_x & \delta_y & \delta_z \end{pmatrix}^T\) is the axis-angle vector in
pypose.so3
, and \(s \in \mathbb{R}\) is the scaling factor inpypose.RxSO3
.Examples
>>> pp.rxso3(torch.randn(2, 4)) rxso3Type LieTensor: tensor([[ 0.3752, -0.1576, 1.2057, 0.6086], [ 0.8434, 0.2449, 0.0488, -0.1202]]) >>> pp.rxso3([0, 0, 0, 0, 1]) RxSO3Type LieTensor: tensor([0., 0., 0., 0., 1.])
If
data
is tensor-like, the last dimension should correspond to the 4 elements of the above embedding.Note
It is not advised to construct rxso3 Tensors by specifying storage sizes with ‘
int
…’, which does not initialize data.Consider using
pypose.randn_rxso3
orpypose.identity_rxso3
instead.See
pypose.Exp
,pypose.Inv
for implementations of relevant operations.