Rapid global path planning algorithm for unmanned surface vehicles in large-scale and multi-island marine environments
- Published
- Accepted
- Received
- Academic Editor
- Alma Alanis
- Subject Areas
- Algorithms and Analysis of Algorithms, Autonomous Systems, Robotics
- Keywords
- Unmanned surface vehicle, Global path planning, Fast marching method, Fast marching square, Time optimal
- Copyright
- © 2021 Wang et al.
- Licence
- This is an open access article distributed under the terms of the Creative Commons Attribution License, which permits unrestricted use, distribution, reproduction and adaptation in any medium and for any purpose provided that it is properly attributed. For attribution, the original author(s), title, publication source (PeerJ Computer Science) and either DOI or URL of the article must be cited.
- Cite this article
- 2021. Rapid global path planning algorithm for unmanned surface vehicles in large-scale and multi-island marine environments. PeerJ Computer Science 7:e612 https://doi.org/10.7717/peerj-cs.612
Abstract
A global path planning algorithm for unmanned surface vehicles (USVs) with short time requirements in large-scale and complex multi-island marine environments is proposed. The fast marching method-based path planning for USVs is performed on grid maps, resulting in a decrease in computer efficiency for larger maps. This can be mitigated by improving the algorithm process. In the proposed algorithm, path planning is performed twice in maps with different spatial resolution (SR) grids. The first path planning is performed in a low SR grid map to determine effective regions, and the second is executed in a high SR grid map to rapidly acquire the final high precision global path. In each path planning process, a modified inshore-distance-constraint fast marching square (IDC-FM2) method is applied. Based on this method, the path portions around an obstacle can be constrained within a region determined by two inshore-distance parameters. The path planning results show that the proposed algorithm can generate smooth and safe global paths wherein the portions that bypass obstacles can be flexibly modified. Compared with the path planning based on the IDC-FM2 method applied to a single grid map, this algorithm can significantly improve the calculation efficiency while maintaining the precision of the planned path.
Introduction
Research on unmanned surface vehicles (USVs) has received increased attention in various military and civilian applications over recent years (Yan et al., 2010; Campbell, Naeem & Irwin, 2012; Liu et al., 2016). Robust and reliable navigation, guidance, and control (NGC) systems are required for USVs to perform a variety of complex marine missions. Path planning is an essential component of an NGC system. The main aim of path planning is to calculate a collision-free path with specific requirements. It determines the automation level of USVs and ensures the reliability and success of missions (Tan et al., 2020).
Global path planning is an important aspect of path planning. A variety of algorithms for the global path planning of USVs have been studied for different requirements. Dijkstra’s algorithm (Dijkstra, 1959) is a classic graph-based algorithm that can plan the shortest global path for USVs (Xie et al., 2016; Singh et al., 2018). As an improvement of Dijkstra’s algorithm, the A* algorithm (Hart, Nilsson & Raphael, 1968) and its related improved algorithms are also commonly used in the global path planning of USVs (Campbell, Naeem & Irwin, 2012), such as the direction priority sequential selection method (Naeem, Irwin & Yang, 2012); the A* algorithm, which considers environment effects (EEA*) (Lee et al., 2015); and the angular rate-constrained Theta* (ARC-Theta*) algorithm, which considers both the angular rate and heading angle of USVs (Kim et al., 2014). These algorithms exhibit acceptable convergence and consistency; however, the planned paths must be further smoothed. The artificial potential field (APF) method (Khatib, 1986) is a classic method for both global and local path planning. The main drawback of the traditional APF method is the local minimum problem. Therefore, different studies (Guo, Gao & Cui, 2013; Song, Hao & Su, 2020) have been conducted to solve the local minimum problem for the path planning of robots or USVs. Evolutionary methods such as the genetic algorithm (GA) (Kim et al., 2017; Arzamendia et al., 2019; Wang et al., 2020), particle swarm optimization (PSO) (Song et al., 2015), and ant colony optimization (ACO) (Song, 2014; Xia et al., 2019) have also been applied in the path planning of USVs. GA is robust and adaptable, but it has the shortcomings of poor local search ability and the premature convergence phenomenon. Therefore, other methods, such as the simulated annealing algorithm, are usually introduced to improve the performance of GA (Zhang, Xu & Xie, 2019). Nevertheless, the path planned by GA still lacks consistency. Similar to GA, PSO has the advantage of strong robustness and the shortcoming of premature convergence. However, it is dependent on various parameters, and there is no specific theory for guiding the setting of these parameters for different problems. Similarly, the parameter selection of ACO is more dependent on experience, and this algorithm can easily fall into local extremum.
In some special applications, the shortest time may be an important requirement for USVs. The fast marching method (FMM) can be a solution for time-optimal global path planning. This method was first proposed by Tsitsiklis (1995), and Adalsteinsson & Sethian (1995) independently and was extended by Sethian (1999). An experimental survey for nine different FMMs is shown in Gómez et al. (2019). The path planned by the FMM is usually extremely close to the obstacles. One solution is to adjust the speed map, as exemplified by the method with an adjusted cost function (Messias et al., 2014) and the FM2 method (Garrido et al., 2007). FMM-based methods have been widely used in path planning applications (Gómez et al., 2013; Amorim & Ventura, 2014; Alvarez et al., 2015; González et al., 2016). Marine applications based on FMM were introduced by Garrido, Alvarez & Moreno (2020). Interesting modifications for the FM2 method have been performed, and the FMM has been subjected to a vector field considering the effects of several vector variables such as wind flow or water currents (Garrido, Alvarez & Moreno, 2020). In addition, studies on path following and obstacle avoidance and formations have also been conducted using FMM (Garrido, Alvarez & Moreno, 2020). USV formation path planning has also been performed by Liu & Bucknall (2015) and Tan et al. (2020), and an angle-guidance FM2 method has been used for the Springer USV to make the generated path compliant with the dynamics and orientation restrictions of USVs (Liu & Bucknall, 2016; Liu, Bucknall & Zhang, 2017). An improved anisotropic fast marching method using a multi-layered fast marching was proposed by Song, Liu & Bucknall (2017), which combines different environmental factors and provides interesting results. In addition to the global path planning, the FMM-based methods also show potential in collision avoidance of USVs (Wang, Jin & Er, 2019; Garrido, Alvarez & Moreno, 2020). These successful studies have demonstrated the potential of FMM-based methods in global path planning of USVs.
The basic FMM can plan time-optimal paths for USVs. However, some of the main shortcomings are that the paths planned by the FMM are too close to obstacles, and there may be abrupt turns when the paths bypass obstacles with sharp corners. Thus, the FM2 method is proposed to address these problems, and two dimensionless parameters are introduced to adjust the paths more flexibly (Garrido et al., 2007; Garrido, Alvarez & Moreno, 2020). However, the two introduced parameters lack clear physical meaning, and the suitable adjustment is difficult to identify with specific values. Moreover, the adjustment effects of these two parameters are not common because the adjustment degree with the same parameters varies with different grid maps. Another common problem about FM-based methods is that the computational efficiency of path planning decreases sharply when the scale of the grid map is very large. Therefore, we make two improvements to address the mentioned shortcomings of the basic FM2 method. First, we introduced an inshore-distance-constraint fast marching square (IDC-FM2) method to improve the inshore path adjustment performance for the first time. Comparing with the basic FM2 method, the IDC-FM2 method applies two inshore distance parameters other than the two dimensionless parameters to adjust the paths around the obstacles. The adjustment effects for path planning of the IDC-FM2 method are stable in different grid maps as the IDC-FM2 method can constrain the path portions around the obstacles within the region constrained by the two inshore distance parameters. Further, to improve the computational efficiency, the algorithm that applies the IDC-FM2 method based on two-level spatial resolution grid maps is designed.
Related Methods
Environment map model
In 2D global path planning applications based on the FMM or its improved methods, discrete numerical calculations are based on cartesian grid maps. Therefore, an environment map should first be converted into a binary grid map with a suitable spatial resolution (SR). Free and open-source satellite images (such as Google satellite images) can be used as the data source for the maps in most USV applications, and the corresponding grid maps can be generated using image processing (Shi et al., 2018) combined with manual assistance. The binary cell is set as an obstacle cell when an obstacle exists at the geographic location (0 values); otherwise, it is set as a free cell (1 value).
Fast marching square method
When using FM-based methods to plan a path, the basis is the FMM. The core work of the FMM is calculating solutions of the Eikonal equation (Tsitsiklis, 1995; Adalsteinsson & Sethian, 1995). The Eikonal equation describes a wave front propagation scenario from sources with the speed of a wave front given as Fx at cell x. It can be expressed as , where Tx is the arrival time of the wave from the source to the cell x and ∇ is a vector differential operator. From the perspective of time-cost, the Eikonal equation can be expressed in another form (that of Lin, 2003): (1) where τx is the time-cost at cell x and is equivalent to 1∕Fx. The solution we want to calculate is Tx, and all of them compose the arrival time map, . All time-cost τx compose the time-cost function map, .
The FMM was first proposed independently by Tsitsiklis (1995) and Adalsteinsson & Sethian (1995).The solution Tx in cell x can be interpreted as the wave arrival time from the nearest source to cell x. Three cell sets (the accepted set , trial set , and far set ) are defined to calculate . The set of all cells at which Tx will not change is is the set of cells to be examined. Every Tx in has been previously computed but may be updated. is the set of all other cells with Tx, which has never been computed (Lin, 2003).
The calculation process includes initialization and loop procedures. During initialization, source cells x0 with Tx0 = 0 are set to , and all other cells are set to with Tx = ∞. After the initialization, the cell xm with the smallest T value in is selected and moved from to . Thereafter, the non-accepted neighbor cells of xm are updated, including the solutions and cell sets. Considering Tsitsiklis’s deduction (Tsitsiklis, 1995; Lin, 2003), each of the new neighbor solutions is determined by: (2) where denotes the original solution. Txmxi, i = 1, 2 are the candidate solutions for the paths that pass through the line segment xmxi and propagate to cell x (see Fig. 1), which are calculated by: (3) where Txm and Txi are the accepted solutions at cells xm and xi, respectively. If cell xi is in , Txi is ∞. For the cell set, if a non-accepted neighbor cell x is in , it moves from to . The loop procedure is performed continually until all cells are in . The resulting map is the arrival time map, .
The main disadvantage of the basic FMM is that the computed path is too close to obstacles and forces the vehicle to perform abrupt turns (Garrido, Alvarez & Moreno, 2020). As described in Garrido et al. (2007) and Garrido, Alvarez & Moreno (2020), a smooth path with sufficient safety distances from obstacles can be computed using the FM2 method. This method applies the basic FMM twice. The procedure for computing paths is described as follows (Garrido, Alvarez & Moreno, 2020):
-
The environment is modeled as a binary grid map (Fig. 2A).
-
The FM-1st step. All obstacle cells are used as wave sources (T = 0), expanding several waves at the same time at a constant speed. The value of each cell in the resulting map indicates the time required for a wave to reach the closest obstacle (see Fig. 2B). This is proportional to the distance from the obstacles. By reversing the meaning of these values, they can be understood as the maximum admissible speed at each cell. Finally, the speed values are rescaled to fix a maximum cell value of 1.
Modifications of the speed map with two parameters, α and β, can adjust distances between the computed paths and obstacles. The value of each cell in the speed map Fi,j is adjusted exponentially by α: (4) The parameter β is used to saturate the values in the speed map. It is defined within the range of 0 and 1. Every Fi,j with a value greater than β is set to one (see Fig. 2C).
Comparing with a path without modifications, the path modified by α will be closer to obstacles when α < 1. On the contrary, if α > 1, the modified path will stay further away from obstacles. The parameter β allows the path to move closer to obstacles. When β is smaller, the modified path will be closer to obstacles.
-
The FM-2nd step. The goal point is used as a unique wave source. The wave is expanded over the map until the starting point is reached. The speed at each cell (equivalent to 1∕τx) is obtained from the modified speed map computed in the FM-1st step. The resulting arrival time map is shown in Fig. 2D.
-
Finally, a gradient descent is applied over the resulting arrival time map from the starting point to the goal point. An optimal path in terms of the arrival time, smoothness, and safety is obtained.
Gradient descent method
The global path can be extracted by applying the gradient descent method. The path propagates along the gradient descent direction from the starting position Ps to the goal position Pg with a step length d. The value of d can be set to a value equal to the SR of the grid map. The gradient of the cell xi,j is calculated by: (5) where Ti,j represents the arrival time value at cell xi,j and the non-italic T in the upper-right corner represents the transpose of vector .
The path waypoints are not limited to cell centers. Generally, the gradient of a path waypoint located in the cell xi,j is approximated by the cell gradient ∇Ti,j. However, a modified gradient ∇Tu,v calculated by the bilinear interpolation can be used to improve the path precision (see Fig. 3).
Proposed algorithm
To improve the computational efficiency of global path planning in a large-scale and multi-island marine environment, the proposed algorithm performs path planning twice for different purposes. First, the path planning is performed in a low SR (LSR) grid map to determine an effective region. The final global path is then obtained in the second path planning within the effective region of a high SR (HSR) grid map. The relevant methods and procedures applied in the algorithm are as follows. The complete algorithm flow is summarized in the last part of this section.
Mapping of two-level SR grid maps
The two-level SR grid maps are contained in the HSR and LSR grid maps. The HSR grid map is directly obtained from the Google satellite image data. A mapping relationship between the LSR cells and the corresponding L × L HSR cell sub-blocks is established, which can be expressed as: (6) where are the LSR cell coordinates, and are the original cell coordinates of the mapped HSR cell sub-block, as shown in Fig. 4.
To map the LSR grid map to a sub-block of the HSR grid map, the following is used: (7)
To map from a sub-block of the HSR grid map to a cell of the LSR grid map, we use: (8) where are the HSR cell coordinates. are the original cell coordinates of the original HSR cell sub-block (see Fig. 4), which are determined by: (9) where are the HSR cell coordinates of the goal cell xg, the function indicates a rounding down of m, and a%b indicates the modulo operation.
The SR of the LSR grid map is: (10) where DHRes is the SR of the HSR grid map. In general, L is defined as: (11) where DTh is the distance threshold of the virtual obstacle influence, and the function indicates a rounding of m. The cell numbers of the LSR grid map in the X-axis and Y-axis directions are: (12) (13) where MH and NH are the cell numbers of the HSR grid map in the X-axis and Y-axis directions, respectively.
Based on the mapping relationship, an LSR cell type is determined by comparing the setting threshold Γ and obstacle cell proportion γ in the HSR cell sub-block. If γ > Γ, the LSR cell is set as an obstacle cell; otherwise, it is set as a free cell. Γ prefers to select a small value to retain as much obstacle information as possible.
IDC-FM2 method
In the basic FM2 method, the path is improved using a modified speed map. Two parameters, α and β, are used to modify the speed map. These modifications ensure the flexibility of the computed path. However, these two parameters have no clear physical meaning. The normalization of the speed values in the FM-1st step also results in several shortcomings. For example, all the speed values in the speed map must be calculated. When the map range changes slightly, the entire speed map rescales and differs in the same locations of the original map, and the parameters must be adjusted.
An IDC-FM2 method is proposed to address these shortcomings. In this method, a time-cost weighting function, wx, is introduced to adjust the speed map. Three inshore-distance parameters (the distance threshold DTh, as well as the virtual strong and weak constraint distance parameters, Dsc and Dwc, respectively) and two weighting function values with respect to Dsc and Dwc (wsc and wwc, respectively) are used to determine the function wx, and DTh is used to achieve the same function as the speed saturation. Although five parameters are set, only two inshore-distance parameters, DTh and Dsc, must be considered, while suitable values of wsc and wwc can be selected as constant values. Based on this method, the path portion around an obstacle is constrained in a region determined by DTh and Dsc.
Time-cost weighting function
The time-cost weighting function wx is introduced as a concept of the virtual obstacle influence. When a USV is far away from obstacles, there is no obstacle influence. As the USV approaches, the virtual obstacle influence increases slowly at first and the amplitude increases gradually. The obstacle influence increases dramatically when the USV is close to within a certain degree.
Similar to the FM-1st step in the basic FM2 method, all obstacle cells are set as source cells to first calculate the arrival time map. The difference here is that a threshold TTh = τDTh∕DRes could be set to speed up the calculation, where DRes is the SR of the map, and τ is the unified time-cost which can take 1 as the value. In the loop procedure, if the smallest T value of a cell in is larger than or equal to TTh, all T values of non-accepted cells can be set as TTh directly. Based on the resulting arrival time map, , with a saturation threshold, the time-cost weighting function map, W′, is designed as: (14) where and Tx are the values of the cell x in W′ and , respectively, and a and b are two positive coefficients to be determined.
When a free cell, x, is within the virtual influenced scope of obstacles (i.e., 0 < Dx ≤ DTh, where Dx is the closest distance to obstacles), then: (15)
Therefore, wx with respect to Dx is used to approximate : (16) where is the value in cell x of the approximate time-cost weighting function map, W. The time-cost value of each cell in the time-cost map, which is the inversion of the speed map, is then adjusted to: (17)
Equation 16 implies that wx increases when cell x is closer to obstacles. The planned path tends to select points with a lower arrival time-cost. Therefore, when the path is close to obstacles, it will be farther away from obstacles compared to the path planned by the basic FMM.
Parameters for the time-cost weighting function
Five parameters, DTh, Dsc, Dwc, wsc, and wwc, are introduced to determine the coefficients a and b, which are determined by: (18) (19) where esc = Dsc∕DTh, ewc = Dwc∕DTh, Dsc < Dwc < DTh, and wsc > wwc > 1.
The parameter DTh determines the largest virtual influence scope of the obstacles. The suggestion for the selection of DTh is that there should be a sufficiently safe buffer area for obstacles. The parameter Dsc is very important for the safety of the USV. First, it is suggested that this parameter satisfies: (20) where vU,max is the maximum speed of the USV, tr is the reaction time of the thruster, and ad is the negative maximum acceleration of the USV under braking. In an unknown environment, it is better to select a slightly larger value to ensure safety, which is similar in environments with shallow and reef waters. This value may be relatively small in deep and reef-free waters to improve path efficiency. Dwc is a parameter that acts as the adjusted constraint distance. In a non-channel ocean area, the path portions around obstacles will be limited to the regions between Dwc and DTh. The Dwc value can be set independently or determined jointly by DTh and Dsc. In this study, it is set as: (21)
The area around the obstacles is divided into four parts by the three inshore-distance parameters: Dsc, Dwc, and DTh. The three parts extending from an obstacle to the outside region are the danger region, Sd; the strong constraint region, Ssc; and the weak constraint region, Swc (see Fig. 5). The influences of wwc and wsc on the path are shown in Fig. 5. As shown in Fig. 5A, the path will be located far from the obstacle until it is near the boundary of Swc when wwc is large. In contrast, the path is closer to the obstacle when wsc is large (see Fig. 5B). The minimum degree of the path close to Ssc is mainly determined by wwc, which can be inferred by further comparing the paths in Fig. 5B with the closest path to the obstacle (wwc = 1.1) in Fig. 5A. However, regardless of the change in wwc and wsc (wsc > wwc > 1), the path portions bypassing obstacles will always be within Swc or around the outside boundary of Swc in non-channel ocean areas. In channel areas where there is no Swc, the path will follow the quasi-centerline of the channel if it passes through the channel. In this study, the values of wsc = 40.0 and wwc = 2.0 were selected and fixed. The paths can be flexibly modified by the inshore-distance parameters DTh and Dsc.
Determination of effective regions within the HSR grid map
The effective region within the HSR grid map is important for improving the computational efficiency of the proposed algorithm. It is acquired based on the mapping between the LSR and HSR grid maps when the corresponding region within the LSR grid map is determined.
Two effective regions that are respectively used in the FM-1st and FM-2nd steps of the IDC-FM2 method must be determined. The low-precision initial path, ℓini, is obtained first based on the LSR arrival time map . Two effective regions within the LSR grid map, SLER_1st and SLER_2nd, are determined by expanding the cells around the “path-passed” cells of ℓini. As shown in Fig. 6, the nearest neighbor cell among the four neighbor cells of the waypoint is defined as the “path-passed” cells. When all “path-passed” cells are determined, the κ2nd = κ levels of the cells are extended to obtain SLER_2nd. Considering SLER_1st, there are three different situations:
-
Situation 1: there is no cell with wx > 1 in SLER_2nd;
-
Situation 2: there is at least one cell with wx > 1 and no obstacle cell in SLER_2nd.
-
Situation 3: there is at least one obstacle cell in SLER_2nd.
In Situations 1 and 3, κ1st = κ. In Situation 2, SLER_2nd is extended continuously with Δκ levels of cells until there is at least one obstacle cell for the first time, and κ1st = κ + Δκ. Finally, two corresponding effective regions within the HSR grid map, SHER_1st and SHER_2nd, are determined and used in the different FM steps of the IDC-FM2 method to obtain the HSR arrival time map .
The extended parameter κ affects the paths (recorded as ℓκ) based on the proposed algorithm. When κ is not adequately large, these paths may not be consistent with the reference path ℓref, which is acquired by applying the IDC-FM2 method in the HSR grid map directly. A navigable global path is used as a case to compare the consistency between ℓκ and ℓref. The basic parameters used in the proposed algorithm are listed in Table 1. Using ℓref as the reference, the distances between the corresponding waypoints of ℓκ (κ = 3, …, 6) and ℓref are shown in Fig. 7. It is shown that the largest distance decreases when κ increases, and the distance becomes 0 when κ ≥ 7. Other cases were tested and similar results were obtained. These results indicate that there is good consistency when κ is sufficiently large (such as κ = 10). Δκ is a variable parameter that was determined based on three different cases.
Parameter | Value | Parameter | Value | Parameter | Value |
---|---|---|---|---|---|
L | 8 | Γ | 0.2 | DTh (m) | 200 |
Dsc (m) | 50 | wsc | 40.0 | wwc | 2.0 |
Algorithm flow
The proposed algorithm is improved based on the basic FM2-based algorithm. The basic FM2-based algorithm is executed directly on a single grid map. The algorithm flow of this basic algorithm is shown in Fig. 8 in the form of main data stream and used methods. This algorithm flow has two main steps. In Step S1, an arrival time map with obstacle sources and a saturation threshold, , is obtained by first applying the FMM. Then, the approximate time-cost weighting function map, W, is calculated and used to adjust the time-cost map. Based on the adjusted time-cost map, an arrival time map with the goal point source, , is obtained by applying the FMM again. The entire process is used to obtain by applying the IDC-FM2 method. Finally, the global path is acquired based on by applying the gradient descent method in Step S2.
The main data stream in the proposed algorithm and the methods used to obtain them are shown in Fig. 9. The main flow is as follows:
-
Step T1. Obtain the two-level SR grid maps;
-
Step T2. Obtain the LSR arrival time map in the LSR grid map;
-
Step T3. Determine the effective regions within the HSR grid map (SHER_1st and SHER_2nd);
-
Step T4. Obtain the HSR grid arrival time map with the effective region constraint in both FM steps of the IDC-FM2 method. There are several adjustments in both FM steps compared to the basic FMM performance. For the FM-1st step, all wx values within SHER_1st need not be adjusted, and this step can be ignored in Situation 1. In Situation 2 and Situation 3, all free cells out of SHER_1st are set to with T = ∞ in the initialization of this step. In the FM-2nd step, all free cells out of SHER_2nd are set to with T = ∞ in the initialization;
-
Step T5. Acquire the final high precision global path by applying the gradient descent method based on .
Results and discussion
Simulation environments
Two surrounding spatial areas of Zhucha Island and Changhai County were selected as the simulation environments. The original maps adopted Google satellite images, as shown in Fig. 10. The spatial resolutions in the longitude and latitude directions are approximately 4.8 m and 3.9 m, respectively. Temporary binary grid maps are obtained based on the image processing method (Shi et al., 2018) combined with manual assistance, and then the HSR grid maps with DHRes = 10m in both the longitude and latitude directions are determined by resampling processing. The corresponding binary grid maps are presented in Fig. 11. Their ranges are 7 km × 7 km and 64 km × 48km, respectively.
Inshore-distance-constraint performances
A path planning from Ps = [4.3 km, 2.8 km] to Pg = [3.6 km, 2.0 km] is used as a typical case to analyze the inshore-distance-constraint performance of the IDC-FM2 method using the inshore-distance parameters DTh and Dsc. As shown in Fig. 12, the path planned based on the basic FMM, ℓFMM, is very close to the islands when this path bypasses them. For comparison, all paths planned by the proposed algorithm, ℓ1 to ℓ4, are located away from islands by a certain distance. They are therefore significantly better choices from a safety perspective.
Paths ℓ1 to ℓ4 are acquired using different inshore-constraint distance parameters (DTh and Dsc, see Table 2 wherein Dwc is calculated based on DTh and Dsc) in the IDC-FM2 method in which wsc = 40.0 and wwc = 2.0. These paths are clearly adjusted by these distance parameters. When the distance constraints (DTh and Dsc) are small, the path (such as ℓ1, see Fig. 12) will be a somewhat close to the islands. The estimated quasi-closest distance from ℓ1 to an island is approximately 38 m, which is shorter than half of the shortest channel width (dhscw ≈ 101m). In this situation, ℓ1 is always outside of its Ssc (<28.2 m) value, and the path portions around the islands are located in the region of its Swc (28.2 m to 60.0 m). When the distance constraints increase, the paths (such as ℓ2 and ℓ3, see Fig. 12) in the non-channel areas will be outside of Ssc. The estimated quasi-closest distances (approximately 115 m and 128 m, respectively) are larger than dhscw. However, ℓ2 and ℓ3 will be along the quasi-midline of the channel in the channel area, regardless of whether dhscw is greater or less than Dwc for these two paths because the weighting time-cost will be smaller than the path around the islands (as in ℓ4, see Fig. 12). If the distance constraints are further increased, ℓ4 will be selected for safety, although more time will be required. These results indicate that the path based on the proposed algorithm can be adjusted by setting different inshore-constraint distance parameters to meet safety requirements. Additionally, when the inshore-constraint distance parameters are determined, the path will cross a channel when its width is adequately large; otherwise, the path will bypass around the islands.
Path | DTh(m) | Dwc(m) | Dsc(m) |
---|---|---|---|
ℓ1 | 60.0 | 28.2 | 15.0 |
ℓ2 | 200.0 | 79.8 | 30.0 |
ℓ3 | 200.0 | 104.5 | 65.0 |
ℓ4 | 200.0 | 118.7 | 85.0 |
One classical approach to plan collision-free paths is applying the FMM within the map with inflated obstacles. For comparison, paths planned by the classical approach and the IDC-FM2 method are shown in Fig. 13. The starting and goal positions are Ps = [4.15 km, 2.74 km] to Pg = [4.33 km, 2.40 km] and the island obstacles have been inflated by 94.0 m. As shown in Fig. 13, the path planned by the classical approach, ℓFMM+inflated, is obviously influenced by the shape of the inflated obstacle. In some path turns which are marked by ellipses in Fig. 13, they are both affected by the shape of the inflated obstacle and the time-value gradient calculation of cells adjacent to the inflated obstacle. A smooth path, ℓFMM+inflated+smooth, is also shown in Fig. 13. Although it removes abrupt turn waypoints, the path is still not very smooth. As comparisons, paths planed based on the IDC-FM2 method, ℓ1 and ℓ2, are obviously smoother than ℓFMM+inflated+smooth. In addition, when using the proposed rapid path planning algorithm based on two-level SR grid maps to improve the computational efficiency, the channel will be mapped as obstacle cells when mapping the HSR grid map to the LSR grid map in this case (taking the mapping parameter L = 8 as shown in Table 1), because of the influence of the inflated obstacle. This unexpected mapping will result in the loss of the path through the channel.
Global path planning in a large-scale and complex multi-island environment
To verify the path planning ability and the computational efficiency improvement of the proposed algorithm in a large-scale and relatively complex multi-island environment, the simulation environment shown in Fig. 11B is selected, and the long-length path cases of USVs around the islands or across channels are investigated.
Path planning cases
Five typical path cases were selected to demonstrate the performance of the proposed algorithm. The Ps and Pg groups are listed in Table 3. When determining the inshore-distance parameter Dsc, a USV with vU,max = 6m∕s, tr = 2s, ad = − 1m∕s2 is considered as a case. Based on Eq. (20), Dsc is suggested to select a value larger than 30 m. Therefore, a larger value Dsc = 50m is used for the path planning of the selected five path cases. Another inshore-distance parameter DTh = 200 m is selected empirically. The main parameters used in these path planning cases are shown in Table 1.
Path | Ps(km) | Pg(km) | Length (km) |
---|---|---|---|
ℓ1 | [35.34, 39.25] | [15.31, 11.65] | 38.84 |
ℓ2 | [19.42, 41.02] | [17.10, 3.63] | 37.90 |
ℓ3 | [42.96, 43.67] | [46.34, 8.24] | 38.20 |
ℓ4 | [36.11, 18.77] | [47.44, 41.01] | 26.47 |
ℓ5 | [3.95, 26.52] | [50.45, 30.83] | 47.82 |
As shown in Fig. 14, all paths successfully bypass the islands. The enlarged views (see Fig. 15, every path is displayed with a solid line) provide further details. Every path maintains a relatively safe distance when close to an island, and smooth when turning around the island. For a narrow channel of a certain degree (usually wider than 2DLRes), the path is planned along the quasi-midline of the channel to ensure that it is as safety as possible. The path lengths range from about 26.52 km to 47.86 km (see Table 3). These lengths can cover the range of most applications of current small-and medium-sized USVs. These results show the effective path planning ability of the proposed algorithm in a large-scale and complex multi-island environment.
Computational efficiency improvement
To verify the computational efficiency improvement of the proposed algorithm, the time spent on the five typical paths (see Table 3) based on the proposed algorithm was calculated. For comparison, the time spent on the basic algorithm which is executed directly on a single HSR grid map by applying the IDC-FM2 method was also calculated as a reference. The C algorithm code was tested on a computer with a Core i5-6300U CPU and 8G memory, which runs a 64-bit Win7 operating system.
Path planning for every typical path was repeated 10 times. Every planning time starts from the HSR grid map reading (in Steps S1 and T1) and ends when the global path has been calculated (in Steps S2 and T5). Because the path planning is performed on a Windows operating system, which involves multitasking, there may be many factors influencing the planning time, such as the variable CPU usage, random CPU hit rate to the cache, and possible thread scheduling. Therefore, the average planning time is used to evaluate the computational efficiency. The average planning time results of the five planned paths are presented in Table 4. These results indicate that the computational efficiency of the proposed algorithm based on two-level grid maps is significantly higher than the algorithm based on a single HSR grid map. The time for all cases is approximately 2 s, indicating that this method can be used in less demanding real-time planning applications. This can effectively improve the practicality of the proposed algorithm.
Path | Average planning times (s) | |
---|---|---|
Compared algorithm | Proposed algorithm | |
ℓ1 | 29.21 | 1.94 |
ℓ2 | 24.65 | 1.95 |
ℓ3 | 30.25 | 1.97 |
ℓ4 | 16.44 | 1.76 |
ℓ5 | 40.40 | 2.24 |
When planning a path by applying the basic FM2-based algorithm, if the grid map scale is very large, two aspects of calculations will severely increase compared with small-scale maps. First, as the number of cells increases significantly, the calculations for free cells increase. Second, changes in every iteration of calculations. The overall scale of clearly increases, resulting in the increase in sorting time of the adopted priority heap struct. This compared algorithm, whose algorithm flow is shown in Fig. 8, is used directly on a single HSR grid map. The valid scale of the HSR grid map is the number of free cells. For comparison, the proposed algorithm determines the effective regions within the HSR grid map first and then plans a path within the determined effective regions. As shown in Fig. 9, Steps T1–T3 complete the determination of effective regions, and Steps T4–T5 realize the path planning. The same function of the path planning is also realized by Steps S1–S2, as shown in Fig. 8. Comparing the path planning steps of the compared and proposed algorithms, the numbers of free cells in effective regions are much less than the ones in the HSR grid map. This indicates that the calculations for free cells and the overall scale of will greatly decrease. Therefore, the planning time of the proposed algorithm reduces. Certainly, there are more steps in the proposed algorithm. Planning time spent on these steps (Steps T1–T3) mainly depends on the LSR mapping parameter L. When the planning time spent on the compared algorithm, tref, is large enough, the planning time spent on Step T2 can reduce to less than tref∕L2 (in the cases shown in Table 4, this value is approximately ). The planning time spent on Steps T1 and T3 is often much less than tref. Therefore, the increased planning time spent on Steps T1–T3 is much less than the saved planning time spent on Steps T4–T5.
Conclusions
In some special USV applications such as sea rescue, it requires the USV to reach a goal position as soon as possible. FMM is a suitable global path planning method which can plan a time-optimal global path. However, the planned paths are not safe enough when they bypass obstacles, because of that they are too close to the obstacles. Therefore, FMM should be improved for safety considerations. One classical approach is applying the FMM within the map with inflated obstacles. Although the planned paths are safe by inflating the obstacle size, there may be abrupt turns when the obstacles have sharp corners, and the planned paths are influenced by shapes of inflated obstacles and may be not very smooth. Such paths are usually unfriendly for USVs. A rapid global path planning algorithm applying an IDC-FM2 method in two-level SR grid maps is proposed for USV applications with short time requirements in large-scale and complex multi-island environments. This algorithm can acquire a continuous, smooth, quasi-time-optimal path while maintaining a safe distance around obstacles when bypassing obstacles. When the path is near obstacles, it is limited to a safe area determined by two inshore-distance parameters. By adjusting these two inshore-distance parameters, the path can be modified flexibly. Although the time optimality is missed by using the IDC-FM2 method, the safety with a higher priority in most applications has been ensured initially while the optimal loss of time remains at a certain level. The two-path planning process based on two-level SR grid maps improves the computational efficiency compared with the basic FM2-based method. The planning time on the order of seconds is acceptable in many global path planning applications of USVs. Meanwhile, the planning time of this order of magnitude is typically short enough for USVs in most situations with the requirement to replan the path. This indicates the potential of replanning by using the proposed algorithm from the perspective of planning time. As a comparison, when using the classical approach which applies the FMM within the map with inflated obstacles, narrow channels will be easier to map as obstacles when mapping the HSR grid map to the LSR grid map in the rapid planning process based on two-level SR grid maps. This shortcoming may result in the loss of some possible paths through channels.
On the other hand, there are still some challenges when using the proposed algorithm. For example, how to accurately obtain the location information of newly detected obstacles and how to add this information into the grid map when replanning are the common challenges. The IDC-FM2 method also needs to be modified to plan the path meeting the dynamic characteristics of a USV. Otherwise, the USV may not follow the replanned path successfully at the beginning of the path.
One shortcoming of the proposed algorithm is that paths through channels that are very narrow but still passable in reality may be missed because of the first path planning process in the LSR grid map. The introduction of environmental effects into the proposed algorithm is an important task to be performed in future works. Marine experiments should also be conducted to verify the validity of the algorithm.
Supplemental Information
Waypoint positions of five paths shown in Fig. 12
The spatial resolution of the position is 10m. For example, a position (360.00, 200.00) which is shown in this file indicates the position (3.6 km, 2.0 km) in Fig. 12.
Waypoint positions of five typical paths shown in Fig. 13
The spatial resolution of the position is 10m. For example, a position (433.00, 240.00) which is shown in this file indicates the position (4.33 km, 2.40 km) in Fig. 13.
Waypoint positions of five typical paths shown in Fig. 14
The spatial resolution of the position is 10m. For example, a position (3534.00, 3925.00) which is shown in this file indicates the position (35.34 km, 39.25 km) in Fig. 14.
Execution time of five typical paths which are calculated based on a single HSR grid map by applying the IDC-FM2 method
Path planning for every typical path was repeated 10 times. The statistic information is shown in Table 4.
Execution time of five typical paths which are calculated by applying the proposed algorithm based on two-level SR grid map
Path planning for every typical path was repeated 10 times. The statistic information is shown in Table 4.
Binary grid map data of the surrounding areas of Zhucha Island and Changhai County
Two grid map data files including the binary grid map data of the surrounding areas of Zhucha Island in Qingdao(mapData700_700) and Changhai County in Liaoning(mapData4800_6400), which are shown in Fig. 11. These two data files can be loaded directly with MATLAB. Values in a row show the grid type in East direction of the map, while values in a column show the grid type in North direction of the map. Value 0 indicates the free grid cell and value 1 indicates the obstacle grid cell. The spatial resolution of a grid is 10m.
The codes and required data for the USV global path planning algorithm
The code files contain 5 files (main.c, funFMS.c, funFMS.h, C_Time.c, C_Time.h), and the required data contain 3 files (config.ini, obsMapCHX_4800_6400.dat, obsMapZCD_700_700.dat). Before running the code, there are several notes: 1). Source and goal positions should be set correctly (function “setSourceGoalPosGroup()” in funFMS.c file). Wrong settings (Source and goal positions are set in obstacle grids) will lead to unknown results. 2). Parameters are defined in the data file “config.ini”. The parameters ’disThreshold’, ’safeThreshold’, ’fwsc’ and ’fwwc’ indicate the corresponding parametrs ’ DTh’, ’ Dsc’, ’ wsc’ and ’ wwc’ in the article. 3). Obstacle map file ’obsMapZCD_700_700.dat’ is the map data as shown in Fig. 11A, while ’obsMapCHX_4800_6400.dat’ is the map data as shown in Fig. 11b. 4). This code has been tested and runs sucessfully in the platform of Visual Studio 2010.
The codes and required data of the classical approach which applies the FMM within the map with inflated obstacles
The code files contain 3 files (main.c, funFMS.c, funFMS.h), and the required data contain 2 files (config.ini, obsMapZCD_700_700.dat).Before running the code, there are several notes: (1). Source and goal positions should be set correctly (function “setSourceGoalPosGroup()” in funFMS.c file). Wrong settings (Source and goal positions are set in obstacle grids) will lead to unknown results. (2). Parameters are defined in the data file “config.ini”. The parameters ’disThreshold’, ’safeThreshold’, ’fwsc’ and ’fwwc’ indicate the corresponding parametrs ’ DTh’, ’ Dsc’, ’ wsc’ and ’ wwc’ in the article. (3). Obstacle map file ’obsMapZCD_700_700.dat’ is the map data as shown in Fig. 11A. (4). This code has been tested and runs sucessfully in the platform of Visual Studio 2010.