Improved laser mapping method based on Cartograph algorithm

By introducing laser distance regulator and Weightsubmap weights into the Cartographer algorithm, combined with the scan matcher of the Ceres library, the problem of map error accumulation and processing performance in the SLAM method is solved, and more efficient laser mapping is achieved, which improves real-time and Accuracy.

CN118962713APending Publication Date: 2024-11-15HUAIYIN INSTITUTE OF TECHNOLOGY
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411019696.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-29
Publication Date
2024-11-15

AI Technical Summary

Technical Problem

In the SLAM method, map error accumulation caused by factors such as sensor accuracy, noise and temperature lead to map drift, and using a larger-scale scan matcher to reduce errors will increase the processor's computing needs and reduce computing performance.

Method used

By introducing a laser distance regulator in the Cartographer algorithm, the radar scanning distance is adaptively selected, and the Weightsubmap weight is added to the probability grid map, the nonlinear least squares problem is solved using the scan matcher of the Ceres library, and the maximum and minimum search windows are added , to control the matching range and improve processing speed.

Benefits of technology

It effectively reduces the performance requirements of the host computer processor, improves the accuracy and processing speed of the probability grid map, improves the real-time map construction efficiency, and shortens the map construction time.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118962713A_ABST
    Figure CN118962713A_ABST
Patent Text Reader

Abstract

The invention discloses an improved laser mapping method based on a Cartograph algorithm. The method comprises the following steps: 1, controlling the scanning range of a laser radar by using a laser distance regulator; 2, correcting the pose of radar scanning data in a sub-graph coordinate system; 3, generating a sub-graph; 4, perfecting the sub-graph generated in the step 3, and continuing to update the next sub-graph; fifthly, new radar scanning data and the sub-graphs are subjected to loopback detection through a branch defining method, and according to the branch defining method, the number of grids of the probability grid map is large on the uppermost layer till the lowest layer is matched with each grid; and 6, after loopback detection succeeds each time, updating the new sub-graph to the global map, and finally outputting the global map. According to the invention, through combination of the laser distance regulator and the adaptive method, the scanning range of the laser radar, the operational capability load generated by the subgraph and the size of the scanning matching window are reasonably adjusted; the full-distance precision of the laser radar is maintained, and the scanning performance speed of the short-distance laser radar can be effectively improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of patrol unmanned vehicle safety and laser radar mapping and positioning, and specifically relates to an improved laser mapping method based on the Cartographer algorithm. Background Art

[0002] In recent years, unmanned driving technology has gradually matured and its application areas have become increasingly extensive. Inspection unmanned vehicles have become an indispensable auxiliary for large industrial enterprises. As a mobile robot with autonomous navigation capabilities, inspection unmanned vehicles can be equipped with various sensors, such as lidar, cameras, infrared cameras, hazardous gas concentration monitors, etc., to replace inspection personnel to conduct dynamic patrols of factory areas and complete daily inspection tasks.

[0003] The Cartographer algorithm is a laser SLAM method proposed by Google in 2016 that is suitable for large-scale mapping. It uses grid-based mapping and Ceres library-based scan matchers, equipped with various sensors for mapping. In the SLAM method, due to factors such as sensor accuracy, noise, and temperature, corresponding errors will be generated, and the accumulation of errors will cause map drift; using a larger-scale scan matcher to scan and match the map can reduce the accumulated map error, but it will increase the processor's computing requirements, thereby reducing computing performance. Summary of the invention

[0004] In view of the above technical problems, this technical solution provides an improved laser mapping method based on the Cartographer algorithm. According to the sampling frequency of the upper computer laser radar scanning, the laser radar regulator adaptively selects the radar scanning distance, including the maximum distance allowed for radar scanning and the minimum distance allowed for radar scanning, thereby reducing the performance requirements of the upper computer processor for sampling and ensuring the real-time acquisition of radar data. Weight is added to the probability grid map M generated by the sub-graph. submap Weights are used to increase the proportion of sub-images in a small area and improve the accuracy of the probability grid map. The scan matcher of the Ceres library is used to solve the nonlinear least squares problem, which is to match new radar scan data to the sub-image. In order to update the probability of each grid in the probability grid map in real time, the maximum search window W is increased in the scan matcher. max and the minimum search window W min , control the matching range of the scan matcher, thereby improving the processing speed; it can effectively solve the above problems.

[0005] The present invention is achieved through the following technical solutions:

[0006] An improved laser mapping method based on Cartographer algorithm comprises the following steps:

[0007] Step 1: When obtaining the point cloud data of the laser radar scanning the surrounding environment, use the laser distance regulator to control the scanning range of the laser radar; the specific operation method is:

[0008] Step 1.1: Obtain the radar point cloud R through laser radar scanning, obtain the sampling frequency of the host computer, set the initial step value of the laser distance regulator, set the maximum distance Dmax allowed for radar scanning and the minimum distance Dmin allowed for radar scanning;

[0009] Step 1.2: Get the sampling frequency of the laser radar in the host computer, and compare it with the step value of the current laser radar regulator. If they are equal, execute step 1.3; if they are not equal, execute step 1.4;

[0010] Step 1.3: If they are equal, compare all points p in the laser scanned point cloud R with the maximum distance Dmax allowed for radar scanning, and delete all points in the point cloud R that are greater than this distance;

[0011] Step 1.4: If they are not equal, compare all points p in the point cloud R scanned by the laser with the minimum distance Dmin allowed for radar scanning, and delete all points in the point cloud R that are greater than this distance;

[0012] Step 1.5: End this judgment, and add the step value of the current regulator to the current time as the step value of the next regulator;

[0013] Step 1.6: Output the currently filtered laser scanning point cloud R and end the method;

[0014] Step 2: Use the IMU sensor to obtain the radar acceleration direction to correct the position and posture of the radar scanning data in the sub-image coordinate system;

[0015] Step 3: Use all the scan points in the current radar scan frame to insert into the probability grid map, and calculate the probability of each grid being hit by the radar scan according to the probability grid update method; take the first radar scan frame as the center position of the sub-graph, and generate a sub-graph from the probability grid map of this range;

[0016] Step 4: Set a search window for the scan matcher, and use the Ceres library to match each frame of radar scan data in the window to the sub-image. When the subsequent radar scan data has no intersection with the probability grid map of the current sub-image, the sub-image is generated; the radar scan pose related to the sub-image is stored in the memory for closed-loop optimization; continue to update the next sub-image;

[0017] Step 5: Use the branch and bound method to perform loop detection on the new radar scan data and the sub-graph. The branch and bound method matches more grids in the probability grid map at the top level until every grid is matched at the bottom level.

[0018] Step 6: After each successful loop detection, update the new sub-map to the global map, and finally output the global map.

[0019] Furthermore, in the point cloud R of the laser scanning in step 1.3 and step 1.4, the conversion relationship between the coordinates of the radar scanning frame and the sub-image coordinates is:

[0020]

[0021] In the above formula, Rx is the x-axis coordinate in the two-dimensional map of the laser radar point cloud R, Ry is the y-axis coordinate in the two-dimensional map of the laser radar point cloud R, and R θ The rotation angle is the rotation matrix, translation is the translation vector, and the position of the current radar scanning frame in the sub-image coordinate system is T R ;

[0022] The role of this relationship is to convert the coordinates of the radar scan frame into the sub-image coordinates, preparing for the calculation of the probability grid map M below and the optimization of the pose of each frame of radar scan data.

[0023] Furthermore, when calculating the probability of each grid being hit by the radar scan as described in step 3, the subgraph weight Weight is increased. submap To optimize the probability grid map update method; the sub-map is composed of multiple probability grid maps The resolution of the probability grid map M is r, and the probability of each grid is p min to p max Several consecutive radar scans will form a sub-map; the probability grid map M is updated as follows:

[0024]

[0025] M new (x) = clamp(odds -1 (odds(M old (x)))·odds(p hit ))

[0026] In the above formula, odds is the ratio of whether the current probability grid map M is hit by the lidar, prob is the probability parameter, and Weight is submap is the sub-graph weight, i.e., the weight value of the current sub-graph for the probability grid map M, p hit is the probability that the grid of the current probability grid map is hit by the lidar, and clamp is the interval clamping function of the current probability grid map M.

[0027] Furthermore, the use of the Ceres library to match each frame of radar scan data in the window to the sub-image in step 4 is to use the Ceres library to optimize the posture of each frame of radar scan data in the window and match the radar scan data to the sub-image.

[0028] In the continuous laser scanning point cloud R, the error of the scanning data needs to be filtered to obtain the current position of the unmanned vehicle after rotation and translation. The Ceres library is used to optimize and solve the least squares problem in the system. According to the method steps of the laser radar regulator in step 1, the point cloud search window for matching the laser scanning point cloud R to the sub-image in the least squares problem should be set in a reasonable range. According to the maximum distance D allowed for radar scanning set in step 1.1 max and the minimum distance D that allows radar scanning min Set the maximum search window W max and the minimum search window W min ; Then the optimization of subgraph matching is:

[0029]

[0030] In the above formula, T R is the position of the current radar scanning frame in the sub-image coordinate system, h k is the scanning point of a radar scan, M smooth is a smooth function;

[0031] In the process of matching radar scan data with sub-images, the search window is adaptively adjusted according to the method steps of the laser distance adjuster to match the radar scan data into the sub-image, thereby improving the processing speed of sub-image matching.

[0032] Beneficial Effects

[0033] The improved laser mapping method based on the Cartographer algorithm proposed in the present invention has the following beneficial effects compared with the prior art:

[0034] (1) The present invention enables the laser radar regulator to adaptively select the radar scanning distance according to the sampling frequency of the upper computer laser radar scanning, including the maximum distance allowed for radar scanning and the minimum distance allowed for radar scanning, thereby reducing the performance requirements of the upper computer processor for sampling and ensuring the real-time acquisition of radar data; Weight is added to the probability grid map M generated by the subgraph submap Weights are used to increase the proportion of sub-images in a small area and improve the accuracy of the probability grid map. The scan matcher of the Ceres library is used to solve the nonlinear least squares problem, which is to match new radar scan data to the sub-image. In order to update the probability of each grid in the probability grid map in real time, the maximum search window W is increased in the scan matcher.max and the minimum search window W min , control the matching range of the scan matcher, thereby improving the processing speed.

[0035] (2) The present invention controls the scanning range of the laser radar through a laser distance regulator, and adaptively selects and sets the maximum distance D allowed for the radar to scan. max and the minimum distance D that allows radar scanning min , which improves the processing efficiency of the upper computer for short-range laser radar scanning. By adding Weight to the probability grid map M generated by the sub-graph submap The weights improve the accuracy of the probability grid map. max and the minimum search window W min , controlling the matching range of the scan matcher, thereby improving the processing efficiency of the position machine for the scan matcher. This method effectively improves the efficiency of real-time mapping and shortens the mapping time. BRIEF DESCRIPTION OF THE DRAWINGS

[0036] Figure 1 It is a specific schematic diagram of the present invention.

[0037] Figure 2 Schematic diagram of radar data points hit in a probability grid map M by a single radar scan in the present invention. DETAILED DESCRIPTION

[0038] The following will be combined with the accompanying drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. The described embodiments are only part of the embodiments of the present invention, rather than all the embodiments. Under the premise of not departing from the design concept of the present invention, various modifications and improvements made by ordinary persons in the art to the technical solutions of the present invention should all fall within the protection scope of the present invention.

[0039] Embodiment 1:

[0040] like Figure 1 As shown, an improved laser mapping method based on the Cartographer algorithm includes the following steps:

[0041] Step 1: When obtaining the point cloud data of the laser radar scanning the surrounding environment, use the laser distance regulator to control the scanning range of the laser radar. According to the sampling frequency of the upper computer for the laser radar scanning, if the current radar scanning environment range is large and complex, the computing performance of the upper computer is not enough to quickly process the radar scanning data, which will cause the system to be unable to generate sub-maps online in real time. Based on this problem, this embodiment proposes that the specific operation method of the laser distance regulator to control the laser radar scanning range is:

[0042] Step 1.1: Obtain the radar point cloud R through laser radar scanning, obtain the sampling frequency of the host computer, set the initial step size of the laser distance regulator, and set the maximum distance D allowed for radar scanning max and the minimum distance D that allows radar scanning min .

[0043] Step 1.2: Get the sampling frequency of the laser radar in the host computer and compare it with the step value of the current laser radar regulator. If they are equal, execute step 1.3; if they are not equal, execute step 1.4.

[0044] Step 1.3: If they are equal, compare all points p in the laser scanned point cloud R with the maximum distance Dmax allowed for radar scanning, and delete all points in the point cloud R that are greater than this distance.

[0045] Step 1.4: If they are not equal, compare all points p in the laser scanned point cloud R with the minimum distance Dmin allowed for radar scanning, and delete all points in the point cloud R that are greater than this distance.

[0046] Step 1.5: End this judgment, and add the step value of the current regulator to the current time as the step value of the next regulator.

[0047] Step 1.6: Output the currently filtered laser scanning point cloud R and end the method.

[0048] The point cloud R (R) of the laser scan described in step 1.3 and step 1.4 x ,R y ,R θ ), where the coordinate transformation relationship between the radar scanning frame and the sub-image coordinate is:

[0049]

[0050] In the above formula, Rx is the x-axis coordinate in the two-dimensional map of the laser radar point cloud R, Ry is the y-axis coordinate in the two-dimensional map of the laser radar point cloud R, and R θ The rotation angle is the rotation matrix, translation is the translation vector, and the position of the current radar scanning frame in the sub-image coordinate system is T R .

[0051] The role of this relationship is to convert the coordinates of the radar scan frame into the sub-image coordinates, preparing for the calculation of the probability grid map M below and the optimization of the pose of each frame of radar scan data.

[0052] Step 2: Use the IMU sensor to obtain the radar acceleration direction to correct the position and posture of the radar scanning data in the sub-image coordinate system.

[0053] Step 3: Use all the scan points in the current radar scan frame to insert into the probability grid map, and calculate the probability of each grid being hit by the radar scan according to the probability grid update method; use the first radar scan frame as the center position of the sub-graph, and generate a sub-graph from the probability grid map of this range.

[0054] like Figure 2 As shown, whether there is a hit grid in the probability grid map M. When calculating the current probability grid map, increase the sub-graph weight Weight submap To optimize the probability grid map update method. The submap is composed of multiple probability grid maps The resolution of the probability grid map M is r, and the probability of each grid is p min to p max Several consecutive radar scans will form a sub-map. The probability grid map M is updated as follows:

[0055]

[0056] M new (x) = clamp(odds -1 (odds(M old (x)))·odds(p hit ))

[0057] In the above formula, odds is the ratio of whether the current probability grid map M is hit by the lidar, prob is the probability parameter, and Weight is submap is the sub-graph weight, i.e., the weight value of the current sub-graph for the probability grid map M, p hit is the probability that the grid of the current probability grid map is hit by the lidar, and clamp is the interval clamping function of the current probability grid map M.

[0058] Step 4: Set a search window for the scan matcher, and use the Ceres library to match each frame of radar scan data in the window to the sub-image. When the subsequent radar scan data has no intersection with the probability grid map of the current sub-image, the sub-image is generated; the radar scan pose related to the sub-image is stored in the memory for closed-loop optimization; continue to update the next sub-image.

[0059] Set a search window for the scan matcher, use the Ceres library to optimize the pose of each frame of radar scan data in the window, and match the radar scan data to the sub-image. In the continuous laser scanning point cloud R, the error of the scan data needs to be filtered to obtain the pose of the current unmanned vehicle after rotation and translation. Use the Ceres library to match each frame of radar scan data in the window to the sub-image. Use the Ceres library to optimize the pose of each frame of radar scan data in the window, and match the radar scan data to the sub-image.

[0060] In the continuous laser scanning point cloud R, the error of the scanning data needs to be filtered to obtain the current position of the unmanned vehicle after rotation and translation. The Ceres library is used to optimize and solve the least squares problem in the system. According to the method steps of the laser radar regulator in step 1, the point cloud search window for matching the laser scanning point cloud R to the sub-image in the least squares problem should be set in a reasonable range. According to the maximum distance D allowed for radar scanning set in step 1.1 max and the minimum distance D that allows radar scanning min Set the maximum search window W max and the minimum search window W min ; Then the optimization of subgraph matching is:

[0061]

[0062]

[0063] In the above formula, T R is the position of the current radar scanning frame in the sub-image coordinate system, h k is the scanning point of a radar scan, M smooth is a smooth function;

[0064] In the process of matching radar scan data with sub-images, the search window is adaptively adjusted according to the method steps of the laser distance adjuster to match the radar scan data into the sub-image, thereby improving the processing speed of sub-image matching.

[0065] Step 5: Use the branch and bound method to perform loop detection on the new radar scan data and the sub-graph. The branch and bound method matches more grids in the probability grid map at the top level until every grid is matched at the bottom level.

[0066] Step 6: After each successful loop detection, update the new sub-map to the global map, and finally output the global map.

[0067] Matters not covered by the present invention are known technologies.

[0068] The above embodiments are only for illustrating the technical concept and features of the present invention, and their purpose is to enable people familiar with the technology to understand the content of the present invention and implement it accordingly, and they cannot be used to limit the protection scope of the present invention. Any equivalent transformation or modification made according to the spirit of the present invention should be included in the present invention.

Claims

1. An improved laser mapping method based on the Cartographer algorithm, characterized in that: The following steps are involved: Step 1: When obtaining the point cloud data of the laser radar scanning the surrounding environment, use the laser distance regulator to control the scanning range of the laser radar; the specific operation method is: Step 1.1: Obtain the radar point cloud R through laser radar scanning, obtain the sampling frequency of the host computer, set the initial step value of the laser distance regulator, set the maximum distance Dmax allowed for radar scanning and the minimum distance Dmin allowed for radar scanning; Step 1.2: Get the sampling frequency of the laser radar in the host computer, and compare it with the step value of the current laser radar regulator. If they are equal, execute step 1.3; if they are not equal, execute step 1.4; Step 1.3: If they are equal, compare all points p in the laser scanned point cloud R with the maximum distance Dmax allowed for radar scanning, and delete all points in the point cloud R that are greater than this distance; Step 1.4: If they are not equal, compare all points p in the point cloud R scanned by the laser with the minimum distance Dmin allowed for radar scanning, and delete all points in the point cloud R that are greater than this distance; Step 1.5: End this judgment, and add the step value of the current regulator to the current time as the step value of the next regulator; Step 1.6: Output the currently filtered laser scanning point cloud R and end the method; Step 2: Use the IMU sensor to obtain the radar acceleration direction to correct the position and posture of the radar scanning data in the sub-image coordinate system; Step 3: Use all the scan points in the current radar scan frame to insert into the probability grid map, and calculate the probability of each grid being hit by the radar scan according to the probability grid update method; take the first radar scan frame as the center position of the sub-graph, and generate a sub-graph from the probability grid map of this range; Step 4: Set a search window for the scan matcher, and use the Ceres library to match each frame of radar scan data in the window to the sub-image. When the subsequent radar scan data has no intersection with the probability grid map of the current sub-image, the sub-image is generated; the radar scan pose related to the sub-image is stored in the memory for closed-loop optimization; continue to update the next sub-image; Step 5: Use the branch and bound method to perform loop detection on the new radar scan data and the sub-graph. The branch and bound method matches more grids in the probability grid map at the top level until every grid is matched at the bottom level. Step 6: After each successful loop detection, update the new sub-map to the global map, and finally output the global map.

2. The improved laser mapping method based on the Cartographer algorithm according to claim 1, characterized in that: The point cloud R of the laser scan described in step 1.3 and step 1.4, where the coordinate conversion relationship between the radar scan frame and the sub-image coordinate is: In the above formula, Rx is the x-axis coordinate in the two-dimensional map of the laser radar point cloud R, Ry is the y-axis coordinate in the two-dimensional map of the laser radar point cloud R, and R θ The rotation angle is the rotation matrix, translation is the translation vector, and the pose of the current radar scanning frame in the sub-image coordinate system is T R ; The role of this relationship is to convert the coordinates of the radar scan frame into the sub-image coordinates, preparing for the calculation of the probability grid map M below and the optimization of the pose of each frame of radar scan data.

3. The improved laser mapping method based on the Cartographer algorithm according to claim 2, characterized in that: When calculating the probability of each grid being hit by the radar scan as described in step 3, add the subgraph weight Weight submap To optimize the probability grid map update method; the sub-map is composed of multiple probability grid maps The resolution of the probability grid map M is r, and the probability of each grid is p min to p max Several consecutive radar scans will form a sub-map; the probability grid map M is updated as follows: M new (x)=clamp(odds -1 (odds(M old (x)))·odds(p hit )) In the above formula, odds is the ratio of whether the current probability grid map M is hit by the lidar, prob is the probability parameter, and Weight is submap is the sub-graph weight, i.e., the weight value of the current sub-graph for the probability grid map M, p hit is the probability that the grid of the current probability grid map is hit by the lidar, and clamp is the interval clamping function of the current probability grid map M.

4. The improved laser mapping method based on the Cartographer algorithm according to claim 1, characterized in that: Step 4 uses the Ceres library to match each frame of radar scan data in the window to the sub-image, which is to use the Ceres library to optimize the pose of each frame of radar scan data in the window and match the radar scan data to the sub-image; according to the maximum distance D allowed for radar scanning set in step 1.1 max and the minimum distance D that allows radar scanning min Set the maximum search window W max and the minimum search window W min ; Then the optimization of subgraph matching is: In the above formula, T R is the position of the current radar scanning frame in the sub-image coordinate system, h k is the scanning point of a radar scan, M smooth is a smooth function; In the process of matching radar scan data with sub-images, the search window is adaptively adjusted according to the method steps of the laser distance adjuster to match the radar scan data into the sub-image, thereby improving the processing speed of sub-image matching.

Citation Information

Cited By

  • Rapid repositioning method and device and electronic equipment

    CN120374713A