bindings_fcl_transform.py
Go to the documentation of this file.
1 import unittest
2 import pinocchio as pin
3 import numpy as np
4 
5 class TestFCLTransformConversion(unittest.TestCase):
6 
7  def test_from_SE3(self):
8  M = pin.SE3.Random()
9  fcl_transform = pin.hppfcl.Transform3f(M)
10 
11  self.assertTrue((M.rotation==fcl_transform.getRotation()).all())
12  self.assertTrue((M.translation==fcl_transform.getTranslation()).all())
13 
14  def test_to_SE3(self):
15  fcl_transform = pin.hppfcl.Transform3f()
16  M = pin.SE3(fcl_transform)
17  self.assertTrue(M.isIdentity())
18 
19 if __name__ == '__main__':
20  if pin.WITH_HPP_FCL_BINDINGS:
21  unittest.main()


pinocchio
Author(s):
autogenerated on Fri Jun 23 2023 02:38:28