python-motion-planning 1.1__tar.gz → 2.0__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.
- {python_motion_planning-1.1 → python_motion_planning-2.0}/PKG-INFO +115 -146
- python_motion_planning-2.0/README.md +158 -0
- {python_motion_planning-1.1 → python_motion_planning-2.0}/pyproject.toml +7 -6
- python_motion_planning-2.0/src/python_motion_planning/__init__.py +4 -0
- python_motion_planning-2.0/src/python_motion_planning/common/__init__.py +3 -0
- python_motion_planning-2.0/src/python_motion_planning/common/env/__init__.py +6 -0
- python_motion_planning-2.0/src/python_motion_planning/common/env/map/__init__.py +2 -0
- python_motion_planning-2.0/src/python_motion_planning/common/env/map/base_map.py +119 -0
- python_motion_planning-2.0/src/python_motion_planning/common/env/map/grid.py +562 -0
- python_motion_planning-2.0/src/python_motion_planning/common/env/node.py +111 -0
- python_motion_planning-2.0/src/python_motion_planning/common/env/robot/__init__.py +3 -0
- python_motion_planning-2.0/src/python_motion_planning/common/env/robot/base_robot.py +214 -0
- python_motion_planning-2.0/src/python_motion_planning/common/env/robot/circular_robot.py +47 -0
- python_motion_planning-2.0/src/python_motion_planning/common/env/robot/diff_drive_robot.py +109 -0
- python_motion_planning-2.0/src/python_motion_planning/common/env/types.py +19 -0
- python_motion_planning-2.0/src/python_motion_planning/common/env/world/__init__.py +1 -0
- python_motion_planning-2.0/src/python_motion_planning/common/env/world/base_world.py +120 -0
- python_motion_planning-2.0/src/python_motion_planning/common/env/world/toy_simulator.py +206 -0
- python_motion_planning-2.0/src/python_motion_planning/common/utils/__init__.py +3 -0
- python_motion_planning-2.0/src/python_motion_planning/common/utils/child_tree.py +22 -0
- python_motion_planning-2.0/src/python_motion_planning/common/utils/frame_transformer.py +218 -0
- python_motion_planning-2.0/src/python_motion_planning/common/utils/geometry.py +94 -0
- python_motion_planning-2.0/src/python_motion_planning/common/visualizer/__init__.py +3 -0
- python_motion_planning-2.0/src/python_motion_planning/common/visualizer/base_visualizer.py +165 -0
- python_motion_planning-2.0/src/python_motion_planning/common/visualizer/visualizer_2d.py +406 -0
- python_motion_planning-2.0/src/python_motion_planning/common/visualizer/visualizer_3d.py +242 -0
- python_motion_planning-2.0/src/python_motion_planning/controller/__init__.py +3 -0
- python_motion_planning-2.0/src/python_motion_planning/controller/base_controller.py +191 -0
- python_motion_planning-2.0/src/python_motion_planning/controller/path_tracker/__init__.py +6 -0
- python_motion_planning-2.0/src/python_motion_planning/controller/path_tracker/apf.py +231 -0
- python_motion_planning-2.0/src/python_motion_planning/controller/path_tracker/dwa.py +250 -0
- python_motion_planning-2.0/src/python_motion_planning/controller/path_tracker/path_tracker.py +260 -0
- python_motion_planning-2.0/src/python_motion_planning/controller/path_tracker/pid.py +82 -0
- python_motion_planning-2.0/src/python_motion_planning/controller/path_tracker/pure_pursuit.py +71 -0
- python_motion_planning-2.0/src/python_motion_planning/controller/path_tracker/rpp.py +111 -0
- python_motion_planning-2.0/src/python_motion_planning/controller/random_controller.py +27 -0
- python_motion_planning-2.0/src/python_motion_planning/path_planner/__init__.py +4 -0
- python_motion_planning-2.0/src/python_motion_planning/path_planner/base_path_planner.py +122 -0
- python_motion_planning-2.0/src/python_motion_planning/path_planner/graph_search/__init__.py +6 -0
- python_motion_planning-2.0/src/python_motion_planning/path_planner/graph_search/a_star.py +94 -0
- python_motion_planning-2.0/src/python_motion_planning/path_planner/graph_search/dijkstra.py +97 -0
- python_motion_planning-2.0/src/python_motion_planning/path_planner/graph_search/gbfs.py +100 -0
- python_motion_planning-2.0/src/python_motion_planning/path_planner/graph_search/jps.py +199 -0
- python_motion_planning-2.0/src/python_motion_planning/path_planner/graph_search/lazy_theta_star.py +113 -0
- python_motion_planning-2.0/src/python_motion_planning/path_planner/graph_search/theta_star.py +116 -0
- python_motion_planning-2.0/src/python_motion_planning/path_planner/hybrid_search/__init__.py +1 -0
- python_motion_planning-2.0/src/python_motion_planning/path_planner/hybrid_search/voronoi_planner.py +204 -0
- python_motion_planning-2.0/src/python_motion_planning/path_planner/sample_search/__init__.py +3 -0
- python_motion_planning-2.0/src/python_motion_planning/path_planner/sample_search/rrt.py +243 -0
- python_motion_planning-2.0/src/python_motion_planning/path_planner/sample_search/rrt_connect.py +237 -0
- python_motion_planning-2.0/src/python_motion_planning/path_planner/sample_search/rrt_star.py +279 -0
- python_motion_planning-2.0/src/python_motion_planning/traj_optimizer/__init__.py +2 -0
- python_motion_planning-2.0/src/python_motion_planning/traj_optimizer/base_curve_generator.py +53 -0
- python_motion_planning-2.0/src/python_motion_planning/traj_optimizer/curve_generator/__init__.py +2 -0
- python_motion_planning-2.0/src/python_motion_planning/traj_optimizer/curve_generator/point_based/__init__.py +2 -0
- python_motion_planning-2.0/src/python_motion_planning/traj_optimizer/curve_generator/point_based/bspline.py +256 -0
- python_motion_planning-2.0/src/python_motion_planning/traj_optimizer/curve_generator/point_based/cubic_spline.py +115 -0
- python_motion_planning-2.0/src/python_motion_planning/traj_optimizer/curve_generator/pose_based/__init__.py +4 -0
- python_motion_planning-2.0/src/python_motion_planning/traj_optimizer/curve_generator/pose_based/bezier.py +121 -0
- python_motion_planning-2.0/src/python_motion_planning/traj_optimizer/curve_generator/pose_based/dubins.py +355 -0
- python_motion_planning-2.0/src/python_motion_planning/traj_optimizer/curve_generator/pose_based/polynomial.py +197 -0
- python_motion_planning-2.0/src/python_motion_planning/traj_optimizer/curve_generator/pose_based/reeds_shepp.py +606 -0
- {python_motion_planning-1.1 → python_motion_planning-2.0}/src/python_motion_planning.egg-info/PKG-INFO +115 -146
- python_motion_planning-2.0/src/python_motion_planning.egg-info/SOURCES.txt +67 -0
- python_motion_planning-2.0/src/python_motion_planning.egg-info/requires.txt +8 -0
- {python_motion_planning-1.1 → python_motion_planning-2.0}/src/python_motion_planning.egg-info/top_level.txt +1 -0
- python_motion_planning-1.1/README.md +0 -191
- python_motion_planning-1.1/src/python_motion_planning/__init__.py +0 -4
- python_motion_planning-1.1/src/python_motion_planning/curve_generation/__init__.py +0 -9
- python_motion_planning-1.1/src/python_motion_planning/curve_generation/bezier_curve.py +0 -131
- python_motion_planning-1.1/src/python_motion_planning/curve_generation/bspline_curve.py +0 -271
- python_motion_planning-1.1/src/python_motion_planning/curve_generation/cubic_spline.py +0 -128
- python_motion_planning-1.1/src/python_motion_planning/curve_generation/curve.py +0 -64
- python_motion_planning-1.1/src/python_motion_planning/curve_generation/dubins_curve.py +0 -348
- python_motion_planning-1.1/src/python_motion_planning/curve_generation/fem_pos_smooth.py +0 -114
- python_motion_planning-1.1/src/python_motion_planning/curve_generation/polynomial_curve.py +0 -226
- python_motion_planning-1.1/src/python_motion_planning/curve_generation/reeds_shepp.py +0 -736
- python_motion_planning-1.1/src/python_motion_planning/global_planner/__init__.py +0 -3
- python_motion_planning-1.1/src/python_motion_planning/global_planner/evolutionary_search/__init__.py +0 -4
- python_motion_planning-1.1/src/python_motion_planning/global_planner/evolutionary_search/aco.py +0 -186
- python_motion_planning-1.1/src/python_motion_planning/global_planner/evolutionary_search/evolutionary_search.py +0 -87
- python_motion_planning-1.1/src/python_motion_planning/global_planner/evolutionary_search/pso.py +0 -356
- python_motion_planning-1.1/src/python_motion_planning/global_planner/graph_search/__init__.py +0 -28
- python_motion_planning-1.1/src/python_motion_planning/global_planner/graph_search/a_star.py +0 -124
- python_motion_planning-1.1/src/python_motion_planning/global_planner/graph_search/d_star.py +0 -291
- python_motion_planning-1.1/src/python_motion_planning/global_planner/graph_search/d_star_lite.py +0 -188
- python_motion_planning-1.1/src/python_motion_planning/global_planner/graph_search/dijkstra.py +0 -77
- python_motion_planning-1.1/src/python_motion_planning/global_planner/graph_search/gbfs.py +0 -78
- python_motion_planning-1.1/src/python_motion_planning/global_planner/graph_search/graph_search.py +0 -87
- python_motion_planning-1.1/src/python_motion_planning/global_planner/graph_search/jps.py +0 -165
- python_motion_planning-1.1/src/python_motion_planning/global_planner/graph_search/lazy_theta_star.py +0 -114
- python_motion_planning-1.1/src/python_motion_planning/global_planner/graph_search/lpa_star.py +0 -230
- python_motion_planning-1.1/src/python_motion_planning/global_planner/graph_search/s_theta_star.py +0 -133
- python_motion_planning-1.1/src/python_motion_planning/global_planner/graph_search/theta_star.py +0 -171
- python_motion_planning-1.1/src/python_motion_planning/global_planner/graph_search/voronoi.py +0 -200
- python_motion_planning-1.1/src/python_motion_planning/global_planner/sample_search/__init__.py +0 -6
- python_motion_planning-1.1/src/python_motion_planning/global_planner/sample_search/informed_rrt.py +0 -152
- python_motion_planning-1.1/src/python_motion_planning/global_planner/sample_search/rrt.py +0 -151
- python_motion_planning-1.1/src/python_motion_planning/global_planner/sample_search/rrt_connect.py +0 -147
- python_motion_planning-1.1/src/python_motion_planning/global_planner/sample_search/rrt_star.py +0 -77
- python_motion_planning-1.1/src/python_motion_planning/global_planner/sample_search/sample_search.py +0 -135
- python_motion_planning-1.1/src/python_motion_planning/local_planner/__init__.py +0 -15
- python_motion_planning-1.1/src/python_motion_planning/local_planner/apf.py +0 -144
- python_motion_planning-1.1/src/python_motion_planning/local_planner/dwa.py +0 -212
- python_motion_planning-1.1/src/python_motion_planning/local_planner/local_planner.py +0 -262
- python_motion_planning-1.1/src/python_motion_planning/local_planner/lqr.py +0 -146
- python_motion_planning-1.1/src/python_motion_planning/local_planner/mpc.py +0 -214
- python_motion_planning-1.1/src/python_motion_planning/local_planner/pid.py +0 -158
- python_motion_planning-1.1/src/python_motion_planning/local_planner/rpp.py +0 -147
- python_motion_planning-1.1/src/python_motion_planning/utils/__init__.py +0 -19
- python_motion_planning-1.1/src/python_motion_planning/utils/agent/__init__.py +0 -0
- python_motion_planning-1.1/src/python_motion_planning/utils/agent/agent.py +0 -135
- python_motion_planning-1.1/src/python_motion_planning/utils/environment/__init__.py +0 -0
- python_motion_planning-1.1/src/python_motion_planning/utils/environment/env.py +0 -134
- python_motion_planning-1.1/src/python_motion_planning/utils/environment/node.py +0 -85
- python_motion_planning-1.1/src/python_motion_planning/utils/environment/point2d.py +0 -96
- python_motion_planning-1.1/src/python_motion_planning/utils/environment/pose2d.py +0 -91
- python_motion_planning-1.1/src/python_motion_planning/utils/helper/__init__.py +0 -3
- python_motion_planning-1.1/src/python_motion_planning/utils/helper/math_helper.py +0 -65
- python_motion_planning-1.1/src/python_motion_planning/utils/planner/__init__.py +0 -0
- python_motion_planning-1.1/src/python_motion_planning/utils/planner/control_factory.py +0 -27
- python_motion_planning-1.1/src/python_motion_planning/utils/planner/curve_factory.py +0 -29
- python_motion_planning-1.1/src/python_motion_planning/utils/planner/planner.py +0 -40
- python_motion_planning-1.1/src/python_motion_planning/utils/planner/search_factory.py +0 -51
- python_motion_planning-1.1/src/python_motion_planning/utils/plot/__init__.py +0 -0
- python_motion_planning-1.1/src/python_motion_planning/utils/plot/plot.py +0 -274
- python_motion_planning-1.1/src/python_motion_planning.egg-info/SOURCES.txt +0 -67
- python_motion_planning-1.1/src/python_motion_planning.egg-info/requires.txt +0 -7
- {python_motion_planning-1.1 → python_motion_planning-2.0}/LICENSE +0 -0
- {python_motion_planning-1.1 → python_motion_planning-2.0}/setup.cfg +0 -0
- {python_motion_planning-1.1 → python_motion_planning-2.0}/src/python_motion_planning.egg-info/dependency_links.txt +0 -0
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
2
|
Name: python-motion-planning
|
|
3
|
-
Version:
|
|
3
|
+
Version: 2.0
|
|
4
4
|
Summary: Motion planning algorithms for Python
|
|
5
|
-
Maintainer-email:
|
|
5
|
+
Maintainer-email: Wu Maojia <omige@mail.nwpu.edu.cn>, Yang Haodong <913982779@qq.com>
|
|
6
6
|
License: GNU GENERAL PUBLIC LICENSE
|
|
7
7
|
Version 3, 29 June 2007
|
|
8
8
|
|
|
@@ -687,14 +687,18 @@ License-File: LICENSE
|
|
|
687
687
|
Requires-Dist: numpy
|
|
688
688
|
Requires-Dist: scipy
|
|
689
689
|
Requires-Dist: matplotlib
|
|
690
|
-
Requires-Dist: cvxopt
|
|
691
690
|
Requires-Dist: osqp
|
|
692
|
-
Requires-Dist:
|
|
693
|
-
Requires-Dist:
|
|
691
|
+
Requires-Dist: gymnasium
|
|
692
|
+
Requires-Dist: faiss-cpu
|
|
693
|
+
Requires-Dist: pyvista
|
|
694
|
+
Requires-Dist: pyvistaqt
|
|
695
|
+
Dynamic: license-file
|
|
694
696
|
|
|
695
697
|
|
|
696
698
|
# Introduction
|
|
697
699
|
|
|
700
|
+
`Python Motion Planning` repository provides the implementations of common `Motion planning` algorithms, including path planners on N-D grid, controllers for path-tracking, curve generators, a visualizer based on matplotlib and a toy physical simulator to test controllers.
|
|
701
|
+
|
|
698
702
|
`Motion planning` plans the state sequence of the robot without conflict between the start and goal.
|
|
699
703
|
|
|
700
704
|
`Motion planning` mainly includes `Path planning` and `Trajectory planning`.
|
|
@@ -702,45 +706,38 @@ Requires-Dist: tensorboard==2.12.0
|
|
|
702
706
|
* `Path Planning`: It's based on path constraints (such as obstacles), planning the optimal path sequence for the robot to travel without conflict between the start and goal.
|
|
703
707
|
* `Trajectory planning`: It plans the motion state to approach the global path based on kinematics, dynamics constraints and path sequence.
|
|
704
708
|
|
|
705
|
-
This repository provides the implementations of common `Motion planning` algorithms. **Your stars and forks are welcome**. Maintaining this repository requires a huge amount of work. **Therefore, you are also welcome to contribute to this repository by opening issues, submitting pull requests or joining our development team**.
|
|
706
|
-
|
|
707
709
|
The theory analysis can be found at [motion-planning](https://blog.csdn.net/frigidwinter/category_11410243.html).
|
|
708
710
|
|
|
709
711
|
We also provide [ROS C++](https://github.com/ai-winter/ros_motion_planning) version and [Matlab](https://github.com/ai-winter/matlab_motion_planning) version.
|
|
710
712
|
|
|
713
|
+
**Your stars and forks are welcome!**
|
|
714
|
+
|
|
711
715
|
# Quick Start
|
|
712
716
|
|
|
713
717
|
## Overview
|
|
714
|
-
The file structure is shown below
|
|
718
|
+
The source file structure is shown below
|
|
715
719
|
|
|
716
720
|
```
|
|
717
721
|
python_motion_planning
|
|
718
|
-
├─
|
|
719
|
-
├─
|
|
720
|
-
├─
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
└─plot
|
|
722
|
+
├─common
|
|
723
|
+
| ├─env
|
|
724
|
+
| | ├─map
|
|
725
|
+
| | ├─robot
|
|
726
|
+
| | └─world
|
|
727
|
+
| ├─utils
|
|
728
|
+
| └─visualizer
|
|
729
|
+
├─controller
|
|
730
|
+
| └─path_tracker
|
|
731
|
+
├─path_planner
|
|
732
|
+
| ├─graph_search
|
|
733
|
+
| ├─sample_search
|
|
734
|
+
| └─hybrid_search
|
|
735
|
+
└─traj_optimizer
|
|
736
|
+
| └─curve_generator
|
|
734
737
|
```
|
|
735
738
|
|
|
736
|
-
* The global planning algorithm implementation is in the folder `global_planner` with `graph_search`, `sample_search` and `evolutionary search`.
|
|
737
|
-
|
|
738
|
-
* The local planning algorithm implementation is in the folder `local_planner`.
|
|
739
|
-
|
|
740
|
-
* The curve generation algorithm implementation is in the folder `curve_generation`.
|
|
741
|
-
|
|
742
739
|
## Install
|
|
743
|
-
*(Optional)* The code was tested in python=3.10. We recommend using `conda` to install the dependencies.
|
|
740
|
+
*(Optional)* The code was tested in python=3.10, though other similar versions should also work. We recommend using `conda` to install the dependencies.
|
|
744
741
|
|
|
745
742
|
```shell
|
|
746
743
|
conda create -n pmp python=3.10
|
|
@@ -754,132 +751,104 @@ pip install python-motion-planning
|
|
|
754
751
|
```
|
|
755
752
|
|
|
756
753
|
## Run
|
|
757
|
-
Below are some simple examples.
|
|
758
|
-
|
|
759
|
-
1. Run planning and animation separately
|
|
760
|
-
```python
|
|
761
|
-
import python_motion_planning as pmp
|
|
762
|
-
planner = pmp.AStar(start=(5, 5), goal=(45, 25), env=pmp.Grid(51, 31))
|
|
763
|
-
cost, path, expand = planner.plan()
|
|
764
|
-
planner.plot.animation(path, str(planner), cost, expand) # animation
|
|
765
|
-
```
|
|
766
|
-
|
|
767
|
-
2. Run planning and animation in one step
|
|
768
|
-
```python
|
|
769
|
-
import python_motion_planning as pmp
|
|
770
|
-
planner = pmp.AStar(start=(5, 5), goal=(45, 25), env=pmp.Grid(51, 31))
|
|
771
|
-
planner.run() # run both planning and animation
|
|
772
|
-
```
|
|
773
754
|
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
755
|
+
Please refer to the Tutorials part of [online documentation](https://ai-winter.github.io/python_motion_planning/).
|
|
756
|
+
|
|
757
|
+
# Demos
|
|
758
|
+
## Path Planner
|
|
759
|
+
### Graph Search
|
|
760
|
+
|Planner|2D Grid|3D Grid
|
|
761
|
+
|-------|-------|-------
|
|
762
|
+
**Dijkstra**||
|
|
763
|
+
**GBFS**||
|
|
764
|
+
**A\***||
|
|
765
|
+
**JPS**||
|
|
766
|
+
**Theta\***||
|
|
767
|
+
**Lazy Theta\***||
|
|
768
|
+
**D\***|Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
769
|
+
**LPA\***|Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
770
|
+
**D\* Lite**|Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
771
|
+
**Anya**|Not implemented|Not implemented
|
|
772
|
+
|
|
773
|
+
### Sample Search
|
|
774
|
+
|Planner|2D Grid|3D Grid
|
|
775
|
+
|-------|-------|-------
|
|
776
|
+
**RRT**||
|
|
777
|
+
**RRT\***||
|
|
778
|
+
**RRT-Connect**||
|
|
779
|
+
**Informed RRT**|Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
780
|
+
**PRM**|Not implemented|Not implemented
|
|
781
|
+
|
|
782
|
+
### Evolutionary Search
|
|
783
|
+
|Planner|2D Grid|3D Grid
|
|
784
|
+
|-------|-------|-------
|
|
785
|
+
| **ACO** |Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
786
|
+
| **GA** |Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
787
|
+
| **PSO** |Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
788
|
+
|
|
789
|
+
### Hybrid Search
|
|
790
|
+
|Planner|2D Grid|3D Grid
|
|
791
|
+
|-------|-------|-------
|
|
792
|
+
**Voronoi Planner**||
|
|
793
|
+
|
|
794
|
+
## Controller
|
|
795
|
+
|
|
796
|
+
We provide a toy simulator with simple physical simulation to test controllers (path-trakcers). The toy simulator supports multi-agents/multi-robots. The available robots include `CircularRobot` (Omnidirectional) and `DiffDriveRobot` (Only support moving forward and backward). Currently only 2D simulator is provided. 3D simulator has not been implemented.
|
|
797
|
+
|
|
798
|
+
In the following demos, the blue robot 1 is the `CircularRobot`, and the orange robot 2 is the `DiffDriveRobot`.
|
|
799
|
+
|
|
800
|
+
|Controller|2D|3D
|
|
801
|
+
|-------|-------|-------
|
|
802
|
+
|**Path Trakcer**||Not implemented
|
|
803
|
+
| **Pure Pursuit** ||Not implemented
|
|
804
|
+
| **PID** ||Not implemented
|
|
805
|
+
| **APF** ||Not implemented
|
|
806
|
+
| **DWA** ||Not implemented
|
|
807
|
+
| **RPP** ||Not implemented
|
|
808
|
+
| **LQR** |Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
809
|
+
| **MPC** |Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
810
|
+
| **MPPI** |Not implemented|Not implemented
|
|
811
|
+
| **TEB** |Not implemented|Not implemented
|
|
812
|
+
| **Lattice** |Not implemented|Not implemented
|
|
813
|
+
| **DQN** |Not implemented|Not implemented
|
|
814
|
+
| **DDPG** |Implemented in [V1.0](https://github.com/ai-winter/python_motion_planning/tree/v1.0), not migrated|Not implemented
|
|
815
|
+
|
|
816
|
+
## Curve Generator
|
|
817
|
+
|
|
818
|
+
|Generator|2D|3D|
|
|
819
|
+
| ------- | -------------------------------------------------------- | --------------------------------------------------------
|
|
820
|
+
| **Polynomia** | |Not implemented
|
|
821
|
+
| **Bezier** ||Not implemented
|
|
822
|
+
| **Cubic Spline** ||Not implemented
|
|
823
|
+
| **BSpline** ||Not implemented
|
|
824
|
+
| **Dubins** ||Not implemented
|
|
825
|
+
| **Reeds-Shepp** ||Not implemented
|
|
787
826
|
|
|
788
|
-
|
|
827
|
+
# Future Works
|
|
789
828
|
|
|
790
|
-
|
|
791
|
-
python generate_mkdocs.py
|
|
792
|
-
mkdocs serve
|
|
793
|
-
```
|
|
829
|
+
* N-D controllers (path-trackers).
|
|
794
830
|
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
# Version
|
|
798
|
-
## Global Planner
|
|
799
|
-
|
|
800
|
-
Planner | Version | Animation
|
|
801
|
-
------------ |---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| ---------
|
|
802
|
-
**GBFS** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/gbfs.py) | 
|
|
803
|
-
**Dijkstra** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/dijkstra.py) | 
|
|
804
|
-
**A*** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/a_star.py) | 
|
|
805
|
-
**JPS** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/jps.py) | 
|
|
806
|
-
**D*** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/d_star.py) | 
|
|
807
|
-
**LPA*** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/lpa_star.py) | 
|
|
808
|
-
**D\* Lite** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/d_star_lite.py) | 
|
|
809
|
-
**Theta\*** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/theta_star.py) | 
|
|
810
|
-
**Lazy Theta\*** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/lazy_theta_star.py) | 
|
|
811
|
-
**S-Theta\*** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/s_theta_star.py) | 
|
|
812
|
-
**Anya** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/anya.py) | 
|
|
813
|
-
**Voronoi** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/voronoi.py) | 
|
|
814
|
-
**RRT** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/sample_search/rrt.py) | 
|
|
815
|
-
**RRT*** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/sample_search/rrt_star.py) | 
|
|
816
|
-
**Informed RRT** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/sample_search/informed_rrt.py) | 
|
|
817
|
-
**RRT-Connect** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/sample_search/rrt_connect.py) | 
|
|
818
|
-
| **ACO** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/evolutionary_search/aco.py) | 
|
|
819
|
-
| **GA** |  | 
|
|
820
|
-
| **PSO** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/evolutionary_search/pso.py) |  
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
## Local Planner
|
|
824
|
-
|
|
825
|
-
| Planner | Version | Animation
|
|
826
|
-
|-------------|--------------------------------------------------------------------------------------------------------------------------------------------------------| --------------------------------------------------
|
|
827
|
-
| **PID** | [](https://github.com/ai-winter/python_motion_planning/blob/master/local_planner/pid.py) | 
|
|
828
|
-
| **APF** | [](https://github.com/ai-winter/python_motion_planning/blob/master/local_planner/apf.py) | 
|
|
829
|
-
| **DWA** | [](https://github.com/ai-winter/python_motion_planning/blob/master/local_planner/dwa.py) | 
|
|
830
|
-
| **RPP** | [](https://github.com/ai-winter/python_motion_planning/blob/master/local_planner/rpp.py) | 
|
|
831
|
-
| **LQR** | [](https://github.com/ai-winter/python_motion_planning/blob/master/local_planner/lqr.py) | 
|
|
832
|
-
| **TEB** |  | 
|
|
833
|
-
| **MPC** | [](https://github.com/ai-winter/python_motion_planning/blob/master/local_planner/mpc.py) | 
|
|
834
|
-
| **MPPI** |  |
|
|
835
|
-
| **Lattice** |  |
|
|
836
|
-
| **DQN** |  |
|
|
837
|
-
| **DDPG** |  |
|
|
838
|
-
|
|
839
|
-
## Curve Generation
|
|
840
|
-
|
|
841
|
-
| Planner | Version | Animation |
|
|
842
|
-
| ------- | -------------------------------------------------------- | --------------------------------------------------------
|
|
843
|
-
| **Polynomia** | [](https://github.com/ai-winter/python_motion_planning/blob/master/curve_generation/polynomial_curve.py) | 
|
|
844
|
-
| **Bezier** | [](https://github.com/ai-winter/python_motion_planning/blob/master/curve_generation/bezier_curve.py) | 
|
|
845
|
-
| **Cubic Spline** | [](https://github.com/ai-winter/python_motion_planning/blob/master/curve_generation/cubic_spline.py) | 
|
|
846
|
-
| **BSpline** | [](https://github.com/ai-winter/python_motion_planning/blob/master/curve_generation/bspline_curve.py) | 
|
|
847
|
-
| **Dubins** | [](https://github.com/ai-winter/python_motion_planning/blob/master/curve_generation/dubins_curve.py) | 
|
|
848
|
-
| **Reeds-Shepp** | [](https://github.com/ai-winter/python_motion_planning/blob/master/curve_generation/reeds_shepp.py) | 
|
|
849
|
-
| **Fem-Pos Smoother** | [](https://github.com/ai-winter/python_motion_planning/blob/master/curve_generation/fem_pos_smooth.py) | 
|
|
831
|
+
* Path planning for robotic arms.
|
|
850
832
|
|
|
833
|
+
* Path planning on topological map.
|
|
851
834
|
|
|
835
|
+
* Sample search with Dubins or Reeds-Shepp curves.
|
|
852
836
|
|
|
837
|
+
* Application on ROS2.
|
|
853
838
|
|
|
854
|
-
|
|
855
|
-
## Global Planning
|
|
839
|
+
* Application in mainstream robot simulation environments (e.g. Gazebo, Carla, Airsim, PyBullet, MuJoCo, Issac Sim).
|
|
856
840
|
|
|
857
|
-
*
|
|
858
|
-
* [JPS:](https://ojs.aaai.org/index.php/AAAI/article/view/7994) Online Graph Pruning for Pathfinding On Grid Maps
|
|
859
|
-
* [Lifelong Planning A*: ](https://www.cs.cmu.edu/~maxim/files/aij04.pdf) Lifelong Planning A*
|
|
860
|
-
* [D*: ](http://web.mit.edu/16.412j/www/html/papers/original_dstar_icra94.pdf) Optimal and Efficient Path Planning for Partially-Known Environments
|
|
861
|
-
* [D* Lite: ](http://idm-lab.org/bib/abstracts/papers/aaai02b.pdf) D* Lite
|
|
862
|
-
* [Theta*: ](https://www.jair.org/index.php/jair/article/view/10676) Theta*: Any-Angle Path Planning on Grids
|
|
863
|
-
* [Lazy Theta*: ](https://ojs.aaai.org/index.php/AAAI/article/view/7566) Lazy Theta*: Any-Angle Path Planning and Path Length Analysis in 3D
|
|
864
|
-
* [S-Theta*: ](https://link.springer.com/chapter/10.1007/978-1-4471-4739-8_8) S-Theta*: low steering path-planning algorithm
|
|
865
|
-
* [Anya: ](http://www.grastien.net/ban/articles/hgoa-jair16.pdf) Optimal Any-Angle Pathfinding In Practice
|
|
866
|
-
* [RRT: ](http://msl.cs.uiuc.edu/~lavalle/papers/Lav98c.pdf) Rapidly-Exploring Random Trees: A New Tool for Path Planning
|
|
867
|
-
* [RRT-Connect: ](http://www-cgi.cs.cmu.edu/afs/cs/academic/class/15494-s12/readings/kuffner_icra2000.pdf) RRT-Connect: An Efficient Approach to Single-Query Path Planning
|
|
868
|
-
* [RRT*: ](https://journals.sagepub.com/doi/abs/10.1177/0278364911406761) Sampling-based algorithms for optimal motion planning
|
|
869
|
-
* [Informed RRT*: ](https://arxiv.org/abs/1404.2334) Optimal Sampling-based Path Planning Focused via Direct Sampling of an Admissible Ellipsoidal heuristic
|
|
870
|
-
* [ACO: ](http://www.cs.yale.edu/homes/lans/readings/routing/dorigo-ants-1999.pdf) Ant Colony Optimization: A New Meta-Heuristic
|
|
841
|
+
* More mainstream motion planning algorithms.
|
|
871
842
|
|
|
872
|
-
|
|
843
|
+
* Performance optimization.
|
|
873
844
|
|
|
874
|
-
|
|
875
|
-
* [APF: ](https://ieeexplore.ieee.org/document/1087247) Real-time obstacle avoidance for manipulators and mobile robots
|
|
876
|
-
* [RPP: ](https://arxiv.org/pdf/2305.20026.pdf) Regulated Pure Pursuit for Robot Path Tracking
|
|
877
|
-
* [DDPG: ](https://arxiv.org/abs/1509.02971) Continuous control with deep reinforcement learning
|
|
845
|
+
Contributors are welcome! For trivial modification, please directly contribute to `dev` branch. For big modification, please [contact](#contact) us before you contribute.
|
|
878
846
|
|
|
879
|
-
|
|
847
|
+
# Contact
|
|
880
848
|
|
|
881
|
-
|
|
849
|
+
Long-term maintainers:
|
|
882
850
|
|
|
883
|
-
|
|
851
|
+
* [@omigeft](https://github.com/omigeft) (Wu Maojia)
|
|
852
|
+
* [@ai-winter](https://github.com/ai-winter) (Yang Haodong)
|
|
884
853
|
|
|
885
|
-
|
|
854
|
+
You can contact us via the information provided on our profile.
|
|
@@ -0,0 +1,158 @@
|
|
|
1
|
+
|
|
2
|
+
# Introduction
|
|
3
|
+
|
|
4
|
+
`Python Motion Planning` repository provides the implementations of common `Motion planning` algorithms, including path planners on N-D grid, controllers for path-tracking, curve generators, a visualizer based on matplotlib and a toy physical simulator to test controllers.
|
|
5
|
+
|
|
6
|
+
`Motion planning` plans the state sequence of the robot without conflict between the start and goal.
|
|
7
|
+
|
|
8
|
+
`Motion planning` mainly includes `Path planning` and `Trajectory planning`.
|
|
9
|
+
|
|
10
|
+
* `Path Planning`: It's based on path constraints (such as obstacles), planning the optimal path sequence for the robot to travel without conflict between the start and goal.
|
|
11
|
+
* `Trajectory planning`: It plans the motion state to approach the global path based on kinematics, dynamics constraints and path sequence.
|
|
12
|
+
|
|
13
|
+
The theory analysis can be found at [motion-planning](https://blog.csdn.net/frigidwinter/category_11410243.html).
|
|
14
|
+
|
|
15
|
+
We also provide [ROS C++](https://github.com/ai-winter/ros_motion_planning) version and [Matlab](https://github.com/ai-winter/matlab_motion_planning) version.
|
|
16
|
+
|
|
17
|
+
**Your stars and forks are welcome!**
|
|
18
|
+
|
|
19
|
+
# Quick Start
|
|
20
|
+
|
|
21
|
+
## Overview
|
|
22
|
+
The source file structure is shown below
|
|
23
|
+
|
|
24
|
+
```
|
|
25
|
+
python_motion_planning
|
|
26
|
+
├─common
|
|
27
|
+
| ├─env
|
|
28
|
+
| | ├─map
|
|
29
|
+
| | ├─robot
|
|
30
|
+
| | └─world
|
|
31
|
+
| ├─utils
|
|
32
|
+
| └─visualizer
|
|
33
|
+
├─controller
|
|
34
|
+
| └─path_tracker
|
|
35
|
+
├─path_planner
|
|
36
|
+
| ├─graph_search
|
|
37
|
+
| ├─sample_search
|
|
38
|
+
| └─hybrid_search
|
|
39
|
+
└─traj_optimizer
|
|
40
|
+
| └─curve_generator
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
## Install
|
|
44
|
+
*(Optional)* The code was tested in python=3.10, though other similar versions should also work. We recommend using `conda` to install the dependencies.
|
|
45
|
+
|
|
46
|
+
```shell
|
|
47
|
+
conda create -n pmp python=3.10
|
|
48
|
+
conda activate pmp
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
To install the repository, please run the following command in shell.
|
|
52
|
+
|
|
53
|
+
```shell
|
|
54
|
+
pip install python-motion-planning
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
## Run
|
|
58
|
+
|
|
59
|
+
Please refer to the Tutorials part of [online documentation](https://ai-winter.github.io/python_motion_planning/).
|
|
60
|
+
|
|
61
|
+
# Demos
|
|
62
|
+
## Path Planner
|
|
63
|
+
### Graph Search
|
|
64
|
+
|Planner|2D Grid|3D Grid
|
|
65
|
+
|-------|-------|-------
|
|
66
|
+
**Dijkstra**||
|
|
67
|
+
**GBFS**||
|
|
68
|
+
**A\***||
|
|
69
|
+
**JPS**||
|
|
70
|
+
**Theta\***||
|
|
71
|
+
**Lazy Theta\***||
|
|
72
|
+
**D\***|Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
73
|
+
**LPA\***|Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
74
|
+
**D\* Lite**|Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
75
|
+
**Anya**|Not implemented|Not implemented
|
|
76
|
+
|
|
77
|
+
### Sample Search
|
|
78
|
+
|Planner|2D Grid|3D Grid
|
|
79
|
+
|-------|-------|-------
|
|
80
|
+
**RRT**||
|
|
81
|
+
**RRT\***||
|
|
82
|
+
**RRT-Connect**||
|
|
83
|
+
**Informed RRT**|Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
84
|
+
**PRM**|Not implemented|Not implemented
|
|
85
|
+
|
|
86
|
+
### Evolutionary Search
|
|
87
|
+
|Planner|2D Grid|3D Grid
|
|
88
|
+
|-------|-------|-------
|
|
89
|
+
| **ACO** |Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
90
|
+
| **GA** |Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
91
|
+
| **PSO** |Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
92
|
+
|
|
93
|
+
### Hybrid Search
|
|
94
|
+
|Planner|2D Grid|3D Grid
|
|
95
|
+
|-------|-------|-------
|
|
96
|
+
**Voronoi Planner**||
|
|
97
|
+
|
|
98
|
+
## Controller
|
|
99
|
+
|
|
100
|
+
We provide a toy simulator with simple physical simulation to test controllers (path-trakcers). The toy simulator supports multi-agents/multi-robots. The available robots include `CircularRobot` (Omnidirectional) and `DiffDriveRobot` (Only support moving forward and backward). Currently only 2D simulator is provided. 3D simulator has not been implemented.
|
|
101
|
+
|
|
102
|
+
In the following demos, the blue robot 1 is the `CircularRobot`, and the orange robot 2 is the `DiffDriveRobot`.
|
|
103
|
+
|
|
104
|
+
|Controller|2D|3D
|
|
105
|
+
|-------|-------|-------
|
|
106
|
+
|**Path Trakcer**||Not implemented
|
|
107
|
+
| **Pure Pursuit** ||Not implemented
|
|
108
|
+
| **PID** ||Not implemented
|
|
109
|
+
| **APF** ||Not implemented
|
|
110
|
+
| **DWA** ||Not implemented
|
|
111
|
+
| **RPP** ||Not implemented
|
|
112
|
+
| **LQR** |Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
113
|
+
| **MPC** |Implemented in [V1.1.1](https://github.com/ai-winter/python_motion_planning/tree/v1.1.1), not migrated|Not implemented
|
|
114
|
+
| **MPPI** |Not implemented|Not implemented
|
|
115
|
+
| **TEB** |Not implemented|Not implemented
|
|
116
|
+
| **Lattice** |Not implemented|Not implemented
|
|
117
|
+
| **DQN** |Not implemented|Not implemented
|
|
118
|
+
| **DDPG** |Implemented in [V1.0](https://github.com/ai-winter/python_motion_planning/tree/v1.0), not migrated|Not implemented
|
|
119
|
+
|
|
120
|
+
## Curve Generator
|
|
121
|
+
|
|
122
|
+
|Generator|2D|3D|
|
|
123
|
+
| ------- | -------------------------------------------------------- | --------------------------------------------------------
|
|
124
|
+
| **Polynomia** | |Not implemented
|
|
125
|
+
| **Bezier** ||Not implemented
|
|
126
|
+
| **Cubic Spline** ||Not implemented
|
|
127
|
+
| **BSpline** ||Not implemented
|
|
128
|
+
| **Dubins** ||Not implemented
|
|
129
|
+
| **Reeds-Shepp** ||Not implemented
|
|
130
|
+
|
|
131
|
+
# Future Works
|
|
132
|
+
|
|
133
|
+
* N-D controllers (path-trackers).
|
|
134
|
+
|
|
135
|
+
* Path planning for robotic arms.
|
|
136
|
+
|
|
137
|
+
* Path planning on topological map.
|
|
138
|
+
|
|
139
|
+
* Sample search with Dubins or Reeds-Shepp curves.
|
|
140
|
+
|
|
141
|
+
* Application on ROS2.
|
|
142
|
+
|
|
143
|
+
* Application in mainstream robot simulation environments (e.g. Gazebo, Carla, Airsim, PyBullet, MuJoCo, Issac Sim).
|
|
144
|
+
|
|
145
|
+
* More mainstream motion planning algorithms.
|
|
146
|
+
|
|
147
|
+
* Performance optimization.
|
|
148
|
+
|
|
149
|
+
Contributors are welcome! For trivial modification, please directly contribute to `dev` branch. For big modification, please [contact](#contact) us before you contribute.
|
|
150
|
+
|
|
151
|
+
# Contact
|
|
152
|
+
|
|
153
|
+
Long-term maintainers:
|
|
154
|
+
|
|
155
|
+
* [@omigeft](https://github.com/omigeft) (Wu Maojia)
|
|
156
|
+
* [@ai-winter](https://github.com/ai-winter) (Yang Haodong)
|
|
157
|
+
|
|
158
|
+
You can contact us via the information provided on our profile.
|
|
@@ -4,11 +4,11 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "python-motion-planning"
|
|
7
|
-
version = "
|
|
7
|
+
version = "2.0"
|
|
8
8
|
description = "Motion planning algorithms for Python"
|
|
9
9
|
maintainers = [
|
|
10
|
-
{name = "
|
|
11
|
-
{name = "
|
|
10
|
+
{name = "Wu Maojia", email = "omige@mail.nwpu.edu.cn"},
|
|
11
|
+
{name = "Yang Haodong", email = "913982779@qq.com"}
|
|
12
12
|
]
|
|
13
13
|
readme = "README.md"
|
|
14
14
|
license = {file = "LICENSE"}
|
|
@@ -17,10 +17,11 @@ dependencies = [
|
|
|
17
17
|
"numpy",
|
|
18
18
|
"scipy",
|
|
19
19
|
"matplotlib",
|
|
20
|
-
"cvxopt",
|
|
21
20
|
"osqp",
|
|
22
|
-
"
|
|
23
|
-
"
|
|
21
|
+
"gymnasium",
|
|
22
|
+
"faiss-cpu",
|
|
23
|
+
"pyvista",
|
|
24
|
+
"pyvistaqt"
|
|
24
25
|
]
|
|
25
26
|
classifiers = [
|
|
26
27
|
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
|