Navigation with Polytopes: A Toolbox for Optimal Path Planning with Polytope Maps and B-spline Curves
Abstract
:1. Introduction
- A complete procedure to construct the polytope map from a standard occupancy grid map and seek an appropriate corridor (sequence of connected polytopes), leading to the destination.
- A new algorithm to calculate the B-spline-to-Bézier conversion matrix of a uniform B-spline curve: It takes into account the differences between each interval of the whole curve and the dependencies on the total number of control points as well as the degree of the curve.
- New path planning constraints for a B-spline path to stay inside a sequence of connected polytopes in 2D. The equivalent Bézier representation is introduced in two variants:
- Navigation with Polytopes (https://gitlab.rob.uni-luebeck.de/robPublic/navigation_with_polytopes, accessed on 19 February 2023) toolbox: It comes as a complete Python package and serves as a framework for direct and quick implementation of existing polytope-based navigation control techniques on a realistic grid map of the environment with ROS (robot operating system) compatibility (c.f. Figure 1). It provides the following features:
- (a)
- Construction of a polytope map from a standard grid map with consideration of the robot’s dimension and possible noises.
- (b)
- Search for a sequence of connected polytopes (i.e., a polytopic corridor) connecting two given points with minimal distance.
- (c)
- (d)
- Library for calculating and storing the B-spline-to-Bézier conversion matrix.
2. Problem Description
3. Polytope Map
3.1. Construction of Polytope Map from an Occupancy Grid Map
- Extract the outer boundary of the complete map using the function findContours with the option RETR_EXTERNAL of the OpenCV toolbox (https://opencv.org/, accessed on 19 February 2023) as shown in Figure 2b.
- Extract the boundaries for all of the obstacles by using the same function findContours with the option RETR_LIST as shown in Figure 2c.
- Simplify the contours obtained using the RDP (Ramer–Douglas–Peucker) algorithm (https://github.com/biran0079/crdp, accessed on 19 February 2023) with two parameters for the outer boundary and for inner obstacles [23].
- Shrink the outer boundary and enlarge the obstacles by a safety offset by using the Gdspy toolbox (https://github.com/heitzmann/gdspy, accessed on 19 February 2023) and apply the Boolean operation to remove obstacles from the outer boundary polytope, as shown in Figure 2d.
- Partition the obstacle-free polytope (possibly with holes) into connected polytopes by using Mark Bayazit’s algorithm (https://github.com/wsilva32/poly_decomp.py, accessed on 19 February 2023), as shown in Figure 2e.
3.2. Finding of Appropriate Sequence of Polytopes for Navigation
- Each pair of polytopes is examined to find out if they share a common edge. If yes, then they are recognized as a connected pair.
- From the information, an adjacency graph is created (c.f Figure 3b), which presents all polytopes as nodes and their connections to other polytopes.
- Then a weighted graph is created from the adjacency graph by adding the distances between the center points of any pairs of connected polytopes.
- Next, there is a search for the starting and ending polytopes by checking which polytopes contain the points .
- A graph search algorithm can then be implemented on the weighted graph to obtain the sequence of polytopes with minimal travel distance.
3.3. Transition Zone and Extended Polytope
4. B-spline and Equivalent Bézier Curves
4.1. Definition of B-spline Curves
- (P1)
- (P2)
- The first and last control points and from (10) are also the starting and ending points of the curve :
- (P3)
4.2. Local Equivalent Bézier Representation
- (P1*)
- (P2*)
- The B-spline curve passes through waypoints, which can be determined by using only the B-spline control points (including the first and last control points as two endpoints):
4.3. Calculation of B-spline-to-Bézier Conversion Matrix
4.3.1. Equivalent Bézier Control Points of One Interval
4.3.2. Conversion Matrix of One Interval
4.3.3. Conversion Matrix of the Whole Curve
4.3.4. Evaluation of the B-spline-to-Bézier Conversion Algorithm
4.4. Application of B-spline-to-Bézier Conversion on 2D Path Planning
5. B-spline Path Planning Algorithms in a Sequence of Connected Polytopes
5.1. Variant 1: Constraint Formulation with a Minimal Number of Control Points
5.2. Variant 2: Constraint Formulation with Guaranteed Solution
- (C1)
- (C2)
- (C3)
- First and last intervals stay in the first and last (i.e., ) extended polytopes (8), respectively:
- (C4)
- (1)
- Condition C2 (37) helps to ensure the start and end points of the path.
- (2)
- Condition C1 provides a sufficient number of intervals of the curve for the existence of a feasible solution. All of the intervals are then constrained to stay within the safe region by two conditions C3–C4 because each Bézier control boundary (i.e., the convex hull of the corresponding Bézier control points (24)) is inside one extended polytope.
- (3)
- Solutions for the complete problem (36)–(39) always exist. One can be found by placing the original B-spline control points according to two conditions:
- (i)
- The first and last points chosen according to (37).
- (ii)
- Having d points in every transition zone :
5.3. Path Generation Problem with Minimal Length
6. Navigation with Polytopes Toolbox
6.1. Introduction to the Toolbox
- navigation_with_polytopes—toolbox with source code.
- navigation_with_polytope_ros—integration of the toolbox into ROS.
- Examples–sample python scripts for the illustration of the toolbox.
- Constructs a polytope map from a grid map.
- Finds an appropriate sequence of polytopes.
- Plans a B-spline path with different algorithms.
- (1)
- bezier_min calls the Variant 1 algorithm given in Section 5.1, which uses the proposed B-spline-to-Bézier conversion method with a minimal number of control points [8];
- (2)
- bezier_guarantee (default option) uses the Variant 2 algorithm given in Section 5.2 with a guaranteed solution [9];
- (3)
- bspline_guarantee returns the algebraic solution (40) of Proposition 2. The whole calculation is done with the original B-spline format and with a guaranteed solution.
6.2. ROS Integration
- poly_map_construct—creates a polytope map from a given grid map by using the procedure outlined in Section 3.1.
- bspline_path_planner_node—given the current pose and goal, the node performs the whole path planning process. In addition to performing the tasks as the first node, it searches for the ideal sequence of polytopes and publishes the B-spline path as mentioned in Section 4.
7. Validation Results
7.1. Exploration Strategy for Creating the Occupancy Grid Map
7.2. Simulation Results
8. Discussion
9. Conclusions
Author Contributions
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Acknowledgments
Conflicts of Interest
Abbreviations
ROS | robot operating system |
SLAM | simultaneous localization and mapping |
CAD | computer-aided design |
RDP | Ramer–Douglas–Peucker |
MPC | model predictive control |
Appendix A. Illustration of the Path Planning Results from the Navigation with Polytopes Toolbox
References
- LaValle, S.M. Planning Algorithms; Cambridge University Press: New York, NY, USA, 2006. [Google Scholar]
- Ab Wahab, M.N.; Nefti-Meziani, S.; Atyabi, A. A comparative review on mobile robot path planning: Classical or meta-heuristic methods? Annu. Rev. Control 2020, 50, 233–252. [Google Scholar] [CrossRef]
- Zhang, H.Y.; Lin, W.M.; Chen, A.X. Path planning for the mobile robot: A review. Symmetry 2018, 10, 450. [Google Scholar] [CrossRef] [Green Version]
- Sánchez-Ibáñez, J.R.; Pérez-del Pulgar, C.J.; García-Cerezo, A. Path Planning for Autonomous Mobile Robots: A Review. Sensors 2021, 21, 7898. [Google Scholar] [CrossRef] [PubMed]
- Kim, C.; Suh, J.; Han, J.H. Development of a hybrid path planning algorithm and a bio-inspired control for an omni-wheel mobile robot. Sensors 2020, 20, 4258. [Google Scholar] [CrossRef] [PubMed]
- Schildbach, G.; Borrelli, F. A dynamic programming approach for nonholonomic vehicle maneuvering in tight environments. In Proceedings of the 2016 IEEE Intelligent Vehicles Symposium (IV), Gothenburg, Sweden, 19–22 June 2016; pp. 151–156. [Google Scholar]
- Nguyen, N.T.; Prodan, I. Stabilizing a multicopter using an NMPC design with a relaxed terminal region. IFAC-PapersOnLine 2021, 54, 126–132. [Google Scholar] [CrossRef]
- Nguyen, N.T.; Schilling, L.; Angern, M.S.; Hamann, H.; Ernst, F.; Schildbach, G. B-spline path planner for safe navigation of mobile robots. In Proceedings of the 2021 IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS), Prague, Czech Republic, 27 September–1 October 2021; pp. 339–345. [Google Scholar]
- Nguyen, N.T.; Gangavarapu, P.T.; Sahrhage, A.; Schildbach, G.; Ernst, F. Navigation with polytopes and B-spline path planner. In Proceedings of the 2023 IEEE International Conference on Robotics and Automation (ICRA), London, UK, 29 May–2 June 2023. [Google Scholar]
- Grisetti, G.; Stachniss, C.; Burgard, W. Improved Techniques for Grid Mapping With Rao-Blackwellized Particle Filters. IEEE Trans. Robot. 2007, 23, 34–46. [Google Scholar] [CrossRef] [Green Version]
- Nguyen, N.T.; Prodan, I.; Lefèvre, L. Flat trajectory design and tracking with saturation guarantees: A nano-drone application. Int. J. Control 2020, 93, 1266–1279. [Google Scholar] [CrossRef]
- Manyam, S.G.; Casbeer, D.W.; Weintraub, I.E.; Taylor, C. Trajectory Optimization For Rendezvous Planning Using Quadratic Bézier Curves. In Proceedings of the 2021 IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS), Prague, Czech Republic, 27 September–1 October 2021; pp. 1405–1412. [Google Scholar]
- Stoican, F.; Ivănuçcă, V.M.; Prodan, I.; Popescu, D. Obstacle avoidance via B-spline parametrizations of flat trajectories. In Proceedings of the 24th Mediterranean Conference on Control and Automation (MED’16), Athens, Greece, 21–24 June 2016; pp. 1002–1007. [Google Scholar]
- Stoican, F.; Prodan, I.; Grøtli, E.I.; Nguyen, N.T. Inspection Trajectory Planning for 3D Structures under a Mixed-Integer Framework. In Proceedings of the 2019 IEEE International Conference on Control & Automation (ICCA’19), Edinburgh, UK, 16–19 July 2019; pp. 1349–1354. [Google Scholar]
- Prodan, I.; Stoican, F.; Louembet, C. Necessary and sufficient LMI conditions for constraints satisfaction within a B-spline framework. In Proceedings of the 2019 IEEE 58th Conference on Decision and Control (CDC), Nice, France, 11–13 December 2019; pp. 8061–8066. [Google Scholar]
- Suryawan, F.; De Doná, J.; Seron, M. Splines and polynomial tools for flatness-based constrained motion planning. Int. J. Syst. Sci. 2012, 43, 1396–1411. [Google Scholar] [CrossRef]
- Berglund, T.; Brodnik, A.; Jonsson, H.; Staffanson, M.; Soderkvist, I. Planning smooth and obstacle-avoiding B-spline paths for autonomous mining vehicles. IEEE Trans. Autom. Sci. Eng. 2009, 7, 167–172. [Google Scholar] [CrossRef] [Green Version]
- Zhang, X.; Wang, C.; Chui, K.T.; Liu, R.W. A real-time collision avoidance framework of MASS based on B-spline and optimal decoupling control. Sensors 2021, 21, 4911. [Google Scholar] [CrossRef] [PubMed]
- Maekawa, T.; Noda, T.; Tamura, S.; Ozaki, T.; Machida, K.I. Curvature continuous path generation for autonomous vehicle using B-spline curves. Comput. Aided Des. 2010, 42, 350–359. [Google Scholar] [CrossRef]
- Romani, L.; Sabin, M.A. The conversion matrix between uniform B-spline and Bézier representations. Comput. Aided Geom. Des. 2004, 21, 549–560. [Google Scholar] [CrossRef]
- Böhm, W. Generating the Bézier points of B-spline curves and surfaces. Comput. Aided Des. 1981, 13, 365–366. [Google Scholar]
- Amsters, R.; Slaets, P. Turtlebot 3 as a robotics education platform. In Robotics in Education: Current Research and Innovations 10; Springer: Berlin/Heidelberg, Germany, 2020; pp. 170–181. [Google Scholar]
- Douglas, D.H.; Peucker, T.K. Algorithms for the reduction of the number of points required to represent a digitized line or its caricature. Cartogr. Int. J. Geogr. Inf. Geovisualizat. 1973, 10, 112–122. [Google Scholar]
- Piegl, L.; Tiller, W. B-spline Curves and Surfaces. In The NURBS Book; Springer: Berlin/Heidelberg, Germany, 1995; pp. 81–116. [Google Scholar]
- Hart, W.E.; Watson, J.P.; Woodruff, D.L. Pyomo: Modeling and solving mathematical programs in Python. Math. Program. Comput. 2011, 3, 219–260. [Google Scholar]
- Wächter, A.; Biegler, L.T. On the implementation of an interior-point filter line-search algorithm for large-scale nonlinear programming. Math. Program. 2006, 106, 25–57. [Google Scholar]
- Raja, P.; Pugazhenthi, S. Optimal path planning of mobile robots: A review. Int. J. Phys. Sci. 2012, 7, 1314–1320. [Google Scholar] [CrossRef]
- Nguyen, N.T.; Schildbach, G. Tightening polytopic constraint in MPC designs for mobile robot navigation. In Proceedings of the 2021 25th International Conference on System Theory, Control and Computing (ICSTCC), Iasi, Romania, 20–23 October 2021; pp. 407–412. [Google Scholar]
- Caregnato-Neto, A.; Maximo, M.R.; Afonso, R.J. Real-time motion planning and decision-making for a group of differential drive robots under connectivity constraints using robust MPC and mixed-integer programming. Adv. Robot. 2022, 37, 356–379. [Google Scholar] [CrossRef]
- Nezami, M.; Nguyen, N.T.; Männel, G.; Abbas, H.S.; Schildbach, G. A Safe Control Architecture Based on Robust Model Predictive Control for Autonomous Driving. In Proceedings of the 2022 American Control Conference (ACC), Atlanta, GA, USA, 8–10 June 2022; pp. 914–919. [Google Scholar]
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2023 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Nguyen, N.T.; Gangavarapu, P.T.; Kompe, N.F.; Schildbach, G.; Ernst, F. Navigation with Polytopes: A Toolbox for Optimal Path Planning with Polytope Maps and B-spline Curves. Sensors 2023, 23, 3532. https://doi.org/10.3390/s23073532
Nguyen NT, Gangavarapu PT, Kompe NF, Schildbach G, Ernst F. Navigation with Polytopes: A Toolbox for Optimal Path Planning with Polytope Maps and B-spline Curves. Sensors. 2023; 23(7):3532. https://doi.org/10.3390/s23073532
Chicago/Turabian StyleNguyen, Ngoc Thinh, Pranav Tej Gangavarapu, Niklas Fin Kompe, Georg Schildbach, and Floris Ernst. 2023. "Navigation with Polytopes: A Toolbox for Optimal Path Planning with Polytope Maps and B-spline Curves" Sensors 23, no. 7: 3532. https://doi.org/10.3390/s23073532