roboticstoolbox-python 1.3.0__cp312-cp312-win_amd64.whl

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 (673) hide show
  1. roboticstoolbox/__init__.py +104 -0
  2. roboticstoolbox/backends/Connector.py +107 -0
  3. roboticstoolbox/backends/Dynamixel/README.md +9 -0
  4. roboticstoolbox/backends/Dynamixel/dynamixel.json +581 -0
  5. roboticstoolbox/backends/Dynamixel/dynamixel_io.py +450 -0
  6. roboticstoolbox/backends/Dynamixel/dynamixel_sdk/LICENSE +201 -0
  7. roboticstoolbox/backends/Dynamixel/dynamixel_sdk/README.md +28 -0
  8. roboticstoolbox/backends/Dynamixel/dynamixel_sdk/ReleaseNote.md +181 -0
  9. roboticstoolbox/backends/Dynamixel/dynamixel_sdk/__init__.py +27 -0
  10. roboticstoolbox/backends/Dynamixel/dynamixel_sdk/group_bulk_read.py +163 -0
  11. roboticstoolbox/backends/Dynamixel/dynamixel_sdk/group_bulk_write.py +109 -0
  12. roboticstoolbox/backends/Dynamixel/dynamixel_sdk/group_sync_read.py +166 -0
  13. roboticstoolbox/backends/Dynamixel/dynamixel_sdk/group_sync_write.py +99 -0
  14. roboticstoolbox/backends/Dynamixel/dynamixel_sdk/packet_handler.py +33 -0
  15. roboticstoolbox/backends/Dynamixel/dynamixel_sdk/port_handler.py +155 -0
  16. roboticstoolbox/backends/Dynamixel/dynamixel_sdk/protocol1_packet_handler.py +548 -0
  17. roboticstoolbox/backends/Dynamixel/dynamixel_sdk/protocol2_packet_handler.py +1080 -0
  18. roboticstoolbox/backends/Dynamixel/dynamixel_sdk/robotis_def.py +75 -0
  19. roboticstoolbox/backends/Dynamixel/dyndata.py +121 -0
  20. roboticstoolbox/backends/PyPlot/EllipsePlot.py +253 -0
  21. roboticstoolbox/backends/PyPlot/PyPlot.py +769 -0
  22. roboticstoolbox/backends/PyPlot/PyPlot2.py +526 -0
  23. roboticstoolbox/backends/PyPlot/README.md +67 -0
  24. roboticstoolbox/backends/PyPlot/RobotPlot.py +247 -0
  25. roboticstoolbox/backends/PyPlot/RobotPlot2.py +123 -0
  26. roboticstoolbox/backends/PyPlot/__init__.py +4 -0
  27. roboticstoolbox/backends/ROS/ROS.py +129 -0
  28. roboticstoolbox/backends/ROS/__init__.py +3 -0
  29. roboticstoolbox/backends/__init__.py +39 -0
  30. roboticstoolbox/backends/swift/__init__.py +26 -0
  31. roboticstoolbox/bin/__init__.py +0 -0
  32. roboticstoolbox/bin/rtbtool.py +307 -0
  33. roboticstoolbox/blocks/Icons/250x250/armplot.png +0 -0
  34. roboticstoolbox/blocks/Icons/250x250/bicycle.png +0 -0
  35. roboticstoolbox/blocks/Icons/250x250/camera.png +0 -0
  36. roboticstoolbox/blocks/Icons/250x250/circlepath.png +0 -0
  37. roboticstoolbox/blocks/Icons/250x250/coriolis.png +0 -0
  38. roboticstoolbox/blocks/Icons/250x250/ctraj.png +0 -0
  39. roboticstoolbox/blocks/Icons/250x250/delta2tr.png +0 -0
  40. roboticstoolbox/blocks/Icons/250x250/diffsteer.png +0 -0
  41. roboticstoolbox/blocks/Icons/250x250/fdyn.png +0 -0
  42. roboticstoolbox/blocks/Icons/250x250/fdynx.png +0 -0
  43. roboticstoolbox/blocks/Icons/250x250/fkine.png +0 -0
  44. roboticstoolbox/blocks/Icons/250x250/gravload.png +0 -0
  45. roboticstoolbox/blocks/Icons/250x250/idyn.png +0 -0
  46. roboticstoolbox/blocks/Icons/250x250/idynx.png +0 -0
  47. roboticstoolbox/blocks/Icons/250x250/ikine.png +0 -0
  48. roboticstoolbox/blocks/Icons/250x250/inertia.png +0 -0
  49. roboticstoolbox/blocks/Icons/250x250/jacobian.png +0 -0
  50. roboticstoolbox/blocks/Icons/250x250/jtraj.png +0 -0
  51. roboticstoolbox/blocks/Icons/250x250/lspb.png +0 -0
  52. roboticstoolbox/blocks/Icons/250x250/multirotor.png +0 -0
  53. roboticstoolbox/blocks/Icons/250x250/multirotormixer.png +0 -0
  54. roboticstoolbox/blocks/Icons/250x250/multirotorplot.png +0 -0
  55. roboticstoolbox/blocks/Icons/250x250/point2tr.png +0 -0
  56. roboticstoolbox/blocks/Icons/250x250/tr2delta.png +0 -0
  57. roboticstoolbox/blocks/Icons/250x250/tr2t.png +0 -0
  58. roboticstoolbox/blocks/Icons/250x250/unicycle.png +0 -0
  59. roboticstoolbox/blocks/Icons/250x250/vehicleplot.png +0 -0
  60. roboticstoolbox/blocks/Icons/50x50/armplot.png +0 -0
  61. roboticstoolbox/blocks/Icons/50x50/bicycle.png +0 -0
  62. roboticstoolbox/blocks/Icons/50x50/camera.png +0 -0
  63. roboticstoolbox/blocks/Icons/50x50/circlepath.png +0 -0
  64. roboticstoolbox/blocks/Icons/50x50/coriolis.png +0 -0
  65. roboticstoolbox/blocks/Icons/50x50/delta2tr.png +0 -0
  66. roboticstoolbox/blocks/Icons/50x50/diffsteer.png +0 -0
  67. roboticstoolbox/blocks/Icons/50x50/fdyn.png +0 -0
  68. roboticstoolbox/blocks/Icons/50x50/fdynx.png +0 -0
  69. roboticstoolbox/blocks/Icons/50x50/fkine.png +0 -0
  70. roboticstoolbox/blocks/Icons/50x50/gravload.png +0 -0
  71. roboticstoolbox/blocks/Icons/50x50/idyn.png +0 -0
  72. roboticstoolbox/blocks/Icons/50x50/idynx.png +0 -0
  73. roboticstoolbox/blocks/Icons/50x50/ikine.png +0 -0
  74. roboticstoolbox/blocks/Icons/50x50/inertia.png +0 -0
  75. roboticstoolbox/blocks/Icons/50x50/jacobian.png +0 -0
  76. roboticstoolbox/blocks/Icons/50x50/jtraj.png +0 -0
  77. roboticstoolbox/blocks/Icons/50x50/lspb.png +0 -0
  78. roboticstoolbox/blocks/Icons/50x50/multirotor.png +0 -0
  79. roboticstoolbox/blocks/Icons/50x50/multirotormixer.png +0 -0
  80. roboticstoolbox/blocks/Icons/50x50/multirotorplot.png +0 -0
  81. roboticstoolbox/blocks/Icons/50x50/point2tr.png +0 -0
  82. roboticstoolbox/blocks/Icons/50x50/tr2delta.png +0 -0
  83. roboticstoolbox/blocks/Icons/50x50/tr2t.png +0 -0
  84. roboticstoolbox/blocks/Icons/50x50/unicycle.png +0 -0
  85. roboticstoolbox/blocks/Icons/50x50/vehicleplot.png +0 -0
  86. roboticstoolbox/blocks/Icons/armplot.png +0 -0
  87. roboticstoolbox/blocks/Icons/bicycle.png +0 -0
  88. roboticstoolbox/blocks/Icons/camera.png +0 -0
  89. roboticstoolbox/blocks/Icons/circlepath.png +0 -0
  90. roboticstoolbox/blocks/Icons/coriolis.png +0 -0
  91. roboticstoolbox/blocks/Icons/ctraj.png +0 -0
  92. roboticstoolbox/blocks/Icons/delta2tr.png +0 -0
  93. roboticstoolbox/blocks/Icons/diffsteer.png +0 -0
  94. roboticstoolbox/blocks/Icons/fdyn.png +0 -0
  95. roboticstoolbox/blocks/Icons/fdynx.png +0 -0
  96. roboticstoolbox/blocks/Icons/fkine.png +0 -0
  97. roboticstoolbox/blocks/Icons/gravload.png +0 -0
  98. roboticstoolbox/blocks/Icons/idyn.png +0 -0
  99. roboticstoolbox/blocks/Icons/idynx.png +0 -0
  100. roboticstoolbox/blocks/Icons/ikine.png +0 -0
  101. roboticstoolbox/blocks/Icons/inertia.png +0 -0
  102. roboticstoolbox/blocks/Icons/jacobian.png +0 -0
  103. roboticstoolbox/blocks/Icons/jtraj.png +0 -0
  104. roboticstoolbox/blocks/Icons/lspb.png +0 -0
  105. roboticstoolbox/blocks/Icons/multirotor.png +0 -0
  106. roboticstoolbox/blocks/Icons/multirotormixer.png +0 -0
  107. roboticstoolbox/blocks/Icons/multirotorplot.png +0 -0
  108. roboticstoolbox/blocks/Icons/point2tr.png +0 -0
  109. roboticstoolbox/blocks/Icons/tr2delta.png +0 -0
  110. roboticstoolbox/blocks/Icons/tr2t.png +0 -0
  111. roboticstoolbox/blocks/Icons/unicycle.png +0 -0
  112. roboticstoolbox/blocks/Icons/vehicleplot.png +0 -0
  113. roboticstoolbox/blocks/README.md +43 -0
  114. roboticstoolbox/blocks/__init__.py +6 -0
  115. roboticstoolbox/blocks/arm.py +1587 -0
  116. roboticstoolbox/blocks/mobile.py +500 -0
  117. roboticstoolbox/blocks/quad_model.py +132 -0
  118. roboticstoolbox/blocks/spatial.py +245 -0
  119. roboticstoolbox/blocks/uav.py +949 -0
  120. roboticstoolbox/core/Eigen/Cholesky +45 -0
  121. roboticstoolbox/core/Eigen/CholmodSupport +48 -0
  122. roboticstoolbox/core/Eigen/Core +384 -0
  123. roboticstoolbox/core/Eigen/Dense +7 -0
  124. roboticstoolbox/core/Eigen/Eigen +2 -0
  125. roboticstoolbox/core/Eigen/Eigenvalues +60 -0
  126. roboticstoolbox/core/Eigen/Geometry +59 -0
  127. roboticstoolbox/core/Eigen/Householder +29 -0
  128. roboticstoolbox/core/Eigen/IterativeLinearSolvers +48 -0
  129. roboticstoolbox/core/Eigen/Jacobi +32 -0
  130. roboticstoolbox/core/Eigen/KLUSupport +41 -0
  131. roboticstoolbox/core/Eigen/LU +47 -0
  132. roboticstoolbox/core/Eigen/MetisSupport +35 -0
  133. roboticstoolbox/core/Eigen/OrderingMethods +70 -0
  134. roboticstoolbox/core/Eigen/PaStiXSupport +49 -0
  135. roboticstoolbox/core/Eigen/PardisoSupport +35 -0
  136. roboticstoolbox/core/Eigen/QR +50 -0
  137. roboticstoolbox/core/Eigen/QtAlignedMalloc +39 -0
  138. roboticstoolbox/core/Eigen/SPQRSupport +34 -0
  139. roboticstoolbox/core/Eigen/SVD +50 -0
  140. roboticstoolbox/core/Eigen/Sparse +34 -0
  141. roboticstoolbox/core/Eigen/SparseCholesky +37 -0
  142. roboticstoolbox/core/Eigen/SparseCore +69 -0
  143. roboticstoolbox/core/Eigen/SparseLU +50 -0
  144. roboticstoolbox/core/Eigen/SparseQR +36 -0
  145. roboticstoolbox/core/Eigen/StdDeque +27 -0
  146. roboticstoolbox/core/Eigen/StdList +26 -0
  147. roboticstoolbox/core/Eigen/StdVector +27 -0
  148. roboticstoolbox/core/Eigen/SuperLUSupport +64 -0
  149. roboticstoolbox/core/Eigen/UmfPackSupport +40 -0
  150. roboticstoolbox/core/Eigen/src/Cholesky/LDLT.h +688 -0
  151. roboticstoolbox/core/Eigen/src/Cholesky/LLT.h +558 -0
  152. roboticstoolbox/core/Eigen/src/Cholesky/LLT_LAPACKE.h +99 -0
  153. roboticstoolbox/core/Eigen/src/CholmodSupport/CholmodSupport.h +682 -0
  154. roboticstoolbox/core/Eigen/src/Core/ArithmeticSequence.h +413 -0
  155. roboticstoolbox/core/Eigen/src/Core/Array.h +417 -0
  156. roboticstoolbox/core/Eigen/src/Core/ArrayBase.h +226 -0
  157. roboticstoolbox/core/Eigen/src/Core/ArrayWrapper.h +209 -0
  158. roboticstoolbox/core/Eigen/src/Core/Assign.h +90 -0
  159. roboticstoolbox/core/Eigen/src/Core/AssignEvaluator.h +1010 -0
  160. roboticstoolbox/core/Eigen/src/Core/Assign_MKL.h +178 -0
  161. roboticstoolbox/core/Eigen/src/Core/BandMatrix.h +353 -0
  162. roboticstoolbox/core/Eigen/src/Core/Block.h +448 -0
  163. roboticstoolbox/core/Eigen/src/Core/BooleanRedux.h +162 -0
  164. roboticstoolbox/core/Eigen/src/Core/CommaInitializer.h +164 -0
  165. roboticstoolbox/core/Eigen/src/Core/ConditionEstimator.h +175 -0
  166. roboticstoolbox/core/Eigen/src/Core/CoreEvaluators.h +1741 -0
  167. roboticstoolbox/core/Eigen/src/Core/CoreIterators.h +132 -0
  168. roboticstoolbox/core/Eigen/src/Core/CwiseBinaryOp.h +183 -0
  169. roboticstoolbox/core/Eigen/src/Core/CwiseNullaryOp.h +1001 -0
  170. roboticstoolbox/core/Eigen/src/Core/CwiseTernaryOp.h +197 -0
  171. roboticstoolbox/core/Eigen/src/Core/CwiseUnaryOp.h +103 -0
  172. roboticstoolbox/core/Eigen/src/Core/CwiseUnaryView.h +132 -0
  173. roboticstoolbox/core/Eigen/src/Core/DenseBase.h +701 -0
  174. roboticstoolbox/core/Eigen/src/Core/DenseCoeffsBase.h +685 -0
  175. roboticstoolbox/core/Eigen/src/Core/DenseStorage.h +652 -0
  176. roboticstoolbox/core/Eigen/src/Core/Diagonal.h +258 -0
  177. roboticstoolbox/core/Eigen/src/Core/DiagonalMatrix.h +391 -0
  178. roboticstoolbox/core/Eigen/src/Core/DiagonalProduct.h +28 -0
  179. roboticstoolbox/core/Eigen/src/Core/Dot.h +318 -0
  180. roboticstoolbox/core/Eigen/src/Core/EigenBase.h +160 -0
  181. roboticstoolbox/core/Eigen/src/Core/ForceAlignedAccess.h +150 -0
  182. roboticstoolbox/core/Eigen/src/Core/Fuzzy.h +155 -0
  183. roboticstoolbox/core/Eigen/src/Core/GeneralProduct.h +465 -0
  184. roboticstoolbox/core/Eigen/src/Core/GenericPacketMath.h +1040 -0
  185. roboticstoolbox/core/Eigen/src/Core/GlobalFunctions.h +194 -0
  186. roboticstoolbox/core/Eigen/src/Core/IO.h +258 -0
  187. roboticstoolbox/core/Eigen/src/Core/IndexedView.h +237 -0
  188. roboticstoolbox/core/Eigen/src/Core/Inverse.h +117 -0
  189. roboticstoolbox/core/Eigen/src/Core/Map.h +171 -0
  190. roboticstoolbox/core/Eigen/src/Core/MapBase.h +310 -0
  191. roboticstoolbox/core/Eigen/src/Core/MathFunctions.h +2057 -0
  192. roboticstoolbox/core/Eigen/src/Core/MathFunctionsImpl.h +200 -0
  193. roboticstoolbox/core/Eigen/src/Core/Matrix.h +565 -0
  194. roboticstoolbox/core/Eigen/src/Core/MatrixBase.h +547 -0
  195. roboticstoolbox/core/Eigen/src/Core/NestByValue.h +85 -0
  196. roboticstoolbox/core/Eigen/src/Core/NoAlias.h +109 -0
  197. roboticstoolbox/core/Eigen/src/Core/NumTraits.h +335 -0
  198. roboticstoolbox/core/Eigen/src/Core/PartialReduxEvaluator.h +232 -0
  199. roboticstoolbox/core/Eigen/src/Core/PermutationMatrix.h +605 -0
  200. roboticstoolbox/core/Eigen/src/Core/PlainObjectBase.h +1128 -0
  201. roboticstoolbox/core/Eigen/src/Core/Product.h +191 -0
  202. roboticstoolbox/core/Eigen/src/Core/ProductEvaluators.h +1179 -0
  203. roboticstoolbox/core/Eigen/src/Core/Random.h +218 -0
  204. roboticstoolbox/core/Eigen/src/Core/Redux.h +515 -0
  205. roboticstoolbox/core/Eigen/src/Core/Ref.h +381 -0
  206. roboticstoolbox/core/Eigen/src/Core/Replicate.h +142 -0
  207. roboticstoolbox/core/Eigen/src/Core/Reshaped.h +454 -0
  208. roboticstoolbox/core/Eigen/src/Core/ReturnByValue.h +119 -0
  209. roboticstoolbox/core/Eigen/src/Core/Reverse.h +217 -0
  210. roboticstoolbox/core/Eigen/src/Core/Select.h +164 -0
  211. roboticstoolbox/core/Eigen/src/Core/SelfAdjointView.h +365 -0
  212. roboticstoolbox/core/Eigen/src/Core/SelfCwiseBinaryOp.h +47 -0
  213. roboticstoolbox/core/Eigen/src/Core/Solve.h +188 -0
  214. roboticstoolbox/core/Eigen/src/Core/SolveTriangular.h +235 -0
  215. roboticstoolbox/core/Eigen/src/Core/SolverBase.h +168 -0
  216. roboticstoolbox/core/Eigen/src/Core/StableNorm.h +251 -0
  217. roboticstoolbox/core/Eigen/src/Core/StlIterators.h +463 -0
  218. roboticstoolbox/core/Eigen/src/Core/Stride.h +116 -0
  219. roboticstoolbox/core/Eigen/src/Core/Swap.h +68 -0
  220. roboticstoolbox/core/Eigen/src/Core/Transpose.h +464 -0
  221. roboticstoolbox/core/Eigen/src/Core/Transpositions.h +386 -0
  222. roboticstoolbox/core/Eigen/src/Core/TriangularMatrix.h +1001 -0
  223. roboticstoolbox/core/Eigen/src/Core/VectorBlock.h +96 -0
  224. roboticstoolbox/core/Eigen/src/Core/VectorwiseOp.h +784 -0
  225. roboticstoolbox/core/Eigen/src/Core/Visitor.h +381 -0
  226. roboticstoolbox/core/Eigen/src/Core/arch/AVX/Complex.h +372 -0
  227. roboticstoolbox/core/Eigen/src/Core/arch/AVX/MathFunctions.h +228 -0
  228. roboticstoolbox/core/Eigen/src/Core/arch/AVX/PacketMath.h +1574 -0
  229. roboticstoolbox/core/Eigen/src/Core/arch/AVX/TypeCasting.h +115 -0
  230. roboticstoolbox/core/Eigen/src/Core/arch/AVX512/Complex.h +422 -0
  231. roboticstoolbox/core/Eigen/src/Core/arch/AVX512/MathFunctions.h +362 -0
  232. roboticstoolbox/core/Eigen/src/Core/arch/AVX512/PacketMath.h +2303 -0
  233. roboticstoolbox/core/Eigen/src/Core/arch/AVX512/TypeCasting.h +89 -0
  234. roboticstoolbox/core/Eigen/src/Core/arch/AltiVec/Complex.h +417 -0
  235. roboticstoolbox/core/Eigen/src/Core/arch/AltiVec/MathFunctions.h +90 -0
  236. roboticstoolbox/core/Eigen/src/Core/arch/AltiVec/MatrixProduct.h +2937 -0
  237. roboticstoolbox/core/Eigen/src/Core/arch/AltiVec/MatrixProductCommon.h +221 -0
  238. roboticstoolbox/core/Eigen/src/Core/arch/AltiVec/MatrixProductMMA.h +629 -0
  239. roboticstoolbox/core/Eigen/src/Core/arch/AltiVec/PacketMath.h +2711 -0
  240. roboticstoolbox/core/Eigen/src/Core/arch/CUDA/Complex.h +258 -0
  241. roboticstoolbox/core/Eigen/src/Core/arch/Default/BFloat16.h +700 -0
  242. roboticstoolbox/core/Eigen/src/Core/arch/Default/ConjHelper.h +117 -0
  243. roboticstoolbox/core/Eigen/src/Core/arch/Default/GenericPacketMathFunctions.h +1649 -0
  244. roboticstoolbox/core/Eigen/src/Core/arch/Default/GenericPacketMathFunctionsFwd.h +110 -0
  245. roboticstoolbox/core/Eigen/src/Core/arch/Default/Half.h +942 -0
  246. roboticstoolbox/core/Eigen/src/Core/arch/Default/Settings.h +49 -0
  247. roboticstoolbox/core/Eigen/src/Core/arch/Default/TypeCasting.h +120 -0
  248. roboticstoolbox/core/Eigen/src/Core/arch/GPU/MathFunctions.h +103 -0
  249. roboticstoolbox/core/Eigen/src/Core/arch/GPU/PacketMath.h +1685 -0
  250. roboticstoolbox/core/Eigen/src/Core/arch/GPU/TypeCasting.h +80 -0
  251. roboticstoolbox/core/Eigen/src/Core/arch/HIP/hcc/math_constants.h +23 -0
  252. roboticstoolbox/core/Eigen/src/Core/arch/MSA/Complex.h +648 -0
  253. roboticstoolbox/core/Eigen/src/Core/arch/MSA/MathFunctions.h +387 -0
  254. roboticstoolbox/core/Eigen/src/Core/arch/MSA/PacketMath.h +1233 -0
  255. roboticstoolbox/core/Eigen/src/Core/arch/NEON/Complex.h +584 -0
  256. roboticstoolbox/core/Eigen/src/Core/arch/NEON/GeneralBlockPanelKernel.h +183 -0
  257. roboticstoolbox/core/Eigen/src/Core/arch/NEON/MathFunctions.h +75 -0
  258. roboticstoolbox/core/Eigen/src/Core/arch/NEON/PacketMath.h +4587 -0
  259. roboticstoolbox/core/Eigen/src/Core/arch/NEON/TypeCasting.h +1419 -0
  260. roboticstoolbox/core/Eigen/src/Core/arch/SSE/Complex.h +351 -0
  261. roboticstoolbox/core/Eigen/src/Core/arch/SSE/MathFunctions.h +199 -0
  262. roboticstoolbox/core/Eigen/src/Core/arch/SSE/PacketMath.h +1505 -0
  263. roboticstoolbox/core/Eigen/src/Core/arch/SSE/TypeCasting.h +142 -0
  264. roboticstoolbox/core/Eigen/src/Core/arch/SVE/MathFunctions.h +44 -0
  265. roboticstoolbox/core/Eigen/src/Core/arch/SVE/PacketMath.h +752 -0
  266. roboticstoolbox/core/Eigen/src/Core/arch/SVE/TypeCasting.h +49 -0
  267. roboticstoolbox/core/Eigen/src/Core/arch/SYCL/InteropHeaders.h +232 -0
  268. roboticstoolbox/core/Eigen/src/Core/arch/SYCL/MathFunctions.h +301 -0
  269. roboticstoolbox/core/Eigen/src/Core/arch/SYCL/PacketMath.h +670 -0
  270. roboticstoolbox/core/Eigen/src/Core/arch/SYCL/SyclMemoryModel.h +694 -0
  271. roboticstoolbox/core/Eigen/src/Core/arch/SYCL/TypeCasting.h +85 -0
  272. roboticstoolbox/core/Eigen/src/Core/arch/ZVector/Complex.h +426 -0
  273. roboticstoolbox/core/Eigen/src/Core/arch/ZVector/MathFunctions.h +233 -0
  274. roboticstoolbox/core/Eigen/src/Core/arch/ZVector/PacketMath.h +1060 -0
  275. roboticstoolbox/core/Eigen/src/Core/functors/AssignmentFunctors.h +177 -0
  276. roboticstoolbox/core/Eigen/src/Core/functors/BinaryFunctors.h +541 -0
  277. roboticstoolbox/core/Eigen/src/Core/functors/NullaryFunctors.h +189 -0
  278. roboticstoolbox/core/Eigen/src/Core/functors/StlFunctors.h +166 -0
  279. roboticstoolbox/core/Eigen/src/Core/functors/TernaryFunctors.h +25 -0
  280. roboticstoolbox/core/Eigen/src/Core/functors/UnaryFunctors.h +1131 -0
  281. roboticstoolbox/core/Eigen/src/Core/products/GeneralBlockPanelKernel.h +2645 -0
  282. roboticstoolbox/core/Eigen/src/Core/products/GeneralMatrixMatrix.h +517 -0
  283. roboticstoolbox/core/Eigen/src/Core/products/GeneralMatrixMatrixTriangular.h +317 -0
  284. roboticstoolbox/core/Eigen/src/Core/products/GeneralMatrixMatrixTriangular_BLAS.h +145 -0
  285. roboticstoolbox/core/Eigen/src/Core/products/GeneralMatrixMatrix_BLAS.h +124 -0
  286. roboticstoolbox/core/Eigen/src/Core/products/GeneralMatrixVector.h +518 -0
  287. roboticstoolbox/core/Eigen/src/Core/products/GeneralMatrixVector_BLAS.h +136 -0
  288. roboticstoolbox/core/Eigen/src/Core/products/Parallelizer.h +180 -0
  289. roboticstoolbox/core/Eigen/src/Core/products/SelfadjointMatrixMatrix.h +544 -0
  290. roboticstoolbox/core/Eigen/src/Core/products/SelfadjointMatrixMatrix_BLAS.h +295 -0
  291. roboticstoolbox/core/Eigen/src/Core/products/SelfadjointMatrixVector.h +262 -0
  292. roboticstoolbox/core/Eigen/src/Core/products/SelfadjointMatrixVector_BLAS.h +118 -0
  293. roboticstoolbox/core/Eigen/src/Core/products/SelfadjointProduct.h +133 -0
  294. roboticstoolbox/core/Eigen/src/Core/products/SelfadjointRank2Update.h +94 -0
  295. roboticstoolbox/core/Eigen/src/Core/products/TriangularMatrixMatrix.h +472 -0
  296. roboticstoolbox/core/Eigen/src/Core/products/TriangularMatrixMatrix_BLAS.h +317 -0
  297. roboticstoolbox/core/Eigen/src/Core/products/TriangularMatrixVector.h +350 -0
  298. roboticstoolbox/core/Eigen/src/Core/products/TriangularMatrixVector_BLAS.h +255 -0
  299. roboticstoolbox/core/Eigen/src/Core/products/TriangularSolverMatrix.h +337 -0
  300. roboticstoolbox/core/Eigen/src/Core/products/TriangularSolverMatrix_BLAS.h +167 -0
  301. roboticstoolbox/core/Eigen/src/Core/products/TriangularSolverVector.h +148 -0
  302. roboticstoolbox/core/Eigen/src/Core/util/BlasUtil.h +583 -0
  303. roboticstoolbox/core/Eigen/src/Core/util/ConfigureVectorization.h +512 -0
  304. roboticstoolbox/core/Eigen/src/Core/util/Constants.h +563 -0
  305. roboticstoolbox/core/Eigen/src/Core/util/DisableStupidWarnings.h +106 -0
  306. roboticstoolbox/core/Eigen/src/Core/util/ForwardDeclarations.h +322 -0
  307. roboticstoolbox/core/Eigen/src/Core/util/IndexedViewHelper.h +186 -0
  308. roboticstoolbox/core/Eigen/src/Core/util/IntegralConstant.h +272 -0
  309. roboticstoolbox/core/Eigen/src/Core/util/MKL_support.h +137 -0
  310. roboticstoolbox/core/Eigen/src/Core/util/Macros.h +1464 -0
  311. roboticstoolbox/core/Eigen/src/Core/util/Memory.h +1163 -0
  312. roboticstoolbox/core/Eigen/src/Core/util/Meta.h +812 -0
  313. roboticstoolbox/core/Eigen/src/Core/util/NonMPL2.h +3 -0
  314. roboticstoolbox/core/Eigen/src/Core/util/ReenableStupidWarnings.h +31 -0
  315. roboticstoolbox/core/Eigen/src/Core/util/ReshapedHelper.h +51 -0
  316. roboticstoolbox/core/Eigen/src/Core/util/StaticAssert.h +221 -0
  317. roboticstoolbox/core/Eigen/src/Core/util/SymbolicIndex.h +293 -0
  318. roboticstoolbox/core/Eigen/src/Core/util/XprHelper.h +856 -0
  319. roboticstoolbox/core/Eigen/src/Eigenvalues/ComplexEigenSolver.h +346 -0
  320. roboticstoolbox/core/Eigen/src/Eigenvalues/ComplexSchur.h +462 -0
  321. roboticstoolbox/core/Eigen/src/Eigenvalues/ComplexSchur_LAPACKE.h +91 -0
  322. roboticstoolbox/core/Eigen/src/Eigenvalues/EigenSolver.h +622 -0
  323. roboticstoolbox/core/Eigen/src/Eigenvalues/GeneralizedEigenSolver.h +418 -0
  324. roboticstoolbox/core/Eigen/src/Eigenvalues/GeneralizedSelfAdjointEigenSolver.h +226 -0
  325. roboticstoolbox/core/Eigen/src/Eigenvalues/HessenbergDecomposition.h +374 -0
  326. roboticstoolbox/core/Eigen/src/Eigenvalues/MatrixBaseEigenvalues.h +158 -0
  327. roboticstoolbox/core/Eigen/src/Eigenvalues/RealQZ.h +657 -0
  328. roboticstoolbox/core/Eigen/src/Eigenvalues/RealSchur.h +558 -0
  329. roboticstoolbox/core/Eigen/src/Eigenvalues/RealSchur_LAPACKE.h +77 -0
  330. roboticstoolbox/core/Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h +904 -0
  331. roboticstoolbox/core/Eigen/src/Eigenvalues/SelfAdjointEigenSolver_LAPACKE.h +87 -0
  332. roboticstoolbox/core/Eigen/src/Eigenvalues/Tridiagonalization.h +561 -0
  333. roboticstoolbox/core/Eigen/src/Geometry/AlignedBox.h +486 -0
  334. roboticstoolbox/core/Eigen/src/Geometry/AngleAxis.h +247 -0
  335. roboticstoolbox/core/Eigen/src/Geometry/EulerAngles.h +114 -0
  336. roboticstoolbox/core/Eigen/src/Geometry/Homogeneous.h +501 -0
  337. roboticstoolbox/core/Eigen/src/Geometry/Hyperplane.h +282 -0
  338. roboticstoolbox/core/Eigen/src/Geometry/OrthoMethods.h +235 -0
  339. roboticstoolbox/core/Eigen/src/Geometry/ParametrizedLine.h +232 -0
  340. roboticstoolbox/core/Eigen/src/Geometry/Quaternion.h +870 -0
  341. roboticstoolbox/core/Eigen/src/Geometry/Rotation2D.h +199 -0
  342. roboticstoolbox/core/Eigen/src/Geometry/RotationBase.h +206 -0
  343. roboticstoolbox/core/Eigen/src/Geometry/Scaling.h +188 -0
  344. roboticstoolbox/core/Eigen/src/Geometry/Transform.h +1563 -0
  345. roboticstoolbox/core/Eigen/src/Geometry/Translation.h +202 -0
  346. roboticstoolbox/core/Eigen/src/Geometry/Umeyama.h +166 -0
  347. roboticstoolbox/core/Eigen/src/Geometry/arch/Geometry_SIMD.h +168 -0
  348. roboticstoolbox/core/Eigen/src/Householder/BlockHouseholder.h +110 -0
  349. roboticstoolbox/core/Eigen/src/Householder/Householder.h +176 -0
  350. roboticstoolbox/core/Eigen/src/Householder/HouseholderSequence.h +545 -0
  351. roboticstoolbox/core/Eigen/src/IterativeLinearSolvers/BasicPreconditioners.h +226 -0
  352. roboticstoolbox/core/Eigen/src/IterativeLinearSolvers/BiCGSTAB.h +212 -0
  353. roboticstoolbox/core/Eigen/src/IterativeLinearSolvers/ConjugateGradient.h +229 -0
  354. roboticstoolbox/core/Eigen/src/IterativeLinearSolvers/IncompleteCholesky.h +394 -0
  355. roboticstoolbox/core/Eigen/src/IterativeLinearSolvers/IncompleteLUT.h +453 -0
  356. roboticstoolbox/core/Eigen/src/IterativeLinearSolvers/IterativeSolverBase.h +444 -0
  357. roboticstoolbox/core/Eigen/src/IterativeLinearSolvers/LeastSquareConjugateGradient.h +198 -0
  358. roboticstoolbox/core/Eigen/src/IterativeLinearSolvers/SolveWithGuess.h +117 -0
  359. roboticstoolbox/core/Eigen/src/Jacobi/Jacobi.h +483 -0
  360. roboticstoolbox/core/Eigen/src/KLUSupport/KLUSupport.h +358 -0
  361. roboticstoolbox/core/Eigen/src/LU/Determinant.h +117 -0
  362. roboticstoolbox/core/Eigen/src/LU/FullPivLU.h +877 -0
  363. roboticstoolbox/core/Eigen/src/LU/InverseImpl.h +432 -0
  364. roboticstoolbox/core/Eigen/src/LU/PartialPivLU.h +624 -0
  365. roboticstoolbox/core/Eigen/src/LU/PartialPivLU_LAPACKE.h +83 -0
  366. roboticstoolbox/core/Eigen/src/LU/arch/InverseSize4.h +351 -0
  367. roboticstoolbox/core/Eigen/src/MetisSupport/MetisSupport.h +137 -0
  368. roboticstoolbox/core/Eigen/src/OrderingMethods/Amd.h +435 -0
  369. roboticstoolbox/core/Eigen/src/OrderingMethods/Eigen_Colamd.h +1863 -0
  370. roboticstoolbox/core/Eigen/src/OrderingMethods/Ordering.h +153 -0
  371. roboticstoolbox/core/Eigen/src/PaStiXSupport/PaStiXSupport.h +678 -0
  372. roboticstoolbox/core/Eigen/src/PardisoSupport/PardisoSupport.h +545 -0
  373. roboticstoolbox/core/Eigen/src/QR/ColPivHouseholderQR.h +674 -0
  374. roboticstoolbox/core/Eigen/src/QR/ColPivHouseholderQR_LAPACKE.h +97 -0
  375. roboticstoolbox/core/Eigen/src/QR/CompleteOrthogonalDecomposition.h +635 -0
  376. roboticstoolbox/core/Eigen/src/QR/FullPivHouseholderQR.h +713 -0
  377. roboticstoolbox/core/Eigen/src/QR/HouseholderQR.h +434 -0
  378. roboticstoolbox/core/Eigen/src/QR/HouseholderQR_LAPACKE.h +68 -0
  379. roboticstoolbox/core/Eigen/src/SPQRSupport/SuiteSparseQRSupport.h +335 -0
  380. roboticstoolbox/core/Eigen/src/SVD/BDCSVD.h +1366 -0
  381. roboticstoolbox/core/Eigen/src/SVD/JacobiSVD.h +812 -0
  382. roboticstoolbox/core/Eigen/src/SVD/JacobiSVD_LAPACKE.h +91 -0
  383. roboticstoolbox/core/Eigen/src/SVD/SVDBase.h +376 -0
  384. roboticstoolbox/core/Eigen/src/SVD/UpperBidiagonalization.h +414 -0
  385. roboticstoolbox/core/Eigen/src/SparseCholesky/SimplicialCholesky.h +697 -0
  386. roboticstoolbox/core/Eigen/src/SparseCholesky/SimplicialCholesky_impl.h +174 -0
  387. roboticstoolbox/core/Eigen/src/SparseCore/AmbiVector.h +378 -0
  388. roboticstoolbox/core/Eigen/src/SparseCore/CompressedStorage.h +274 -0
  389. roboticstoolbox/core/Eigen/src/SparseCore/ConservativeSparseSparseProduct.h +352 -0
  390. roboticstoolbox/core/Eigen/src/SparseCore/MappedSparseMatrix.h +67 -0
  391. roboticstoolbox/core/Eigen/src/SparseCore/SparseAssign.h +270 -0
  392. roboticstoolbox/core/Eigen/src/SparseCore/SparseBlock.h +571 -0
  393. roboticstoolbox/core/Eigen/src/SparseCore/SparseColEtree.h +206 -0
  394. roboticstoolbox/core/Eigen/src/SparseCore/SparseCompressedBase.h +370 -0
  395. roboticstoolbox/core/Eigen/src/SparseCore/SparseCwiseBinaryOp.h +722 -0
  396. roboticstoolbox/core/Eigen/src/SparseCore/SparseCwiseUnaryOp.h +150 -0
  397. roboticstoolbox/core/Eigen/src/SparseCore/SparseDenseProduct.h +342 -0
  398. roboticstoolbox/core/Eigen/src/SparseCore/SparseDiagonalProduct.h +138 -0
  399. roboticstoolbox/core/Eigen/src/SparseCore/SparseDot.h +98 -0
  400. roboticstoolbox/core/Eigen/src/SparseCore/SparseFuzzy.h +29 -0
  401. roboticstoolbox/core/Eigen/src/SparseCore/SparseMap.h +305 -0
  402. roboticstoolbox/core/Eigen/src/SparseCore/SparseMatrix.h +1518 -0
  403. roboticstoolbox/core/Eigen/src/SparseCore/SparseMatrixBase.h +398 -0
  404. roboticstoolbox/core/Eigen/src/SparseCore/SparsePermutation.h +178 -0
  405. roboticstoolbox/core/Eigen/src/SparseCore/SparseProduct.h +181 -0
  406. roboticstoolbox/core/Eigen/src/SparseCore/SparseRedux.h +49 -0
  407. roboticstoolbox/core/Eigen/src/SparseCore/SparseRef.h +397 -0
  408. roboticstoolbox/core/Eigen/src/SparseCore/SparseSelfAdjointView.h +659 -0
  409. roboticstoolbox/core/Eigen/src/SparseCore/SparseSolverBase.h +124 -0
  410. roboticstoolbox/core/Eigen/src/SparseCore/SparseSparseProductWithPruning.h +198 -0
  411. roboticstoolbox/core/Eigen/src/SparseCore/SparseTranspose.h +92 -0
  412. roboticstoolbox/core/Eigen/src/SparseCore/SparseTriangularView.h +189 -0
  413. roboticstoolbox/core/Eigen/src/SparseCore/SparseUtil.h +186 -0
  414. roboticstoolbox/core/Eigen/src/SparseCore/SparseVector.h +478 -0
  415. roboticstoolbox/core/Eigen/src/SparseCore/SparseView.h +254 -0
  416. roboticstoolbox/core/Eigen/src/SparseCore/TriangularSolver.h +315 -0
  417. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU.h +923 -0
  418. roboticstoolbox/core/Eigen/src/SparseLU/SparseLUImpl.h +66 -0
  419. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU_Memory.h +226 -0
  420. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU_Structs.h +110 -0
  421. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU_SupernodalMatrix.h +375 -0
  422. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU_Utils.h +80 -0
  423. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU_column_bmod.h +181 -0
  424. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU_column_dfs.h +179 -0
  425. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU_copy_to_ucol.h +107 -0
  426. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU_gemm_kernel.h +280 -0
  427. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU_heap_relax_snode.h +126 -0
  428. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU_kernel_bmod.h +130 -0
  429. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU_panel_bmod.h +223 -0
  430. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU_panel_dfs.h +258 -0
  431. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU_pivotL.h +137 -0
  432. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU_pruneL.h +136 -0
  433. roboticstoolbox/core/Eigen/src/SparseLU/SparseLU_relax_snode.h +83 -0
  434. roboticstoolbox/core/Eigen/src/SparseQR/SparseQR.h +758 -0
  435. roboticstoolbox/core/Eigen/src/StlSupport/StdDeque.h +116 -0
  436. roboticstoolbox/core/Eigen/src/StlSupport/StdList.h +106 -0
  437. roboticstoolbox/core/Eigen/src/StlSupport/StdVector.h +131 -0
  438. roboticstoolbox/core/Eigen/src/StlSupport/details.h +84 -0
  439. roboticstoolbox/core/Eigen/src/SuperLUSupport/SuperLUSupport.h +1025 -0
  440. roboticstoolbox/core/Eigen/src/UmfPackSupport/UmfPackSupport.h +642 -0
  441. roboticstoolbox/core/Eigen/src/misc/Image.h +82 -0
  442. roboticstoolbox/core/Eigen/src/misc/Kernel.h +79 -0
  443. roboticstoolbox/core/Eigen/src/misc/RealSvd2x2.h +55 -0
  444. roboticstoolbox/core/Eigen/src/misc/blas.h +440 -0
  445. roboticstoolbox/core/Eigen/src/misc/lapack.h +152 -0
  446. roboticstoolbox/core/Eigen/src/misc/lapacke.h +16292 -0
  447. roboticstoolbox/core/Eigen/src/misc/lapacke_mangling.h +17 -0
  448. roboticstoolbox/core/Eigen/src/plugins/ArrayCwiseBinaryOps.h +358 -0
  449. roboticstoolbox/core/Eigen/src/plugins/ArrayCwiseUnaryOps.h +696 -0
  450. roboticstoolbox/core/Eigen/src/plugins/BlockMethods.h +1442 -0
  451. roboticstoolbox/core/Eigen/src/plugins/CommonCwiseBinaryOps.h +115 -0
  452. roboticstoolbox/core/Eigen/src/plugins/CommonCwiseUnaryOps.h +177 -0
  453. roboticstoolbox/core/Eigen/src/plugins/IndexedViewMethods.h +262 -0
  454. roboticstoolbox/core/Eigen/src/plugins/MatrixCwiseBinaryOps.h +152 -0
  455. roboticstoolbox/core/Eigen/src/plugins/MatrixCwiseUnaryOps.h +95 -0
  456. roboticstoolbox/core/Eigen/src/plugins/ReshapedMethods.h +149 -0
  457. roboticstoolbox/core/fknm.cpp +1557 -0
  458. roboticstoolbox/core/fknm.h +55 -0
  459. roboticstoolbox/core/frne.c +351 -0
  460. roboticstoolbox/core/frne.h +96 -0
  461. roboticstoolbox/core/ik.cpp +301 -0
  462. roboticstoolbox/core/ik.h +59 -0
  463. roboticstoolbox/core/linalg.cpp +316 -0
  464. roboticstoolbox/core/linalg.h +64 -0
  465. roboticstoolbox/core/methods.cpp +372 -0
  466. roboticstoolbox/core/methods.h +32 -0
  467. roboticstoolbox/core/ne.c +493 -0
  468. roboticstoolbox/core/structs.cpp +24 -0
  469. roboticstoolbox/core/structs.h +62 -0
  470. roboticstoolbox/core/vmath.c +163 -0
  471. roboticstoolbox/core/vmath.h +32 -0
  472. roboticstoolbox/fknm.cp312-win_amd64.pyd +0 -0
  473. roboticstoolbox/frne.cp312-win_amd64.pyd +0 -0
  474. roboticstoolbox/mobile/Animations.py +485 -0
  475. roboticstoolbox/mobile/Bug2.py +455 -0
  476. roboticstoolbox/mobile/CurvaturePolyPlanner.py +179 -0
  477. roboticstoolbox/mobile/DistanceTransformPlanner.py +395 -0
  478. roboticstoolbox/mobile/DstarPlanner.py +591 -0
  479. roboticstoolbox/mobile/DubinsPlanner.py +474 -0
  480. roboticstoolbox/mobile/EKF.py +1617 -0
  481. roboticstoolbox/mobile/LatticePlanner.py +419 -0
  482. roboticstoolbox/mobile/OccGrid.py +613 -0
  483. roboticstoolbox/mobile/PRMPlanner.py +348 -0
  484. roboticstoolbox/mobile/ParticleFilter.py +706 -0
  485. roboticstoolbox/mobile/PlannerBase.py +1009 -0
  486. roboticstoolbox/mobile/PoseGraph.py +544 -0
  487. roboticstoolbox/mobile/QuinticPolyPlanner.py +349 -0
  488. roboticstoolbox/mobile/RRTPlanner.py +359 -0
  489. roboticstoolbox/mobile/ReedsSheppPlanner.py +545 -0
  490. roboticstoolbox/mobile/Vehicle.py +1909 -0
  491. roboticstoolbox/mobile/__init__.py +193 -0
  492. roboticstoolbox/mobile/drivers.py +390 -0
  493. roboticstoolbox/mobile/landmarkmap.py +181 -0
  494. roboticstoolbox/mobile/sensors.py +771 -0
  495. roboticstoolbox/models/DH/AL5D.py +121 -0
  496. roboticstoolbox/models/DH/Ball.py +87 -0
  497. roboticstoolbox/models/DH/Baxter.py +91 -0
  498. roboticstoolbox/models/DH/Cobra600.py +63 -0
  499. roboticstoolbox/models/DH/Coil.py +80 -0
  500. roboticstoolbox/models/DH/Hyper.py +83 -0
  501. roboticstoolbox/models/DH/Hyper3d.py +85 -0
  502. roboticstoolbox/models/DH/IRB140.py +159 -0
  503. roboticstoolbox/models/DH/Jaco.py +102 -0
  504. roboticstoolbox/models/DH/KR5.py +112 -0
  505. roboticstoolbox/models/DH/LWR4.py +85 -0
  506. roboticstoolbox/models/DH/Mico.py +102 -0
  507. roboticstoolbox/models/DH/Orion5.py +91 -0
  508. roboticstoolbox/models/DH/P8.py +80 -0
  509. roboticstoolbox/models/DH/Panda.py +178 -0
  510. roboticstoolbox/models/DH/Planar2.py +69 -0
  511. roboticstoolbox/models/DH/Planar3.py +51 -0
  512. roboticstoolbox/models/DH/Puma560.py +326 -0
  513. roboticstoolbox/models/DH/README.md +216 -0
  514. roboticstoolbox/models/DH/Sawyer.py +85 -0
  515. roboticstoolbox/models/DH/Stanford.py +147 -0
  516. roboticstoolbox/models/DH/TwoLink.py +109 -0
  517. roboticstoolbox/models/DH/UR10.py +124 -0
  518. roboticstoolbox/models/DH/UR3.py +98 -0
  519. roboticstoolbox/models/DH/UR5.py +98 -0
  520. roboticstoolbox/models/DH/Uprighttl.py +24 -0
  521. roboticstoolbox/models/DH/__init__.py +52 -0
  522. roboticstoolbox/models/ETS/Frankie.py +90 -0
  523. roboticstoolbox/models/ETS/GenericSeven.py +54 -0
  524. roboticstoolbox/models/ETS/Omni.py +74 -0
  525. roboticstoolbox/models/ETS/Panda.py +69 -0
  526. roboticstoolbox/models/ETS/Planar2.py +49 -0
  527. roboticstoolbox/models/ETS/Planar_Y.py +65 -0
  528. roboticstoolbox/models/ETS/Puma560.py +69 -0
  529. roboticstoolbox/models/ETS/XYPanda.py +84 -0
  530. roboticstoolbox/models/ETS/__init__.py +20 -0
  531. roboticstoolbox/models/README.md +9 -0
  532. roboticstoolbox/models/URDF/AL5D.py +54 -0
  533. roboticstoolbox/models/URDF/Fetch.py +70 -0
  534. roboticstoolbox/models/URDF/FetchCamera.py +71 -0
  535. roboticstoolbox/models/URDF/Frankie.py +75 -0
  536. roboticstoolbox/models/URDF/FrankieOmni.py +94 -0
  537. roboticstoolbox/models/URDF/KinovaGen3.py +71 -0
  538. roboticstoolbox/models/URDF/LBR.py +59 -0
  539. roboticstoolbox/models/URDF/Mico.py +68 -0
  540. roboticstoolbox/models/URDF/PR2.py +64 -0
  541. roboticstoolbox/models/URDF/Panda.py +67 -0
  542. roboticstoolbox/models/URDF/Puma560.py +97 -0
  543. roboticstoolbox/models/URDF/UR10.py +53 -0
  544. roboticstoolbox/models/URDF/UR3.py +53 -0
  545. roboticstoolbox/models/URDF/UR5.py +74 -0
  546. roboticstoolbox/models/URDF/Valkyrie.py +84 -0
  547. roboticstoolbox/models/URDF/YuMi.py +109 -0
  548. roboticstoolbox/models/URDF/__init__.py +53 -0
  549. roboticstoolbox/models/URDF/px100.py +56 -0
  550. roboticstoolbox/models/URDF/px150.py +56 -0
  551. roboticstoolbox/models/URDF/rx150.py +56 -0
  552. roboticstoolbox/models/URDF/rx200.py +56 -0
  553. roboticstoolbox/models/URDF/vx300.py +56 -0
  554. roboticstoolbox/models/URDF/vx300s.py +56 -0
  555. roboticstoolbox/models/URDF/wx200.py +56 -0
  556. roboticstoolbox/models/URDF/wx250.py +56 -0
  557. roboticstoolbox/models/URDF/wx250s.py +56 -0
  558. roboticstoolbox/models/__init__.py +7 -0
  559. roboticstoolbox/models/list.py +119 -0
  560. roboticstoolbox/robot/BaseRobot.py +3133 -0
  561. roboticstoolbox/robot/DHFactor.py +522 -0
  562. roboticstoolbox/robot/DHLink.py +981 -0
  563. roboticstoolbox/robot/DHRobot.py +2520 -0
  564. roboticstoolbox/robot/Dynamics.py +1620 -0
  565. roboticstoolbox/robot/ELink.py +23 -0
  566. roboticstoolbox/robot/ERobot.py +25 -0
  567. roboticstoolbox/robot/ET.py +1097 -0
  568. roboticstoolbox/robot/ETS.py +3542 -0
  569. roboticstoolbox/robot/Gripper.py +282 -0
  570. roboticstoolbox/robot/IK.py +1522 -0
  571. roboticstoolbox/robot/Link.py +1698 -0
  572. roboticstoolbox/robot/PoERobot.py +348 -0
  573. roboticstoolbox/robot/Robot.py +2100 -0
  574. roboticstoolbox/robot/RobotKinematics.py +1725 -0
  575. roboticstoolbox/robot/RobotProto.py +92 -0
  576. roboticstoolbox/robot/__init__.py +54 -0
  577. roboticstoolbox/tools/DHFactor.py +375 -0
  578. roboticstoolbox/tools/Ticker.py +53 -0
  579. roboticstoolbox/tools/__init__.py +54 -0
  580. roboticstoolbox/tools/data.py +187 -0
  581. roboticstoolbox/tools/jsingu.py +51 -0
  582. roboticstoolbox/tools/null.py +48 -0
  583. roboticstoolbox/tools/numerical.py +96 -0
  584. roboticstoolbox/tools/p_servo.py +106 -0
  585. roboticstoolbox/tools/params.py +11 -0
  586. roboticstoolbox/tools/plot.py +109 -0
  587. roboticstoolbox/tools/trajectory.py +1152 -0
  588. roboticstoolbox/tools/types.py +13 -0
  589. roboticstoolbox/tools/urdf/__init__.py +45 -0
  590. roboticstoolbox/tools/urdf/tests/data/ur5.urdf +341 -0
  591. roboticstoolbox/tools/urdf/tests/test_urdf.py +116 -0
  592. roboticstoolbox/tools/urdf/urdf.py +1976 -0
  593. roboticstoolbox/tools/urdf/utils.py +50 -0
  594. roboticstoolbox/tools/xacro/__init__.py +1148 -0
  595. roboticstoolbox/tools/xacro/cli.py +128 -0
  596. roboticstoolbox/tools/xacro/color.py +66 -0
  597. roboticstoolbox/tools/xacro/tests/CMakeLists.txt +4 -0
  598. roboticstoolbox/tools/xacro/tests/broken.xacro +1 -0
  599. roboticstoolbox/tools/xacro/tests/emoji.xacro +5 -0
  600. roboticstoolbox/tools/xacro/tests/include1.xacro +4 -0
  601. roboticstoolbox/tools/xacro/tests/include1.xml +1 -0
  602. roboticstoolbox/tools/xacro/tests/include2.xacro +4 -0
  603. roboticstoolbox/tools/xacro/tests/include2.xml +1 -0
  604. roboticstoolbox/tools/xacro/tests/robots/README +4 -0
  605. roboticstoolbox/tools/xacro/tests/robots/pr2/base_v0/base.gazebo.xacro +59 -0
  606. roboticstoolbox/tools/xacro/tests/robots/pr2/base_v0/base.transmission.xacro +24 -0
  607. roboticstoolbox/tools/xacro/tests/robots/pr2/base_v0/base.urdf.xacro +264 -0
  608. roboticstoolbox/tools/xacro/tests/robots/pr2/common.xacro +71 -0
  609. roboticstoolbox/tools/xacro/tests/robots/pr2/forearm_v0/forearm.gazebo.xacro +36 -0
  610. roboticstoolbox/tools/xacro/tests/robots/pr2/forearm_v0/forearm.transmission.xacro +20 -0
  611. roboticstoolbox/tools/xacro/tests/robots/pr2/forearm_v0/forearm.urdf.xacro +130 -0
  612. roboticstoolbox/tools/xacro/tests/robots/pr2/gazebo/gazebo.urdf.xacro +24 -0
  613. roboticstoolbox/tools/xacro/tests/robots/pr2/gripper_v0/gripper.gazebo.xacro +288 -0
  614. roboticstoolbox/tools/xacro/tests/robots/pr2/gripper_v0/gripper.transmission.xacro +50 -0
  615. roboticstoolbox/tools/xacro/tests/robots/pr2/gripper_v0/gripper.urdf.xacro +374 -0
  616. roboticstoolbox/tools/xacro/tests/robots/pr2/head_v0/head.gazebo.xacro +16 -0
  617. roboticstoolbox/tools/xacro/tests/robots/pr2/head_v0/head.transmission.xacro +34 -0
  618. roboticstoolbox/tools/xacro/tests/robots/pr2/head_v0/head.urdf.xacro +147 -0
  619. roboticstoolbox/tools/xacro/tests/robots/pr2/materials.urdf.xacro +52 -0
  620. roboticstoolbox/tools/xacro/tests/robots/pr2/pr2.urdf.xacro +157 -0
  621. roboticstoolbox/tools/xacro/tests/robots/pr2/pr2_1.11.4.xml +3781 -0
  622. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/double_stereo_camera.gazebo.xacro +16 -0
  623. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/double_stereo_camera.urdf.xacro +61 -0
  624. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/head_sensor_package.gazebo.xacro +20 -0
  625. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/head_sensor_package.urdf.xacro +63 -0
  626. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/hokuyo_lx30_laser.gazebo.xacro +39 -0
  627. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/hokuyo_lx30_laser.urdf.xacro +27 -0
  628. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/kinect_camera.gazebo.xacro +87 -0
  629. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/kinect_camera.urdf.xacro +55 -0
  630. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/kinect_prosilica_camera.gazebo.xacro +193 -0
  631. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/kinect_prosilica_camera.urdf.xacro +181 -0
  632. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/microstrain_3dmgx2_imu.gazebo.xacro +20 -0
  633. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/microstrain_3dmgx2_imu.urdf.xacro +25 -0
  634. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/projector_wg6802418.gazebo.xacro +31 -0
  635. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/projector_wg6802418.urdf.xacro +42 -0
  636. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/prosilica_gc2450_camera.gazebo.xacro +43 -0
  637. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/prosilica_gc2450_camera.urdf.xacro +49 -0
  638. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/stereo_camera.gazebo.xacro +23 -0
  639. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/stereo_camera.urdf.xacro +71 -0
  640. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/wge100_camera.gazebo.xacro +46 -0
  641. roboticstoolbox/tools/xacro/tests/robots/pr2/sensors/wge100_camera.urdf.xacro +47 -0
  642. roboticstoolbox/tools/xacro/tests/robots/pr2/shoulder_v0/shoulder.gazebo.xacro +40 -0
  643. roboticstoolbox/tools/xacro/tests/robots/pr2/shoulder_v0/shoulder.transmission.xacro +35 -0
  644. roboticstoolbox/tools/xacro/tests/robots/pr2/shoulder_v0/shoulder.urdf.xacro +167 -0
  645. roboticstoolbox/tools/xacro/tests/robots/pr2/tilting_laser_v0/tilting_laser.gazebo.xacro +11 -0
  646. roboticstoolbox/tools/xacro/tests/robots/pr2/tilting_laser_v0/tilting_laser.transmission.xacro +14 -0
  647. roboticstoolbox/tools/xacro/tests/robots/pr2/tilting_laser_v0/tilting_laser.urdf.xacro +60 -0
  648. roboticstoolbox/tools/xacro/tests/robots/pr2/torso_v0/torso.gazebo.xacro +37 -0
  649. roboticstoolbox/tools/xacro/tests/robots/pr2/torso_v0/torso.transmission.xacro +22 -0
  650. roboticstoolbox/tools/xacro/tests/robots/pr2/torso_v0/torso.urdf.xacro +122 -0
  651. roboticstoolbox/tools/xacro/tests/robots/pr2/upper_arm_v0/upper_arm.gazebo.xacro +39 -0
  652. roboticstoolbox/tools/xacro/tests/robots/pr2/upper_arm_v0/upper_arm.transmission.xacro +28 -0
  653. roboticstoolbox/tools/xacro/tests/robots/pr2/upper_arm_v0/upper_arm.urdf.xacro +173 -0
  654. roboticstoolbox/tools/xacro/tests/settings.yaml +9 -0
  655. roboticstoolbox/tools/xacro/tests/subdir/foo.xacro +3 -0
  656. roboticstoolbox/tools/xacro/tests/subdir/include-recursive.xacro +5 -0
  657. roboticstoolbox/tools/xacro/tests/subdir/include1.xml +1 -0
  658. roboticstoolbox/tools/xacro/tests/test_xacro.py +1418 -0
  659. roboticstoolbox/tools/xacro/xmlutils.py +152 -0
  660. roboticstoolbox_python-1.3.0.dist-info/METADATA +552 -0
  661. roboticstoolbox_python-1.3.0.dist-info/RECORD +673 -0
  662. roboticstoolbox_python-1.3.0.dist-info/WHEEL +5 -0
  663. roboticstoolbox_python-1.3.0.dist-info/entry_points.txt +6 -0
  664. roboticstoolbox_python-1.3.0.dist-info/licenses/LICENSE +21 -0
  665. spatialgeometry/__init__.py +32 -0
  666. spatialgeometry/geom/CollisionShape.py +419 -0
  667. spatialgeometry/geom/SceneGroup.py +26 -0
  668. spatialgeometry/geom/SceneNode.py +315 -0
  669. spatialgeometry/geom/Shape.py +420 -0
  670. spatialgeometry/geom/__init__.py +26 -0
  671. spatialgeometry/scene.py +107 -0
  672. spatialgeometry/tools/__init__.py +0 -0
  673. spatialgeometry/tools/stdout_supress.py +302 -0
@@ -0,0 +1,1009 @@
1
+ """
2
+ Python Navigation Abstract Class
3
+ @Author: Peter Corke
4
+ @Author: Kristian Gibson
5
+ """
6
+
7
+ from abc import ABC
8
+
9
+ # from scipy import integrate
10
+ # from scipy.ndimage import interpolation
11
+ from spatialmath.base.transforms2d import *
12
+ from spatialmath.base.vectors import *
13
+ from spatialmath.base.argcheck import getvector
14
+ from spatialmath.base.graphics import axes_logic, plotvol2, axes_get_scale
15
+
16
+ # from spatialmath import SE2, SE3
17
+ from matplotlib import cm
18
+ from abc import ABC
19
+ import matplotlib as mpl
20
+ import matplotlib.pyplot as plt
21
+ import copy
22
+ from roboticstoolbox.mobile.OccGrid import BaseOccupancyGrid, BinaryOccupancyGrid
23
+ from roboticstoolbox.mobile.Animations import VehiclePolygon
24
+ from colored import fg, attr
25
+
26
+ from spatialmath.base.graphics import axes_logic
27
+
28
+ try:
29
+ from progress.bar import FillingCirclesBar
30
+
31
+ _progress = True
32
+ except ImportError:
33
+ _progress = False
34
+
35
+
36
+ class PlannerBase(ABC):
37
+ r"""
38
+ Mobile robot motion planner (superclass)
39
+
40
+ :param occgrid: occupancy grid, defaults to None
41
+ :type occgrid: :class:`OccGrid` instance of ndarray(N,M), optional
42
+ :param start: start position :math:`(x, y)` or configuration :math:`(x, y, \theta)`, defaults to None
43
+ :type start: array_like(2) or array_like(3), optional
44
+ :param goal: goal position :math:`(x, y)` or configuration :math:`(x, y, \theta)`, defaults to None
45
+ :type goal: array_like(2) or array_like(3), optional
46
+ :param inflate: obstacle inflation, defaults to 0
47
+ :type inflate: float, optional
48
+ :param ndims: dimensionality of the planning, either 2 for :math:`\mathbb{R}^2` or
49
+ 3 for :math:`\SE{2}`
50
+ :param ndims: int, optional
51
+ :param verbose: verbosity, defaults to False
52
+ :type verbose: bool, optional
53
+ :param msgcolor: color for message channel printing
54
+ :type msgcolor: str, defaults to yellow
55
+ :param seed: seed provided to private random number generator, defaults to None
56
+ :type seed: int, optional
57
+
58
+ Superclass for all mobile robot motion planners. Key functionality
59
+ includes:
60
+
61
+ - encapsulates an occupancy grid and optionally inflates it
62
+ - validates ``start`` and ``goal`` if given
63
+ - encapsulates a private random number generator with specifiable seed
64
+ - encapsulates state such as start, goal, and the plan
65
+ - provides a message channel for diagnostic output
66
+
67
+ The start and goal can be specifed in various ways:
68
+
69
+ - at constructor time by the arguments ``start`` or ``goal``
70
+ - by assigning the attributes ``start`` or ``goal``
71
+ - at planning time by specifying ``goal`` to :meth:`plan`
72
+ - at query time by specifying ``start`` to :meth:`query`
73
+
74
+ :seealso: :class:`OccGrid`
75
+ """
76
+
77
+ def __init__(
78
+ self,
79
+ occgrid=None,
80
+ inflate=0,
81
+ ndims=None,
82
+ start=None,
83
+ goal=None,
84
+ verbose=False,
85
+ msgcolor="yellow",
86
+ progress=True,
87
+ marker=None,
88
+ seed=None,
89
+ **unused,
90
+ ):
91
+
92
+ self._occgrid = None
93
+ if ndims is None:
94
+ raise ValueError("ndims must be specified")
95
+ self._ndims = ndims
96
+ self._verbose = verbose
97
+ self._msgcolor = msgcolor
98
+ self._seed = seed
99
+ self._private_random = np.random.default_rng(seed=seed)
100
+ self._inflate = inflate
101
+
102
+ self._progress = progress and _progress
103
+
104
+ self.marker = marker
105
+
106
+ if occgrid is not None:
107
+ if isinstance(occgrid, np.ndarray) and occgrid.ndim == 2:
108
+ # it's a NumPy array
109
+ self._occgrid = BinaryOccupancyGrid(occgrid)
110
+ elif isinstance(occgrid, BinaryOccupancyGrid):
111
+ self._occgrid = occgrid # original occgrid for reference
112
+
113
+ if inflate > 0:
114
+ self._occgrid0 = self._occgrid.copy()
115
+ self._occgrid.inflate(inflate)
116
+ else:
117
+ self._occgrid0 = self._occgrid
118
+
119
+ self._start = self.validate_endpoint(start)
120
+ self._goal = self.validate_endpoint(goal)
121
+
122
+ def __str__(self):
123
+ """
124
+ Compact representation of the planner
125
+
126
+ :return: pretty printed representation
127
+ :rtype: str
128
+ """
129
+ s = f"{self.__class__.__name__}: "
130
+ if hasattr(self, "_occgrid") and self._occgrid is not None:
131
+ s += "\n " + str(self._occgrid)
132
+ if self._start is not None:
133
+ s += f"\n Start: {self.start}"
134
+ if self._goal is not None:
135
+ s += f"\n Goal: {self.goal}"
136
+ return s
137
+
138
+ def __repr__(self):
139
+ return str(self)
140
+
141
+ @property
142
+ def start(self):
143
+ r"""
144
+ Set/get start point or configuration (superclass)
145
+
146
+ :getter: Return start point or configuration
147
+ :rtype: ndarray(2) or ndarray(3)
148
+ :setter: Set start point or configuration
149
+ :param: array_like(2) or array_like(3)
150
+
151
+ The start is either a point :math:`(x, y)` or a configuration :math:`(x, y, \theta)`.
152
+
153
+ :seealso: :meth:`goal`
154
+ """
155
+ return self._start
156
+
157
+ @start.setter
158
+ def start(self, start):
159
+ if start is not None:
160
+ if self.isoccupied(start):
161
+ raise ValueError("Start location inside obstacle")
162
+ self._start = getvector(start)
163
+
164
+ @property
165
+ def goal(self):
166
+ r"""
167
+ Set/get goal point or configuration (superclass)
168
+
169
+ :getter: Return goal pointor configuration
170
+ :rtype: ndarray(2) or ndarray(3)
171
+ :setter: Set goal point or configuration
172
+ :param: array_like(2) or array_like(3)
173
+
174
+ The goal is either a point :math:`(x, y)` or a configuration :math:`(x, y, \theta)`.
175
+
176
+ :seealso: :meth:`goal`
177
+ """
178
+ return self._goal
179
+
180
+ @goal.setter
181
+ def goal(self, goal):
182
+ r"""
183
+ Set goal point or configuration for planning
184
+
185
+ :param goal: Set goal :math:`(x, y)` or configuration :math:`(x, y, \theta)`
186
+ :type goal: array_like(2) or array_like(3)
187
+ :raises ValueError: if goal point is occupied
188
+ """
189
+ if goal is not None:
190
+ if self.isoccupied(goal):
191
+ raise ValueError("Goal location inside obstacle")
192
+ self._goal = getvector(goal)
193
+
194
+ @property
195
+ def verbose(self):
196
+ """
197
+ Get verbosity
198
+
199
+ :return: verbosity
200
+ :rtype: bool
201
+
202
+ If ``verbosity`` print more diagnostic messages to the planner's
203
+ message channel.
204
+ """
205
+ return self._verbose
206
+
207
+ @verbose.setter
208
+ def verbose(self, v):
209
+ """
210
+ Set verbosity
211
+
212
+ :param v: verbosity
213
+ :type v: bool
214
+
215
+ If ``verbosity`` print more diagnostic messages to the planner's
216
+ message channel.
217
+ """
218
+ self._verbose = v
219
+
220
+ @property
221
+ def random(self):
222
+ """
223
+ Get private random number generator
224
+
225
+ :return: NumPy random number generator
226
+ :rtype: :class:`numpy.random.Generator`
227
+
228
+ Has methods including:
229
+
230
+ - :meth:`integers(low, high, size, endpoint) <numpy.random.Generator.integers>`
231
+ - :meth:`random(size) <numpy.random.Generator.random>`
232
+ - :meth:`uniform(low, high, size) <numpy.random.Generator.uniform>`
233
+ - :meth:`normal(mean, std, size) <numpy.random.Generator.normal>`
234
+ - :meth:`multivariate_normal(mean, covar, size) <numpy.random.Generator.multivariate_normal>`
235
+
236
+ The generator is initialized with the seed provided at constructor
237
+ time.
238
+
239
+ :seealso: :func:`numpy.random.default_rng`
240
+ """
241
+ return self._private_random
242
+
243
+ def random_init(self, seed=None):
244
+ """
245
+ Initialize private random number generator
246
+
247
+ :param seed: random number seed, defaults to value given to constructor
248
+ :type seed: int
249
+
250
+ The private random number generator is initialized. The seed is ``seed``
251
+ or the value given to the constructor. If None, the generator will
252
+ be randomly seeded using a seed from the operating system.
253
+ """
254
+ if seed is None:
255
+ seed = self._seed
256
+
257
+ self._private_random = np.random.default_rng(seed=seed)
258
+
259
+ # def randinit(self):
260
+ # if self._seed is not None:
261
+ # self._private_random = np.random.default_rng(seed=self._seed)
262
+
263
+ def plan(self):
264
+ r"""
265
+ Plan path (superclass)
266
+
267
+ :param start: start position :math:`(x, y)` or configuration :math:`(x, y, \theta)`, defaults to value passed to constructor
268
+ :type start: array_like(2) or array_like(3), optional
269
+ :param goal: goal position :math:`(x, y)` or configuration :math:`(x, y, \theta)`, defaults to value passed to constructor
270
+ :type goal: array_like(2) or array_like(3), optional
271
+
272
+ The implementation depends on the particular planner. Some may have
273
+ no planning phase. The plan may also depend on just the start or goal.
274
+ """
275
+ pass
276
+
277
+ @property
278
+ def occgrid(self):
279
+ """
280
+ Occupancy grid
281
+
282
+ :return: occupancy grid used for planning
283
+ :rtype: :class:`OccGrid` or subclass or None
284
+
285
+ Returns the occupancy grid that was optionally inflated at constructor time.
286
+
287
+ :seealso: :meth:`validate_endpoint` :meth:`isoccupied`
288
+ """
289
+ return self._occgrid
290
+
291
+ def isoccupied(self, p):
292
+ """
293
+ Test if point is occupied (superclass)
294
+
295
+ :param p: world coordinate (x, y)
296
+ :type p: array_like(2)
297
+ :return: occupancy status of corresponding grid cell
298
+ :rtype: bool
299
+
300
+ The world coordinate is transformed and the status of the occupancy
301
+ grid cell is returned. If the point lies outside the bounds of
302
+ the occupancy grid return True (obstacle)
303
+
304
+ If there is no occupancy grid this function always returns False (free).
305
+
306
+ :seealso: :meth:`occgrid` :meth:`validate_endpoint` :meth:`BinaryOccGrid.isoccupied`
307
+ """
308
+ if self.occgrid is None:
309
+ return False
310
+ else:
311
+ return self.occgrid.isoccupied(p)
312
+
313
+ def validate_endpoint(self, p, dtype=None):
314
+ """
315
+ Validate start or goal point
316
+
317
+ :param p: the point
318
+ :type p: array_like(2)
319
+ :param dtype: data type for point coordinates, defaults to None
320
+ :type dtype: str, optional
321
+ :raises ValueError: point is inside obstacle
322
+ :return: point as a NumPy array of specified dtype
323
+ :rtype: ndarray(2)
324
+
325
+ The coordinate is tested to be a free cell in the occupancy grid.
326
+
327
+ :seealso: :meth:`isoccupied` :meth:`occgrid`
328
+ """
329
+ if p is not None:
330
+ p = getvector(p, self._ndims, dtype=dtype)
331
+ if self.isoccupied(p):
332
+ raise ValueError("Point is inside obstacle")
333
+ return p
334
+
335
+ def progress_start(self, n):
336
+ """
337
+ Initialize a progress bar (superclass)
338
+
339
+ :param n: Number of iterations in the operation
340
+ :type n: int
341
+
342
+ Create a progress bar for an operation that has ``n`` steps, for
343
+ example::
344
+
345
+ planner.progress_start(100)
346
+ for i in range(100):
347
+ # ...
348
+ planner.progress_next()
349
+ planner.progress_end()
350
+
351
+ .. warning: Requires that the ``progress`` package is installed.
352
+
353
+ :seealso: :meth:`progress_next` :meth:`progress_end`
354
+ """
355
+ if _progress:
356
+ self._bar = FillingCirclesBar(
357
+ self.__class__.__name__, max=n, suffix="%(percent).1f%% - %(eta)ds"
358
+ )
359
+
360
+ def progress_next(self):
361
+ """
362
+ Increment a progress bar (superclass)
363
+
364
+ Create a progress bar for an operation that has ``n`` steps, for
365
+ example::
366
+
367
+ planner.progress_start(100)
368
+ for i in range(100):
369
+ # ...
370
+ planner.progress_next()
371
+ planner.progress_end()
372
+
373
+ .. warning: Requires that the ``progress`` package is installed.
374
+
375
+ :seealso: :meth:`progress_start` :meth:`progress_end`
376
+ """
377
+ if _progress:
378
+ self._bar.next()
379
+
380
+ def progress_end(self):
381
+ """
382
+ Finalize a progress bar (superclass)
383
+
384
+ Remove/cleanip a progress bar, for
385
+ example::
386
+
387
+ planner.progress_start(100)
388
+ for i in range(100):
389
+ # ...
390
+ planner.progress_next()
391
+ planner.progress_end()
392
+
393
+ .. warning: Requires that the ``progress`` package is installed.
394
+
395
+ :seealso: :meth:`progress_start` :meth:`progress_next`
396
+ """
397
+ if _progress:
398
+ self._bar.finish()
399
+
400
+ def query(
401
+ self, start=None, goal=None, dtype=None, next=True, animate=False, movie=None
402
+ ):
403
+ r"""
404
+ Find a path from start to goal using planner (superclass)
405
+
406
+ :param start: start position :math:`(x, y)` or configuration :math:`(x, y, \theta)`, defaults to value specified to constructor
407
+ :type start: array_like(), optional
408
+ :param goal: goal position :math:`(x, y)` or configuration :math:`(x, y, \theta)`, defaults to value specified to constructor
409
+ :type goal: array_like(), optional
410
+ :param dtype: data type for point coordinates, defaults to None
411
+ :type dtype: str, optional
412
+ :param next: invoke :meth:`next` method of class, defaults to True
413
+ :type next: bool, optional
414
+ :param animate: show the vehicle path, defaults to False
415
+ :type animate: bool, optional
416
+ :return: path from start to goal, one point :math:`(x, y)` or configuration :math:`(x, y, \theta)` per row
417
+ :rtype: ndarray(N,2) or ndarray(N,3)
418
+
419
+ Find a path from ``start`` to ``goal`` using a previously computed plan.
420
+
421
+ This is a generic method that works for any planner
422
+ (:math:`\mathbb{R}^2` or :math:`\SE{2}`) that can incrementally
423
+ determine the next point on the path. The method performs the following
424
+ steps:
425
+
426
+ - Validate start and goal
427
+ - If ``animate``, visualize the environment using :meth:`plot`
428
+ - Iterate on the class's :meth:`next` method until the ``goal`` is
429
+ achieved, and if ``animate`` plot points.
430
+
431
+ :seealso: :meth:`next` :meth:`plan`
432
+ """
433
+ # make sure start and goal are set and valid
434
+ self.start = self.validate_endpoint(start, dtype=dtype)
435
+ self.goal = self.validate_endpoint(goal, dtype=dtype)
436
+
437
+ # if movie is not None:
438
+ # animate = True
439
+
440
+ if animate:
441
+ self.plot()
442
+
443
+ # movie = MovieWriter(movie)
444
+
445
+ robot = self._start
446
+ path = [robot]
447
+
448
+ while next:
449
+ if animate:
450
+ plt.plot(robot[0], robot[1], "y.", 12)
451
+ plt.pause(0.05)
452
+
453
+ # get next point on the path
454
+ robot = self.next(robot)
455
+
456
+ # are we are done?
457
+ if robot is None:
458
+ path.append(self._goal)
459
+ return np.array(path).astype(int)
460
+
461
+ path.append(robot)
462
+
463
+ def plot(
464
+ self,
465
+ path=None,
466
+ line=None,
467
+ line_r=None,
468
+ configspace=False,
469
+ unwrap=True,
470
+ direction=None,
471
+ background=True,
472
+ path_marker=None,
473
+ path_marker_reverse=None,
474
+ start_marker=None,
475
+ goal_marker=None,
476
+ start_vehicle=None,
477
+ goal_vehicle=None,
478
+ start=None,
479
+ goal=None,
480
+ ax=None,
481
+ block=None,
482
+ bgargs={},
483
+ **unused,
484
+ ):
485
+ r"""
486
+ Plot vehicle path (superclass)
487
+
488
+ :param path: path, defaults to None
489
+ :type path: (N, 2) or ndarray(N, 3)
490
+ :param direction: travel direction associated with each point on path, is either >0 or <0, defaults to None
491
+ :type direction: array_like(N), optional
492
+ :param line: line style for forward motion, default is striped yellow on black
493
+ :type line: sequence of dict of arguments for ``plot``
494
+ :param line_r: line style for reverse motion, default is striped red on black
495
+ :type line_r: sequence of dict of arguments for ``plot``
496
+
497
+ :param configspace: plot the path in 3D configuration space, input must be 3xN.
498
+ Start and goal style will be given by ``qstart_marker`` and ``qgoal_marker``, defaults to False
499
+ :type configspace: bool, optional
500
+ :param unwrap: for configuration space plot unwrap :math:`\theta` so
501
+ there are no discontinuities at :math:`\pm \pi`, defaults to True
502
+ :type unwrap: bool, optional
503
+ :param background: plot occupancy grid if present, default True
504
+ :type background: bool, optional
505
+ :param start_marker: style for marking start point
506
+ :type start_marker: dict, optional
507
+ :param goal_marker: style for marking goal point
508
+ :type goal_marker: dict, optional
509
+ :param start_vehicle: style for vehicle animation object at start configuration
510
+ :type start_vehicle: dict
511
+ :param goal_vehicle: style for vehicle animation object at goal configuration
512
+ :type goal_vehicle: dict
513
+ :param start: start position :math:`(x, y)` or configuration :math:`(x, y, \theta)`, defaults to value previously set
514
+ :type start: array_like(2) or array_like(3), optional
515
+ :param goal: goal position :math:`(x, y)` or configuration :math:`(x, y, \theta)`, defaults to value previously set
516
+ :type goal: array_like(2) or array_like(3), optional
517
+ :param bgargs: arguments passed to :meth:`plot_bg`, defaults to None
518
+ :type bgargs: dict, optional
519
+ :param ax: axes to plot into
520
+ :type ax: matplotlib axes
521
+ :param block: block after displaying the plot
522
+ :type block: bool, optional
523
+
524
+ Plots the start and goal location/pose if they are specified by
525
+ ``start`` or ``goal`` or were set by the object constructor or
526
+ ``plan`` or ``query`` method.
527
+
528
+ If the ``start`` and ``goal`` have length 2, planning in
529
+ :math:`\mathbb{R}^2`, then markers are drawn using styles specified by
530
+ ``start_marker`` and ``end_marker`` which are dicts using Matplotlib
531
+ keywords, for example::
532
+
533
+ planner.plot(path, start=dict(marker='s', color='b'))
534
+
535
+ If the ``start`` and ``goal`` have length 3, planning in :math:`\SE{2}`,
536
+ and ``configspace`` is False, then direction-indicating markers are used
537
+ to display start and goal configuration. These are also given as dicts
538
+ but have two items: ``'shape'`` which is the shape of the polygonal
539
+ marker and is either ``'triangle'`` or ``'car'``. The second item
540
+ ``'args'`` is passed to :func:`base.plot_poly` and Matplotlib and could
541
+ have values such as ``filled=True`` or ``color``.
542
+
543
+ If ``configspace`` is False then a 3D plot is created and the start and
544
+ goal are indicated by Matplotlib markers specified by the dicts
545
+ ``start_marker`` and ``end_marker``
546
+
547
+ Default values are provided for all markers:
548
+
549
+ - the start point is a circle
550
+ - the goal point is a star
551
+ - the start vehicle style is a ``VehiclePolygon(shape='car')`` as
552
+ an unfilled outline
553
+ - the goal vehicle style is a ``VehiclePolygon(shape='car')`` as
554
+ a transparent filled shape
555
+
556
+ If ``background`` is True then the background of the plot is either or
557
+ both of:
558
+
559
+ - the occupancy grid
560
+ - the distance field of the planner
561
+
562
+ Additional arguments ``bgargs`` can be passed through to :meth:`plot_bg`
563
+
564
+ If ``path`` is specified it has one column per point and either 2 or 3 rows:
565
+
566
+ - 2 rows describes motion in the :math:`xy`-plane and a 2D plot is created
567
+ - 3 rows describes motion in the :math:`xy\theta`-configuration space. By
568
+ default only the :math:`xy`-plane is plotted unless ``configspace``
569
+ is True in which case motion in :math:`xy\theta`-configuration space
570
+ is shown as a 3D plot.
571
+
572
+ If the planner supports bi-directional motion then the ``direction``
573
+ option gives the direction for each point on the path.
574
+
575
+ Forward motion segments are drawn using style information from ``line``
576
+ while reverse motion segments are drawn using style information from
577
+ ``line_r``. These are each a sequence of dicts of Matplotlib plot
578
+ options which can draw an arbitrary number of lines on top of each
579
+ other. The default::
580
+
581
+ line = (
582
+ {color:'black', linewidth:4},
583
+ {color:'yellow', linewidth:3, dashes:(5,5)}
584
+ )
585
+
586
+ will draw a blackline of width 4 with a dashed yellow line of width 3
587
+ plotted on top, giving a line of alternating black and yellow dashes.
588
+
589
+ :seealso: :meth:`plot_bg` :func:`base.plot_poly`
590
+ """
591
+ # create default markers
592
+ # passed to Matplotlib plot()
593
+ if start_marker is None:
594
+ start_marker = {
595
+ "marker": "o",
596
+ "markeredgecolor": "k",
597
+ "markerfacecolor": "y",
598
+ "markersize": 10,
599
+ "zorder": 10,
600
+ "linestyle": "none",
601
+ }
602
+ if goal_marker is None:
603
+ goal_marker = {
604
+ "marker": "*",
605
+ "markeredgecolor": "k",
606
+ "markerfacecolor": "y",
607
+ "markersize": 16,
608
+ "zorder": 10,
609
+ "linestyle": "none",
610
+ }
611
+
612
+ # create defaut line styles
613
+ if line is None:
614
+ line = (
615
+ {"color": "black", "linewidth": 4},
616
+ {"color": "yellow", "linewidth": 3, "dashes": (5, 5)},
617
+ )
618
+ if line_r is None:
619
+ line_r = (
620
+ {"color": "black", "linewidth": 4},
621
+ {"color": "red", "linewidth": 3, "dashes": (5, 5)},
622
+ )
623
+
624
+ # passed to VehiclePolygon
625
+ if start_vehicle is None:
626
+ start_vehicle = {"facecolor": "none", "edgecolor": "k", "linewidth": 2}
627
+
628
+ if goal_vehicle is None:
629
+ goal_vehicle = {"alpha": 0.5}
630
+
631
+ ndims = self._ndims
632
+
633
+ if ndims == 3 and not configspace:
634
+ ndims = 2
635
+ if path is not None:
636
+ path = path[:, :2]
637
+
638
+ if configspace and ndims < 3 and path is not None:
639
+ raise ValueError(f"path should have {ndims} rows")
640
+
641
+ ax = axes_logic(ax, ndims)
642
+
643
+ # plot occupancy grid background
644
+ if background:
645
+ self.plot_bg(ax=ax, **bgargs)
646
+
647
+ # mark the path
648
+ if path is not None:
649
+ if ndims == 2:
650
+ # 2D case
651
+ if direction is not None:
652
+ # bidirectional motion
653
+ direction = np.array(direction)
654
+ if direction.shape[0] != path.shape[0]:
655
+ raise ValueError(
656
+ "direction vector must have same length as path"
657
+ )
658
+
659
+ while len(direction) > 0:
660
+ dir = direction[0]
661
+ change = np.argwhere(dir != direction)
662
+ if len(change) == 0:
663
+ k = -1
664
+ else:
665
+ k = change[0, 0]
666
+
667
+ for style in line if dir > 0 else line_r:
668
+ ax.plot(path[:k, 0], path[:k, 1], zorder=9, **style)
669
+
670
+ if len(change) == 0:
671
+ break
672
+ direction = direction[k - 1 :]
673
+ direction[0] = direction[1]
674
+ path = path[k - 1 :, :]
675
+
676
+ else:
677
+ # forward motion only
678
+ for style in line:
679
+ ax.plot(path[:, 0], path[:, 1], zorder=9, **style)
680
+
681
+ elif ndims == 3:
682
+ # 3D case
683
+ if direction is not None:
684
+ # bidirectional motion
685
+
686
+ direction = np.array(direction)
687
+ if direction.shape[0] != path.shape[0]:
688
+ raise ValueError(
689
+ "direction vector must have same length as path"
690
+ )
691
+ theta = path[:, 2]
692
+ if unwrap:
693
+ theta = np.unwrap(theta)
694
+
695
+ while len(direction) > 0:
696
+ dir = direction[0]
697
+ change = np.argwhere(dir != direction)
698
+ if len(change) == 0:
699
+ k = -1
700
+ else:
701
+ k = change[0, 0]
702
+
703
+ for style in line if dir > 0 else line_r:
704
+ ax.plot(path[:k, 0], path[:k, 1], theta[:k], **style)
705
+
706
+ if len(change) == 0:
707
+ break
708
+ direction = direction[k - 1 :]
709
+ direction[0] = direction[1]
710
+ path = path[k - 1 :, :]
711
+ theta = theta[k - 1 :]
712
+
713
+ else:
714
+ # forward motion only
715
+ theta = path[:, 2]
716
+ if unwrap:
717
+ theta = np.unwrap(theta)
718
+ for style in line:
719
+ ax.plot(path[:, 0], path[:, 1], theta, **style)
720
+
721
+ # mark start and goal if requested
722
+ if start is not None:
723
+ start = self.validate_endpoint(start)
724
+ else:
725
+ start = self.start
726
+ if goal is not None:
727
+ self.goal = self.validate_endpoint(goal)
728
+ else:
729
+ goal = self.goal
730
+
731
+ if ndims == 2 and self._ndims == 2:
732
+ # proper 2d plot
733
+ if start is not None:
734
+ ax.plot(start[0], start[1], label="start", **start_marker)
735
+ if goal is not None:
736
+ ax.plot(goal[0], goal[1], label="goal", **goal_marker)
737
+
738
+ elif ndims == 2 and self._ndims == 3:
739
+ # 2d projection of 3d plot, show start/goal configuration
740
+ scale = axes_get_scale(ax) / 10
741
+
742
+ if self.marker is None:
743
+ self.marker = VehiclePolygon(shape="car", scale=scale)
744
+
745
+ if start is not None:
746
+ self.marker.plot(start, **start_vehicle)
747
+ if goal is not None:
748
+ self.marker.plot(goal, **goal_vehicle)
749
+
750
+ elif ndims == 3:
751
+ # 3d plot
752
+
753
+ if start is not None:
754
+ ax.plot(start[0], start[1], start[2], label="start", **start_marker)
755
+ if goal is not None:
756
+ if path is not None and unwrap:
757
+ theta = theta[-1]
758
+ else:
759
+ theta = goal[2]
760
+ plt.plot(goal[0], goal[1], theta, label="goal", **goal_marker)
761
+
762
+ ax.set_xlabel("x")
763
+ ax.set_ylabel("y")
764
+ if ndims == 2:
765
+ ax.set_aspect("equal")
766
+ else:
767
+ ax.set_zlabel(r"$\theta$")
768
+
769
+ if block:
770
+ plt.show(block=block)
771
+
772
+ return ax
773
+
774
+ def _qmarker(self, shape):
775
+ h = 0.3
776
+ t = 0.8 # start of head taper
777
+ c = 0.5 # centre x coordinate
778
+ w = 1 # width in x direction
779
+ if shape == "car":
780
+ return np.array(
781
+ [
782
+ [-c, h],
783
+ [t - c, h],
784
+ [w - c, 0],
785
+ [t - c, -h],
786
+ [-c, -h],
787
+ ]
788
+ ).T
789
+ elif shape == "triangle":
790
+ return np.array(
791
+ [
792
+ [-c, h],
793
+ [w, 0],
794
+ [-c, -h],
795
+ [-c, h],
796
+ ]
797
+ ).T
798
+
799
+ def plot_bg(
800
+ self,
801
+ distance=None,
802
+ cmap="gray",
803
+ ax=None,
804
+ inflated=True,
805
+ colorbar=True,
806
+ block=None,
807
+ **unused,
808
+ ):
809
+ """
810
+ Plot background (superclass)
811
+
812
+ :param distance: override distance field, defaults to None
813
+ :type distance: ndarray(N,M), optional
814
+ :param cmap: Specify a colormap for the distance field, defaults to 'gray'
815
+ :type cmap: str or Colormap, optional
816
+
817
+ Displays the background which is either the occupancy grid or a distance
818
+ field. The distance field encodes the distance of a point from the goal, small
819
+ distance is dark, a large distance is bright.
820
+
821
+ If the planner has an occupancy grid then that will be displayed with:
822
+ - free cells in white
823
+ - occupied cells in red
824
+ - inflated occupied cells in pink
825
+
826
+ If distance is provided, or the planner has a distancemap attribute
827
+ the the distance field will be used as the background and obstacle cells
828
+ (actual or inflated) will be shown in red. A colorbar is added.
829
+ """
830
+ if self._occgrid is None:
831
+ return
832
+
833
+ if isinstance(self._occgrid, BaseOccupancyGrid):
834
+ ax = plotvol2(dim=self._occgrid.workspace, ax=ax)
835
+ else:
836
+ ax = axes_logic(ax, 2)
837
+
838
+ # create color map for free space + obstacle:
839
+ # free space, color index = 1, white, alpha=0 to allow background and grid lines to show
840
+ # obstacle, color index = 2, red, alpha=1
841
+
842
+ if self._inflate > 0 and inflated:
843
+ # 0 background (white, transparent)
844
+ # 1 inflated obstacle (pink)
845
+ # 2 original obstacle (red)
846
+ colors = [(1, 1, 1, 0), (1, 0.75, 0.8, 1), (1, 0, 0, 1)]
847
+ image = self.occgrid.grid.astype(int) + self._occgrid0.grid.astype(int)
848
+ else:
849
+ # 0 background
850
+ # 1 obstacle
851
+ colors = [(1, 1, 1, 0), (1, 0, 0, 1)]
852
+ image = self.occgrid.grid
853
+
854
+ if distance is None and hasattr(self, "distancemap"):
855
+ distance = self.distancemap
856
+
857
+ if distance is not None:
858
+ # distance field with obstacles
859
+
860
+ # find largest finite value
861
+
862
+ v = distance.ravel()
863
+ vmax = max(v[np.isfinite(v)])
864
+
865
+ # create a copy of greyscale color map
866
+ c_map = copy.copy(mpl.cm.get_cmap(cmap))
867
+ # c_map.set_bad(color=(1,0,0,1)) # nan and inf are red
868
+
869
+ # change all inf to large value, so they are not 'bad' ie. red
870
+ distance[np.isinf(distance)] = 2 * vmax
871
+ c_map.set_over(color=(0, 0, 1)) # ex-infs are now blue
872
+
873
+ # display image
874
+ norm = mpl.colors.Normalize(vmin=0, vmax=vmax, clip=False)
875
+ ax.imshow(
876
+ distance,
877
+ origin="lower",
878
+ interpolation=None,
879
+ cmap=c_map,
880
+ norm=norm,
881
+ )
882
+ ax.grid(True, alpha=0.1, color=(1, 1, 1))
883
+
884
+ # add colorbar
885
+ scalar_mappable_c_map = cm.ScalarMappable(cmap=c_map, norm=norm)
886
+ if colorbar is True:
887
+ ax.figure.colorbar(
888
+ scalar_mappable_c_map,
889
+ ax=ax,
890
+ # shrink=0.75,
891
+ # aspect=20 * 0.75,
892
+ label="Distance",
893
+ )
894
+
895
+ elif isinstance(colorbar, dict):
896
+ cb_kwargs = dict(colorbar)
897
+ if "label" not in colorbar:
898
+ cb_kwargs["label"] = "Distance"
899
+ cb_kwargs.setdefault("ax", ax)
900
+ ax.figure.colorbar(scalar_mappable_c_map, **cb_kwargs)
901
+ # overlay obstacles
902
+ c_map = mpl.colors.ListedColormap(colors)
903
+ self.occgrid.plot(image, cmap=c_map, zorder=1)
904
+
905
+ else:
906
+ # occupancy grid only
907
+
908
+ # overlay obstacles
909
+ c_map = mpl.colors.ListedColormap(colors)
910
+ # self.occgrid.plot(image, cmap=c_map, zorder=1)
911
+ self.occgrid.plot(cmap=c_map, zorder=1, ax=ax)
912
+
913
+ ax.set_facecolor((1, 1, 1)) # create white background
914
+ ax.set_xlabel("x (cells)")
915
+ ax.set_ylabel("y (cells)")
916
+ ax.grid(True, zorder=0)
917
+
918
+ # lock axis limits to current value
919
+ # ax.set_xlim(ax.get_xlim())
920
+ # ax.set_ylim(ax.get_ylim())
921
+
922
+ # plt.draw()
923
+ if block is not None:
924
+ plt.show(block=block)
925
+
926
+ def message(self, s, color=None):
927
+ """
928
+ Print message to message channel
929
+
930
+ :param s: message to print
931
+ :type s: str
932
+ :param color: color to print it, defaults to color specified at
933
+ constructor time.
934
+ :type color: str, optional
935
+
936
+ """
937
+ if self.verbose:
938
+ if color is None:
939
+ color = self._msgcolor
940
+ print(fg(color), "Planner:: " + s, attr(0))
941
+
942
+ # @staticmethod
943
+ # def show_distance(d):
944
+ # d[np.isinf(d)] = None
945
+ # ax = plt.gca()
946
+ # c_map = plt.get_cmap("Greys")
947
+ # plt.clim(0, np.max(d[:]))
948
+ # plt.figimage(d)
949
+ # plt.xlabel('X')
950
+ # plt.ylabel('Y')
951
+ # plt.show()
952
+
953
+
954
+ class MovieWriter:
955
+ def __init__(self, filename=None, interval=0.1, fig=None):
956
+ """
957
+ Save animation as a movie file
958
+
959
+ :param filename: name of movie file, or tuple containing filename and
960
+ frame interval
961
+ :type filename: str or tuple(str, float)
962
+ :param interval: frame interval, defaults to 0.1
963
+ :type interval: float, optional
964
+ :param fig: figure to record for the movie
965
+ :type fig: figure reference
966
+
967
+ Example::
968
+
969
+ movie = MovieWriter(filename)
970
+
971
+ while ...
972
+ movie.add()
973
+
974
+ movie.done()
975
+
976
+ To avoid extra user-logic, if ``MovieWriter`` is called with ``filename`` equal to None,
977
+ then the writer will do nothing when the ``add`` and ``done`` methods are called.
978
+ """
979
+ # Set up formatting for the movie files
980
+ if filename is None:
981
+ self.writer = None
982
+ return
983
+
984
+ if isinstance(filename, (tuple, list)):
985
+ filename, interval = filename
986
+
987
+ if os.path.exists(filename):
988
+ print("overwriting movie", filename)
989
+ else:
990
+ print("creating movie", filename)
991
+ self.writer = animation.FFMpegWriter(
992
+ fps=round(1 / interval), extra_args=["-vcodec", "libx264"]
993
+ )
994
+ if fig is None:
995
+ fig = plt.gcf()
996
+ self.writer.setup(fig, filename)
997
+ self.filename = filename
998
+
999
+ def add(self):
1000
+ """
1001
+ Add frame to the movie
1002
+ """
1003
+ if self.writer is not None:
1004
+ self.writer.grab_frame()
1005
+
1006
+ def done(self):
1007
+ if self.writer is not None:
1008
+ self.writer.finish()
1009
+ self.writer = None