Occupancy probability grid map updating method and apparatus, device, and medium
By acquiring hit points and boundary miss points from single-frame point cloud data, and using a ray casting algorithm to correlate and statistically analyze the counted raster submap, the accuracy and efficiency issues of existing technologies for updating occupancy probability raster maps are solved, achieving higher precision and a faster update process.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- UISEE TECH BEIJING LTD
- Filing Date
- 2023-07-06
- Publication Date
- 2026-05-12
AI Technical Summary
In existing technologies, the occupancy probability grid map update method suffers from problems such as decreased accuracy due to positioning and pose errors, unutilized collection of boundary points, false positives in the ground grid, ghosting caused by dynamic obstacles, and high computational load, resulting in inaccurate map updates and low efficiency.
By acquiring hit points and boundary miss points associated with single-frame point cloud data, a ray casting algorithm is used to perform correlation statistics with the counting raster submap. The coordinate system of the counting raster submap is combined with the overlap of the occupancy probability raster submap for updating, including processing the count values of hit and miss rasters. Threshold filtering is used to filter error events and reduce unnecessary traversal and updates.
It improves the accuracy and efficiency of updating the occupancy probability raster map, reduces map errors, avoids false positives in ground raster and ghosting of dynamic obstacles, and reduces computational load.
Smart Images

Figure CN116842025B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of occupancy probability raster map technology, and in particular to an occupancy probability raster map updating method, apparatus, device and medium. Background Technology
[0002] Occupancy probability grid maps are commonly used in the field of artificial intelligence (such as autonomous vehicles and robots). They consist of grids with a certain precision. When performing path planning based on occupancy probability grid maps, the probability of each grid in the occupancy probability grid map being occupied is estimated based on the environmental information returned by LiDAR, providing a basis for path planning.
[0003] In a probability-based grid map, there are two states of a grid: occupied and free. An occupied grid indicates that there is an obstacle at the location represented by the grid, and this type of grid is also called a hit grid. A free grid indicates that there is no obstacle at the location represented by the grid cell, and this type of grid is also called a miss grid.
[0004] Traditional methods for updating occupancy probability grid maps primarily rely on laser point cloud data from LiDAR to determine whether each grid in the map contains obstacles. If a grid is hit by a point cloud, it indicates a hit event, increasing the probability of the grid being occupied. If a grid is traversed by a laser beam from the point cloud, it indicates a miss event, decreasing the probability of the grid being occupied. However, current technologies typically involve directly inserting the current frame's point cloud combined with the current localization pose into the occupancy probability grid map. Then, a ray casting algorithm is used to calculate hit and miss events for each point in the point cloud to obtain hit and miss grids. Finally, a binary Bayesian filter is used to update the hit and miss grids. However, existing technologies do not consider some non-ideal situations: First, in existing technologies, the positioning pose used when inserting the current frame point cloud into the occupancy probability grid map may have calculation errors. Using an erroneous pose will lead to errors in the hit and miss grids obtained based on each point through the ray casting algorithm, resulting in a decrease in the accuracy of the updated map. Second, in existing technologies, only points within the acquisition boundary of the current frame point cloud are used to update the map, while points outside the acquisition boundary are not utilized. Thus, when there are obstacle grids in the occupancy probability grid map to be updated, and only the laser rays corresponding to points beyond the acquisition boundary pass through the obstacle grid during map update, the obstacle grid cannot be updated using only the points within the acquisition boundary, leading to a decrease in the accuracy of the updated map. Specifically, for example, if an obstacle exists in a grid within the acquisition boundary of the previous frame, but not in the next frame, the grid needs to be updated in the next frame. In existing technologies, points outside the acquisition boundary are directly deleted and do not participate in the map update. Third, in existing technologies, when the incident angle between the laser ray and the ground is too large (close to 90°), ground grids are easily mistakenly identified as "miss grids," resulting in the ground being thinned or hollowed out, leading to a decrease in the accuracy of the updated map. Fourth, in existing technologies, during the updating of the occupancy probability grid map, dynamic obstacles, because they are also hit by the laser ray, will also increase the probability value of their corresponding hit grids, forming a ghosting effect on the map. Dynamic obstacles are added to the occupancy probability grid map, leading to a decrease in the accuracy of the updated map. Fifth, in existing technologies, a complete ray casting algorithm is needed to calculate hit and miss events for each point to obtain the hit and miss grids to be updated. However, since the laser radar ray is radial, grids near the laser radar origin are traversed more frequently, resulting in more miss events. This means there are more miss events in the miss grids, and each ray needs to traverse all the miss grids it passes through, leading to a large computational load, time-consuming map updates, and reduced efficiency.
[0005] In view of this, the present invention is hereby proposed. Summary of the Invention
[0006] To address or at least partially address the aforementioned technical problems, this disclosure provides an occupancy probability raster map update method, apparatus, device, and medium, thereby improving the update accuracy of the occupancy probability raster map.
[0007] In a first aspect, embodiments of this disclosure provide a method for updating an occupancy probability grid map, the method comprising:
[0008] Obtain the hit points and boundary miss points associated with a single frame of point cloud data;
[0009] The ray projection algorithm is used to correlate and statistically analyze the ray projection data of the hit points and boundary miss points with the counting grid map to obtain statistical results;
[0010] The occupancy probability grid subgraph to be updated is updated based on the statistical results, wherein the coordinate system of the counting grid subgraph coincides with the coordinate system of the occupancy probability grid subgraph, and the statistical results include the type of each grid in the counting grid subgraph and the number of hit or miss events that occur in each grid. The grid types include hit grids and miss grids.
[0011] Secondly, embodiments of this disclosure also provide an occupancy probability grid map updating apparatus, the apparatus comprising:
[0012] The acquisition module is used to acquire hit points and boundary miss points associated with a single frame of point cloud data;
[0013] The statistics module is used to associate and statistically analyze the ray projection data of the hit points and boundary miss points with the counting raster map using the ray projection algorithm to obtain statistical results.
[0014] An update module is used to update the occupancy probability grid submap to be updated based on the statistical results, wherein the coordinate system of the counting grid submap coincides with the coordinate system of the occupancy probability grid map, and the statistical results include the type of each grid in the counting grid submap and the number of hit events or miss events that occur in each grid, and the grid types include hit grids and miss grids.
[0015] Thirdly, embodiments of this disclosure also provide an electronic device, the electronic device comprising: one or more processors; a storage device for storing one or more programs; and when the one or more programs are executed by the one or more processors, causing the one or more processors to implement the occupancy probability grid map update method as described above.
[0016] Fourthly, embodiments of this disclosure also provide a computer-readable storage medium having a computer program stored thereon that, when executed by a processor, implements the occupancy probability grid map update method as described above.
[0017] This disclosure provides a method for updating an occupancy probability raster map. This method involves acquiring hit points and boundary miss points associated with single-frame point cloud data; using a ray casting algorithm to correlate and statistically analyze the ray casting data of the hit points and boundary miss points with a counted raster submap to obtain statistical results; and updating the occupancy probability raster map to be updated based on these statistical results. This technique improves the accuracy of updating the occupancy probability raster map. Attached Figure Description
[0018] The above and other features, advantages, and aspects of the embodiments of this disclosure will become more apparent from the accompanying drawings and the following detailed description. Throughout the drawings, the same or similar reference numerals denote the same or similar elements. It should be understood that the drawings are schematic, and the originals and elements are not necessarily drawn to scale.
[0019] Figure 1 This is a flowchart of an occupancy probability grid map update method according to an embodiment of this disclosure;
[0020] Figure 2 This is a schematic diagram illustrating a process in this embodiment of the invention for using a ray casting algorithm to associate and statistically analyze the ray casting data of hit points and boundary miss points associated with a single frame of point cloud data with a counting raster submap.
[0021] Figure 3 This is a schematic diagram illustrating a process of updating an occupancy probability grid map to be updated based on the statistical results of a counted grid submap, according to an embodiment of this disclosure.
[0022] Figure 4 This is a schematic diagram of the structure of an occupancy probability grid map updating device according to an embodiment of this disclosure;
[0023] Figure 5 This is a schematic diagram of the structure of an electronic device according to an embodiment of this disclosure. Detailed Implementation
[0024] Embodiments of this disclosure will now be described in more detail with reference to the accompanying drawings. While some embodiments of this disclosure are shown in the drawings, it should be understood that this disclosure can be implemented in various forms and should not be construed as limited to the embodiments set forth herein. Rather, these embodiments are provided to provide a more thorough and complete understanding of this disclosure. It should be understood that the accompanying drawings and embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of protection of this disclosure.
[0025] It should be noted that the concepts of "first" and "second" mentioned in this disclosure are used only to distinguish different devices, modules or units, and are not used to limit the order of functions performed by these devices, modules or units or their interdependencies.
[0026] The names of messages or information exchanged between multiple devices in the embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of such messages or information.
[0027] Figure 1 This is a flowchart illustrating an occupancy probability raster map updating method according to an embodiment of this disclosure. The method can be executed by an occupancy probability raster map updating device, which can be implemented in software and / or hardware and can be configured in an electronic device. Figure 1 As shown, the method may specifically include the following steps:
[0028] S110: Obtain the hit points and boundary miss points associated with a single frame of point cloud data.
[0029] For example, obtaining the hit points and boundary miss points associated with a single frame of point cloud data includes:
[0030] Points within the acquisition boundary in the single-frame point cloud data are defined as hit points;
[0031] The intersection of the laser beam corresponding to the point outside the acquisition boundary in the single frame point cloud data with the acquisition boundary is determined as the boundary miss point.
[0032] The acquisition boundary is a parameter manually set for the LiDAR. The purpose of setting the acquisition boundary is to ensure the accuracy of the point cloud data to be processed, while reducing the amount of data. For example, if the acquisition boundary is a circle with a radius of 120 meters centered on the LiDAR, then the point cloud data within the acquisition boundary is the data of interest to be processed, while the point cloud data outside the acquisition boundary is discarded, thus reducing the amount of data to be processed and ensuring the accuracy of the point cloud data.
[0033] In this embodiment, points within the acquisition boundary of a single-frame point cloud data are defined as hit points, and the intersection of the laser beams (the laser beams that hit points outside the acquisition boundary) with the acquisition boundary is defined as boundary miss points. Specifically, points in the single-frame point cloud data that coincide with the acquisition boundary can also be defined as hit points.
[0034] The advantage of identifying the intersection of the laser beam corresponding to the point outside the acquisition boundary in the single-frame point cloud data with the acquisition boundary as the boundary miss point is that it can improve the accuracy of the updated map. This can be understood in detail through the following content:
[0035] Suppose that obstacles exist on the grids of the original occupancy probability grid map (i.e., obstacle grids exist), and only points outside the acquisition boundary in the current frame's point cloud pass through these obstacle grids. If the point cloud used for map updates only contains points within the acquisition boundary (hit points), the miss grids determined by the ray casting algorithm based on these hit points do not include the obstacle grids, so the obstacle grids cannot be updated. However, this invention proposes a scheme utilizing points outside the acquisition boundary. It calculates the virtual intersections of these points with the acquisition boundary (i.e., boundary miss points), and then performs ray casting on these boundary miss points. The determined miss grids can include the obstacle grids (the operation for determining miss grids is explained in subsequent steps), thus allowing the obstacle grids to be updated, thereby improving the accuracy of the updated map. In other words, for example, if there is an obstacle in a grid within the acquisition boundary of the previous frame, and the grid does not have an obstacle in the next frame, the grid needs to be updated in the next frame. In the prior art, points outside the acquisition boundary are directly deleted and do not participate in the map update. However, in this application, the line segment between the boundary miss point and the emission origin is used to update the grid map, thereby ensuring that the grid is updated as a miss grid in the next frame.
[0036] S120. Using a ray casting algorithm, the ray casting data of the hit points and boundary miss points are correlated and statistically analyzed with the counting raster map to obtain statistical results.
[0037] For example, the step of using a ray casting algorithm to correlate and statistically analyze the ray casting data of the hit points and boundary miss points with the counted raster submap to obtain statistical results includes:
[0038] The hit point is matched with the occupancy probability grid submap based on the origin of the lidar that acquires the single frame point cloud data, so as to obtain the pose of the hit point in the coordinate system of the occupancy probability grid and the corresponding pose confidence.
[0039] If the pose confidence score is greater than a preset position confidence threshold, then based on the pose of the hit point in the coordinate system of the grid submap to be updated, a ray casting algorithm is used to correlate and statistically analyze the ray casting data of the hit point and the boundary miss points with the counted grid submap to obtain statistical results. Adding the step of judging the pose confidence score is to filter out some point cloud frames with large positioning pose errors, reduce the error between hit and miss grids in the counted grid submap, and ensure the accuracy of the updated map.
[0040] Furthermore, based on the pose of the hit point in the coordinate system of the grid subgraph to be updated, the ray projection algorithm is used to correlate and statistically analyze the ray projection data of the hit point and the boundary miss points with the counted grid subgraph to obtain statistical results, including:
[0041] Iterate through each of the aforementioned hit points. For the current hit point, based on its pose in the coordinate system of the occupancy probability grid subgraph, determine the grid in the counting grid subgraph occupied by the current hit point. Increment the count value corresponding to the grid occupied by the current hit point by 1, and mark the grid occupied by the current hit point as a hit grid. If a grid is occupied by one hit point, it is determined that the grid has experienced one hit event, and the corresponding count value of the grid is 1. If the grid is occupied by two hit points, it is determined that the grid has experienced two hit events, and the corresponding count value of the grid is 2, and so on.
[0042] Both the hit points and the boundary miss points are considered as laser ray endpoints. Each laser ray endpoint is traversed. For the current laser ray endpoint, the line segment formed by the current laser ray endpoint and the origin of the lidar is marked as the first line segment. The grid cells in the counting grid sub-graph traversed by the first line segment are marked as miss grid cells. If a grid cell is traversed by one of the line segments, a miss event is determined for that grid cell; if the grid cell is traversed by two of the line segments, a miss event is determined for that grid cell, and so on.
[0043] Each laser ray endpoint is traversed. For the current laser ray endpoint, the miss grid is traversed sequentially in the direction from the current laser ray endpoint to the origin of the lidar. When the current laser ray endpoint is a ground ray endpoint, the count value corresponding to the miss grid is updated based on the first strategy. When the current laser ray endpoint is a non-ground ray endpoint, the count value corresponding to the miss grid is updated based on the second strategy.
[0044] Specifically, if the height of the current laser ray endpoint is less than the ground height threshold, then the current laser ray endpoint is determined to be a ground ray endpoint; otherwise (i.e., the height of the current laser ray endpoint is greater than or equal to the ground height threshold), the current laser ray endpoint is determined to be a non-ground ray endpoint. Further, updating the count value corresponding to the miss grid based on the first strategy includes:
[0045] When the currently traversed miss grid is a non-ground miss grid, if the count value corresponding to the currently traversed miss grid is positive or zero, then the count value corresponding to the currently traversed miss grid is assigned to the preset value; if the count value corresponding to the currently traversed miss grid is negative, then the count value corresponding to the currently traversed miss grid is decremented by one. When the currently traversed miss grid is a ground miss grid, the count value corresponding to the currently traversed miss grid is not updated this time, and the next step is directly entered, that is, the count value decrementing and assignment operations are skipped.
[0046] Specifically, if the height of the currently traversed miss grid is greater than the ground height threshold, then the currently traversed miss grid is determined to be a non-ground miss grid; if the height of the currently traversed miss grid is less than or equal to the ground height threshold, then the currently traversed miss grid is determined to be a ground miss grid.
[0047] Furthermore, updating the count value corresponding to the miss grid based on the second strategy includes: if the count value corresponding to the currently traversed miss grid is negative, then the count value corresponding to the currently traversed miss grid is decremented by 1.
[0048] Furthermore, after the count value corresponding to the currently traversed miss grid is updated, the process further includes: if the count value corresponding to the currently traversed miss grid (referring to the updated count value) is less than the first threshold, then the operation of sequentially traversing the miss grid in the direction from the current laser ray endpoint to the origin of the lidar ends, and it is determined whether all laser ray endpoints have been traversed. If not, the traversal continues to the next laser ray endpoint; if the count value corresponding to the currently traversed miss grid is greater than or equal to the first threshold, then it is determined whether all miss grids on the current laser ray endpoint have been traversed. If not, the traversal continues to the next miss grid. For details of the above process, please refer to [reference needed]. Figure 2 The flowchart shown.
[0049] In particular, when the incident angle between the laser ray and the ground is too large (close to 90°), it is easy to mistakenly identify ground grids as "miss grids," resulting in the ground being thinned or hollowed out, leading to a decrease in the accuracy of the updated map. To address this issue, in the embodiments of this application, each ray endpoint applying the ray casting algorithm is divided into ground ray endpoints and non-ground ray endpoints, and special processing is applied to ground ray endpoints. Specifically, for the "miss grids" generated by applying the ray casting algorithm to ground ray endpoints, the grid height is further determined, and they are divided into ground "miss grids" and non-ground "miss grids." For ground "miss grids," the count decrement operation is skipped so that when the grid count values of all counted grid submaps containing that grid are finally calculated, a non-negative total count can be obtained, thereby avoiding setting that grid as an empty "miss grid," that is, avoiding the mistaken identification of ground grid points and improving the accuracy of the updated map.
[0050] Compared to using a full ray casting algorithm to calculate hit and miss events for each point to obtain the hit and miss grids to be updated (specifically, since the lidar ray is radial, grids near the lidar origin are traversed more times, resulting in more miss events, i.e., more miss events in the miss grids, and each ray needs to traverse all the miss grids it passes through, leading to a large computational load, time-consuming map updates, and reduced efficiency), this embodiment of the invention reduces unnecessary miss grid traversal by setting a maximum traversal count cache (i.e., the first threshold). Miss grids near the lidar ray sensor origin will be generated repeatedly. Because of the miss event, the accumulated count will be more than the number of miss grids far from the sensor origin. Based on the reverse traversal of the miss grids from the laser ray endpoint to the sensor origin, if the count value of the currently traversed miss grid is less than the first threshold, it means that the miss count of the miss grid to be traversed later has been saturated. The count value of the currently traversed miss grid has already met the map reduction threshold when updating the original map later, so there is no need to perform a decrement operation. Therefore, the miss grids to be traversed after the miss grid that has reached the maximum crossing count buffer are skipped. This can reduce the number of traversals, thereby reducing the time consumed by map updates and improving map update efficiency.
[0051] Furthermore, during map updates, moving objects also trigger hit events, increasing the probability value of the corresponding hit grid, resulting in a ghosting effect on the map and reducing the accuracy of the updated map. To address this issue, this invention proposes that for non-ground miss grids generated by ground ray endpoints, regardless of whether the miss grid previously stored a positive or negative count value, a larger negative count is forcibly assigned (i.e., the corresponding count value is assigned the preset value). This modifies the count values of grids that generate hit events on moving objects to negative counts. When the count values of all counted grid submaps containing that grid are finally calculated, a negative total count can be obtained, thus setting that grid as an empty miss grid. This achieves the effect of removing ghosting effects caused by moving objects, avoiding the addition of dynamic obstacles to the global positioning map, and improving the accuracy of the updated map.
[0052] S130. Update the occupancy probability grid subgraph to be updated according to the statistical results, wherein the coordinate system of the counting grid subgraph coincides with the coordinate system of the occupancy probability grid subgraph, and the statistical results include the type of each grid in the counting grid subgraph and the number of hit events or miss events that occur in each grid, and the grid type includes hit grid and miss grid.
[0053] The occupancy probability grid map consists of multiple occupancy probability grid sub-maps, with overlapping map areas between adjacent occupancy probability grid sub-maps. In this scheme, a corresponding counting grid map is set for each occupancy probability grid sub-map. The vehicle-mounted LiDAR continuously collects point cloud frames during vehicle movement. Based on all point cloud frames collected within a certain driving range, the count values of the grids in the corresponding few (usually 1-2) counting grid sub-maps are updated according to steps S110-S120 above. After all the counting grid maps are updated, the occupancy probability grid map to be updated is then updated based on the cumulative count values of the grids in all the counting grid maps. Specifically, the hit points and miss points associated with each single frame of point cloud data are obtained. Each single frame of point cloud data is continuously collected by the vehicle-mounted LiDAR within a preset driving range of the vehicle. The occupancy probability grid map is the map used for positioning when the vehicle is driving within the preset driving range. The ray projection algorithm is used to correlate and statistically analyze the ray projection data of the hit points and miss points associated with multiple frames of point cloud data with the counting grid map to obtain statistical results. The occupancy probability grid map is then updated based on the statistical results.
[0054] Specifically, the coordinate system of the counting grid subgraph coincides with the coordinate system of the occupancy probability grid subgraph, and the statistical results include the type of each grid in the counting grid subgraph and the number of hit or miss events that occur in each grid. The grid types include hit grids and miss grids.
[0055] For example, updating the occupancy probability grid submap based on the statistical results includes:
[0056] Iterate through all cells in all counting raster subgraphs. For the current cell, sum the count values of the current cell in all counting raster subgraphs that contain the current cell.
[0057] If the sum of the count values of the current grid cell in all count grid subgraphs is positive, then determine whether the count value of the current grid cell in all count grid subgraphs is greater than the second threshold. If so, then perform N binary Bayesian filtering state updates for the corresponding grid cell of the current grid cell in the occupancy probability grid subgraph.
[0058] If the sum of the counts of the current grid cell in all count grid subgraphs is negative, then determine whether the count of the current grid cell in all count grid subgraphs is less than the third threshold. If so, then update the occupancy status of the corresponding grid cell in the occupancy probability grid subgraph of the current grid cell to idle.
[0059] For example, you can refer to... Figure 3 The diagram illustrates a process for updating the occupancy probability grid submap based on the statistical results.
[0060] Compared to directly transforming the pose of a single-frame point cloud to the global coordinate system and using a ray casting algorithm to calculate hit and miss events (the pose error of a single frame will generate incorrect hit and miss events, leading to a decrease in the accuracy of the updated map), this embodiment of the invention uses a counting raster submap to store the hit and miss events generated by the ray casting algorithm from multiple frames of point clouds. It accumulates and counts the raster counts of all submaps corresponding to a certain raster position, and finally updates the original map. Then, it filters out some incorrect hit and miss events by using two thresholds: a map raster increase threshold (i.e., the second threshold) and a map raster decrease threshold (i.e., the third threshold). Only the raster with a count value exceeding the specified threshold in the counting raster map is updated to the original raster map, thereby improving the accuracy of the updated map.
[0061] Figure 4This is a schematic diagram of an occupancy probability raster map updating device provided in an embodiment of this disclosure. The device includes: an acquisition module 410, used to acquire hit points and boundary miss points associated with single-frame point cloud data; a statistics module 420, used to use a ray casting algorithm to associate and statistically analyze the ray casting data of the hit points and boundary miss points with a counting raster submap to obtain statistical results; and an update module 430, used to update the occupancy probability raster submap to be updated according to the statistical results. The coordinate system of the counting raster submap coincides with the coordinate system of the occupancy probability raster map. The statistical results include the type of each raster in the counting raster submap and the number of hit or miss events that occur in each raster. The raster types include hit rasters and miss rasters.
[0062] Furthermore, the acquisition module 410 is specifically used to: determine the points within the acquisition boundary in the single-frame point cloud data as hit points; and determine the intersection of the laser beam corresponding to the points outside the acquisition boundary in the single-frame point cloud data and the acquisition boundary as boundary miss points.
[0063] Furthermore, the statistics module 420 includes: a matching unit, used to match the hit point with the occupancy probability grid submap based on the origin of the lidar that acquires the single-frame point cloud data, to obtain the pose of the hit point in the coordinate system of the occupancy probability grid submap and the corresponding pose confidence; and a statistics unit, used to, if the pose confidence is greater than a preset position confidence threshold, use a ray casting algorithm to associate and statistically analyze the ray casting data of the hit point and the boundary miss point with the counting grid submap based on the pose of the hit point in the coordinate system of the grid submap to be updated, to obtain statistical results.
[0064] Furthermore, the statistical unit includes: a first statistical subunit, used to traverse each hit point, and for the current hit point, determine the grid in the counting grid subgraph occupied by the current hit point based on the pose of the current hit point in the coordinate system of the occupancy probability grid subgraph, increment the count value corresponding to the grid occupied by the current hit point by 1, and mark the grid occupied by the current hit point as the hit grid.
[0065] The second statistical subunit is used to treat both the hit point and the boundary miss point as laser ray endpoints, and to traverse each laser ray endpoint. For the current laser ray endpoint, the line segment formed by the current laser ray endpoint and the origin of the lidar is marked as the first line segment, and the grid in the counting grid subgraph passed by the first line segment is marked as the miss grid.
[0066] The third statistical subunit is used to traverse each of the laser ray endpoints. For the current laser ray endpoint, the miss grid is traversed sequentially in the direction from the current laser ray endpoint to the origin of the lidar. When the current laser ray endpoint is a ground ray endpoint, the count value corresponding to the miss grid is updated based on the first strategy. When the current laser ray endpoint is a non-ground ray endpoint, the count value corresponding to the miss grid is updated based on the second strategy.
[0067] Furthermore, the third statistical subunit is used to: when the currently traversed miss grid is a non-ground miss grid, if the count value corresponding to the currently traversed miss grid is positive or zero, then assign the count value corresponding to the currently traversed miss grid to a preset value; if the count value corresponding to the currently traversed miss grid is negative, then decrement the count value corresponding to the currently traversed miss grid by one; if the count value corresponding to the currently traversed miss grid is negative, then decrement the count value corresponding to the currently traversed miss grid by 1; if the count value corresponding to the currently traversed miss grid is less than the first threshold, then end the operation of traversing the miss grid sequentially in the direction from the current laser ray endpoint to the origin of the lidar, so as to traverse the next laser ray endpoint; if the count value corresponding to the currently traversed miss grid is greater than or equal to the first threshold, then continue to traverse the next miss grid.
[0068] Furthermore, the update module 430 is specifically used for: traversing all grids in all counting grid subgraphs; for the current grid, summing the count values of the current grid in all counting grid subgraphs containing the current grid; if the sum of the count values of the current grid in all counting grid subgraphs is positive, then determining whether the count value of the current grid in all counting grid subgraphs is greater than the second threshold; if so, then performing N binary Bayesian filtering state updates for the corresponding grid in the occupancy probability grid subgraph for the current grid; if the sum of the count values of the current grid in all counting grid subgraphs is negative, then determining whether the count value of the current grid in all counting grid subgraphs is less than the third threshold; if so, then updating the occupancy status of the corresponding grid in the occupancy probability grid subgraph to idle.
[0069] The occupancy probability raster map updating apparatus provided in this disclosure can execute the steps in the occupancy probability raster map updating method provided in this disclosure method embodiment, and can obtain the same beneficial effects, which will not be repeated here.
[0070] Figure 5 This is a schematic diagram of the structure of an electronic device according to an embodiment of this disclosure. See below for details. Figure 5 It shows a schematic diagram of a structure suitable for implementing the electronic device 500 in the embodiments of this disclosure. Figure 5The electronic device shown is merely an example and should not be construed as limiting the functionality and scope of the embodiments disclosed herein.
[0071] like Figure 5 As shown, the electronic device 500 may include a processing device (e.g., a central processing unit, a graphics processor, etc.) 501, which can perform various appropriate actions and processes to implement the methods of the embodiments described herein, based on a program stored in a read-only memory (ROM) 502 or a program loaded from a storage device 508 into a random access memory (RAM) 503. The RAM 503 also stores various programs and data required for the operation of the electronic device 500. The processing device 501, ROM 502, and RAM 503 are interconnected via a bus 504. An input / output (I / O) interface 505 is also connected to the bus 504.
[0072] In particular, according to embodiments of this disclosure, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of this disclosure include a computer program product comprising a computer program carried on a non-transitory computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts, thereby implementing the occupancy probability grid map update method as described above. In such embodiments, the computer program can be downloaded and installed from a network via communication device 509, or installed from storage device 508, or installed from ROM 502. When the computer program is executed by processing device 501, it performs the functions defined in the methods of embodiments of this disclosure.
[0073] It should be noted that the computer-readable medium described in this disclosure can be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. A computer-readable storage medium can be, for example,—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this disclosure, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in connection with an instruction execution system, apparatus, or device. In this disclosure, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium can be any computer-readable medium other than a computer-readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to: wires, optical fibers, RF (radio frequency), etc., or any suitable combination thereof.
[0074] The aforementioned computer-readable medium may be included in the aforementioned electronic device; or it may exist independently and not assembled into the electronic device. The aforementioned computer-readable medium carries one or more programs that, when executed by the electronic device, cause the electronic device to: acquire hit points and boundary miss points associated with single-frame point cloud data; use a ray casting algorithm to correlate and statistically analyze the ray casting data of the hit points and boundary miss points with a counting raster submap, obtaining statistical results; update the occupancy probability raster submap to be updated based on the statistical results, wherein the coordinate system of the counting raster submap coincides with the coordinate system of the occupancy probability raster submap, and the statistical results include the type of each raster in the counting raster submap and the number of hit or miss events occurring in each raster, the raster type including hit rasters and miss rasters.
[0075] Optionally, when one or more of the above-described procedures are executed by the electronic device, the electronic device may also perform other steps described in the above embodiments.
[0076] In the context of this disclosure, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can be, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
[0077] The above description is merely a preferred embodiment of this disclosure and an explanation of the technical principles employed. Those skilled in the art should understand that the scope of this disclosure is not limited to technical solutions formed by specific combinations of the above-described technical features, but should also cover other technical solutions formed by arbitrary combinations of the above-described technical features or their equivalents without departing from the above-described concept. For example, technical solutions formed by substituting the above features with (but not limited to) technical features disclosed in this disclosure that have similar functions.
Claims
1. A method for updating a probability-based raster map, characterized in that, The method includes: Obtain the hit points and boundary miss points associated with a single frame of point cloud data; The ray projection algorithm is used to correlate and statistically analyze the ray projection data of the hit points and boundary miss points with the counting grid submap to obtain statistical results. This includes: matching the hit points with the occupancy probability grid submap based on the origin of the lidar that acquired the single-frame point cloud data to obtain the pose of the hit points in the coordinate system of the occupancy probability grid submap; traversing each hit point, for the current hit point, determining the grid in the counting grid submap occupied by the current hit point based on the pose of the current hit point in the coordinate system of the occupancy probability grid submap, incrementing the count value corresponding to the grid occupied by the current hit point by 1, and marking the grid occupied by the current hit point as the hit grid; Both the hit point and the boundary miss point are regarded as laser ray endpoints. Each laser ray endpoint is traversed. For the current laser ray endpoint, the line segment formed by the current laser ray endpoint and the origin of the lidar is marked as the first line segment. The grids in the counting grid sub-graph that the first line segment passes through are marked as miss grids. Iterate through each laser ray endpoint. For the current laser ray endpoint, iterate through the miss grid in sequence from the current laser ray endpoint to the origin of the lidar. When the current laser ray endpoint is a ground ray endpoint, and when the currently traversed miss grid is a non-ground miss grid, if the count value corresponding to the currently traversed miss grid is positive or zero, then assign a large negative number to the count value corresponding to the currently traversed miss grid. If the count value corresponding to the currently traversed miss grid is negative, then decrement the count value corresponding to the currently traversed miss grid by one. When the current laser ray endpoint is a non-ground ray endpoint, the count value corresponding to the miss grid is updated based on the second strategy. When the currently traversed miss grid is a ground miss grid, the count value corresponding to the currently traversed miss grid is not updated, and the operation proceeds directly to the next step. The occupancy probability grid subgraph to be updated is updated based on the statistical results, wherein the coordinate system of the counting grid subgraph coincides with the coordinate system of the occupancy probability grid subgraph, and the statistical results include the type of each grid in the counting grid subgraph and the number of hit or miss events that occur in each grid. The grid types include hit grids and miss grids.
2. The method according to claim 1, characterized in that, The acquisition of hit points and boundary miss points associated with single-frame point cloud data includes: Points within the acquisition boundary in the single-frame point cloud data are defined as hit points; The intersection of the laser beam corresponding to the point outside the acquisition boundary in the single frame point cloud data with the acquisition boundary is determined as the boundary miss point.
3. The method according to claim 1, characterized in that, The step of using a ray casting algorithm to correlate and statistically analyze the ray casting data of the hit points and boundary miss points with the counting raster map to obtain statistical results also includes: Obtain the pose confidence level corresponding to the pose; If the pose confidence is greater than a preset position confidence threshold, then based on the pose of the hit point in the coordinate system of the grid subgraph to be updated, the ray projection algorithm is used to associate and statistically analyze the ray projection data of the hit point and the boundary miss point with the count grid subgraph to obtain statistical results.
4. The method according to claim 1, characterized in that, The step of updating the count value corresponding to the miss grid based on the second strategy includes: If the count value corresponding to the currently traversed miss grid is negative, then the count value corresponding to the currently traversed miss grid is decremented by 1.
5. The method according to claim 4, characterized in that, After the count value corresponding to the currently traversed miss grid is updated, the step of using a ray casting algorithm to correlate and statistically analyze the ray casting data of the hit point and the boundary miss points with the count grid based on the pose of the hit point in the coordinate system of the grid subgraph to be updated, and obtaining statistical results, further includes: If the count value corresponding to the currently traversed miss grid is less than the first threshold, the operation of traversing the miss grid sequentially in the direction from the current laser ray endpoint to the origin of the lidar ends, so as to traverse the next laser ray endpoint; if the count value corresponding to the currently traversed miss grid is greater than or equal to the first threshold, the traversal of the next miss grid continues.
6. The method according to claim 1, characterized in that, The step of updating the occupancy probability grid submap based on the statistical results includes: Iterate through all cells in all counting raster subgraphs. For the current cell, sum the count values of the current cell in all counting raster subgraphs that contain the current cell. If the sum of the count values of the current grid cell in all count grid subgraphs is positive, then determine whether the count value of the current grid cell in all count grid subgraphs is greater than the second threshold. If so, then perform N binary Bayesian filtering state updates for the corresponding grid cell of the current grid cell in the occupancy probability grid subgraph. If the sum of the counts of the current grid cell in all count grid subgraphs is negative, then determine whether the count of the current grid cell in all count grid subgraphs is less than the third threshold. If so, then update the occupancy status of the corresponding grid cell in the occupancy probability grid subgraph of the current grid cell to idle.
7. An occupancy probability raster map updating device, characterized in that, include: The acquisition module is used to acquire hit points and boundary miss points associated with a single frame of point cloud data; The statistics module is used to associate and statistically analyze the ray projection data of the hit points and boundary miss points with the counting grid submap using a ray projection algorithm to obtain statistical results. This includes: matching the hit points with the occupancy probability grid submap based on the origin of the lidar that acquired the single-frame point cloud data, obtaining the pose of the hit points in the coordinate system of the occupancy probability grid submap; traversing each hit point, for the current hit point, determining the grid in the counting grid submap occupied by the current hit point based on its pose in the coordinate system of the occupancy probability grid submap, incrementing the count value corresponding to the grid occupied by the current hit point by 1, and marking the grid occupied by the current hit point as a hit grid. Both the hit point and the boundary miss point are regarded as laser ray endpoints. Each laser ray endpoint is traversed. For the current laser ray endpoint, the line segment formed by the current laser ray endpoint and the origin of the lidar is marked as the first line segment. The grids in the counting grid sub-graph that the first line segment passes through are marked as miss grids. Iterate through each laser ray endpoint. For the current laser ray endpoint, iterate through the miss grid in sequence from the current laser ray endpoint to the origin of the lidar. When the current laser ray endpoint is a ground ray endpoint, and when the currently traversed miss grid is a non-ground miss grid, if the count value corresponding to the currently traversed miss grid is positive or zero, then assign a large negative number to the count value corresponding to the currently traversed miss grid. If the count value corresponding to the currently traversed miss grid is negative, then decrement the count value corresponding to the currently traversed miss grid by one. When the current laser ray endpoint is a non-ground ray endpoint, the count value corresponding to the miss grid is updated based on the second strategy. When the currently traversed miss grid is a ground miss grid, the count value corresponding to the currently traversed miss grid is not updated, and the operation proceeds directly to the next step. An update module is used to update the occupancy probability grid submap to be updated based on the statistical results, wherein the coordinate system of the counting grid submap coincides with the coordinate system of the occupancy probability grid map, and the statistical results include the type of each grid in the counting grid submap and the number of hit events or miss events that occur in each grid, and the grid types include hit grids and miss grids.
8. An electronic device, characterized in that, The electronic device includes: One or more processors; Storage device for storing one or more programs; When the one or more programs are executed by the one or more processors, the one or more processors implement the method as described in any one of claims 1-6.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the processor, it implements the method as described in any one of claims 1-6.