|
| 1 | +Examples: |
1 | 2 |
|
2 | | -# Introduction |
3 | | - |
4 | | -`Motion planning` plans the state sequence of the robot without conflict between the start and goal. |
5 | | - |
6 | | -`Motion planning` mainly includes `Path planning` and `Trajectory planning`. |
7 | | - |
8 | | -* `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. |
9 | | -* `Trajectory planning`: It plans the motion state to approach the global path based on kinematics, dynamics constraints and path sequence. |
10 | | - |
11 | | -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**. |
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 | | -# Quick Start |
18 | | - |
19 | | -## Overview |
20 | | -The file structure is shown below |
21 | | - |
22 | | -``` |
23 | | -python_motion_planning |
24 | | -├─assets |
25 | | -├─docs |
26 | | -├─examples |
27 | | -└─python_motion_planning |
28 | | - ├─global_planner |
29 | | - | ├─graph_search |
30 | | - | ├─sample_search |
31 | | - | └─evolutionary_search |
32 | | - ├─local_planner |
33 | | - ├─curve_generation |
34 | | - └─utils |
35 | | - ├─agent |
36 | | - ├─environment |
37 | | - ├─helper |
38 | | - ├─planner |
39 | | - └─plot |
40 | | -``` |
41 | | -* The global planning algorithm implementation is in the folder `global_planner` with `graph_search`, `sample_search` and `evolutionary search`. |
42 | | -* The local planning algorithm implementation is in the folder `local_planner`. |
43 | | -* The curve generation algorithm implementation is in the folder `curve_generation`. |
44 | | - |
45 | | -## Install |
46 | | -*(Optional)* The code was tested in python=3.10. We recommend using `conda` to install the dependencies. |
47 | | - |
48 | | -```shell |
49 | | -conda create -n pmp python=3.10 |
50 | | -conda activate pmp |
51 | | -``` |
52 | | - |
53 | | -To install the repository, please run the following command in shell. |
54 | | - |
55 | | -```shell |
56 | | -pip install python-motion-planning |
57 | | -``` |
58 | | - |
59 | | -## Run |
60 | | -Below are some simple examples. |
61 | | - |
62 | | -1. Run planning and animation separately |
63 | | -```python |
64 | | -import python_motion_planning as pmp |
65 | | -planner = pmp.AStar(start=(5, 5), goal=(45, 25), env=pmp.Grid(51, 31)) |
66 | | -cost, path, expand = planner.plan() |
67 | | -planner.plot.animation(path, str(planner), cost, expand) # animation |
68 | | -``` |
69 | | - |
70 | | -2. Run planning and animation in one step |
71 | | -```python |
72 | | -import python_motion_planning as pmp |
73 | | -planner = pmp.AStar(start=(5, 5), goal=(45, 25), env=pmp.Grid(51, 31)) |
74 | | -planner.run() # run both planning and animation |
75 | | -``` |
76 | | - |
77 | | -3. Create planner in factory mode |
78 | | -```python |
79 | | -import python_motion_planning as pmp |
80 | | -search_factory = pmp.SearchFactory() |
81 | | -planner = search_factory("a_star", start=(5, 5), goal=(45, 25), env=pmp.Grid(51, 31)) |
82 | | -planner.run() # run both planning and animation |
83 | | -``` |
84 | | - |
85 | | -More examples can be found in the folder `examples` in the repository. You can also refer to the examples in the documentations generated using the following method. |
86 | | - |
87 | | -## Documentation |
88 | | - |
89 | | -This repository also support auto-generated documentation using mkdocs. Enter the root directory and run |
90 | | - |
91 | | -```shell |
| 3 | +```bash |
| 4 | +pip install mike |
| 5 | +git checkout v1.0 |
92 | 6 | python generate_mkdocs.py |
93 | | -mkdocs serve |
94 | | -``` |
95 | | - |
96 | | -Then open the browser and go to [http://127.0.0.1:8000](http://127.0.0.1:8000). That is the generated documentation. |
97 | | - |
98 | | -# Version |
99 | | -## Global Planner |
100 | | - |
101 | | -Planner | Version | Animation |
102 | | ------------- |---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| --------- |
103 | | -**GBFS** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/gbfs.py) |  |
104 | | -**Dijkstra** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/dijkstra.py) |  |
105 | | -**A*** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/a_star.py) |  |
106 | | -**JPS** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/jps.py) |  |
107 | | -**D*** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/d_star.py) |  |
108 | | -**LPA*** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/lpa_star.py) |  |
109 | | -**D\* Lite** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/d_star_lite.py) |  |
110 | | -**Theta\*** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/theta_star.py) |  |
111 | | -**Lazy Theta\*** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/lazy_theta_star.py) |  |
112 | | -**S-Theta\*** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/s_theta_star.py) |  |
113 | | -**Anya** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/anya.py) |  |
114 | | -**Voronoi** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/graph_search/voronoi.py) |  |
115 | | -**RRT** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/sample_search/rrt.py) |  |
116 | | -**RRT*** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/sample_search/rrt_star.py) |  |
117 | | -**Informed RRT** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/sample_search/informed_rrt.py) |  |
118 | | -**RRT-Connect** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/sample_search/rrt_connect.py) |  |
119 | | -| **ACO** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/evolutionary_search/aco.py) |  |
120 | | -| **GA** |  |  |
121 | | -| **PSO** | [](https://github.com/ai-winter/python_motion_planning/blob/master/global_planner/evolutionary_search/pso.py) |   |
122 | | - |
123 | | - |
124 | | -## Local Planner |
125 | | -| Planner | Version | Animation |
126 | | -|-------------|--------------------------------------------------------------------------------------------------------------------------------------------------------| -------------------------------------------------- |
127 | | -| **PID** | [](https://github.com/ai-winter/python_motion_planning/blob/master/local_planner/pid.py) |  |
128 | | -| **APF** | [](https://github.com/ai-winter/python_motion_planning/blob/master/local_planner/apf.py) |  |
129 | | -| **DWA** | [](https://github.com/ai-winter/python_motion_planning/blob/master/local_planner/dwa.py) |  |
130 | | -| **RPP** | [](https://github.com/ai-winter/python_motion_planning/blob/master/local_planner/rpp.py) |  |
131 | | -| **LQR** | [](https://github.com/ai-winter/python_motion_planning/blob/master/local_planner/lqr.py) |  |
132 | | -| **TEB** |  |  |
133 | | -| **MPC** | [](https://github.com/ai-winter/python_motion_planning/blob/master/local_planner/mpc.py) |  |
134 | | -| **MPPI** |  | |
135 | | -| **Lattice** |  | |
136 | | -| **DQN** |  | |
137 | | -| **DDPG** |  | |
138 | | - |
139 | | -## Curve Generation |
140 | | - |
141 | | -| Planner | Version | Animation | |
142 | | -| ------- | -------------------------------------------------------- | -------------------------------------------------------- |
143 | | -| **Polynomia** | [](https://github.com/ai-winter/python_motion_planning/blob/master/curve_generation/polynomial_curve.py) |  |
144 | | -| **Bezier** | [](https://github.com/ai-winter/python_motion_planning/blob/master/curve_generation/bezier_curve.py) |  |
145 | | -| **Cubic Spline** | [](https://github.com/ai-winter/python_motion_planning/blob/master/curve_generation/cubic_spline.py) |  |
146 | | -| **BSpline** | [](https://github.com/ai-winter/python_motion_planning/blob/master/curve_generation/bspline_curve.py) |  |
147 | | -| **Dubins** | [](https://github.com/ai-winter/python_motion_planning/blob/master/curve_generation/dubins_curve.py) |  |
148 | | -| **Reeds-Shepp** | [](https://github.com/ai-winter/python_motion_planning/blob/master/curve_generation/reeds_shepp.py) |  |
149 | | -| **Fem-Pos Smoother** | [](https://github.com/ai-winter/python_motion_planning/blob/master/curve_generation/fem_pos_smooth.py) |  |
150 | | - |
151 | | - |
152 | | - |
153 | | - |
154 | | -# Papers |
155 | | -## Global Planning |
156 | | -* [A*: ](https://ieeexplore.ieee.org/document/4082128) A Formal Basis for the heuristic Determination of Minimum Cost Paths |
157 | | -* [JPS:](https://ojs.aaai.org/index.php/AAAI/article/view/7994) Online Graph Pruning for Pathfinding On Grid Maps |
158 | | -* [Lifelong Planning A*: ](https://www.cs.cmu.edu/~maxim/files/aij04.pdf) Lifelong Planning A* |
159 | | -* [D*: ](http://web.mit.edu/16.412j/www/html/papers/original_dstar_icra94.pdf) Optimal and Efficient Path Planning for Partially-Known Environments |
160 | | -* [D* Lite: ](http://idm-lab.org/bib/abstracts/papers/aaai02b.pdf) D* Lite |
161 | | -* [Theta*: ](https://www.jair.org/index.php/jair/article/view/10676) Theta*: Any-Angle Path Planning on Grids |
162 | | -* [Lazy Theta*: ](https://ojs.aaai.org/index.php/AAAI/article/view/7566) Lazy Theta*: Any-Angle Path Planning and Path Length Analysis in 3D |
163 | | -* [S-Theta*: ](https://link.springer.com/chapter/10.1007/978-1-4471-4739-8_8) S-Theta*: low steering path-planning algorithm |
164 | | -* [Anya: ](http://www.grastien.net/ban/articles/hgoa-jair16.pdf) Optimal Any-Angle Pathfinding In Practice |
165 | | -* [RRT: ](http://msl.cs.uiuc.edu/~lavalle/papers/Lav98c.pdf) Rapidly-Exploring Random Trees: A New Tool for Path Planning |
166 | | -* [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 |
167 | | -* [RRT*: ](https://journals.sagepub.com/doi/abs/10.1177/0278364911406761) Sampling-based algorithms for optimal motion planning |
168 | | -* [Informed RRT*: ](https://arxiv.org/abs/1404.2334) Optimal Sampling-based Path Planning Focused via Direct Sampling of an Admissible Ellipsoidal heuristic |
169 | | -* [ACO: ](http://www.cs.yale.edu/homes/lans/readings/routing/dorigo-ants-1999.pdf) Ant Colony Optimization: A New Meta-Heuristic |
170 | | - |
171 | | -## Local Planning |
172 | | - |
173 | | -* [DWA: ](https://www.ri.cmu.edu/pub_files/pub1/fox_dieter_1997_1/fox_dieter_1997_1.pdf) The Dynamic Window Approach to Collision Avoidance |
174 | | -* [APF: ](https://ieeexplore.ieee.org/document/1087247) Real-time obstacle avoidance for manipulators and mobile robots |
175 | | -* [RPP: ](https://arxiv.org/pdf/2305.20026.pdf) Regulated Pure Pursuit for Robot Path Tracking |
176 | | -* [DDPG: ](https://arxiv.org/abs/1509.02971) Continuous control with deep reinforcement learning |
177 | | - |
178 | | -## Curve Generation |
179 | | -* [Dubins: ]() On curves of minimal length with a constraint on average curvature, and with prescribed initial and terminal positions and tangents |
180 | | - |
181 | | -# Acknowledgment |
182 | | -* Our visualization and animation framework of Python Version refers to [https://github.com/zhm-real/PathPlanning](https://github.com/zhm-real/PathPlanning). Thanks sincerely. |
| 7 | +mike deploy v1.0 --push |
| 8 | +git checkout v1.1 |
| 9 | +python generate_mkdocs.py |
| 10 | +mike deploy v1.1 latest --push |
| 11 | +``` |
0 commit comments