mindsponge.common.invert_rots

View Source On Gitee
mindsponge.common.invert_rots(m)[source]

Computes inverse of rotations \(m\).

rotations \(m = (xx, xy, xz, yx, yy, yz, zx, zy, zz)\) and inverse of \(m\) is \(m^{T} = (xx, yx, zx, xy, yy, zy, xz, yz, zz)\) .

Parameters

m (tuple) – rotations \(m\) , length is 9. Data type is constant or Tensor with same shape.

Returns

tuple, inverse of rotations \(m\) , length is 9. Data type is constant or Tensor with same shape.

Supported Platforms:

Ascend GPU

Examples

>>> import mindsponge
>>> m = (1, 2, 3, 4, 5, 6, 7, 8, 9)
>>> inv_m = mindsponge.common.invert_rots(m)
>>> print(inv_m)
(1, 4, 7, 2, 5, 8, 3, 6, 9)