Improving Lateral Safety Distance-Based on Feature Detection and Probabilistic Roadmaps for Unmanned Vehicle Path Planning

8 Most of the existing path-planning algorithms do not consider lateral safe distance requirements in 9 practical applications. Hence, in this study, a new path point selection algorithm is proposed for path 10 planning. The algorithm first used the Harris and Line Segment Detector(LSD) algorithms to detect and 11 obtain the corner and edge information of obstacles. A vertical line was provided to the edge of the 12 surrounding obstacles along each corner successively. In this process, the narrow impassable area in the 13 map was filtered and removed by setting a safety threshold, and the foot of the vertical coordinates were 14 simultaneously obtained. The corresponding midpoint coordinates were solved by using the corner 15 coordinates and the foot of the corresponding perpendicular coordinates. The midpoint coordinates were 16 used as candidate points to generate path points. These candidate points are screened and relaxed using 17 the Probabilistic Roadmaps(PRM) algorithm to obtain the series of path points required. Finally, the path 18 was planned according to these path points and smoothed using the Quadratic polynomial interpolation 19 method(QPMI). Through simulation experiments, the method proposed in this study can solve a unique 20 path without randomness under given conditions, and the probability of a collision in practical applications 21 was reduced. 22


Introduction
Path planning, as one of the key technologies for driverless driving has been a hot research topic, attracting 2 the attention of a large number of researchers. It is designed to enable an autonomous vehicle to achieve 3 a series of collision-free and safety motions in a given environment to accomplish certain tasks. Traditional 4 path searching and planning algorithms have many types, such as rapidly exploring random tree path 5 planning, sub-goal networks, A* algorithms and D* algorithms, artificial potential fields, particle swarm 6 optimization (PSO) algorithms, and polynomial interpolation methods [1][2][3][4]. With the increasing 7 complexity of the environment and the difficulty of tasks, these traditional methods are, however, often 8 incapable of achieving the ultimate performance. In [5], the cubic polynomial model was used to solve the constraint conditions and objective functions, 10 and a dynamic optimal trajectory model was obtained. However, this study was based on a relatively 11 representative scenario, which investigated local path planning, and only considered the longitudinal safe 12 distance, while other more complex road conditions were not completely considered. In [6-8], the artificial 13 potential energy field model was used to plan the road, in consideration of a dynamic target position and 14 road boundary, and simulations were carried out, the results of which were deemed to be satisfactory. 15 However, the artificial potential energy field model cannot address the problems of local minima, and the 16 target cannot be satisfactorily reached. The researchers in [9] proposed an improved artificial potential 17 field based on the regression search method for mobile robot path planning, which can plan a short solution Hamiltonian Monte Carlo algorithm to their modification, which constantly forced the initial path to jump 5 out of the local extremum, thus improving the robustness and success rate of their path planning approach. 6 However, this method currently cannot sufficiently address the path planning problems of large maps and 7 maze-like maps. The researchers in [12] used the ant colony algorithm to address the problem of unmanned 8 vehicle path planning. Liang et al. [13] proposed control strategies for the torque of each wheel and the 9 rear-wheel-steering angle to maintain a stable velocity by using second-order sliding mode (SOSM) 10 techniques. Tan et al. [14] proposed a novel method of global optimal path planning for mobile robots 11 based on the improved Dijkstra algorithm and ant system algorithm. Li et al. [15] proposed methods based 12 on kinematics and dynamic constraints to solve path planning problems for unmanned vehicles. Yun et al.

13
[16] suggested a path-planning algorithm that considered the stability of unmanned ground vehicles based 14 on the genetic algorithm. Cai et al. [17] introduced the PSO algorithm as one of the new swarm intelligent 15 optimization methods into a path planning for autonomous vehicles, which comprised particle 16 representation methods for vehicle routing problems with fast convergence speeds. Fethi,D et al. [18] 17 proposed a new approach of optimal simultaneous localization, mapping, and path planning based on the 18 optimal control theory and simultaneous localization and mapping. As an initial idea for solving a min-  In path planning, most of the above algorithms simplify the control vehicle and do not completely 7 consider its actual body size. When the actual control vehicle is driven, deviations always exist in the 8 control technology, making the vehicle likely to collide as its lateral safe distance is insufficient when it 9 actually follows the planned path. To address this problem, a new path point selection method for path 10 planning is proposed in this study. After a map is obtained, the algorithm is used to detect the corner and 11 edge information of each obstacle successively. Then, it takes each corner as a starting point to make a 12 vertical line to the surrounding obstacles, calculating the corresponding vertical foot coordinates. In this 13 process, the narrow impassable areas in the map are filtered out by setting a security threshold. 14 Subsequently, the corresponding midpoints are obtained by calculating the corners and vertical foot 15 coordinates, and these midpoints are regarded as the path points for path planning. Finally, these path 16 points are used to plan the path and smoothen it. The path planned using this method can ensure that the 17 path is far removed from obstacles on both sides, thereby maximizing the safety of the driven vehicle.

18
The remainder of this paper is organized as follows. Section 2 describes in detail the algorithm proposed 19 in this study and the problems we intend to address. Section 3 discusses the implementation steps and 20 solutions of the algorithm proposed in this study. Section 4 presents the simulations performed on the 21 proposed algorithm, the results of which are analyzed. Section 5 concludes this paper.  Considering these problems, we propose a new path planning algorithm in this study, which aims to 8 eliminate the possibility of vehicle collisions in the process of path planning. In existing path planning 9 algorithms, most of the collisions are caused by insufficient lateral distance. Fig. 1 shows several cases of 10 path point selection-the red area representing the obstacle and the white area representing the passable 11 area. Provided that the planned path can pass through the blue triangular points in the figure, the control 12 vehicle can maximize its distance from obstacles on both sides of the path simultaneously. The main 13 objective of our work on this algorithm is to extract the blue triangular points for path planning.   Corner detection algorithms based on a grayscale image include the gradient, template, and template 11 gradient methods. In the template-based method, it considers the gray change of a pixel region and 12 compares it with the brightness of its neighborhood, the large point of the neighborhood being defined as 13 the corner. The commonly used template-based corner detection algorithms include the Kitchen-Rosenfeld 14 corner detection algorithm, Harris corner detection algorithm, KLT algorithm, and SUSAN corner 15 detection algorithm [23]. In this study, we selected the Harris corner detection algorithm to address our 16 corner detection problems and obtain corner coordinates. In this study, the map for path planning was simplified, the edges of obstacles all being simplified to 19 straight lines. Therefore, when detecting the edge of an obstacle, the problem was the detection of a 20 straight-line segment on the map. To address this problem, the LSD algorithm [24] was used. The LSD 1 algorithm is a linear timeline detector, which can provide accurate sub-pixel results. It is designed to work 2 on any digital image without the adjustment of parameters. It controls the number of false positives: on 3 average, one false alarm is allowed per image. After algorithm detection, the edge information of the 4 obstacle was obtained, as shown in Table 1.  The required corner coordinates and obstacle edge information were detected in the first two steps.

9
Thereafter, each corner was used as a starting point, and vertical lines were made to all of the detected 10 edges of the obstacle successively-the corresponding coordinates of the foot of perpendicular were 11 obtained.

12
To obtain the foot of perpendicular, the solution was divided into three cases. In the first case, when 13 | | ≥ 100, let = Inf, and the foot of perpendicular was solved using equation 1: where . represents the horizontal coordinate of the corner point.

2
In the third case, when 0.01 < | | < 100, the foot of perpendicular was solved using equation 3:  In this step, in order to achieve collision-free operation as much as possible in the process of path 6 planning, a threshold was set for the distance from the corner to the edge of the obstacle. As the actual 7 vehicle requires sufficient lateral distance when driving and some deviations exist during tracking control 8 process, the distance from the corner to the edge of the obstacle is required to be more than 6 m. Thus, 9 some impassable areas can be filtered out during the path planning process. The distance is solved using   As the obtained midpoint coordinates are all over the map and some of the previous steps do not filter the 8 data, some midpoints will fall into obstacle areas, so they cannot be used directly in the path planning 9 process and need to be further screened.

10
In this study, we used the PRM algorithm [25] to process the data obtained in the previous step. The

11
PRM algorithm automatically filters and deletes midpoints that fall in the obstacle area. Meanwhile, 12 through a repeated relaxation process, the PRM algorithm obtains the midpoint required for the shortest 13 path from the starting point to the end point-that is, a path point that can be used to generate the path 14 itself.

3
According to the implementation steps of the above algorithm, we wrote a program to solve the problem. The processing result of the ordinary PRM algorithm is shown in Fig. 5. It obtains a linear path by 5 randomly placing points on the entire graph. Using this method of randomly scattered points, if the number 6 of sampling points is insufficient, it leads to no path being generated. Even if the number of sampling 7 points is adequate, to create the shortest path in the process of generating a path, the final path generated 8 is too close to obstacles in some places, as shown in Fig. 5. This makes the application of the path more 9 difficult. In addition, this randomness renders the sampling points generated by different operations 10 different, and the path generated by these path points is not unique. This leads to an increased risk of 11 collision in the process of subsequent smoothing and practical application. Further, the randomness of the 12 algorithm itself makes it more difficult to address this problem.  The result of path smoothing using the QPMI method is shown in Fig. 7-the orange curve in the figure. 2 The path shown in Fig. 7(a) is based on the ordinary PRM algorithm. The path generated using this method 3 is evidently too close to the obstacle in some places, and if this path were to be applied in practice, a 4 collision would be likely to occur. Fig. 7(b) shows the path planned using the proposed algorithm. This since the path point used for path planning is unique, the path generated using this method is also unique, 9 which renders the path easier to control in practical applications.

10
During simulation, the proposed method was used to improve the selection of path points for path 11 planning. Through simulation and analysis, we found that this method clearly improves the path generated

18
In existing path planning methods, only few considers the problem of lateral safe distance in the driving 19 process, thereby increasing the risk of collision. In this study, we proposed a method to improve the 20 selection of path points. Our method successively used the Harris and LSD algorithms to detect the corner 1 and edge information of obstacles in a given map. Using the corner as a starting point, a vertical line was 2 provided to the edge of the surrounding obstacles successively, and the corresponding vertical coordinates 3 were obtained. In the process of establishing the vertical foot, the narrow impassable areas in the map 4 were removed by setting a safety threshold. The corresponding midpoint coordinates were obtained using 5 the corner points and the corresponding perpendicular coordinates, which were used as the candidate 6 points for each path point needed in the path planning process. After the starting and end points of a path 7 were given, the candidate points were screened using the PRM algorithm to determine a path of the 8 shortest length. Finally, the QPMI method was used to smooth the path.

9
In this study, simulation experiments were carried out on the proposed algorithm and compared to the   Availability of data and materials 5 The datasets used and/or analysed during the current study are available from the corresponding author on 6 reasonable request. Results of the foot of perpendicular Ordinary PRM algorithm Smooth path with QPMI algorithm. a) Ordinary QPMI and b) QPMI based on the proposed method