Obstacle clustering method, apparatus, device, storage medium and program product

By clustering obstacles in the grid around autonomous vehicles and merging adjacent grids using the disjoint-set data structure algorithm to form clustered grids, the problem of large computational load and high computing power consumption caused by an excessive number of grids is solved, thus improving processing efficiency.

CN116503629BActive Publication Date: 2026-02-17HANGZHOU FABU TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310370379.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-04-03
Publication Date
2026-02-17
Estimated Expiration
2043-04-03

AI Technical Summary

Technical Problem

In autonomous driving scenarios, dividing the vehicle's detectable area into multiple grids leads to a large amount of computation and consumes a lot of computing power.

Method used

The disjoint-set data structure algorithm is used to cluster grids containing obstacles, merging adjacent grids to form clustered grids, thus reducing the number of grids.

Benefits of technology

This reduces the computational load and computing power consumption of subsequent processing, and improves processing efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116503629B_ABST
    Figure CN116503629B_ABST
Patent Text Reader

Abstract

The application provides an obstacle clustering method, device, equipment, storage medium and program product. The method comprises the following steps: determining a plurality of first grids, then acquiring attribute information of the plurality of first grids, and performing clustering processing on the first grids with obstacles according to the attribute information by using a union-find set algorithm to obtain a plurality of clustering grids; and determining at least one target region in a ground region based on the plurality of clustering grids, wherein at least one obstacle exists in the target region. Since the number of the clustering grids is smaller than the number of the plurality of grids obtained by segmentation, the calculation amount of subsequent processing of a vehicle is also reduced, and the consumed computing power is also small.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of point cloud data processing technology, and in particular to a method, apparatus, device, storage medium and program product for clustering obstacles. Background Technology

[0002] In autonomous driving scenarios, obstacle detection models can detect different types of targets. For example, in a port, the types of targets to be detected include vehicles, pedestrians, autonomous vehicles, tricycles, gantry cranes, bridge cranes, forklifts, reach stackers, and forklifts. When encountering targets other than those of a specific type, the model may not detect them. Alternatively, the presence of noise or other obstacles may cause specific types of targets to be missed. To prevent collisions between the autonomous vehicle and obstacles in these two situations, the system typically includes point cloud data segmented from the ground as redundant information.

[0003] Cloud-based ground segmentation divides the detectable area of ​​autonomous vehicles into multiple grids. The attribute information of each grid (such as whether it is an obstacle) is independent of each other. In downstream applications (such as subsequent path planning), each grid needs to be processed. However, the large number of grids leads to a large amount of computation in subsequent applications and consumes a lot of computing power. Summary of the Invention

[0004] This application provides a method, apparatus, device, storage medium, and program product for clustering obstacles, in order to solve the problem in related technologies that the number of grids for segmenting the detectable area of ​​a vehicle is large, resulting in a large amount of computation and high computing power consumption for subsequent applications.

[0005] Firstly, this application provides a method for clustering obstacles, including:

[0006] Multiple first grids are defined, which are obtained by dividing the ground area within a preset range around the vehicle;

[0007] Obtain attribute information of multiple first grids, the attribute information being used to indicate whether there are obstacles in the grids;

[0008] Using the disjoint-set data structure algorithm, the first grid containing obstacles is clustered based on the attribute information to obtain multiple clustered grids;

[0009] Based on the multiple clustering grids, at least one target region is determined in the ground region, and at least one obstacle exists in the target region.

[0010] In one possible implementation, the first grid containing obstacles is clustered based on the attribute information using a disjoint-set data structure algorithm to obtain multiple clustered grids, including:

[0011] Based on the attribute information of each first grid, a plurality of second grids containing obstacles are determined among the plurality of first grids;

[0012] Determine the coordinates of the plurality of first grids;

[0013] Based on the coordinates of the plurality of first grids, the plurality of second grids are merged using the disjoint-set data structure algorithm to obtain the plurality of clustered grids.

[0014] In one possible implementation, the step of merging the multiple second grids using the disjoint-set data structure algorithm based on their coordinates to obtain the multiple clustered grids includes:

[0015] For any given second grid, determine the adjacent grids of the second grid based on the coordinates of the second grid;

[0016] If there are obstacles in the adjacent grids and the adjacent grids have not been clustered, then the second grid and the adjacent grids are merged to obtain the cluster grid in which the second grid is located.

[0017] In one possible implementation, merging the second grid and the adjacent grids to obtain the cluster grid containing the second grid includes:

[0018] Determine the first grid tree in which the second grid belongs, and the second grid tree in which the adjacent grids belong;

[0019] Determine the first level of the first grid tree and the second level of the second grid tree;

[0020] If the first level is greater than or equal to the second level, the second grid tree is merged into the first grid tree to obtain the first target grid tree, and the grids in the first target grid tree are determined as the clustering grids corresponding to the second grids. The root node of the first target grid tree is the root node of the first grid tree.

[0021] If the first level is lower than the second level, the first grid tree is merged into the second grid tree to obtain the second target grid tree, and the grid in the second target grid tree is determined as the cluster grid in which the second grid belongs. The root node of the second target grid tree is the root node of the second grid tree.

[0022] In one possible implementation, determining at least one target region in the ground region based on the plurality of clustering grids includes:

[0023] Obtain the target point cloud for each cluster grid;

[0024] For any clustered grid, based on the target point cloud of the clustered grid, the point cloud convex hull and boundary information are obtained through the point cloud convex hull algorithm. The point cloud convex hull is the region occupied by obstacles in the clustered grid, and the boundary information includes the shape, size and position of the region occupied by obstacles in the clustered grid.

[0025] The corresponding target region is determined based on the point cloud convex hull and the boundary information.

[0026] In one possible implementation, for each cluster grid, obtaining the target point cloud of the cluster grid includes:

[0027] Obtain the first point cloud of each grid in the clustering grid;

[0028] Determine the rectangular region where the points in the first point cloud are clustered, and the points at the four corners of the rectangular region are the points in the first point cloud;

[0029] The points at the four corners are defined as the target point cloud.

[0030] Secondly, this application provides a clustering device for obstacles, comprising:

[0031] The first determining module is used to determine a plurality of first grids, wherein the plurality of first grids are obtained by dividing the ground area within a preset range around the vehicle;

[0032] An acquisition module is used to acquire attribute information of multiple first grids, the attribute information being used to indicate whether there are obstacles in the grids;

[0033] The clustering module is used to cluster the first grid containing obstacles according to the attribute information using a disjoint-set data structure algorithm, thereby obtaining multiple clustered grids.

[0034] The second determining module is used to determine at least one target region in the ground region based on the plurality of clustering grids, wherein at least one obstacle exists in the target region.

[0035] In one possible implementation, the clustering module is specifically used for:

[0036] Based on the attribute information of each first grid, a plurality of second grids containing obstacles are determined among the plurality of first grids;

[0037] Determine the coordinates of the plurality of first grids;

[0038] Based on the coordinates of the plurality of first grids, the plurality of second grids are merged using the disjoint-set data structure algorithm to obtain the plurality of clustered grids.

[0039] In one possible implementation, the clustering module is specifically used for:

[0040] For any given second grid, determine the adjacent grids of the second grid based on the coordinates of the second grid;

[0041] If there are obstacles in the adjacent grids and the adjacent grids have not been clustered, then the second grid and the adjacent grids are merged to obtain the cluster grid in which the second grid is located.

[0042] In one possible implementation, the clustering module is specifically used for:

[0043] Determine the first grid tree in which the second grid belongs, and the second grid tree in which the adjacent grids belong;

[0044] Determine the first level of the first grid tree and the second level of the second grid tree;

[0045] If the first level is greater than or equal to the second level, the second grid tree is merged into the first grid tree to obtain the first target grid tree, and the grids in the first target grid tree are determined as the clustering grids corresponding to the second grids. The root node of the first target grid tree is the root node of the first grid tree.

[0046] If the first level is lower than the second level, the first grid tree is merged into the second grid tree to obtain the second target grid tree, and the grid in the second target grid tree is determined as the cluster grid in which the second grid belongs. The root node of the second target grid tree is the root node of the second grid tree.

[0047] In one possible implementation, the second determining module is specifically used for:

[0048] Obtain the target point cloud for each cluster grid;

[0049] For any clustered grid, based on the target point cloud of the clustered grid, the point cloud convex hull and boundary information are obtained through the point cloud convex hull algorithm. The point cloud convex hull is the region occupied by obstacles in the clustered grid, and the boundary information includes the shape, size and position of the region occupied by obstacles in the clustered grid.

[0050] The corresponding target region is determined based on the point cloud convex hull and the boundary information.

[0051] In one possible implementation, for each cluster grid, the second determining module is specifically used for:

[0052] Obtain the first point cloud of each grid in the clustering grid;

[0053] Determine the rectangular region where the points in the first point cloud are clustered, and the points at the four corners of the rectangular region are the points in the first point cloud;

[0054] The points at the four corners are defined as the target point cloud.

[0055] Thirdly, this application provides an electronic device, including: a processor, and a memory communicatively connected to the processor;

[0056] The memory stores computer-executed instructions;

[0057] The processor executes computer execution instructions stored in the memory to implement the obstacle clustering method as described in the first aspect.

[0058] Fourthly, this application provides a computer-readable storage medium storing computer-executable instructions, which, when executed by a computer, are used to implement the obstacle clustering method as described in the first aspect.

[0059] Fifthly, this application provides a computer program product, including a computer program, which, when executed by a computer, is used to implement the obstacle clustering method described in the first aspect.

[0060] This application provides a method, apparatus, device, storage medium, and program product for clustering obstacles. By determining multiple first grids, obtaining attribute information of the multiple first grids, and using a disjoint-set data structure algorithm, the first grids containing obstacles are clustered according to the attribute information to obtain multiple clustered grids. Based on the multiple clustered grids, at least one target area is determined in the ground area, and at least one obstacle exists in the target area. Since the number of clustered grids is less than the number of multiple grids obtained by segmentation, the computational load of subsequent vehicle processing is reduced, and the computing power consumed is also smaller. Attached Figure Description

[0061] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.

[0062] Figure 1 This is a schematic diagram illustrating one application scenario to which this application applies;

[0063] Figure 2 A flowchart illustrating an obstacle clustering method provided in Embodiment 1 of this application;

[0064] Figure 3 A flowchart illustrating another obstacle clustering method provided in Embodiment 2 of this application;

[0065] Figure 4 This is a schematic diagram of an exemplary second grid in this application;

[0066] Figure 5 This is a schematic diagram illustrating a tree merging process as an example of this application;

[0067] Figure 6 This is a schematic diagram illustrating another tree merging process as an example of this application;

[0068] Figure 7 A flowchart illustrating another obstacle clustering method provided in Embodiment 3 of this application;

[0069] Figure 8 This is a schematic diagram of the structure of an obstacle clustering device provided in Embodiment 4 of this application;

[0070] Figure 9 This is a schematic diagram of the structure of an electronic device provided in Embodiment 5 of this application.

[0071] The accompanying drawings illustrate specific embodiments of this application, which will be described in more detail below. These drawings and descriptions are not intended to limit the scope of the concept in any way, but rather to illustrate the concept of this application to those skilled in the art through reference to particular embodiments. Detailed Implementation

[0072] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.

[0073] In autonomous driving scenarios, obstacle detection models can detect different types of targets. For example, in a port, the types of targets to be detected include vehicles, pedestrians, autonomous vehicles, tricycles, gantry cranes, bridge cranes, forklifts, reach stackers, and forklifts. When encountering targets other than those of a specific type, the model may not detect them. Alternatively, the presence of noise or other obstacles may cause specific types of targets to be missed. To prevent collisions between autonomous vehicles (which can be called autonomous vehicles) and obstacles in these two situations, the system typically includes point cloud data segmented from the ground as redundant information.

[0074] For example, the detectable area of ​​an autonomous vehicle can be divided into multiple grids through cloud-ground segmentation. Each grid will obtain corresponding attribute information, such as ground height, whether the ground is an obstacle (i.e., whether an obstacle exists), whether it is a static obstacle, point cloud distance, etc.

[0075] For example, the attribute information of whether a cell is an obstacle can be represented by false or true. False means that the cell is an obstacle and the vehicle cannot pass through the area corresponding to the cell, while true means that the cell is not an obstacle and the vehicle can pass through the area corresponding to the cell.

[0076] Since the attribute information of each grid is independent of each other, in downstream applications (such as subsequent path planning), the vehicle needs to process each grid. The large number of grids leads to a large amount of computation in subsequent applications and consumes a lot of computing power.

[0077] Therefore, this application provides a clustering method for obstacles. Based on the attribute information of multiple grids, a disjoint-set data structure algorithm is used to cluster multiple grids to obtain multiple clustered grids. In other words, grids containing obstacles are clustered. For example, if five adjacent grids all contain obstacles, these five grids can be clustered into one clustered grid. This allows a vehicle to determine at least one target area in the ground region based on multiple clustered grids. Each target area contains obstacles. Since the number of clustered grids is less than the number of grids obtained from the segmentation, the computational load for subsequent vehicle processing is reduced, and the computational power consumed is also smaller.

[0078] The following is an explanation of the terms used in the embodiments of this application:

[0079] The first grid refers to the grid obtained by segmenting the ground area within a preset range that the vehicle can recognize.

[0080] The second grid refers to the grid containing obstacles within the ground area segmented within the preset range.

[0081] The first grid tree refers to the tree containing the nodes of the grids with obstacles (i.e., the second grids).

[0082] Second grid tree: refers to the tree containing the nodes of the adjacent grids of the second grid.

[0083] First target grid tree: refers to the tree obtained after merging the second grid tree into the first grid tree when the level of the first grid tree is higher than the level of the second grid tree.

[0084] Second target grid tree: refers to the tree obtained after merging the first grid tree into the second grid tree when the level of the first grid tree is lower than the level of the second grid tree.

[0085] To facilitate understanding, the following will be combined with... Figure 1 The examples illustrate the application scenarios to which the embodiments of this application are applicable.

[0086] Figure 1 Please refer to the diagram illustrating one application scenario to which this application applies. Figure 1 This includes a vehicle 101, whose detectable area is divided into multiple grids. The detectable area includes the detectable area in front of the vehicle 101 and the detectable area behind the vehicle 101. The vehicle 101 can cluster the grids containing obstacles within the segmented grids. For example, if multiple adjacent grids contain obstacles, these grids can be clustered. This allows the vehicle to process the clustered grids once, rather than processing each individual grid, thus improving processing efficiency. This processing could include, for example, path planning.

[0087] Understandable. Figure 1 The number of grids in the detectable region shown are for illustrative purposes only.

[0088] The technical solutions of this application and how they solve the aforementioned technical problems are described in detail below with specific embodiments. These specific embodiments may exist independently or in combination with each other. Identical or similar concepts or processes may not be repeated in some embodiments. The embodiments of this application will now be described with reference to the accompanying drawings.

[0089] Figure 2 This is a flowchart illustrating an obstacle clustering method provided in Embodiment 1 of this application. This method can be executed by a vehicle or by an obstacle clustering device installed in the vehicle. The device can be a chip, a chip module, or an integrated development environment (IDE), etc. The following uses a vehicle as an example. Figure 2 The method includes the following steps:

[0090] S201. Determine multiple first grids, which are obtained by dividing the ground area within a preset range around the vehicle.

[0091] The vehicle can divide its identifiable range, i.e., a preset range, into multiple grids. The preset range can include a detectable area in front of the vehicle and a detectable area behind the vehicle. For example, the detectable area in front is 90m long and 60m wide, and the detectable area behind is 10m long and 60m wide. The detectable areas in front and behind can be divided into 200×200 grids with a granularity of 0.5m × 0.3m. The division can be achieved using methods such as cloud-ground segmentation. Data processing can be performed on the resulting grids, such as identifying whether each grid represents an obstacle and identifying the point cloud of each grid. Point cloud acquisition methods can include, for example, a 3D laser scanner or a photographic scanner.

[0092] Point cloud refers to a massive collection of points representing the surface characteristics of a target. For example, a point cloud obtained by laser measurement can include the three-dimensional coordinates of points and the intensity of laser reflection. A point cloud obtained by photogrammetry can include the three-dimensional coordinates and color information of points. Alternatively, a point cloud obtained by combining laser measurement and photogrammetry can include the three-dimensional coordinates of points, the intensity of laser reflection, and color information. The color information can be, for example, the colors of the three channels: red, green, and blue (RGB).

[0093] S202. Obtain attribute information for multiple first grids. The attribute information is used to indicate whether there are obstacles in the grid.

[0094] After the vehicle identifies multiple first grids, it can obtain the attribute information of each grid, which can indicate whether there are obstacles in the grid.

[0095] For example, a vehicle can use a target recognition algorithm to determine whether an obstacle exists in each grid cell. If an obstacle is detected in a grid cell, the obstacle attribute `ob` in the corresponding attribute information of that grid cell is set to True; if no obstacle is detected in a grid cell, the obstacle attribute `ob` is set to False. Alternatively, the value of the obstacle attribute `ob` can also be set to a number, for example, 1 to indicate the presence of an obstacle and 0 to indicate the absence of an obstacle. Other forms of representation are also possible, and this application does not impose any limitations on this comparison.

[0096] S203. Using the disjoint-set data structure algorithm, cluster the first grid containing obstacles based on attribute information to obtain multiple clustered grids.

[0097] The vehicle can use the disjoint-set data structure algorithm to cluster the first grid containing obstacles based on the attribute information of each first grid, thus obtaining multiple clustered grids.

[0098] For example, each first grid can be treated as a node in a disjoint-set data structure, with each node being a root node without child nodes, i.e., an independent node. Then, based on these nodes, the first grid can be clustered using a disjoint-set data structure algorithm to obtain multiple clustered grids.

[0099] Each cluster grid includes at least two first grids, which are adjacent grids, and each cluster grid includes at least one obstacle.

[0100] S204. Based on multiple clustering grids, determine at least one target region in the ground region, where at least one obstacle exists.

[0101] After determining multiple cluster grids, the vehicle can identify at least one target area in the ground region based on these grids. For example, each cluster grid can identify one target area. Alternatively, if the distance between two cluster grids is less than or equal to a preset threshold, it indicates that the obstacles in these two cluster grids are clustered close together. The vehicle can treat these two obstacles as a single obstacle. In this case, the identified target area can include two or more obstacles.

[0102] In this embodiment, the vehicle can determine multiple first grids, obtain attribute information of multiple first grids, and use a disjoint-set data structure algorithm to cluster the first grids containing obstacles according to the attribute information to obtain multiple clustered grids. Based on the multiple clustered grids, at least one target area is determined in the ground area, and at least one obstacle exists in the target area. Since the number of clustered grids is less than the number of multiple grids obtained by segmentation, the computational load of subsequent vehicle processing is reduced, and the computing power consumed is also smaller.

[0103] The following is an example of another obstacle clustering method provided in this application, illustrated by Example 2.

[0104] Figure 3 This is a flowchart illustrating another obstacle clustering method provided in Embodiment 2 of this application. This method can be executed by a vehicle or by an obstacle clustering device installed in the vehicle. This device can be a chip, a chip module, or an IDE, etc. The following uses a vehicle as an example. Figure 3 The method includes the following steps:

[0105] S301. Determine multiple first grids, which are obtained by dividing the ground area within a preset range around the vehicle.

[0106] S302. Obtain attribute information for multiple first grids. The attribute information is used to indicate whether there are obstacles in the grid.

[0107] For a description of S301 and S302, please refer to Embodiment 1, which will not be repeated here.

[0108] S303. Based on the attribute information of each first grid, determine multiple second grids containing obstacles among the multiple first grids.

[0109] After obtaining the attribute information of each first grid, the vehicle can determine the multiple first grids containing obstacles based on the attribute information of each first grid.

[0110] In other words, a vehicle can identify a second grid as one of multiple first grids whose attribute information indicates the presence of an obstacle. For example, Figure 4 This is a schematic diagram of an exemplary second grid. The gray grids in the diagram represent the second grid (i.e., the grids in the first grid where obstacles exist), while the non-gray grids represent the grids in the first grid where no obstacles exist.

[0111] S304. Determine the coordinates of multiple first grids.

[0112] After determining the second grid, the vehicle can determine the coordinates of multiple first grids. This means that the multiple first grids include the second grids; that is, the coordinates of multiple second grids are simultaneously determined. Figure 4 For example, the coordinates of each first grid can be determined with the bottom left corner as the origin.

[0113] S305. Based on the coordinates of multiple first grids, merge multiple second grids using the disjoint-set data structure algorithm to obtain multiple clustered grids.

[0114] After determining the coordinates of multiple first grids, the second grids can be used as nodes in a disjoint-set data structure, where each node is a root node without child nodes, i.e., an independent node.

[0115] It can be understood that multiple second grids are grids containing obstacles, and each second grid has its own cluster grid. That is, at least one second grid can determine a cluster grid. Therefore, for any given second grid, its adjacent grids can be determined based on its coordinates. Adjacent grids can include one or more of the following: the first grid adjacent to the second grid on its left, the first grid adjacent to the second grid below it, and the first grid adjacent to the second grid on its bottom left. Adjacent grids can be referenced... Figure 4 Specifically, if the second grid is Figure 4 The edge grids (grids within the bold dashed boxes) are defined as follows: taking the top-left grid as an example, its adjacent grids include the first adjacent grid below it. For the bottom-right grid, its adjacent grids include the first adjacent grid to its left.

[0116] For example, if the coordinates of the first grid are represented as (i, j), then the coordinates of the first grid adjacent to the left are (i-1, j), the coordinates of the first grid adjacent to the bottom are (i, j-1), and the coordinates of the first grid adjacent to the bottom left are (i-1, j-1), where i and j are integers greater than or equal to 1.

[0117] After determining adjacent grids, if there are obstacles in adjacent grids and these adjacent grids have not been clustered, then the adjacent grids and the second grid can be merged to obtain the cluster grid containing the second grid. In other words, for any second grid, if there are obstacles in its adjacent grids and these adjacent grids have not been clustered (i.e., they are not considered adjacent grids of other second grids), these adjacent grids can be merged into the cluster grid containing the second grid. This avoids clustering adjacent grids that have already been clustered, thus improving clustering efficiency.

[0118] Optionally, the above clustering process can be performed as follows:

[0119] Determine the first grid tree where the second grid is located, and the second grid tree where the adjacent grids are located. That is, the first grid tree is the tree where the node corresponding to the second grid is located, and the second grid tree is the tree where the adjacent grids are located.

[0120] Then, determine the first level of the first grid tree and the second level of the second grid tree. Specifically, the following cases exist:

[0121] Case 1

[0122] If the first level is higher than the second level, the second grid tree is merged into the first grid tree to obtain the first target grid tree, and the grids in the first target grid tree are determined as the cluster grids where the second grids are located. The root node of the first target grid tree is the root node of the first grid tree.

[0123] Case 2

[0124] If the first level is lower than the second level, the first grid tree is merged into the second grid tree to obtain the second target grid tree, and the grids in the second target grid tree are determined as the clustering grids corresponding to the second grids. The root node of the second target grid tree is the root node of the second grid tree.

[0125] Case 3

[0126] If the first level is equal to the second level, the second grid tree can be merged into the first grid tree, or the first grid tree can be merged into the second grid tree. For details, please refer to Case 1 and Case 2 above.

[0127] The first level of the first grid tree can be determined based on the number of times the first grid tree is merged, and the second level of the second grid tree can be determined based on the number of times the second grid tree is merged. In other words, the first level can be determined based on the number of times the root node of the first grid tree is merged. For example, if the number of merges is 5, the first level can be 5.

[0128] It can be understood that the first level is the level of the first network tree, and the second level is the level of the second network tree.

[0129] For example, Figure 5 This is a schematic diagram illustrating a tree merging process as an example. Figure 5 This involves merging the meshes corresponding to node 1 and node 5. In the first mesh tree, the root node of nodes 2, 3, and 4 is node 1. In the second mesh tree, the root node of nodes 6 and 7 is node 5. Assuming the first level of the first mesh tree is 2 and the second level of the second mesh tree is 1, merging the second mesh tree into the first mesh tree yields the first target mesh tree as shown below. Figure 5 As shown, the root node of the first target grid tree is the root node of the first grid tree, i.e., node 1. The "+" in the figure indicates merging.

[0130] In another example, Figure 6 This is a schematic diagram illustrating a tree merging process as an example. Figure 6 This involves merging the mesh corresponding to node 4 and the mesh corresponding to node 7. In the first mesh tree, the root node of nodes 2, 3 and 4 is node 1. First, point node 4 to its root node (i.e. node 1) to obtain the transformed first mesh tree. In the second mesh tree, the root node of nodes 6 and 7 is node 5. Point node 7 to its root node (node ​​5) to obtain the transformed second mesh tree.

[0131] Assuming the first grid tree has a first level of 2 and the second grid tree has a second level of 1, the transformed second grid tree can be merged into the transformed first grid tree to obtain the first target grid tree, as shown below. Figure 6 As shown, the root node of the first target grid tree is the root node of the first grid tree, i.e., node 1. The "+" in the figure indicates merging.

[0132] It is understandable that if a second grid is an independent node, then the first level of the first grid tree is 0, and the root node of the first grid tree is that second grid.

[0133] It should be noted that if the second grid a, the second grid b, the second grid c, and the second grid d are all adjacent grids, then the grid tree containing the second grid a, the second grid b, the second grid c, and the second grid d is the same tree, and the clustering grid containing the second grid a, the second grid b, the second grid c, and the second grid d is the same clustering grid.

[0134] S306. Based on multiple clustering grids, determine at least one target region in the ground region, where at least one obstacle exists in the target region.

[0135] After determining the clustering grid, at least one target region can be identified in the ground area based on multiple clustering grids, and at least one obstacle exists in the target region.

[0136] In this embodiment, the vehicle can determine multiple first grids, obtain the attribute information of the multiple first grids, determine the coordinates of the multiple first grids, and then merge multiple second grids using a disjoint-set data structure algorithm based on the coordinates of the multiple first grids to obtain multiple clustered grids. Based on the multiple clustered grids, at least one target area is determined in the ground area, and at least one obstacle exists in the target area. Since the number of clustered grids is less than the number of multiple grids obtained by segmentation, the computational load of subsequent processing by the vehicle is reduced, and the computing power consumed is also smaller.

[0137] The following describes another obstacle clustering method provided in this application through Example 3.

[0138] Figure 7 This is a flowchart illustrating another obstacle clustering method provided in Embodiment 3 of this application. This method can be executed by a vehicle or by an obstacle clustering device installed in the vehicle. This device can be a chip, a chip module, or an IDE, etc. The following uses a vehicle as an example. Figure 7 The method includes the following steps:

[0139] S701. Determine multiple first grids, which are obtained by dividing the ground area within a preset range around the vehicle.

[0140] S702. Obtain attribute information for multiple first grids. The attribute information is used to indicate whether there are obstacles in the grid.

[0141] S703. Using the disjoint-set data structure algorithm, cluster the first grid containing obstacles based on attribute information to obtain multiple clustered grids.

[0142] For the descriptions and implementation methods of S701 to S703, please refer to the above method embodiments, which will not be repeated here.

[0143] S704. Obtain the target point cloud for each cluster grid.

[0144] Each cluster grid includes at least one second grid, and each second grid includes a point cloud.

[0145] In one possible implementation, the vehicle can acquire the first point cloud of each grid in the clustering grid, which includes multiple points, and then use each point in the first point cloud as the target point. That is, the points in the first point cloud of each grid in the clustering grid are used as the points in the target point cloud of that clustering grid.

[0146] In another possible implementation, the vehicle can determine the rectangular region where points in the first point cloud are clustered. The points at the four corners of the rectangular region are points in the first point cloud. By identifying the points at the four corners as points in the target point cloud, the number of points in the target point cloud in the clustering grid is reduced, thereby improving the efficiency of subsequent processing to determine the convex hull of the point cloud based on the target point cloud.

[0147] S705. For any clustering grid, based on the target point cloud of the clustering grid, obtain the point cloud convex hull and boundary information through the point cloud convex hull algorithm.

[0148] After determining the target point cloud, for any clustered grid, the vehicle can obtain the point cloud convex hull and boundary information corresponding to that clustered grid by using the point cloud convex hull algorithm.

[0149] The convex hull of a point cloud represents the region occupied by obstacles in a clustered mesh. Boundary information includes the shape, size, and location of the region occupied by the obstacles in the clustered mesh—that is, the shape, size, and location of the region occupied by the point cloud convex hull. The shape of the point cloud convex hull can be a two-dimensional irregular shape or a three-dimensional irregular polyhedron.

[0150] S707. Determine the corresponding target region based on the point cloud convex hull and boundary information.

[0151] After obtaining the point cloud convex hull and boundary information, for each point cloud convex hull, the vehicle can determine the corresponding target region based on the point cloud convex hull and boundary information, so that subsequent vehicle processing (such as subsequent path planning) can be performed based on the target region.

[0152] In this embodiment, the vehicle can determine multiple first grids, obtain attribute information for these first grids, and then use a disjoint-set data structure algorithm to cluster the first grids containing obstacles based on the attribute information, resulting in multiple clustered grids. Then, the target point cloud of each clustered grid is obtained. For any given clustered grid, based on the target point cloud, a point cloud convex hull algorithm is used to obtain the point cloud convex hull and boundary information. Then, based on the point cloud convex hull and boundary information, the corresponding target region is determined. The target region contains at least one obstacle. Since the number of clustered grids is less than the number of grids obtained from segmentation, the computational load for subsequent vehicle processing is reduced, and the computational power consumed is also lower.

[0153] Figure 8This is a schematic diagram of an obstacle clustering device provided in Embodiment 4 of this application. (Reference) Figure 8 The device 80 includes: a first determining module 801, an acquisition module 802, a clustering module 803, and a second determining module 804.

[0154] The first determining module 801 is used to determine multiple first grids, which are obtained by dividing the ground area within a preset range around the vehicle.

[0155] The acquisition module 802 is used to acquire attribute information of multiple first grids, and the attribute information is used to indicate whether there are obstacles in the grid.

[0156] Clustering module 803 is used to cluster the first grid containing obstacles based on attribute information using the disjoint-set data structure algorithm to obtain multiple clustered grids.

[0157] The second determining module 804 is used to determine at least one target region in the ground region based on multiple clustering grids, wherein at least one obstacle exists in the target region.

[0158] In one possible implementation, clustering module 803 is specifically used for:

[0159] Based on the attribute information of each first grid, multiple second grids containing obstacles are identified among the multiple first grids.

[0160] Determine the coordinates of multiple first grids.

[0161] Based on the coordinates of multiple first grids, multiple second grids are merged using a disjoint-set data structure algorithm to obtain multiple clustered grids.

[0162] In one possible implementation, clustering module 803 is specifically used for:

[0163] For any given second grid, determine the adjacent grids based on the coordinates of the second grid.

[0164] If there are obstacles in adjacent grids and the adjacent grids have not been clustered, then the second grid and the adjacent grids are merged to obtain the cluster grid in which the second grid belongs.

[0165] In one possible implementation, clustering module 803 is specifically used for:

[0166] Determine the first grid tree in which the second grid belongs, and the second grid tree in which the adjacent grids belong.

[0167] Determine the first level of the first grid tree and the second level of the second grid tree.

[0168] If the first level is greater than or equal to the second level, the second grid tree is merged into the first grid tree to obtain the first target grid tree, and the grids in the first target grid tree are determined as the clustering grids corresponding to the second grids. The root node of the first target grid tree is the root node of the first grid tree.

[0169] If the first level is lower than the second level, the first grid tree is merged into the second grid tree to obtain the second target grid tree. The grids in the second target grid tree are determined as the cluster grids where the second grids belong, and the root node of the second target grid tree is the root node of the second grid tree.

[0170] In one possible implementation, the second determining module 804 is specifically used for:

[0171] Obtain the target point cloud for each cluster grid.

[0172] For any clustering grid, based on the target point cloud of the clustering grid, the point cloud convex hull algorithm is used to obtain the point cloud convex hull and boundary information. The point cloud convex hull is the region occupied by obstacles in the clustering grid, and the boundary information includes the shape, size and position of the region occupied by obstacles in the clustering grid.

[0173] The corresponding target region is determined based on the point cloud convex hull and boundary information.

[0174] In one possible implementation, for each cluster grid, the second determining module 804 is specifically used for:

[0175] Obtain the first point cloud for each grid in the clustering grid;

[0176] Determine the rectangular region where the points in the first point cloud are clustered, and the points at the four corners of the rectangular region are the points in the first point cloud;

[0177] The points at the four corners are defined as the target point cloud.

[0178] The apparatus in this embodiment can be used to execute the technical solutions of the above method embodiments. The specific implementation methods and technical effects are similar, and will not be described again here.

[0179] Figure 9 This is a schematic diagram of the structure of an electronic device provided in Embodiment 5 of this application, as shown below. Figure 9 As shown, the electronic device 90 may include at least one processor 901 and a memory 902.

[0180] The memory 902 is used to store programs. Specifically, the program may include program code, which includes computer-executable instructions.

[0181] The memory 902 may include random access memory (RAM) and may also include non-volatile memory, such as at least one disk storage device.

[0182] The processor 901 is used to execute computer execution instructions stored in the memory 902 to implement the method described in the foregoing method embodiments. The processor 901 may be a central processing unit (CPU), an application-specific integrated circuit (ASIC), or one or more integrated circuits configured to implement the embodiments of this application.

[0183] Optionally, the electronic device 90 may also include a communication interface 903. In specific implementations, if the communication interface 903, memory 902, and processor 901 are implemented independently, they can be interconnected via a bus to complete communication. The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. Buses can be categorized as address buses, data buses, control buses, etc., but this does not imply that there is only one bus or one type of bus.

[0184] Optionally, in a specific implementation, if the communication interface 903, memory 902, and processor 901 are integrated on a single chip, then the communication interface 903, memory 902, and processor 901 can communicate through an internal interface.

[0185] Electronic devices 90 can be chips, chip modules, IDEs, autonomous vehicles, non-autonomous vehicles, etc.

[0186] The electronic device in this embodiment can be used to execute the technical solutions of the above method embodiments. The specific implementation methods and technical effects are similar, and will not be repeated here.

[0187] Embodiment 6 of this application provides a computer-readable storage medium, which may include various media capable of storing computer-executable instructions, such as a USB flash drive, a portable hard drive, a read-only memory (ROM), RAM, a disk, or an optical disk. Specifically, the computer-readable storage medium stores computer-executable instructions, which, when executed by a computer, cause the technical solution shown in the above method embodiment to be executed. The specific implementation method and technical effect are similar, and will not be repeated here.

[0188] Embodiment 7 of this application provides a computer program product, including a computer program. When the computer program is executed by a computer, the technical solution shown in the above method embodiment is executed. The specific implementation method and technical effect are similar, and will not be repeated here.

[0189] Other embodiments of this application will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this application that follow the general principles of this application and include common knowledge or customary techniques in the art not disclosed herein. The specification and examples are to be considered exemplary only, and the true scope and spirit of this application are indicated by the following claims.

[0190] It should be understood that this application is not limited to the precise structure described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this application is limited only by the appended claims.

[0191] In this application, "and / or" is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent three cases: A existing alone, A and B existing simultaneously, and B existing alone. Additionally, the character " / " in this document indicates that the preceding and following related objects have an "or" relationship.

[0192] "At least one of the following" or similar expressions refer to any combination of these items, including any combination of single or multiple items. For example, at least one of a, b, or c can mean: a, b, c, a and b, a and c, b and c, or a, b, and c, where each of a, b, and c can be an element itself or a set containing one or more elements.

[0193] In this application, "at least one" means one or more. "More than one" means two or more. The descriptions of "first," "second," etc., appearing in the embodiments of this application are only for illustration and to distinguish the described objects, and have no order, nor do they indicate a special limitation on the number of devices in the embodiments of this application, and cannot constitute any limitation on the embodiments of this application. For example, "first threshold" and "second threshold" are only used to distinguish different thresholds, and do not indicate that the size, priority, or importance of these two thresholds are different.

[0194] In this application, terms such as "exemplary," "in some embodiments," and "in other embodiments" are used to indicate that something is an example, illustration, or description. Any embodiment or design described as "exemplary" in this application should not be construed as being more preferred or advantageous than other embodiments or designs. Rather, the term "exemplary" is used to present the concept in a specific manner.

[0195] In this application, the terms "of," "corresponding (relevant)," "corresponding," and "related" may sometimes be used interchangeably. It should be noted that, unless a distinction is emphasized, their intended meanings are consistent. Similarly, in the embodiments of this application, "communication" and "transmission" may sometimes be used interchangeably. It should be noted that, unless a distinction is emphasized, their intended meanings are consistent. For example, transmission can include sending and / or receiving, and can be a noun or a verb.

[0196] In this application, "equal to" can be used with "less than" or "greater than", but not simultaneously with both. When "equal to" is used with "less than", it applies to the technical solution adopted by "less than". When "equal to" is used with "greater than", it applies to the technical solution adopted by "greater than".

Claims

1. A method of clustering obstacles, characterized by, The method comprises the following steps: determining a plurality of first grids, the plurality of first grids being obtained by dividing a ground area within a preset range around a vehicle; obtaining attribute information of the plurality of first grids, the attribute information being used to indicate whether an obstacle exists in the grid; determining, according to the attribute information of each first grid, a plurality of second grids in which an obstacle exists in the plurality of first grids; determining coordinates of the plurality of first grids; for any one second grid, determining, according to the coordinates of the second grid, adjacent grids of the second grid; the adjacent grids include one or more of a first grid adjacent to the left of the second grid, a first grid adjacent to the bottom of the second grid, and a first grid adjacent to the lower left corner of the second grid; if an obstacle exists in the adjacent grids and the adjacent grids have not been processed by clustering, merging the second grid and the adjacent grids to obtain a cluster grid in which the second grid is located; determining at least one target area in the ground area based on a plurality of cluster grids, the target area having at least one obstacle; the merging of the second grid and the adjacent grids to obtain the cluster grid in which the second grid is located comprises: determining a first grid tree in which the second grid is located and a second grid tree in which the adjacent grids are located; determining a first level of the first grid tree and a second level of the second grid tree; wherein the first level is determined according to the number of times the first grid tree is merged; the second level is determined according to the number of times the second grid tree is merged; if the first level is higher than the second level, merging the second grid tree into the first grid tree to obtain a first target grid tree, and determining the grids in the first target grid tree as the cluster grid corresponding to the second grid, the root node of the first target grid tree being the root node of the first grid tree; if the first level is lower than the second level, merging the first grid tree into the second grid tree to obtain a second target grid tree, and determining the grids in the second target grid tree as the cluster grid in which the second grid is located, the root node of the second target grid tree being the root node of the second grid tree.

2. The method of claim 1, wherein, the determining of at least one target area in the ground area based on a plurality of cluster grids comprises: obtaining a target point cloud of each cluster grid; for any one cluster grid, obtaining a point cloud convex hull and boundary information by a point cloud convex hull algorithm according to the target point cloud of the cluster grid, the point cloud convex hull being an area occupied by an obstacle in the cluster grid, and the boundary information including a shape, a size, and a position of the area occupied by the obstacle in the cluster grid; determining a corresponding target area according to the point cloud convex hull and the boundary information.

3. The method of claim 2, wherein, for each cluster grid; the obtaining of the target point cloud of the cluster grid comprises: obtaining a first point cloud of each grid in the cluster grid; determining a rectangular area range in which points in the first point cloud are concentrated, four corners of the rectangular area range being points in the first point cloud; determining the four corners as the target point cloud.

4. A device for clustering obstacles, characterized in that the method comprises the following steps: The first determination module is configured to determine a plurality of first grids, which are obtained by dividing a ground area in a preset range around a vehicle; The acquisition module is configured to acquire attribute information of the plurality of first grids, the attribute information being used to indicate whether an obstacle exists in a grid; The clustering module is configured to determine, according to the attribute information of each first grid, a plurality of second grids in which an obstacle exists, from the plurality of first grids; The coordinates of the plurality of first grids are determined; For any one second grid, the coordinates of the second grid are determined, and neighboring grids of the second grid are determined according to the coordinates of the second grid; the neighboring grids include one or more of a first grid adjacent to the left of the second grid, a first grid adjacent to the bottom of the second grid, and a first grid adjacent to the lower left corner of the second grid; if an obstacle exists in the neighboring grids and the neighboring grids have not been processed by clustering, the second grid and the neighboring grids are merged to obtain a cluster grid in which the second grid is located; The second determination module is configured to determine at least one target area in which at least one obstacle exists, from the ground area based on the plurality of cluster grids; When the second grid and the neighboring grids are merged to obtain the cluster grid in which the second grid is located, the clustering module is specifically configured to determine a first grid tree in which the second grid is located and a second grid tree in which the neighboring grids are located; A first level of the first grid tree and a second level of the second grid tree are determined; the first level is determined according to a number of times of merging of the first grid tree; and the second level is determined according to a number of times of merging of the second grid tree; If the first level is higher than the second level, the second grid tree is merged into the first grid tree to obtain a first target grid tree, and grids in the first target grid tree are determined as cluster grids corresponding to the second grid; a root node of the first target grid tree is a root node of the first grid tree; If the first level is lower than the second level, the first grid tree is merged into the second grid tree to obtain a second target grid tree, and grids in the second target grid tree are determined as cluster grids in which the second grid is located; a root node of the second target grid tree is a root node of the second grid tree.

5. An electronic device, comprising: The processor and a memory connected with the processor in communication; The memory stores computer execution instructions; The processor executes the computer execution instructions stored in the memory to implement the clustering method of the obstacle according to any one of claims 1-3. The computer readable storage medium stores computer execution instructions, and the computer execution instructions are executed by the processor to implement the clustering method of the obstacle according to any one of claims 1-3.

6. A computer-readable storage medium, characterized in that, The computer program is executed by the processor to implement the clustering method of the obstacle according to any one of claims 1-3.

7. A computer program product, characterised in that, ​

Citation Information

Patent Citations

  • Parallel density clustering mining method based on MapReduce

    CN111597230A

  • Clustering method and device and server

    CN114266317A