mindsponge.common.invert_rigids
- mindsponge.common.invert_rigids(rigids)[source]
Computes group inverse of rigid transformations. Change rigid from local coordinate system to global coordinate system.
Use invert_rots to calculate the invert rotations of rigid. Then use rots_mul_vecs to rotate the translations of rigid. The opposite of the result is the translations of invert rigid.
- Parameters
rigids (tuple) – rigids, including the rots and trans changing rigids from global coordinate system to local coordinate system.
- Returns
- tuple(rots, trans), group inverse of rigid transformations, length is 2. Include rots
and trans . Data type is constant or Tensor with same shape.
- Supported Platforms:
Ascend
GPU
Examples
>>> import mindsponge >>> a = ((1, 2, 3, 4, 5, 6, 7, 8, 9), (3, 4, 5)) >>> inv_a = mindsponge.common.invert_rigids(a) >>> print(inv_a) ((1, 4, 7, 2, 5, 8, 3, 6, 9), (-54.0, -66.0, -78.0))