Ground filtering method, device, electronic equipment and medium for steep environment
By eliminating outlier points in steep environments, generating outsourced virtual points and performing multi-directional rotation before performing PTD ground filtering, the problem of difficulty in distinguishing ground points and non-ground points in steep areas is solved, and filtering performance and accuracy are improved.
Patent Information
- Application Number
- CN202411088392.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-09
- Publication Date
- 2024-10-18
- Estimated Expiration
- 2044-08-09
AI Technical Summary
Existing ground filtering algorithms have poor filtering performance in steep areas with large slopes, especially in extremely steep terrain such as vertical cliffs and suspended cliffs close to 90°, where it is difficult to effectively distinguish between ground points and non-ground points.
By obtaining the original point cloud and eliminating outlier points, a set of outsourced virtual points is generated. The point cloud containing the outsourced virtual points is rotated in multiple directions as a whole and then PTD ground filtering is performed. The union is obtained to obtain a set of candidate ground points, and the union is identified from it. Remove non-ground points to form a target set of ground points.
It effectively avoids the occurrence of areas prone to misjudgment, improves the filtering performance of the ground filtering algorithm in steep areas, reduces the average slope of the filtered area, and improves the filtering accuracy.
Smart Images

Figure CN118643447B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of point cloud data processing, and in particular to a ground filtering method, device, electronic equipment and medium for steep environments. Background Art
[0002] Point cloud ground filtering refers to the operation of distinguishing ground points from non-ground points in point clouds. After years of development, a large number of ground filtering methods have been proposed and widely used in practical work. Most of these methods use features such as local minimum value, slope threshold, elevation difference threshold and smoothness to distinguish ground points from non-ground points in point clouds. However, most of the current ground filtering algorithms have poor filtering performance in steep areas with large slopes. In particular, for extremely steep terrain, such as vertical cliffs close to 90°, or even cliffs that exceed 90° and hang above the ground, there is currently a lack of effective ground filtering algorithms. This is mainly due to the high similarity between ground points and non-ground points in steep terrain scenes. This makes it particularly difficult to distinguish these ground points from non-ground points using conventional features such as height difference and slope. However, these steep areas are often the focus of geological disaster investigations. Therefore, it is particularly important to study ground filtering algorithms for steep terrain.
[0003] It should be noted that the information disclosed in the above background technology section is only used to enhance the understanding of the background of the present disclosure, and therefore may include information that does not constitute the prior art known to ordinary technicians in the field. Summary of the invention
[0004] In view of this, the embodiments of the present application at least provide a ground filtering method, device, electronic device and medium for steep environments, which can avoid the generation of areas that are easily misjudged and improve the filtering performance of the ground filtering algorithm in steep areas with large slopes.
[0005] This application mainly includes the following aspects:
[0006] In a first aspect, an embodiment of the present application provides a ground filtering method for a steep environment, and the ground filtering method for a steep environment includes:
[0007] Acquire an original point cloud corresponding to a steep environment, and remove outlier points in the original point cloud; the outlier points are target measurement points that are lower than the actual ground;
[0008] Generate an outsourced virtual point set at the edge of the original point cloud after removing the outlier points, and perform multi-directional overall rotation on the target point cloud; the target point cloud includes the outsourced virtual point set and the original point cloud;
[0009] Perform PTD ground filtering on the target point cloud after multi-directional overall rotation, and after removing each outsourced virtual point, take the union of ground points obtained from filtering in different directions to obtain a candidate ground point set after the union;
[0010] Non-ground points are identified and removed from the merged candidate ground point set to obtain a target ground point set.
[0011] In a second aspect, an embodiment of the present application further provides a ground filtering device for a steep environment, the ground filtering device for a steep environment comprising:
[0012] A rejection module is used to obtain an original point cloud corresponding to a steep environment and to reject outlier points in the original point cloud; the outlier points are target measurement points that are lower than the actual ground;
[0013] A rotation module, used to generate an outsourced virtual point set at the edge of the original point cloud after removing the outlier points, and perform multi-directional overall rotation on the target point cloud; the target point cloud includes the outsourced virtual point set and the original point cloud;
[0014] A union processing module is used to perform PTD ground filtering on the target point cloud after the overall rotation in multiple directions, and after removing each outsourced virtual point, take the union of the ground points obtained from filtering in different directions to obtain a candidate ground point set after the union;
[0015] The identification module is used to identify and remove non-ground points from the merged candidate ground point set to obtain a target ground point set.
[0016] In a third aspect, an embodiment of the present application further provides an electronic device, comprising: a processor, a memory and a bus, wherein the memory stores machine-readable instructions executable by the processor, and when the electronic device is running, the processor and the memory communicate through the bus, and the machine-readable instructions are executed by the processor to execute the steps of the ground filtering method for steep environments described in the first aspect or any possible implementation scheme of the first aspect.
[0017] In a fourth aspect, an embodiment of the present application further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the ground filtering method for steep environments described in the above-mentioned first aspect or any possible implementation scheme of the first aspect are executed.
[0018] The ground filtering method, device, electronic device and medium for steep environments provided in the embodiments of the present application generate outsourced virtual points around the original point cloud, and after rotating the target point cloud containing the outsourced virtual points, these outsourced virtual points can block the non-ground points at the edge of the filtering area, thereby avoiding the generation of areas that are easily misjudged. Compared with the related art, most ground filtering algorithms have poor filtering performance in steep areas with large slopes, such as vertical cliffs close to 90°, or even cliffs that are more than 90° and suspended above the ground. The embodiments of the present application reduce the average slope of the filtering area to a certain extent, can improve the filtering accuracy, and can improve the filtering performance of the ground filtering algorithm in steep areas with large slopes.
[0019] In order to make the above-mentioned objects, features and advantages of the present application more obvious and easy to understand, preferred embodiments are specifically cited below and described in detail with reference to the attached drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.
[0021] Figure 1 A flow chart of a ground filtering method for steep environments provided by an embodiment of the present application is shown;
[0022] Figure 2 A schematic diagram showing a region that is prone to misjudgment after the original point cloud is rotated in the related art;
[0023] Figure 3 A schematic diagram showing a result of generating virtual edge points in a filtering area provided by an embodiment of the present application is shown;
[0024] Figure 4 A schematic diagram of rotating a target point cloud including outsourced virtual points provided in an embodiment of the present application is shown;
[0025] Figure 5 It shows a plurality of different filtering directions provided by the embodiments of the present application;
[0026] Figure 6 A schematic diagram showing normal vectors and connection vectors of ground points and non-ground points provided in an embodiment of the present application is shown;
[0027] Figure 7 A schematic diagram showing normal vectors and connection vectors of ground points and non-ground points at a protrusion provided by an embodiment of the present application is shown;
[0028] Figure 8 A functional module diagram of a ground filtering device for steep environments provided by an embodiment of the present application is shown;
[0029] Fig. 9 A schematic structural diagram of an electronic device provided in an embodiment of the present application is shown. DETAILED DESCRIPTION
[0030] To make the purpose, technical scheme and advantages of the embodiments of the present application clearer, the technical scheme in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. It should be understood that the drawings in the present application only serve the purpose of explanation and description and are not used to limit the scope of protection of the present application. In addition, it should be understood that the schematic drawings are not drawn in real proportion. The flowchart used in this application shows the operations implemented according to some embodiments of the present application. It should be understood that the operations of the flowchart can be implemented out of sequence, and the steps without logical context can be reversed in order or implemented simultaneously. In addition, those skilled in the art, under the guidance of the content of the present application, can add one or more other operations to the flowchart, or remove one or more operations from the flowchart.
[0031] In addition, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. The components of the embodiments of the present application described and shown in the drawings here can be arranged and designed in various configurations. Therefore, the following detailed description of the embodiments of the present application provided in the drawings is not intended to limit the scope of the application claimed for protection, but merely represents the selected embodiments of the present application. Based on the embodiments of the present application, all other embodiments obtained by those skilled in the art without making creative work belong to the scope of protection of the present application.
[0032] In order to enable those skilled in the art to use the contents of this application, the following implementation methods are given in combination with the specific application scenario "data processing". For those skilled in the art, the general principles defined here can be applied to other embodiments and application scenarios without departing from the spirit and scope of this application.
[0033] The following methods, devices, electronic devices or computer-readable storage media of the embodiments of the present application can be applied to any scenario that requires point cloud data processing. The embodiments of the present application are not limited to specific application scenarios. Any solution using the ground filtering method, device, electronic device and medium for steep environments provided by the embodiments of the present application is within the scope of protection of the present application.
[0034] It is worth noting that before the present application was proposed, point cloud ground filtering refers to the operation of distinguishing ground points from non-ground points in the point cloud. After years of development, a large number of ground filtering methods have been proposed and widely used in practical work. Most of these methods use features such as local minimum value, slope threshold, elevation difference threshold and smoothness to distinguish ground points and non-ground points in point clouds. However, most of the current ground filtering algorithms have poor filtering performance in steep areas with large slopes. In particular, for extremely steep terrain, such as vertical cliffs close to 90°, or even cliffs that exceed 90° and hang above the ground, there is currently a lack of effective ground filtering algorithms. This is mainly due to the high similarity between ground points and non-ground points in steep terrain scenes. This makes it particularly difficult to distinguish these ground points from non-ground points using conventional features such as height difference and slope. However, these steep areas are often the focus of geological disaster investigations. Therefore, it is particularly important to study ground filtering algorithms for steep terrain.
[0035] In view of the above problems, the embodiment of the present application obtains the original point cloud corresponding to the steep environment and removes the outlier points in the original point cloud; the outlier points are target measurement points that are lower than the real ground; an outsourced virtual point set is generated at the edge of the original point cloud after removing the outlier points, and the target point cloud is rotated in multiple directions as a whole; the target point cloud includes the outsourced virtual point set and the original point cloud; PTD ground filtering is performed on the target point cloud after the multi-directional overall rotation, and after removing each outsourced virtual point, the ground points obtained from filtering in different directions are taken as a union to obtain a candidate ground point set after the union; non-ground points are identified and removed from the candidate ground point set after the union to obtain a target ground point set. In this way, the outsourced virtual points in the present application can block the non-ground points at the edge of the filtering area, thereby avoiding the generation of areas that are easily misjudged, and can improve the filtering performance of the ground filtering algorithm in steep areas with large slopes.
[0036] To facilitate the understanding of the present application, the technical solution provided by the present application is described in detail below in conjunction with specific embodiments.
[0037] Figure 1 The flowchart of a ground filtering method for steep environments provided by an embodiment of the present application is shown in FIG. Figure 1 As shown, the ground filtering method for steep environments provided by the embodiment of the present application includes the following steps:
[0038] S101: Acquire an original point cloud corresponding to a steep environment, and remove outlier points in the original point cloud; the outlier points are target measurement points that are lower than the actual ground.
[0039] In the specific implementation, low outlier points that are lower than the real ground will seriously affect the accuracy of the PTD ground filtering algorithm. Based on this, the embodiment of the present application removes the outlier points in the original point cloud. Generally, compared with the correct measurement points, the spatial distance between the outlier points and other points is generally larger.
[0040] S102: generating an outsourced virtual point set at the edge of the original point cloud after removing outlier points, and performing a multi-directional overall rotation on the target point cloud; the target point cloud includes the outsourced virtual point set and the original point cloud.
[0041] It should be noted that rotating the point cloud can reduce the average slope of the filter area to a certain extent, thereby improving the filtering accuracy. However, the embodiment of the present application takes into account that the rotation will cause the non-ground points at the edge of the filter area to no longer be blocked by ground points, and thus they will be misjudged as ground points. Figure 2 FIG. 1 shows a schematic diagram of a region that is prone to misjudgment after the original point cloud is rotated in the related art; Figure 2 As shown, the point cloud is rotated in multiple directions, which will cause the non-ground points at the edge of the filter area to no longer be blocked by ground points, and thus will be misjudged as ground points. In order to solve this problem, the embodiment of the present application first generates outsourced virtual points at the edge of the original point cloud, and then rotates the point cloud containing the outsourced virtual points as a whole. After the point cloud containing the outsourced virtual points is rotated, these outsourced virtual points can block the non-ground points at the edge of the filter area, thereby avoiding the generation of areas that are easily misjudged.
[0042] S103: Perform PTD ground filtering on the target point cloud after the overall rotation in multiple directions, and after eliminating each outsourced virtual point, take the union of the ground points obtained from filtering in different directions to obtain a candidate ground point set after the union.
[0043] It can be understood that when the target point cloud is directly ground filtered, the filtering plane is a horizontal plane, and the filtering direction can be represented by the normal vector of the horizontal plane. When filtering in this direction, steep cliffs and cliffs are easily filtered out by mistake due to the influence of lower ground points. The embodiment of the present application performs multi-directional filtering on the target point cloud, so steep cliffs and cliffs can be better retained in a certain direction. PTD ground filtering is performed on multiple rotated target point clouds, and after removing the outsourced virtual points, the ground points filtered from different directions are taken as a union. That is: if a point is judged as a ground point by the PTD algorithm in any direction, the point is added to the ground point set, and if a point is judged as a non-ground point by the PTD algorithm in all directions, it is added to the non-ground point set.
[0044] Among them, PTD ground filtering, also known as Progressive TIN Densification (PTD), can directly record dense, discrete, detailed, and accurate three-dimensional point clouds returned from objects or surfaces, compared to traditional photogrammetric images and INSAR (interferometric synthetic aperture radar). How to process and apply these irregular point clouds is the problem we need to solve. One of the important processing steps is ground filterring, which is to find out which ones are returned from the surface and which ones are returned from objects in the disordered and irregular three-dimensional discrete point clouds.
[0045] S104: Identify and remove non-ground points from the merged candidate ground point set to obtain a target ground point set.
[0046] Here, the embodiment of the present application considers that although filtering from multiple directions can better preserve surface features, the filtering result of each direction may mistakenly retain some non-ground points. Taking the union of ground points obtained from all filtering directions will result in the accumulation of the number of non-ground points. Therefore, the embodiment of the present application identifies and removes these non-ground points from the ground point set after taking the union.
[0047] It should be noted that points located on the surface of vertical steep cliffs and hanging cliffs are easily filtered out by the filtering algorithm due to the influence of lower ground points. Through steps S102 and S103, the embodiment of the present application uses multi-directional information to independently refine the surface, which can well preserve the surface features of steep cliffs and cliffs.
[0048] In addition, in the related art, the algorithm usually uses a smaller grid size, a larger slope threshold and a height difference threshold when filtering steep terrain. However, such parameter settings can cause a considerable number of non-ground points to be retained in the ground point set by mistake. S103 in the embodiment of the present application will also produce similar problems. Through S104, the embodiment of the present application can be well identified and removed from these non-ground points that are retained by mistake.
[0049] In the embodiment of the present application, the original point cloud corresponding to the steep environment is obtained, and the outlier points in the original point cloud are removed; the outlier points are target measurement points that are lower than the real ground; an outsourced virtual point set is generated at the edge of the original point cloud after the outlier points are removed, and the target point cloud is rotated in multiple directions; the target point cloud includes the outsourced virtual point set and the original point cloud; PTD ground filtering is performed on the target point cloud after the multi-directional overall rotation, and after removing each outsourced virtual point, the ground points obtained from filtering in different directions are taken as a union to obtain a candidate ground point set after the union; non-ground points are identified and removed from the candidate ground point set after the union to obtain a target ground point set. In this way, the outsourced virtual points in the present application can block the non-ground points at the edge of the filtering area, thereby avoiding the generation of areas that are easily misjudged, and can improve the filtering performance of the ground filtering algorithm in steep areas with large slopes.
[0050] In a possible implementation manner, in S101, the outlier point is determined according to the following steps:
[0051] Step 1011: for any first measurement point in the original point cloud, determine the spatial distance between the first measurement point and each second measurement point; the second measurement point is a measurement point in the original point cloud that is adjacent to the first measurement point;
[0052] Step 1012: determining an average distance between a preset number of the second measuring points and the first measuring point according to the spatial distance between the first measuring point and each second measuring point;
[0053] Step 1013: Determine whether the average distance corresponding to the first measurement point is greater than a preset distance threshold;
[0054] Step 1014: If yes, determine the first measurement point as the outlier point.
[0055] In a specific embodiment, considering that the spatial distance between an outlier point and other points is generally larger than that between an outlier point and a correct measurement point, based on this fact, the embodiment of the present application calculates the average distance between each point (first measurement point) and a preset number of adjacent points (second measurement points). If the average distance of a point (first measurement point) is greater than a preset distance threshold, , then remove the point as an outlier point. The preset number can be set according to the accuracy requirements of the outlier point in the actual steep environment, and is not specifically limited here. For example, the preset number can be 12.
[0056] In a possible implementation manner, in S102, the outsourced virtual point set is generated according to the following steps:
[0057] Step 1021a: According to the preset grid size, the lowest point in each grid is selected as a seed point, and the queried seed point is used as a control point to construct a TPS interpolation function.
[0058] Step 1022a: Determine the planar position of each virtual edge point based on the planar coordinates and preset spacing of the virtual edge points in multiple preset directions in the filtering area; the multiple preset directions include the minimum east-west direction, the maximum east-west direction, the minimum north-south direction, and the maximum north-south direction.
[0059] Here, the plane position of each virtual edge point is determined according to the following formula:
[0060] ;
[0061] in, represents the minimum east-west coordinate of the filtering area, represents the maximum east-west coordinate of the filtering area, represents the minimum north-south coordinate of the filtering area, represents the maximum north-south coordinate of the filtering area, d v Indicates the preset spacing, N X Indicates that according to the X coordinate range and the preset spacing d v Determine the number of virtual edge points required in the east-west direction, N y Indicates that according to the Y coordinate range and the preset spacing d v The number of virtual edge points required in the north-south direction is determined, and Int represents the rounding function. represents the plane coordinates of any virtual edge point, P e1 represents the set of virtual edge points at the southernmost edge of the filtering area, P e2 represents the set of virtual edge points at the northernmost edge of the filtering area, P e3 represents the set of virtual edge points at the westernmost edge of the filtering area, P e4 Represents the set of virtual edge points at the easternmost edge of the filtering area.
[0062] In the specific implementation, the minimum east-west coordinate of the filtering area is set to , the maximum east-west coordinate is , the minimum north-south coordinate is , the maximum north-south coordinate is , then the preset spacing d of the virtual edge points is set v After that, the plane position of the virtual edge point can be calculated by formula (1) to formula (6).
[0063] Step 1023a: According to the plane position of each virtual edge point, the elevation value of each virtual edge point in the filtering area is obtained by TPS interpolation.
[0064] In the specific implementation, after the plane positions of the virtual edge points are determined, the elevations of these edge points are obtained through the TPS interpolation function constructed previously. At this point, the virtual edge points have three-dimensional coordinates.
[0065] Step 1024a: Each of the virtual edge points is translated to a position outside the edge of the filtering area, and after the translation, a union of the virtual edge points corresponding to the multiple preset directions in the filtering area is taken to obtain an edge point set.
[0066] In a specific implementation, the virtual edge points fit closely to the edge of the filtering area, which cannot achieve the purpose of "blocking" the non-ground points on the edge. Therefore, these virtual edge points are translated, that is, each virtual edge point is translated to the periphery of the edge of the filtering area, and then the edge point set is obtained by taking the union of the virtual edge points corresponding to multiple preset directions in the filtering area.
[0067] Here, each of the virtual edge points is translated to the periphery of the edge of the filtering area according to the following formula:
[0068] ;
[0069] in, represents the set of the southernmost virtual edge points of the filter area obtained after translation, represents the set of virtual edge points at the northernmost edge of the filter area obtained after translation, represents the set of the westernmost virtual edge points of the filter area obtained after translation, represents the set of virtual edge points at the easternmost edge of the filter area obtained after translation, represents the spatial coordinates of any virtual edge point, d t represents a target distance for translating each of the virtual edge points to the periphery of the edge of the filtering area;
[0070] The edge point set P is obtained by taking the union of the virtual edge points corresponding to the multiple preset directions in the filtering area according to the following formula: e :
[0071]
[0072] Here, these virtual edge points can be translated according to formula (7) to formula (10). Through the above operation, the virtual edge points are translated to the periphery d away from the edge of the filtering area. tThen, through formula (11), , , , Take the union and get the edge point set P e . Figure 3 FIG. 4 shows a schematic diagram of generating virtual edge point results in a filtering area provided by an embodiment of the present application, such as Figure 3 As shown, the blue points are real measurement points and the red points are virtual edge points.
[0073] Step 1025a: Create multiple copies according to the generated edge point set to obtain a copy set; the Z coordinate of each copy is the Z coordinate of the previous copy plus the preset distance.
[0074] In a specific implementation, according to the generated virtual edge point set P e Create several copies, each with a Z coordinate that is the same as the previous copy plus a preset distance d v . Let the minimum elevation of the filter area be Z min , the maximum elevation is Z max , then the number of replicas that need to be created is N z .
[0075] Step 1026a: Taking the union of the edge point set and the replica set to obtain the outsourced virtual point set.
[0076] Here, the edge point set and the replica set are combined according to the following formula to obtain the outsourced virtual point set:
[0077]
[0078] Among them, N Z Indicates the number of replica points that need to be created, Z min Indicates the minimum elevation of the filtering area, Z max represents the maximum elevation of the filtering area, d v represents the preset spacing, Int represents the rounding function, C i represents the replica set, represents the spatial coordinates of any replica point, P b represents the outsourced virtual point set, P e Represents a set of edge points.
[0079] Among them, the set P is given by formula (14) e And all the replica sets C i Take the union and get the outsourced virtual point set P b .
[0080] In one possible implementation, Figure 4 FIG. 1 shows a schematic diagram of rotating a target point cloud including outsourced virtual points provided in an embodiment of the present application, such as Figure 4 As shown, green is non-ground points, black is external virtual points, and gray is ground points. Specifically, in S102, the target point cloud is rotated in multiple directions as a whole according to the following steps:
[0081] Step 1021b: Define multiple filtering directions.
[0082] It should be noted that when the point cloud is directly ground filtered, the filtering plane is a horizontal plane, and the filtering direction can be represented by the normal vector of the horizontal plane. When filtering in this direction, steep cliffs and cliffs are easily filtered out by mistake due to the influence of lower ground points. However, in the embodiment of the present application, the target point cloud is filtered in multiple directions, so steep cliffs and cliffs can be better retained in a certain direction. Figure 5 It shows a plurality of different filtering directions provided by the embodiment of the present application, Figure 5 9 filtering directions are shown, and each filtering direction corresponds to a blue arrow. Specifically, the embodiment of the present application defines multiple filtering directions, and the number of filtering directions is at least 3. The number of filtering directions can be set according to the actual requirements of the filtering accuracy in the steep environment, and is not specifically limited here. Exemplarily, the number of filtering directions can be 9.
[0083] Here, any of the filtering directions is defined according to the following filter vector representation:
[0084]
[0085] in, represents the filter vector corresponding to any of the filter directions, i represents a positive integer, represents the normal vector of the horizontal plane, represents the angle between any of the filter vectors and the normal vector, j represents a positive integer, j≥2.
[0086] Step 1022b: For any defined filtering direction, determine a normalized rotation axis matrix from the filtering direction to the target direction.
[0087] Here, the normalized rotation axis matrix from the filtering direction to the target direction is determined according to the following formula: ;
[0088] Among them, A represents each filtering direction except the (0, 0, 1) direction, B represents the target direction pointed by the (0, 0, 1) vector, and Anor represents the normalized rotation axis matrix from the A direction to the B direction.
[0089] After defining the filtering direction, the target point cloud is rotated in different directions. For each direction except the (0, 0, 1) direction, let the filtering direction be the initial direction A, and the direction pointed by the (0, 0, 1) vector be the target direction B. Then the unitized rotation axis matrix A from the A direction to the B direction is nor It can be calculated by formula (17) and formula (18).
[0090] Step 1023b: Based on the normalized rotation axis matrix, determine a target rotation matrix from the filtering direction to the target direction.
[0091] The target rotation matrix from the filtered direction to the target direction is determined according to the following formula:
[0092] ;
[0093] Wherein, θ represents the angle between any of the filter vectors and the normal vector, A represents each filter direction except the (0, 0, 1) direction, B represents the target direction pointed by the (0, 0, 1) vector, and A nor represents the normalized rotation axis matrix from direction A to direction B, and R represents the target rotation matrix from the filtering direction A to the target direction (0, 0, 1).
[0094] Among them, after obtaining the unitized rotation axis matrix, the rotation matrix R from vector A to vector B can be calculated according to formula (19) to formula (25).
[0095] Step 1024b: Based on the target rotation matrix from each of the filtering directions to the target direction, determine the target point cloud after multi-directional overall rotation.
[0096] Here, the target point cloud P after multi-directional overall rotation is determined according to the following formula: r :
[0097]
[0098] Where P represents a three-dimensional point cloud.
[0099] It can be understood that if the three-dimensional point cloud is P, then the rotated point cloud P r It can be calculated by formula (26).
[0100] In a possible implementation, if any target point in the candidate ground point set satisfies the following three conditions at the same time, the target point is determined to be the non-ground point: the elevation value of the target point is the local maximum elevation; the maximum target absolute value of the target point is greater than a preset threshold, and the target absolute value is the absolute value of the difference between the included angle and the right angle; the distance between the target point and the adjacent point that produces the largest target absolute value is less than the average distance between the target point and all adjacent points.
[0101] It should be noted that, although filtering from multiple directions can better preserve surface features, the filtering results in each direction will mistakenly retain some non-ground points. Taking the union of ground points obtained from all filtering directions will result in the accumulation of the number of non-ground points. Therefore, the embodiment of the present application identifies and removes these non-ground points from the ground point set after taking the union.
[0102] Here, the main steps of identifying and removing the erroneously retained non-ground points in S104 are as follows:
[0103] Step 1041: feature calculation;
[0104] Among them, all features are calculated using only points in the ground point set. Figure 6 A schematic diagram showing the normal vectors and connection vectors of ground points and non-ground points provided in an embodiment of the present application is shown. Figure 6 As shown, the features that need to be calculated include the normal vector N of each point, the connection vectors V1~Vk of each point and its k adjacent points, and the distances d1~dk; the angles between the normal vector N of each point and the connection vectors V1~Vk, and the absolute values β1~βk of the differences between these angles and the right angles; the elevation value h0 of each point and the elevation values h1~hn of its n adjacent points.
[0105] Step 1042: Error point identification;
[0106] Figure 7 A schematic diagram showing the normal vectors and connection vectors of the ground points and non-ground points at the protrusion provided by the embodiment of the present application is shown, as shown in FIG. Figure 7 As shown in the figure, the angle between the normal vector of the ground point and the connection vector of its neighboring points is close to 90°, so its β value is close to 0°, while the β value of the non-ground point is larger. Therefore, based on this fact, the non-ground points that are incorrectly retained in the ground point set are identified. However, there are two points to note: the β value of the ground point that is lower than the neighboring points may also be large, but it can be distinguished by elevation; the β value of the ground point on the convex is also large, but the larger β value of the non-ground point is generally generated by its connection vector with the closer point, while the ground point on the convex does not have this phenomenon.
[0107] Based on the above reasons, the rules for determining whether a point in a ground point set is a non-ground point in the embodiment of the present application are as follows:
[0108] a) The elevation h0 of the target point is the local maximum elevation, that is, h0 ≥ max (h1, h2, …, hn).
[0109] b) The maximum β value of the target point is greater than the threshold Tβ, that is, max(β1, β2, …, βk) ≥ Tβ.
[0110] c) The distance d between the target point and the adjacent point that produces the maximum β value is less than the average of its distances to all k adjacent points, that is, d < mean (d1, d2, …, dk).
[0111] If a point satisfies all three conditions above, it will be judged as a non-ground point that is mistakenly retained.
[0112] Step 1043: If a new error point is identified, it is removed from the ground point set and marked as a non-ground point, and then steps 1041 and 1042 are iteratively executed after the ground point set is updated. If no new error point is identified in a certain iteration, the iteration is terminated and the result is used as the final output.
[0113] Based on the same application concept, the embodiments of the present application also provide a ground filtering device for steep environments corresponding to the ground filtering method for steep environments provided in the above embodiments. Since the principle of solving the problem by the device in the embodiments of the present application is similar to the ground filtering method for steep environments in the above embodiments of the present application, the implementation of the device can refer to the implementation of the method, and the repeated parts will not be repeated.
[0114] Figure 8 This is a functional module diagram of a ground filtering device 800 for steep environments provided in an embodiment of the present application. Figure 8 As shown, the ground filtering device 800 for steep environments includes:
[0115] The elimination module 810 is used to obtain the original point cloud corresponding to the steep environment and eliminate the outlier points in the original point cloud; the outlier points are target measurement points that are lower than the real ground;
[0116] A rotation module 820 is used to generate an outsourced virtual point set at the edge of the original point cloud after removing the outlier points, and perform a multi-directional overall rotation on the target point cloud; the target point cloud includes the outsourced virtual point set and the original point cloud;
[0117] The union processing module 830 is used to perform PTD ground filtering on the target point cloud after the multi-directional overall rotation, and after removing each outsourced virtual point, take the union of the ground points obtained from filtering in different directions to obtain a candidate ground point set after the union;
[0118] The identification module 840 is used to identify and remove non-ground points from the combined candidate ground point set to obtain a target ground point set.
[0119] In a possible implementation, Figure 8 As shown, the elimination module 810 is used to determine the abnormal value points according to the following steps:
[0120] For any first measurement point in the original point cloud, determine the spatial distance between the first measurement point and each second measurement point; the second measurement point is a measurement point in the original point cloud that is adjacent to the first measurement point;
[0121] Determine, according to the spatial distances between the first measuring point and each second measuring point, an average distance between a preset number of the second measuring points and the first measuring point;
[0122] Determining whether the average distance corresponding to the first measurement point is greater than a preset distance threshold;
[0123] If so, the first measurement point is determined as the outlier point.
[0124] In a possible implementation, Figure 8 As shown, the rotation module 820 is used to generate the outsourced virtual point set according to the following steps:
[0125] According to the preset grid size, the lowest point in each grid is selected as the seed point, and the queried seed point is used as the control point to construct the TPS interpolation function;
[0126] Determine the plane position of each virtual edge point based on the plane coordinates and preset spacing of the virtual edge points in multiple preset directions in the filtering area; the multiple preset directions include a minimum east-west direction, a maximum east-west direction, a minimum north-south direction, and a maximum north-south direction;
[0127] According to the plane position of each virtual edge point, the elevation value of each virtual edge point in the filtering area is obtained by TPS interpolation;
[0128] Each of the virtual edge points is translated to a position outside the edge of the filter area, and a union of the virtual edge points corresponding to the multiple preset directions in the translated filter area is taken to obtain an edge point set;
[0129] Creating multiple copies according to the generated edge point set to obtain a copy set; the Z coordinate of each copy is the Z coordinate of the previous copy plus the preset spacing;
[0130] The edge point set and the replica set are combined to obtain the outsourced virtual point set.
[0131] In a possible implementation, Figure 8 As shown, the rotation module 820 is used to perform multi-directional overall rotation on the target point cloud according to the following steps:
[0132] Define multiple filtering directions;
[0133] For any of the defined filtering directions, determining a unitized rotation axis matrix from the filtering direction to the target direction;
[0134] Determining a target rotation matrix from the filtering direction to the target direction based on the normalized rotation axis matrix;
[0135] Based on the target rotation matrix from each of the filtering directions to the target direction, the target point cloud after the overall rotation in multiple directions is determined.
[0136] In the embodiment of the present application, the original point cloud corresponding to the steep environment is obtained, and the outlier points in the original point cloud are removed; the outlier points are target measurement points that are lower than the real ground; an outsourced virtual point set is generated at the edge of the original point cloud after the outlier points are removed, and the target point cloud is rotated in multiple directions; the target point cloud includes the outsourced virtual point set and the original point cloud; PTD ground filtering is performed on the target point cloud after the multi-directional overall rotation, and after removing each outsourced virtual point, the ground points obtained from filtering in different directions are taken as a union to obtain a candidate ground point set after the union; non-ground points are identified and removed from the candidate ground point set after the union to obtain a target ground point set. In this way, the outsourced virtual points in the present application can block the non-ground points at the edge of the filtering area, thereby avoiding the generation of areas that are easily misjudged, and can improve the filtering performance of the ground filtering algorithm in steep areas with large slopes.
[0137] Based on the same application concept, see Fig. 9 As shown, it is a structural diagram of an electronic device 900 provided in an embodiment of the present application, including: a processor 910, a memory 920 and a bus 930, the memory 920 stores machine-readable instructions executable by the processor 910, when the electronic device 900 is running, the processor 910 and the memory 920 communicate through the bus 930, and the machine-readable instructions are executed by the processor 910 when running to perform the steps of the ground filtering method for steep environments as described in any of the above embodiments.
[0138] Specifically, when the machine-readable instruction is executed by the processor 910, the following processing may be performed:
[0139] Acquire an original point cloud corresponding to a steep environment, and remove outlier points in the original point cloud; the outlier points are target measurement points that are lower than the actual ground;
[0140] Generate an outsourced virtual point set at the edge of the original point cloud after removing the outlier points, and perform multi-directional overall rotation on the target point cloud; the target point cloud includes the outsourced virtual point set and the original point cloud;
[0141] Perform PTD ground filtering on the target point cloud after multi-directional overall rotation, and after removing each outsourced virtual point, take the union of ground points obtained from filtering in different directions to obtain a candidate ground point set after the union;
[0142] Non-ground points are identified and removed from the merged candidate ground point set to obtain a target ground point set.
[0143] In the embodiment of the present application, the original point cloud corresponding to the steep environment is obtained, and outlier points in the original point cloud are removed; the outlier points are target measurement points that are lower than the real ground; an outsourced virtual point set is generated at the edge of the original point cloud after the outlier points are removed, and the target point cloud is rotated as a whole in multiple directions;
[0144] The target point cloud includes an outsourced virtual point set and an original point cloud; PTD ground filtering is performed on the target point cloud after multi-directional overall rotation, and after removing each outsourced virtual point, the ground points obtained from filtering in different directions are combined to obtain a candidate ground point set after the combination; non-ground points are identified and removed from the candidate ground point set after the combination to obtain a target ground point set. In this way, the outsourced virtual points in this application can block the non-ground points at the edge of the filtering area, thereby avoiding the generation of areas that are easily misjudged, and can improve the filtering performance of the ground filtering algorithm in steep areas with large slopes.
[0145] Based on the same application concept, an embodiment of the present application further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the ground filtering method for steep environments provided in the above embodiment are executed.
[0146] Specifically, the storage medium can be a general storage medium, such as a mobile disk, a hard disk, etc. When the computer program on the storage medium is run, the above-mentioned ground filtering method for steep environments can be executed. The outsourced virtual points in this application can block the non-ground points at the edge of the filtering area, thereby avoiding the generation of areas that are easily misjudged, and can improve the filtering performance of the ground filtering algorithm in steep areas with large slopes.
[0147] In the embodiment of the present application, the computer program can also execute other machine-readable instructions when run by the processor to execute other methods described in the embodiment. For the specific execution method steps and principles, please refer to the description of the embodiment, which will not be repeated here.
[0148] In the embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. The device embodiments described above are merely schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some communication interfaces, and the indirect coupling or communication connection of the devices or units can be electrical, mechanical or other forms.
[0149] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0150] In addition, each functional unit in the embodiments provided in the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0151] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, and other media that can store program codes.
[0152] It should be noted that similar numbers and letters represent similar items in the following figures. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures. In addition, the terms "first", "second", "third", etc. are only used to distinguish the description and are not to be understood as indicating or implying relative importance.
[0153] Finally, it should be noted that the above-described embodiments are only specific implementation methods of the present application, which are used to illustrate the technical solutions of the present application, rather than to limit them. The protection scope of the present application is not limited thereto. Although the present application is described in detail with reference to the above-mentioned embodiments, ordinary technicians in the field should understand that any technician familiar with the technical field can still modify the technical solutions recorded in the above-mentioned embodiments within the technical scope disclosed in the present application, or can easily think of changes, or make equivalent replacements for some of the technical features therein; and these modifications, changes or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present application. They should all be included in the protection scope of the present application. Therefore, the protection scope of the present application shall be based on the protection scope of the claims.
Claims
1. A ground filtering method for steep environments, characterized in that: The ground filtering method for steep environments includes: Acquire an original point cloud corresponding to a steep environment, and remove outlier points in the original point cloud; the outlier points are target measurement points that are lower than the actual ground; Generate an outsourced virtual point set at the edge of the original point cloud after removing the outlier points, and perform multi-directional overall rotation on the target point cloud; the target point cloud includes the outsourced virtual point set and the original point cloud; Performing PTD ground filtering on the target point cloud after multi-directional overall rotation, and after removing each outsourced virtual point, taking a union of ground points obtained from filtering in different directions to obtain a candidate ground point set after the union; Non-ground points are identified and removed from the merged candidate ground point set to obtain a target ground point set.
2. The ground filtering method for steep environments according to claim 1, characterized in that: Determine the outlier points according to the following steps: For any first measurement point in the original point cloud, determine the spatial distance between the first measurement point and each second measurement point; the second measurement point is a measurement point in the original point cloud that is adjacent to the first measurement point; Determine, according to the spatial distances between the first measuring point and each second measuring point, an average distance between a preset number of the second measuring points and the first measuring point; Determining whether the average distance corresponding to the first measurement point is greater than a preset distance threshold; If so, the first measurement point is determined as the outlier point.
3. The ground filtering method for steep environments according to claim 1, characterized in that: The outsourcing virtual point set is generated according to the following steps: According to the preset grid size, the lowest point in each grid is selected as the seed point, and the queried seed point is used as the control point to construct the TPS interpolation function; Determine the plane position of each virtual edge point based on the plane coordinates and preset spacing of the virtual edge points in multiple preset directions in the filtering area; the multiple preset directions include a minimum east-west direction, a maximum east-west direction, a minimum north-south direction, and a maximum north-south direction; According to the plane position of each virtual edge point, the elevation value of each virtual edge point in the filtering area is obtained by TPS interpolation; Each of the virtual edge points is translated to a position outside the edge of the filter area, and a union of the virtual edge points corresponding to the multiple preset directions in the translated filter area is taken to obtain an edge point set; Creating multiple copies according to the generated edge point set to obtain a copy set; the Z coordinate of each copy is the Z coordinate of the previous copy plus the preset spacing; The edge point set and the replica set are combined to obtain the outsourced virtual point set.
4. The ground filtering method for steep environments according to claim 3, characterized in that: The plane position of each virtual edge point is determined according to the following formula: ; in, represents the minimum east-west coordinate of the filtering area, represents the maximum east-west coordinate of the filtering area, represents the minimum north-south coordinate of the filtering area, represents the maximum north-south coordinate of the filtering area, d v Indicates the preset spacing, N X Indicates that according to the X coordinate range and the preset spacing d v Determine the number of virtual edge points required in the east-west direction, N y Indicates that according to the Y coordinate range and the preset spacing d v The number of virtual edge points required in the north-south direction is determined, and Int represents the rounding function. represents the plane coordinates of any virtual edge point, P e1 represents the set of virtual edge points at the southernmost edge of the filtering area, P e2 represents the set of virtual edge points at the northernmost edge of the filtering area, P e3 represents the set of virtual edge points at the westernmost edge of the filtering area, P e4 Represents the set of virtual edge points at the easternmost edge of the filtering area.
5. The ground filtering method for steep environments according to claim 3, characterized in that: Each of the virtual edge points is translated to the periphery of the edge of the filtering area according to the following formula: ; in, represents the set of the southernmost virtual edge points of the filter area obtained after translation, represents the set of virtual edge points at the northernmost edge of the filter area obtained after translation, represents the set of the westernmost virtual edge points of the filter area obtained after translation, represents the set of virtual edge points at the easternmost edge of the filter area obtained after translation, represents the spatial coordinates of any virtual edge point, d t represents a target distance for translating each of the virtual edge points to the periphery of the edge of the filtering area; The edge point set P is obtained by taking the union of the virtual edge points corresponding to the multiple preset directions in the filtering area according to the following formula: e : 。 6. The ground filtering method for steep environments according to claim 3, characterized in that: The edge point set and the replica set are combined according to the following formula to obtain the outsourced virtual point set: ; Among them, N Z Indicates the number of replica points that need to be created, Z min Indicates the minimum elevation of the filtering area, Z max represents the maximum elevation of the filtering area, d v represents the preset spacing, Int represents the rounding function, C i represents the replica set, represents the spatial coordinates of any replica point, P b represents the outsourced virtual point set, P e Represents a set of edge points.
7. The ground filtering method for steep environments according to claim 1, characterized in that: The target point cloud is rotated in multiple directions as a whole according to the following steps: Define multiple filtering directions; For any of the defined filtering directions, determining a unitized rotation axis matrix from the filtering direction to the target direction; Determining a target rotation matrix from the filtering direction to the target direction based on the normalized rotation axis matrix; Based on the target rotation matrix from each of the filtering directions to the target direction, the target point cloud after the overall rotation in multiple directions is determined.
8. A ground filtering device for steep environments, characterized in that: The ground filtering device for steep environments comprises: A rejection module is used to obtain an original point cloud corresponding to a steep environment and to reject outlier points in the original point cloud; the outlier points are target measurement points that are lower than the actual ground; A rotation module, used to generate an outsourced virtual point set at the edge of the original point cloud after removing the outlier points, and perform multi-directional overall rotation on the target point cloud; the target point cloud includes the outsourced virtual point set and the original point cloud; A union processing module is used to perform PTD ground filtering on the target point cloud after the overall rotation in multiple directions, and after removing each outsourced virtual point, take the union of the ground points obtained from filtering in different directions to obtain a candidate ground point set after the union; The identification module is used to identify and remove non-ground points from the merged candidate ground point set to obtain a target ground point set.
9. An electronic device, characterized in that: include: A processor, a memory and a bus, wherein the memory stores machine-readable instructions executable by the processor, and when the electronic device is running, the processor and the memory communicate through the bus, and the machine-readable instructions are executed by the processor to execute the steps of the ground filtering method for steep environments as described in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the ground filtering method for steep environments as claimed in any one of claims 1 to 7 are executed.
Citation Information
Patent Citations
Point cloud processing method and device of laser radar, electronic equipment and storage medium
CN117214915A
Method for generating simulated point cloud data, device, and storage medium
EP3618008A1
Generation and application of autonomously-created three-dimensional safety offset bounding surfaces from three-dimensional virtual maps around points of interest
US20230204326A1
