EAIK 0.0.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (46) hide show
  1. eaik-0.0.1/MANIFEST.in +1 -0
  2. eaik-0.0.1/PKG-INFO +108 -0
  3. eaik-0.0.1/README.md +89 -0
  4. eaik-0.0.1/external/EAIK/.git +1 -0
  5. eaik-0.0.1/external/EAIK/.gitignore +8 -0
  6. eaik-0.0.1/external/EAIK/.gitmodules +3 -0
  7. eaik-0.0.1/external/EAIK/LICENSE +674 -0
  8. eaik-0.0.1/external/EAIK/README.md +2 -0
  9. eaik-0.0.1/external/EAIK/Tests/CMakeLists.txt +24 -0
  10. eaik-0.0.1/external/EAIK/Tests/IK_system_tests.cpp +252 -0
  11. eaik-0.0.1/external/EAIK/Tests/IK_unit_tests.cpp +369 -0
  12. eaik-0.0.1/external/EAIK/external/ik-geo/.git +1 -0
  13. eaik-0.0.1/external/EAIK/external/ik-geo/.gitignore +43 -0
  14. eaik-0.0.1/external/EAIK/external/ik-geo/LICENSE +29 -0
  15. eaik-0.0.1/external/EAIK/external/ik-geo/README.md +60 -0
  16. eaik-0.0.1/external/EAIK/external/ik-geo/cpp/subproblems/CMakeLists.txt +13 -0
  17. eaik-0.0.1/external/EAIK/external/ik-geo/cpp/subproblems/sp.cpp +950 -0
  18. eaik-0.0.1/external/EAIK/external/ik-geo/cpp/subproblems/sp.h +237 -0
  19. eaik-0.0.1/external/EAIK/src/CMakeLists.txt +16 -0
  20. eaik-0.0.1/external/EAIK/src/EAIK.cpp +50 -0
  21. eaik-0.0.1/external/EAIK/src/EAIK.h +28 -0
  22. eaik-0.0.1/external/EAIK/src/IK/CMakeLists.txt +16 -0
  23. eaik-0.0.1/external/EAIK/src/IK/General_IK.cpp +155 -0
  24. eaik-0.0.1/external/EAIK/src/IK/IKS.h +41 -0
  25. eaik-0.0.1/external/EAIK/src/IK/Spherical_IK.cpp +261 -0
  26. eaik-0.0.1/external/EAIK/src/utils/kinematic_remodelling.cpp +105 -0
  27. eaik-0.0.1/external/EAIK/src/utils/kinematic_remodelling.h +16 -0
  28. eaik-0.0.1/pyproject.toml +29 -0
  29. eaik-0.0.1/setup.cfg +4 -0
  30. eaik-0.0.1/setup.py +20 -0
  31. eaik-0.0.1/src/EAIK.egg-info/PKG-INFO +108 -0
  32. eaik-0.0.1/src/EAIK.egg-info/SOURCES.txt +44 -0
  33. eaik-0.0.1/src/EAIK.egg-info/dependency_links.txt +1 -0
  34. eaik-0.0.1/src/EAIK.egg-info/requires.txt +5 -0
  35. eaik-0.0.1/src/EAIK.egg-info/top_level.txt +1 -0
  36. eaik-0.0.1/src/eaik/IK_CSV.py +97 -0
  37. eaik-0.0.1/src/eaik/IK_URDF.py +47 -0
  38. eaik-0.0.1/src/eaik/__init__.py +3 -0
  39. eaik-0.0.1/src/eaik/cpp/eaik_pybindings.cpp +56 -0
  40. eaik-0.0.1/src/eaik/examples/evaluate_ik.py +49 -0
  41. eaik-0.0.1/src/eaik/examples/load_urdf.py +52 -0
  42. eaik-0.0.1/src/eaik/examples/robot_csv.py +79 -0
  43. eaik-0.0.1/tests/test_axis_convention_trafo.py +115 -0
  44. eaik-0.0.1/tests/test_sphericalwrist_first_intersection.py +123 -0
  45. eaik-0.0.1/tests/test_sphericalwrist_generation.py +28 -0
  46. eaik-0.0.1/tests/test_sphericalwrist_second_intersection.py +199 -0
eaik-0.0.1/MANIFEST.in ADDED
@@ -0,0 +1 @@
1
+ graft external/EAIK
eaik-0.0.1/PKG-INFO ADDED
@@ -0,0 +1,108 @@
1
+ Metadata-Version: 2.1
2
+ Name: EAIK
3
+ Version: 0.0.1
4
+ Summary: Toolbox for Efficient Analytical Inverse Kinematics by Subproblem Decomposition.
5
+ Author-email: Daniel Ostermeier <daniel.sebastian.ostermeier@tum.de>
6
+ Project-URL: Homepage, https://eaik.cps.cit.tum.de
7
+ Project-URL: Repository, https://github.com/OstermD/EAIK
8
+ Keywords: Analytical Inverse Kinematic,Inverse Kinematic,Robot Kinematic
9
+ Classifier: Programming Language :: Python
10
+ Classifier: Programming Language :: Python :: 3
11
+ Classifier: Programming Language :: Python :: 3 :: Only
12
+ Requires-Python: >=3.8
13
+ Description-Content-Type: text/markdown
14
+ Requires-Dist: numpy>=1.21.0
15
+ Requires-Dist: urchin>=0.0.27
16
+ Requires-Dist: setuptools
17
+ Requires-Dist: pybind11>=2.10.0
18
+ Requires-Dist: pybind11-stubgen>=0.13.0
19
+
20
+ # EAIK: A Toolbox for Efficient Analytical Inverse Kinematics
21
+ This is a preliminary version of the implementation of the EAIK toolbox. The functionality is currently limited and will be extended during the next weeks! Keep updated to not miss out!
22
+ See our [Project page](https://https://eaik.cps.tum.de/) fore further information.
23
+
24
+ ## Overview
25
+ The problem of calculating the inverse kinematics appears for any manipulator with arbitrary degrees of freedom.
26
+ This problem might have exactly one, multiple, infinite, or no solution at all depending on the number of joints, their types, and their respective placement ( i.e., the manipulator's joint configuration).
27
+
28
+ Due to this characteristic of the inverse kinematic problem, the existence of a closed-form solution is not guaranteed.
29
+ Current methods for general closed-form derivation comprise the above-mentioned requirements in their final solution (given a solvable manipulator) but suffer from complex setup procedures.
30
+ With this toolbox, we propose a method for automatic inverse kinematic derivation.
31
+ We exploit intersecting and parallel axes to remodel a manipulator's kinematic chain.
32
+
33
+ This allows us for a hard-coded decomposition of its inverse kinematics into pre-solved subproblems.
34
+ This approach surpasses current analytical methods in terms of usability and derivation speed without compromising on computation time or the completeness of the overall solution set.
35
+
36
+ ## Credits
37
+ See our [Project page](https://https://eaik.cps.tum.de/) fore further information.
38
+
39
+ We adopt the solutions and overall canonical subproblem set from [Elias et al.](https://arxiv.org/abs/2211.05737).
40
+ Check out their publication and [implementation](https://github.com/rpiRobotics/ik-geo).
41
+
42
+ ## Example
43
+ We currently provide support for CSV files containing the homogeneous transformations of each joint in zero-pose with respect to the basis, as well as [ROS URDF](http://wiki.ros.org/urdf) files.
44
+
45
+ #### URDF
46
+ ```
47
+ import numpy as np
48
+ import random
49
+
50
+ from eaik.IK_URDF import Robot
51
+
52
+ def test_urdf(path, batch_size):
53
+
54
+ bot = Robot(path)
55
+
56
+ # Example desired pose
57
+ test_angles = []
58
+ for i in range(batch_size):
59
+ rand_angles = np.array([random.random(), random.random(), random.random(), random.random(), random.random(), random.random()])
60
+ rand_angles *= 2*np.pi
61
+ test_angles.append(rand_angles)
62
+ poses = []
63
+ for angles in test_angles:
64
+ poses.append(bot.fwdKin(angles))
65
+
66
+ for pose in poses:
67
+ ik_solution = bot.IK(pose)
68
+
69
+ test_urdf("../tests/UR5.urdf", 100)
70
+ ```
71
+
72
+ #### CSV
73
+
74
+ ```
75
+ from eaik.IK_CSV import Robot
76
+ import numpy as np
77
+ import csv
78
+
79
+ def load_test_csv(path):
80
+ bot = Robot(path, False)
81
+
82
+ total_num_ls = 0
83
+ error_sum = 0
84
+ total_num_analytic = 0
85
+ num_no_solution = 0
86
+ with open(path, newline='') as csvfile:
87
+ reader = csv.DictReader(csvfile)
88
+
89
+ T01 = None
90
+ T02 = None
91
+ T03 = None
92
+ T04 = None
93
+ T05 = None
94
+ T06 = None
95
+
96
+ for row in reader:
97
+ T06 = np.array([[np.float64(row['6-T00']), np.float64(row['6-T01']), np.float64(row['6-T02']), np.float64(row['6-T03'])],
98
+ [np.float64(row['6-T10']), np.float64(row['6-T11']), np.float64(row['6-T12']), np.float64(row['6-T13'])],
99
+ [np.float64(row['6-T20']), np.float64(row['6-T21']), np.float64(row['6-T22']), np.float64(row['6-T23'])],
100
+ [np.float64(row['6-T30']), np.float64(row['6-T31']), np.float64(row['6-T32']), np.float64(row['6-T33'])]])
101
+
102
+
103
+ ik_solutions = bot.IK(T06)
104
+
105
+
106
+ load_test_csv("./tests/robot_1.csv")
107
+
108
+ ```
eaik-0.0.1/README.md ADDED
@@ -0,0 +1,89 @@
1
+ # EAIK: A Toolbox for Efficient Analytical Inverse Kinematics
2
+ This is a preliminary version of the implementation of the EAIK toolbox. The functionality is currently limited and will be extended during the next weeks! Keep updated to not miss out!
3
+ See our [Project page](https://https://eaik.cps.tum.de/) fore further information.
4
+
5
+ ## Overview
6
+ The problem of calculating the inverse kinematics appears for any manipulator with arbitrary degrees of freedom.
7
+ This problem might have exactly one, multiple, infinite, or no solution at all depending on the number of joints, their types, and their respective placement ( i.e., the manipulator's joint configuration).
8
+
9
+ Due to this characteristic of the inverse kinematic problem, the existence of a closed-form solution is not guaranteed.
10
+ Current methods for general closed-form derivation comprise the above-mentioned requirements in their final solution (given a solvable manipulator) but suffer from complex setup procedures.
11
+ With this toolbox, we propose a method for automatic inverse kinematic derivation.
12
+ We exploit intersecting and parallel axes to remodel a manipulator's kinematic chain.
13
+
14
+ This allows us for a hard-coded decomposition of its inverse kinematics into pre-solved subproblems.
15
+ This approach surpasses current analytical methods in terms of usability and derivation speed without compromising on computation time or the completeness of the overall solution set.
16
+
17
+ ## Credits
18
+ See our [Project page](https://https://eaik.cps.tum.de/) fore further information.
19
+
20
+ We adopt the solutions and overall canonical subproblem set from [Elias et al.](https://arxiv.org/abs/2211.05737).
21
+ Check out their publication and [implementation](https://github.com/rpiRobotics/ik-geo).
22
+
23
+ ## Example
24
+ We currently provide support for CSV files containing the homogeneous transformations of each joint in zero-pose with respect to the basis, as well as [ROS URDF](http://wiki.ros.org/urdf) files.
25
+
26
+ #### URDF
27
+ ```
28
+ import numpy as np
29
+ import random
30
+
31
+ from eaik.IK_URDF import Robot
32
+
33
+ def test_urdf(path, batch_size):
34
+
35
+ bot = Robot(path)
36
+
37
+ # Example desired pose
38
+ test_angles = []
39
+ for i in range(batch_size):
40
+ rand_angles = np.array([random.random(), random.random(), random.random(), random.random(), random.random(), random.random()])
41
+ rand_angles *= 2*np.pi
42
+ test_angles.append(rand_angles)
43
+ poses = []
44
+ for angles in test_angles:
45
+ poses.append(bot.fwdKin(angles))
46
+
47
+ for pose in poses:
48
+ ik_solution = bot.IK(pose)
49
+
50
+ test_urdf("../tests/UR5.urdf", 100)
51
+ ```
52
+
53
+ #### CSV
54
+
55
+ ```
56
+ from eaik.IK_CSV import Robot
57
+ import numpy as np
58
+ import csv
59
+
60
+ def load_test_csv(path):
61
+ bot = Robot(path, False)
62
+
63
+ total_num_ls = 0
64
+ error_sum = 0
65
+ total_num_analytic = 0
66
+ num_no_solution = 0
67
+ with open(path, newline='') as csvfile:
68
+ reader = csv.DictReader(csvfile)
69
+
70
+ T01 = None
71
+ T02 = None
72
+ T03 = None
73
+ T04 = None
74
+ T05 = None
75
+ T06 = None
76
+
77
+ for row in reader:
78
+ T06 = np.array([[np.float64(row['6-T00']), np.float64(row['6-T01']), np.float64(row['6-T02']), np.float64(row['6-T03'])],
79
+ [np.float64(row['6-T10']), np.float64(row['6-T11']), np.float64(row['6-T12']), np.float64(row['6-T13'])],
80
+ [np.float64(row['6-T20']), np.float64(row['6-T21']), np.float64(row['6-T22']), np.float64(row['6-T23'])],
81
+ [np.float64(row['6-T30']), np.float64(row['6-T31']), np.float64(row['6-T32']), np.float64(row['6-T33'])]])
82
+
83
+
84
+ ik_solutions = bot.IK(T06)
85
+
86
+
87
+ load_test_csv("./tests/robot_1.csv")
88
+
89
+ ```
@@ -0,0 +1 @@
1
+ gitdir: ../../.git/modules/external/EAIK
@@ -0,0 +1,8 @@
1
+ # Binary files
2
+ *.out
3
+
4
+ # build files
5
+ *build/
6
+
7
+ # .vscode files
8
+ *.vscode/
@@ -0,0 +1,3 @@
1
+ [submodule "external/ik-geo"]
2
+ path = external/ik-geo
3
+ url = git@github.com:OstermD/ik-geo.git