A point cloud data compression method and device based on spherical quadtree
Through the spherical quadtree point cloud data compression method, the point cloud data is dynamically divided into spherical triangles, which solves the point cloud data compression accuracy and consistency problems in the existing technology and realizes efficient point cloud data compression.
Patent Information
- Application Number
- CN202511073813.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-08-01
- Publication Date
- 2025-09-26
- Estimated Expiration
- 2045-08-01
AI Technical Summary
In the existing technology, point cloud data compression methods cannot effectively maintain spatial coherence and accuracy, especially when processing non-uniform or highly structured point cloud data, resulting in reduced compression accuracy and storage redundancy.
A point cloud data compression method based on spherical quadtree is adopted. By constructing spherical triangles and spherical quadtree nodes, combining spherical half-space detection and spherical triangle partitioning, the point cloud data is dynamically divided into spherical triangles to generate a coding path structure.
It improves the compression accuracy of point cloud data, eliminates directional bias, adapts to non-uniform or highly structured point cloud characteristics, avoids structural bloat caused by excessive division, and integrates spatial information and depth information.
Smart Images

Figure CN120563639B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of point cloud compression, and in particular relates to a point cloud data compression method and device based on a spherical quadtree. Background Art
[0002] Ground-based LiDAR (Light Detection and Ranging) is a key means of acquiring high-precision, high-resolution three-dimensional spatial information. By emitting laser pulses and receiving the echo signals reflected from the ground and objects, it can directly obtain the three-dimensional coordinates of the target point, as well as information such as intensity and number of echoes, forming dense three-dimensional point cloud data. This point cloud data realistically and objectively records the geometric form and spatial structural details of the scanned scene, providing indispensable basic data support for many fields such as topographic mapping, engineering surveys, three-dimensional modeling, and autonomous driving environmental perception. However, a single scan by a ground-based LiDAR generates a massive point cloud containing tens of millions or even hundreds of millions of spatial points. Storing and compressing this point cloud data without compression can further lead to excessive resource storage capacity or increased transmission time, hindering the application of point cloud data.
[0003] Currently, the compression methods for point cloud data usually use image projection coding and space partitioning methods based on cube octrees. Image projection coding is compressed through an image codec, but this will make the compressed point cloud data unable to maintain spatial coherence, resulting in a decrease in the accuracy of point cloud compression; and based on the cube octree, although it can retain the three-dimensional spatial structure, this solution maps the point cloud data to a cube based on rectangular coordinate axes, which is an aligned recursive subdivision mapping in a three-dimensional Cartesian coordinate system. This solution will cause directional bias in the space of point cloud data, and when processing non-uniform or highly structured point cloud data, it will reduce the accuracy of point cloud compression. In addition, due to the structural characteristics of the octree, when processing massive point cloud data, it will cause bloated structure and storage redundancy, which also leads to poor accuracy of point cloud compression. Therefore, there is an urgent need for a point cloud data compression method and device based on a spherical quadtree to address the shortcomings of the existing technology. Summary of the Invention
[0004] The present invention aims to provide a point cloud data compression method and device based on a spherical quadtree to address the defects of the existing technology and solve the above technical problems. By constructing spherical triangles and spherical quadtree nodes, combining spherical half-space detection and spherical triangle division, the compression accuracy of point cloud data is improved.
[0005] In order to solve the above technical problems, an embodiment of the present invention provides a point cloud data compression method based on a spherical quadtree, comprising:
[0006] Obtain some point cloud data to be compressed, initialize some spherical triangles and the spherical quadtree nodes corresponding to each spherical triangle;
[0007] According to a preset spherical half-space detection method, the first spherical triangle and the first spherical quadtree node corresponding to the point cloud data are determined by combining the spherical triangle, the spherical quadtree node and the spherical coordinates;
[0008] Obtaining the side length of the first spherical triangle and the number of point cloud data within the first spherical triangle, and determining a division judgment result of the first spherical triangle according to the side length of the first spherical triangle and the number of point cloud data within the first spherical triangle;
[0009] According to the division judgment result, the first spherical triangle is divided in combination with the first spherical quadtree node, a second spherical triangle and a second spherical quadtree node corresponding to the point cloud data are determined, and the point cloud data is assigned to the second spherical triangle;
[0010] After all point cloud data are assigned to the second spherical triangle, an encoding path structure for each point cloud data is generated based on the radial depth of each point cloud data, the second spherical quadtree node and the second spherical triangle to complete the compression of the point cloud data.
[0011] It can be understood that, compared with the prior art, the present invention initializes several spherical triangles and spherical quadtree nodes, and then based on the spherical half-space detection method, can accurately locate the first spherical triangle to which the point cloud data belongs, and then dynamically divides the first spherical triangle based on the side length of the first spherical triangle and the number of point cloud data inside, thereby determining the second spherical triangle to which the point cloud data ultimately belongs; after all the point cloud data are assigned to the second spherical triangle, a path encoding structure of the point cloud data is constructed, thereby achieving high-precision compression of the point cloud data. The present invention combines spherical triangles with spherical quadtree nodes, so that the spherical triangles are more in line with the spherical point cloud scanning characteristics of the laser radar, can eliminate the directional bias problem of cube octree point cloud compression in the prior art, and distribute point cloud data to spherical triangles with spherical coordinates, which can achieve coherent distribution of point cloud data in three-dimensional space; by dynamically dividing the spherical triangles, not only can the spherical triangles be more adapted to the non-uniform or highly structured characteristics of the point cloud data, but also can avoid the bloated structure caused by excessive division; by constructing a coding structure, the compressed point cloud data integrates the spatial information and depth information of the point cloud data, thereby improving the accuracy of point cloud compression.
[0012] Accordingly, an embodiment of the present invention provides a point cloud data compression device based on a spherical quadtree, comprising: a data acquisition module, a spherical half-space detection module, a spherical triangle division judgment module, a spherical triangle division module, and a point cloud data encoding module;
[0013] The data acquisition module is used to acquire a number of point cloud data to be compressed, initialize a number of spherical triangles and a spherical quadtree node corresponding to each spherical triangle;
[0014] The spherical half-space detection module is used to determine the first spherical triangle and the first spherical quadtree node corresponding to the point cloud data according to a preset spherical half-space detection method, combining spherical triangles, spherical quadtree nodes and spherical coordinates;
[0015] The spherical triangle division judgment module is used to obtain the side length of the first spherical triangle and the number of point cloud data within the first spherical triangle, and determine the division judgment result of the first spherical triangle according to the side length of the first spherical triangle and the number of point cloud data within the first spherical triangle;
[0016] The spherical triangle partitioning module is used to partition the first spherical triangle according to the partition judgment result and the first spherical quadtree node, determine the second spherical triangle and the second spherical quadtree node corresponding to the point cloud data, and allocate the point cloud data to the second spherical triangle;
[0017] The point cloud data encoding module is used to generate an encoding path structure for each point cloud data based on the radial depth, the second spherical quadtree node and the second spherical triangle after all the point cloud data are assigned to the second spherical triangle, so as to complete the compression of the point cloud data.
[0018] It can be understood that, compared with the existing technology, this device initializes several spherical triangles and spherical quadtree nodes, and then based on the spherical half-space detection method, it can accurately locate the first spherical triangle to which the point cloud data belongs. Then, based on the side length of the first spherical triangle and the number of point cloud data inside, the first spherical triangle is dynamically divided to determine the second spherical triangle to which the point cloud data ultimately belongs; after all the point cloud data are assigned to the second spherical triangle, a path encoding structure of the point cloud data is constructed to achieve high-precision compression of the point cloud data. The present invention combines spherical triangles with spherical quadtree nodes, so that the spherical triangles are more in line with the spherical point cloud scanning characteristics of the laser radar, can eliminate the directional bias problem of cube octree point cloud compression in the prior art, and distribute point cloud data to spherical triangles with spherical coordinates, which can achieve coherent distribution of point cloud data in three-dimensional space; by dynamically dividing the spherical triangles, not only can the spherical triangles be more adapted to the non-uniform or highly structured characteristics of the point cloud data, but also can avoid the bloated structure caused by excessive division; by constructing a coding structure, the compressed point cloud data integrates the spatial information and depth information of the point cloud data, thereby improving the accuracy of point cloud compression. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] Figure 1 A flowchart of a point cloud data compression method based on a spherical quadtree provided in an embodiment of the present invention;
[0020] Figure 2 A schematic diagram of spherical triangle division provided by an embodiment of the present invention;
[0021] Figure 3 A schematic diagram of point cloud data compression distribution under different compression schemes provided by an embodiment of the present invention;
[0022] Figure 4 A schematic structural diagram of a point cloud data compression device based on a spherical quadtree provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0023] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments of the present invention without making any creative efforts shall fall within the scope of protection of the present invention.
[0024] Example 1
[0025] Please refer to Figure 1 , Figure 1 A flowchart of a point cloud data compression method based on a spherical quadtree is provided in an embodiment of the present invention, including steps S101 to S105.
[0026] Step S101: Acquire a number of point cloud data to be compressed, initialize a number of spherical triangles and a spherical quadtree node corresponding to each spherical triangle.
[0027] In this embodiment, initializing a number of spherical triangles and a spherical quadtree node corresponding to each spherical triangle includes: obtaining a unit sphere and a golden section number, and dividing the sphere of the unit sphere according to the golden section number to obtain a number of initial vertex coordinates; normalizing the initial vertex coordinates to obtain a number of first vertex coordinates; combining the first vertex coordinates according to a preset vertex connection order to obtain a number of spherical triangles and triangle vertex coordinates of each spherical triangle; encoding the spherical triangles based on the vertex connection order to obtain encoding information of each spherical triangle; constructing an index of each triangle vertex coordinate to determine the triangle vertex coordinate index of each spherical triangle; constructing a spherical triangle vertex coordinate index table based on the triangle vertex coordinate index and the triangle vertex coordinates; constructing a spherical triangle index table based on the encoding information of the spherical triangle and the triangle vertex coordinate index; constructing and initializing a spherical quadtree node corresponding to each spherical triangle according to the triangle vertex coordinate index of each spherical triangle, wherein the spherical quadtree node includes: a triangle vertex coordinate index, a parent node pointer, a child node pointer, and a leaf node flag.
[0028] In an optional embodiment, a polyhedron with symmetry such as a regular icosahedron or a regular octahedron is used as a spherical primitive to construct a unit sphere; the golden section number is obtained. Because the number of initial vertex coordinates obtained by segmenting the unit spheres corresponding to different regular polyhedra is different, the following embodiment only uses the regular icosahedron as an example. The process for other regular polyhedra is the same as that for the regular icosahedron.
[0029] Furthermore, the spherical surface of the unit sphere constructed by the regular icosahedron is divided using the golden section number to obtain twelve initial vertex coordinates, where the twelve initial vertex coordinates are: 、 、 、 、 、 、 、 、 、 、 and ; Then, the coordinates of the twelve initial vertices are normalized to normalize them to the spherical surface of the unit sphere. The specific formula for the normalization process is as follows:
[0030] ; ; ;
[0031] Based on the above normalized formula, the coordinates of the twelve first vertices are obtained as follows:
[0032]
[0033] In the above formulas (1), (2), and (3), Before coordinate normalization The values on the axis, Before coordinate normalization The values on the axis, Before coordinate normalization The values on the axis, After the coordinates are normalized, The values on the axis, After the coordinates are normalized, The values on the axis, After the coordinates are normalized, The values on the axis;
[0034] The first vertex coordinates are combined in a counterclockwise direction (i.e., the preset vertex connection order) to obtain twenty spherical triangles and the three triangle vertex coordinates of each spherical triangle; since the spherical triangles are obtained by combining the first vertex coordinates based on the vertex connection order, that is, the generation order of the spherical triangles is related to the vertex connection order, the encoding information of the spherical triangles can be made consistent with the generation order of the spherical triangles based on the vertex connection order, that is, the encoding information of the spherical triangles at this time is binary numbers from 0 to 19 in sequence; then, the index of each of the triangle vertex coordinates is constructed, and then the index of the three triangle vertex coordinates corresponding to the spherical triangle is used as the index of the spherical triangle. The triangle vertex coordinate index of the spherical triangle; then, a spherical triangle vertex coordinate index table is constructed based on the triangle vertex coordinate index and the triangle vertex coordinates, and a spherical triangle index table is constructed according to the coding information of the spherical triangle and the triangle vertex coordinate index; specifically, please refer to Table 1 and Table 2, Table 1 is a schematic table of a spherical triangle vertex coordinate index table provided by an embodiment of the present invention, and Table 2 is a schematic table of a spherical triangle index table provided by an embodiment of the present invention. As shown in Table 1, the left column is the triangle vertex coordinate index, and the right column is the triangle vertex coordinates; as shown in Table 2, the left column is the coding information, and the right column is the triangle vertex coordinate index;
[0035] Table 1
[0036]
[0037] Table 2
[0038]
[0039] Then, according to the triangle vertex coordinate index of each spherical triangle, a spherical quadtree node corresponding to each spherical triangle is constructed and initialized, wherein the spherical quadtree node includes: a triangle vertex coordinate index, a parent node pointer, a child node pointer, and a leaf node flag. Specifically, the triangle vertex coordinate index of the spherical quadtree node is kept consistent with the triangle vertex coordinate index of the spherical triangle, so that one spherical triangle corresponds to one spherical quadtree node. At this time, the parent node pointer of the spherical quadtree node is empty, the four child node pointers are all empty, and the leaf node flag is 1 (in this embodiment, when the value is set to 1, it indicates a leaf node).
[0040] It should be noted that in a quadtree, each quadtree node includes a parent node pointer pointing to a parent node, four child node pointers pointing to child nodes, and a leaf node flag used to mark whether it is a leaf node; this part of the content is common knowledge among technicians in this field, and this embodiment will not be elaborated on here.
[0041] This embodiment initializes spherical triangles on the unit sphere through the golden section number, ensuring the uniform distribution and regular shape of the spherical triangles, so that the spherical triangles can be more adapted to the spatial characteristics of the point cloud data, and the point cloud data can be evenly and coherently distributed to the spherical triangles; by constructing a spherical triangle vertex coordinate index table and a spherical triangle index table, the spherical triangles can be managed efficiently and accurately; the spherical quadtree nodes corresponding to the spherical triangles are constructed through the triangle vertex coordinate index, which can provide a basis for the dynamic division of the spherical triangles and can dynamically manage the point cloud data, providing an efficient and accurate framework for the subsequent allocation of point cloud data to spherical triangles, thereby improving the accuracy of point cloud compression.
[0042] In an optional embodiment, a plurality of point cloud data to be compressed is obtained, including: obtaining a plurality of initial point cloud data to be compressed, each initial point cloud data including: spherical coordinates and radial depth; substituting the spherical coordinates of each initial point cloud data into the above formulas (1), (2), and (3) to normalize the spherical coordinates of the initial point cloud data to obtain point cloud data, wherein the spherical coordinates of the point cloud data are obtained by normalizing the spherical coordinates of the initial point cloud data, and the radial depth of the point cloud data is consistent with the radial depth of the initial point cloud data.
[0043] Step S102: According to a preset spherical half-space detection method, a first spherical triangle and a first spherical quadtree node corresponding to the point cloud data are determined in combination with spherical triangles, spherical quadtree nodes and spherical coordinates.
[0044] In this embodiment, according to a preset spherical half-space detection method, in combination with spherical triangles, spherical quadtree nodes and spherical coordinates, the first spherical triangle and the first spherical quadtree node corresponding to the point cloud data are determined, including: based on the parent node pointer of the spherical quadtree node, determining a number of spherical quadtree root nodes and the spherical root triangle corresponding to each spherical quadtree root node; determining the triangle vertex coordinates of each spherical root triangle according to the triangle vertex coordinate index of each spherical quadtree root node and the spherical triangle vertex coordinate index table; performing a cross product calculation on the triangle vertex coordinates of each spherical root triangle to obtain the edge normal vector of each spherical root triangle; determining the first spherical triangle and the first spherical quadtree node corresponding to the point cloud data according to the edge normal vector of each spherical root triangle, the spherical quadtree root node and the spherical coordinates of the point cloud data.
[0045] This embodiment determines several spherical quadtree root nodes and spherical root triangles, and then calculates the edge normal vector of each spherical root triangle through cross product. By using spherical coordinates and edge normal vectors, the complex three-dimensional spatial positioning problem can be converted into a simple coordinate and vector calculation, so that the first spherical triangle and the first spherical quadtree node corresponding to the point cloud data can be determined quickly and accurately, avoiding the misjudgment caused by spatial overlap or boundary ambiguity in three-dimensional spatial positioning in traditional cube octrees, so that the position of point cloud data in the spherical triangle can be quickly and accurately located, thereby improving the accuracy of point cloud compression.
[0046] In this embodiment, the first spherical triangle and the first spherical quadtree node corresponding to the point cloud data are determined based on the edge normal vector of each spherical root triangle, the spherical quadtree root node and the spherical coordinates of the point cloud data, including: performing dot multiplication on the spherical coordinates of the point cloud data and the edge normal vector of each spherical root triangle respectively to obtain the dot multiplication result of the point cloud data; based on the dot multiplication result of the point cloud data, the spherical root triangle and the spherical quadtree root node are screened to determine the third spherical triangle of the point cloud data and the third spherical quadtree node corresponding to the third spherical triangle; if the leaf node flag of the third spherical quadtree node is not a preset value, based on the child node pointer of the third spherical quadtree node, several fourth spherical quadtree nodes of the point cloud data are determined, and the fourth spherical triangle corresponding to each fourth spherical quadtree node is determined; based on the triangle vertex coordinate index and the spherical triangle vertex coordinates of each fourth spherical quadtree node Index table, determine the edge normal vector of each fourth spherical triangle; perform dot multiplication on the spherical coordinates of the point cloud data and the edge normal vector of each fourth spherical triangle respectively, and update the dot multiplication result of the point cloud data; according to the dot multiplication result of the updated point cloud data, screen the fourth spherical triangle and the fourth spherical quadtree node to redetermine the third spherical triangle and the third spherical quadtree node of the point cloud data, and then redetermine several fourth spherical quadtree nodes and several fourth spherical triangles of the point cloud data, until the leaf node flag of the third spherical triangle of the point cloud data is a preset value, completing the iteration of the third spherical triangle and the third spherical quadtree node of the point cloud data; use the third spherical triangle obtained from the last iteration of the point cloud data as the first spherical triangle corresponding to the point cloud data; use the third spherical quadtree node obtained from the last iteration of the point cloud data as the first spherical quadtree node corresponding to the point cloud data.
[0047] This embodiment constructs a hierarchical spherical triangle spatial retrieval system and recursively traverses the spherical quadtree nodes through leaf node flags and child node pointers to achieve progressive spatial positioning allocation of point cloud data. In each iteration, only the dot multiplication operation of the spherical coordinates and the edge normal vector of the spherical quadtree node of the current level (the fourth spherical quadtree node) needs to be performed. This not only avoids the excessive computational overhead caused by global search, but also can adapt to point cloud data of different densities and structures, further improving the accuracy and flexibility of point cloud compression.
[0048] In an optional embodiment, a spherical quadtree node with a null parent node pointer is used as a spherical quadtree root node, thereby obtaining twenty spherical quadtree root nodes, and marking the spherical triangle corresponding to each spherical quadtree root node as a spherical root triangle; then, based on the triangle vertex coordinate index of the spherical quadtree root node and the spherical triangle vertex coordinate index table, the triangle vertex coordinates of each spherical root triangle are determined; then, a cross product calculation is performed on the triangle vertex coordinates of each spherical root triangle to obtain an edge normal vector of each spherical root triangle, wherein the edge vector refers to the normal vector of the plane formed by the edge of the spherical triangle and the center of the unit sphere; the calculation formula of the edge normal vector is a cross product calculation in mathematics, which is specifically as follows:
[0049] Assume that the three vertices of the spherical triangle are 、 and (This embodiment uses triangle vertex coordinate index to represent), and the corresponding triangle vertex coordinates are 、 and Therefore, for the edge For example, its edge normal vector ; For edge For example, its edge normal vector ; For edge For example, its edge normal vector ; Therefore, the edge normal vector of the spherical root triangle is 、 and ;
[0050] Then the spherical coordinates of the point cloud data are the edge normal vectors of the spherical root triangle ( 、 and ) to perform point multiplication calculation, and the point multiplication result of the point cloud data is 、 and ; is the spherical coordinate of the point cloud data and The dot product result of is the spherical coordinate of the point cloud data and The dot product result of is the spherical coordinate of the point cloud data and The dot product result of
[0051] Afterwards, according to 、 and The size of the spherical root triangle and the spherical quadtree root node are screened. 、 and The spherical root triangle whose values are all greater than zero is used as the third spherical triangle of the point cloud data, and the third spherical quadtree node corresponding to the third spherical triangle is obtained;
[0052] If the leaf node flag of the third spherical quadtree node is not 1 at this time, it means that the third spherical quadtree node has child nodes. Therefore, based on the child node pointer of the third spherical quadtree node, four fourth spherical quadtree nodes of the point cloud data are obtained (four because it is a quadtree, each fourth spherical quadtree node is a child node of the third spherical quadtree node), and the fourth spherical triangle corresponding to each fourth spherical quadtree node is determined;
[0053] Then, according to the triangle vertex coordinate index of the fourth spherical quadtree node and the spherical triangle vertex coordinate index table, the edge normal vector of each fourth spherical triangle is calculated (the specific calculation method is shown above); then, the spherical coordinates of the point cloud data are respectively multiplied by the edge normal vector of each fourth spherical triangle to update the dot product result of the point cloud data;
[0054] Then, according to the updated point multiplication result of the point cloud data, that is, the updated 、 and The size of the fourth spherical triangle and the fourth spherical quadtree node are filtered. 、 and The fourth spherical triangle whose values are all greater than zero is used as the third spherical triangle of the point cloud data, and 、 and The spherical quadtree node corresponding to the fourth spherical triangle whose values are all greater than zero is used as the third spherical quadtree node of the point cloud data, thereby completing the redetermination of the third spherical triangle and the third spherical quadtree node of the point cloud data;
[0055] If the leaf node flag of the re-determined third spherical quadtree node is still not 1 at this time, then based on the child node pointer of the re-determined third spherical quadtree node, the four fourth spherical quadtree nodes of the point cloud data are re-determined, and the fourth spherical triangle corresponding to each fourth spherical quadtree node is re-determined, and then the dot product result of the point cloud data is re-determined, thereby re-determining the third spherical triangle and the third spherical quadtree node of the point cloud data again, until the leaf node flag of the third spherical triangle of the point cloud data is 1, completing the iteration of the third spherical triangle and the third spherical quadtree node of the point cloud data; the third spherical triangle obtained from the last iteration of the point cloud data is used as the first spherical triangle corresponding to the point cloud data; the third spherical quadtree node obtained from the last iteration of the point cloud data is used as the first spherical quadtree node corresponding to the point cloud data.
[0056] Step S103: Obtain the side length of the first spherical triangle and the number of point cloud data within the first spherical triangle, and determine the division judgment result of the first spherical triangle according to the side length of the first spherical triangle and the number of point cloud data within the first spherical triangle.
[0057] In this embodiment, the side length of the first spherical triangle and the number of point cloud data within the first spherical triangle are obtained, and the division judgment result of the first spherical triangle is determined according to the side length of the first spherical triangle and the number of point cloud data within the first spherical triangle, including: obtaining the side length of the first spherical triangle and the number of point cloud data within the first spherical triangle; if the number of point cloud data within the first spherical triangle exceeds a preset capacity threshold, and the side length of the first spherical triangle exceeds a preset first side length threshold, determining that the division judgment result of the first spherical triangle is that spherical triangle division is required; otherwise, determining that the division judgment result of the first spherical triangle is that spherical triangle division is not required.
[0058] It should be noted that, in this embodiment, the preset capacity threshold is set to 10, and the preset first side length threshold is set to 0.001m. The preset capacity threshold and the preset first side length threshold can be modified according to actual needs, and this embodiment does not impose too many restrictions on them.
[0059] Step S104: Divide the first spherical triangle according to the division judgment result and in combination with the first spherical quadtree node, determine the second spherical triangle and the second spherical quadtree node corresponding to the point cloud data, and assign the point cloud data to the second spherical triangle.
[0060] In this embodiment, according to the division judgment result, the first spherical triangle is divided in combination with the first spherical quadtree node, the second spherical triangle and the second spherical quadtree node corresponding to the point cloud data are determined, and the point cloud data is allocated to the second spherical triangle, including: if the division judgment result is that spherical triangle division is required, the first spherical triangle is divided according to the first spherical quadtree node; according to the preset spherical half-space detection method, the first spherical triangle and the first spherical quadtree node corresponding to the point cloud data are re-determined, and then the division judgment result of the first spherical triangle is re-determined until the first spherical triangle is divided. The division judgment result is that spherical triangle division is not required, and the first spherical triangle of the point cloud data is used as the second spherical triangle corresponding to the point cloud data, and the first spherical quadtree node of the point cloud data is used as the second spherical quadtree node corresponding to the point cloud data, and then the point cloud data is allocated to the second spherical triangle; if the division judgment result is that spherical triangle division is not required, the first spherical triangle of the point cloud data is used as the second spherical triangle corresponding to the point cloud data, and the first spherical quadtree node of the point cloud data is used as the second spherical quadtree node corresponding to the point cloud data, and then the point cloud data is allocated to the second spherical triangle.
[0061] This embodiment determines the division judgment result by the side length of the first spherical triangle and the number of point cloud data therein, thereby realizing dynamic spherical triangle division. When the division judgment result is that spherical triangle division is not required, the current spherical triangle and spherical quadtree node allocation will be directly retained; if spherical triangle division is required, the first spherical triangle will be divided based on the first spherical quadtree node, and the spherical half-space detection will be re-performed to ensure that the point cloud data is allocated to more subdivided spherical triangles; this dynamic division mechanism can not only avoid the structural bloat caused by excessive division, but also ensure that point cloud data of different spatial structures can be allocated to appropriate spherical triangles, so that the efficiency and space utilization of point cloud compression can be improved when processing point cloud data of different scales and complexities, thereby improving the accuracy of point cloud compression.
[0062] In this embodiment, the first spherical triangle is divided according to the first spherical quadtree node, including: calculating the midpoint coordinates of each side of the first spherical triangle according to the triangle vertex coordinates of the first spherical triangle to obtain the initial side midpoint coordinates of the first spherical triangle; combining the triangle vertex coordinates of the first spherical triangle and the initial side midpoint coordinates according to the vertex connection order to divide the first spherical triangle into a plurality of spherical triangles, and determining the triangle vertex coordinates of each spherical triangle obtained by the division; determining the index corresponding to the initial side midpoint coordinates according to a preset floating-point error correction method and a preset hash mapping table; determining the triangle vertex coordinate index of each spherical triangle obtained by the division based on the index corresponding to the initial side midpoint coordinates in combination with the triangle vertex coordinate index of the first spherical triangle; updating the spherical triangle vertex coordinate index table based on the triangle vertex coordinate index and the triangle vertex coordinates of each spherical triangle obtained by the division; updating the spherical triangle vertex coordinate index table based on the vertex connection order in combination with the Coding information, encode each spherical triangle obtained by division, and determine the coding information of each spherical triangle obtained by division; based on the coding information and triangle vertex coordinate index of each spherical triangle obtained by division, update the spherical triangle index table; based on the triangle vertex coordinate index of each spherical triangle obtained by division, combined with the first spherical quadtree node, construct and initialize the spherical quadtree node of each spherical triangle obtained by division; based on the spherical quadtree node of each spherical triangle obtained by division, update the child node pointer and leaf node flag of the first spherical quadtree node; according to the spherical half-space detection method, redetermine the first spherical triangle and the first spherical quadtree node corresponding to each point cloud data in the first spherical triangle, and then redetermine the second spherical triangle and the second spherical quadtree node corresponding to each point cloud data in the first spherical triangle; and then redistribute each point cloud data in the first spherical triangle to the corresponding second spherical triangle to complete the division of the first spherical triangle.
[0063] This embodiment calculates the midpoint coordinates of each edge of a first spherical triangle, then divides the first spherical triangle into several spherical triangles based on the vertex connection order, and then updates the triangle vertex coordinate index and the spherical triangle vertex coordinate index table. The vertex connection order ensures the order and consistency of the spherical triangles, thereby ensuring the accuracy and precision of point cloud compression based on spherical triangles. A floating-point error correction method and a hash map are used to accurately determine the index corresponding to the initial edge midpoint coordinates, avoiding coordinate duplication or spherical triangle encoding errors caused by floating-point errors. Corresponding spherical quadtree nodes are simultaneously generated, and the child node pointers of the first spherical quadtree nodes are modified, ensuring the sequential order and continuity between spherical quadtree nodes. Orderly and accurate hierarchical expansion of spherical triangles and spherical quadtree nodes is achieved. Each point cloud data within the first spherical triangle is reallocated using a spherical half-space detection method, ensuring the accuracy of the allocated point cloud data even when the spherical triangles are divided, thereby improving the accuracy of the overall point cloud data allocation and the precision of the point cloud compression.
[0064] In this embodiment, the index corresponding to the initial side midpoint coordinates is determined according to a preset floating-point error correction method and a preset hash mapping table, including: correcting the initial side midpoint coordinates according to the preset floating-point error correction method to obtain the first side midpoint coordinates of the first spherical triangle; querying the preset hash mapping table according to the first side midpoint coordinates; if the first side midpoint coordinates exist in the hash mapping table, obtaining the index corresponding to the initial side midpoint coordinates; if the first side midpoint coordinates do not exist in the hash mapping table, constructing the index corresponding to the initial side midpoint coordinates, and storing the index corresponding to the initial side midpoint coordinates and the first side midpoint coordinates in the hash mapping table.
[0065] This embodiment corrects the initial midpoint coordinates through a floating-point error correction method, which can eliminate the influence of floating-point errors on coordinate accuracy, thereby improving the accuracy of the index. In addition, through the query and update operations of the hash mapping table, repeated calculations and storage can be avoided, thereby reducing storage redundancy and computing overhead, and can improve the compression efficiency of massive point cloud data. The accuracy of point cloud compression is improved by improving the accuracy of the index.
[0066] In this embodiment, before allocating the point cloud data to the second spherical triangle, it also includes: if the side length of the second spherical triangle is less than a preset second side length threshold, according to a preset principal component analysis method, combined with the spherical coordinates of the point cloud data, calculating the normal vector of the point cloud data; according to a preset principal component analysis method, combined with the spherical coordinates of each point cloud data in the second spherical triangle, calculating the normal vector of each point cloud data in the second spherical triangle; comparing the angle between the normal vector of the point cloud data and the normal vector of each point cloud data in the second spherical triangle in turn; if the angle is greater than or equal to the preset angle threshold, allocating the point cloud data to the second spherical triangle; otherwise, discarding the point cloud data.
[0067] Before allocating the point cloud data to the second spherical triangle, this embodiment calculates the normal vector of each point cloud data in the second spherical triangle and uses an angle comparison mechanism to avoid inconsistency in the geometric features reflected by the point cloud data and the point cloud data in the second spherical triangle, thereby avoiding spatial structure distortion of point cloud data compression and improving the accuracy of point cloud compression.
[0068] In an optional embodiment, if the division judgment result is that spherical triangle division is required, the first spherical triangle is divided according to the first spherical quadtree node, and the specific process is as follows:
[0069] Calculate the coordinates of the midpoints of each side of the first spherical triangle according to the coordinates of the triangle vertices of the first spherical triangle, and perform normalization based on the above formulas (1), (2), and (3) to obtain the coordinates of the initial side midpoints of the first spherical triangle;
[0070] Then, in a counterclockwise order, the triangle vertex coordinates of the first spherical triangle and the initial side midpoint coordinates are combined to divide the first spherical triangle into a plurality of spherical triangles, and the triangle vertex coordinates of each of the divided spherical triangles are determined; for example, please refer to Figure 2 , Figure 2A schematic diagram of spherical triangle division is provided for an embodiment of the present invention; assuming that the three triangle vertices of the first spherical triangle (A, B, C) are A, B, and C, respectively, and the midpoints of the three sides are AB, AC, and BC, respectively; since a triangle vertex corresponds to a triangle vertex coordinate, and the midpoint of each side corresponds to an initial side midpoint coordinate, a spherical triangle can be represented by the triangle vertex coordinates. Combining the triangle vertex coordinates and the initial side midpoint coordinates of the first spherical triangle is equivalent to combining the three triangle vertices and the midpoints of the three sides, thereby dividing the first spherical triangle (A, B, C) into three spherical triangles. The three spherical triangles obtained by division are (A, AB, AC), (AB, B, BC), (AC, BC, C), and (AB, BC, AC), respectively. The triangle vertex coordinates of each spherical triangle obtained by division are (A, AB, AC), (AB, B, BC), (AC, BC, C), and (AB, BC, AC), respectively.
[0071] Then, the initial side midpoint coordinates are corrected according to a preset floating-point error correction formula (i.e., the initial side midpoint coordinates are corrected according to the floating-point error correction method) to obtain the first side midpoint coordinates of the first spherical triangle. The floating-point error correction formula is:
[0072] ; ; ;
[0073] In the above formulas (4), (5), and (6), The coordinates of the midpoint of the first side are The values on the axis, The coordinates of the midpoint of the first side are The values on the axis, The coordinates of the midpoint of the first side are The values on the axis, The coordinates of the initial side midpoint are The values on the axis, The coordinates of the initial side midpoint are The values on the axis, The coordinates of the initial side midpoint are The values on the axis; Represents the rounding function; is the precision scaling factor. In this embodiment, , means that the floating point number is retained to 8 decimal places;
[0074] Then, the preset hash mapping table is queried, wherein the hash mapping table is a two-column index table. The first column stores the coordinate value of the midpoint of each side of the spherical triangle after the floating-point error correction of the above formulas (4), (5), and (6) (i.e., the coordinate of the midpoint of the first side), and the second column stores the index of the midpoint coordinate of each side of the spherical triangle (i.e., the index corresponding to the coordinate of the midpoint of the initial side). If the midpoint coordinate of the first side exists in the hash mapping table, it means that the index of the midpoint coordinate of the initial side corresponding to the midpoint coordinate of the first side has been constructed before, so the midpoint of the initial side is directly obtained from the hash mapping table. The index corresponding to the point coordinate; if the first side midpoint coordinate does not exist in the hash mapping table, it indicates that the index of the initial side midpoint coordinate corresponding to the first side midpoint coordinate has not been constructed before, so the index corresponding to the initial side midpoint coordinate is constructed (the construction of the index belongs to the existing conventional technology and is not expanded in this embodiment. For example, the index can be constructed in sequence according to the order of natural numbers), and the index corresponding to the initial side midpoint coordinate and the first side midpoint coordinate are stored in the hash mapping table, so that when the index of the initial side midpoint coordinate is calculated again later, it can be directly obtained from the hash mapping table;
[0075] Then, based on the index corresponding to the coordinates of the midpoint of the initial edge and the triangle vertex coordinate index of the first spherical triangle, the triangle vertex coordinate index of each spherical triangle obtained by division is determined; for example, Figure 2 As shown, a spherical triangle (A, AB, AC) is obtained by division, which includes the initial side midpoint coordinates AB (index is assumed to be 40) and AC (index is assumed to be 41), and the triangle vertex A of the first spherical triangle (index is assumed to be 0). The indices corresponding to the initial side midpoint coordinates AB and AC (that is, the indices corresponding to the initial side midpoint coordinates) and the index of the triangle vertex A (that is, the triangle vertex coordinate index of the first spherical triangle) are directly used as the triangle vertex coordinate index of the spherical triangle (A, AB, AC) obtained by division. In other words, the triangle vertex coordinate indexes of the spherical triangle (A, AB, AC) are 0, 40, and 41.
[0076] Then, the triangle vertex coordinate index and the triangle vertex coordinates of each spherical triangle are stored in the spherical triangle vertex coordinate index table. If there is a duplicate record, the duplicate record is not stored in the spherical triangle vertex coordinate index table, thereby updating the spherical triangle vertex coordinate index table.
[0077] Since the encoding when initializing the spherical triangle is based on the counterclockwise order, the embodiment here also encodes each spherical triangle obtained by division based on the counterclockwise order, so that the encoding can be performed based on the division order of each spherical triangle obtained by division. Specifically, according to the vertex connection order, the initial encoding of each spherical triangle obtained by division is generated, and the encoding information of the first spherical triangle is added to the front of the initial encoding, thereby obtaining the encoding information of each spherical triangle obtained by division; for example, Figure 2 As shown, assuming that the coding information of the first spherical triangle (A, B, C) is 00011, and the initial coding of the divided spherical triangle (A, AB, AC) is 00, then the coding information of the divided spherical triangle (A, AB, AC) is 0001100; the initial coding of the divided spherical triangle (AB, B, BC) is 01, then the coding information of the divided spherical triangle (A, AB, AC) is 0001101; the initial coding of the divided spherical triangle (AC, BC, C) is 10, then the coding information of the divided spherical triangle (A, AB, AC) is 0001110; the initial coding of the divided spherical triangle (AB, BC, AC) is 11, then the coding information of the divided spherical triangle (A, AB, AC) is 0001111;
[0078] Then, the coded information of each spherical triangle and the triangle vertex coordinate index obtained by the division are used to update the spherical triangle index table;
[0079] Then, based on the triangle vertex coordinate index of each spherical triangle obtained by the division, in combination with the first spherical quadtree node, a spherical quadtree node of each spherical triangle obtained by the division is constructed and initialized, wherein the parent node pointer of the spherical quadtree node of each spherical triangle obtained by the division points to the first spherical quadtree node, the leaf node flag bit of the spherical quadtree node of each spherical triangle obtained by the division is 1, the child node pointer of the spherical quadtree node of each spherical triangle obtained by the division is empty, and the triangle vertex coordinate index of the spherical quadtree node of each spherical triangle obtained by the division is the same as the triangle vertex index of each corresponding spherical triangle obtained by the division; then, the child node pointer of the first spherical quadtree node points to the spherical quadtree node of each spherical triangle obtained by the division, and the leaf node flag bit of the first spherical quadtree node is set to a non-1 value (i.e., any natural number other than 1);
[0080] For each point cloud data in the first spherical quadtree node at this time, based on the spherical half-space detection method, the first spherical triangle and the first spherical quadtree node corresponding to each point cloud data in the first spherical triangle are re-determined, and then the second spherical triangle and the second spherical quadtree node corresponding to each point cloud data in the first spherical triangle are re-determined; then each point cloud data in the first spherical triangle is reallocated to the corresponding second spherical triangle (the specific process is the same as steps S102 to S104 above), completing the division of the first spherical triangle.
[0081] In an optional embodiment, a preset second side length threshold is set to 0.1m, and a preset angle threshold is set to 10 degrees. Before assigning the point cloud data to the second spherical triangle, if the side length of the second spherical triangle is less than the preset second side length threshold, a normal vector of the point cloud data is calculated according to a preset principal component analysis method in combination with the spherical coordinates of the point cloud data. A normal vector of each point cloud data in the second spherical triangle is calculated according to the preset principal component analysis method in combination with the spherical coordinates of each point cloud data in the second spherical triangle. Then, the angle between the normal vector of the point cloud data and the normal vector of each point cloud data in the second spherical triangle is compared in sequence, where the dot product of the two normal vectors is the cosine value of the angle. When the angle threshold is set to 10 degrees, the cosine value of the angle is 0.174. If the angle is less than 10 degrees, the cosine value is greater than 0.174. If the angle is greater than or equal to the preset angle threshold (i.e., the cosine value is less than or equal to 0.174), the point cloud data is assigned to the second spherical triangle. Otherwise, the point cloud data is discarded.
[0082] It should be noted that principal component analysis (PCA) is a classic multivariate statistical method. Its core goal is to project high-dimensional data into a low-dimensional space through linear transformation while retaining as much information as possible from the original data. Solving the normal vector of point cloud data through principal component analysis is common knowledge among those skilled in the art and will not be elaborated on in this embodiment.
[0083] It should be noted that the first spherical triangle, the second spherical triangle, the third spherical triangle, and the fourth spherical triangle described in this embodiment are all spherical triangles; the first spherical quadtree node, the second spherical quadtree node, the third spherical quadtree node, and the fourth spherical quadtree node are all spherical quadtree nodes, and all spherical quadtree nodes constitute a spherical quadtree.
[0084] Step S105: After all point cloud data are assigned to the second spherical triangle, an encoding path structure for each point cloud data is generated based on the radial depth of each point cloud data, the second spherical quadtree node and the second spherical triangle to complete the compression of the point cloud data.
[0085] In this embodiment, after all point cloud data are assigned to the second spherical triangle, an encoding path structure for each point cloud data is generated based on the radial depth of each point cloud data, the second spherical quadtree node and the second spherical triangle to complete the compression of the point cloud data, including: after all point cloud data are assigned to the second spherical triangle, a depth value field for each point cloud data is generated based on the radial depth of each point cloud data; based on the parent node pointer of the second spherical quadtree node of each point cloud data, the node depth of the second spherical quadtree node of each point cloud data is determined; based on the node depth of the second spherical quadtree node of each point cloud data, a node depth field for each point cloud data is generated; based on the encoding information of the second spherical triangle of each point cloud data, a path encoding field for each point cloud data is generated; based on the depth value field, the node depth field and the path encoding field of each point cloud data, an encoding path structure for each point cloud data is generated; according to the path encoding field, the encoding path structures are sorted to construct an encoding path structure array, and the encoding path structure array is used as the point cloud data compression data to complete the compression of the point cloud data.
[0086] This embodiment constructs a coding path structure through radial depth, a second spherical quadtree node, and a second spherical triangle, so that the spatial structure and geometric information of the point cloud data can be encoded and stored while maintaining the spatial coherence of the point cloud data; and the coding structure is sorted to construct an ordered coding structure array, so that different point cloud data can be stored based on spatial coherence, which can further improve the compression accuracy of the point cloud data.
[0087] In an optional embodiment, after all the point cloud data are assigned to the second spherical triangle, a depth value field of each point cloud data is generated based on the radial depth of each point cloud data. ;
[0088] Then, based on the parent node pointer of the second spherical quadtree node of each point cloud data, the node depth of the second spherical quadtree node of each point cloud data is determined (here, the level of the second spherical quadtree node in the spherical quadtree, that is, the leaf node depth is determined. Since this is common knowledge for those skilled in the art, it will not be described in detail here); then the node depth of the second spherical quadtree node of each point cloud data is used as the node depth field of each point cloud data ;
[0089] Then, based on the encoding information of the second spherical triangle of each point cloud data, a path encoding field of each point cloud data is generated. ;
[0090] Then, based on the depth value field, node depth field and path coding field of each point cloud data, a coding path structure of each point cloud data is generated; then, the coding path structures are sorted according to the path coding field to construct a coding path structure array.
[0091] Among them, first compare the values of the path coding fields, and sort all the coding path structures in ascending order according to the values of the path coding fields. When the values of the path coding fields are the same, further sort them in ascending order according to the depth value field or the node depth field to obtain the coding path structure array, and use the coding path structure array as the point cloud data compression data to complete the compression of the point cloud data.
[0092] It should be noted that the path coding field in this embodiment Set to a 32-bit unsigned integer (ie, 32-bit int type), the node depth field Set to an 8-bit unsigned integer (ie, 8-bit int type), the depth value field Set to a 32-bit floating point number (i.e., 32-bit float type).
[0093] In an optional embodiment, after completing the compression of the point cloud data, if you want to quickly locate all the point cloud data within a target area (i.e., a spherical triangle), it can also be regarded as decompression of the compressed point cloud data; suppose that the spherical root triangle to be located at this time is numbered 5, has a depth of 2, and has a path of All point cloud data in the area, then the number "5" is converted into binary encoding form, that is, into 0b00101; path It becomes the binary encoding form of 0b0010. At this time, 0b00101 and 0b0010 are merged to obtain the target area code prefix );
[0094] Then query the path encoding field of each encoding path structure in the encoding path structure array , if the path encoding field If the following expression is satisfied, the path encoding field The second spherical triangle of the corresponding encoding path structure is the target area to be located; the specific expression is:
[0095] ;
[0096] in, Encode the prefix for the target region, Indicates the actual number of valid digits of the code. In this embodiment, ; Indicates that the bit width after the target area encoding prefix can be changed; Indicates that all the bits that can be changed after the target area code prefix are set to 1; in particular, the binary search method can be used in combination with this expression to determine the target area from the encoding path structure array, thereby obtaining all the point cloud data of the target area.
[0097] Please note that, please refer to Figure 3 , Figure 3 A schematic diagram of point cloud data compression distribution under different compression schemes provided by an embodiment of the present invention; based on the above detailed steps, the point cloud data compression method based on spherical quadtree provided by this embodiment, on the basis of a number of spherical triangles and spherical quadtrees constructed using the unit sphere based on the regular icosahedron used in this embodiment, identifies spherical leaf triangles in spherical triangles, and spherical leaf triangles refer to spherical triangles whose leaf flag bits of the corresponding spherical quadtree nodes are not 1; then, from all the point cloud data in each spherical leaf triangle, select one point cloud data (which can be selected by the spherical centroid of the spherical leaf triangle) to form a final point cloud data set; that is, only one point cloud data is retained in each spherical leaf triangle, and then the retained point cloud data is used as a sampling point to form a point cloud data set as shown below. Figure 3 The blue and orange sampling points are distributed in the middle left half; Figure 3 It can be seen that these sampling points (point cloud data) are evenly distributed and have consistent density, which indicates that the combination of spherical quadtree and spherical triangle makes the sampling points in each spherical leaf triangle evenly distributed, and thus makes the sampling density of each spherical leaf triangle roughly equal; Figure 3 The right half of is shown in blue, which is the distribution of sampling points using the traditional polar coordinate uniform grid to divide the sphere. Figure 3 As can be seen from the right half of the figure, when using the traditional polar coordinate uniform grid to divide the sphere, the sampling points are not evenly distributed, showing the characteristics of uniformity in angular space and density distortion in area. Therefore, the point cloud compression method of this embodiment, which uses a combination of spherical triangles and spherical quadtree nodes, can obtain a point cloud compression result with more uniform distribution and more consistent density, indicating that the point cloud compression method of this embodiment can have higher accuracy. In addition, the compression rate of the point cloud data of this embodiment on the sphere can be calculated according to the following formula:
[0098] ; ; ;
[0099] in, is the compression ratio of point cloud data on the sphere, Indicates the maximum depth of the spherical quadtree; Represents the average angular distance (i.e. arc length) between any two sampling points on the surface of the unit sphere; The arc length of the side of the spherical root triangle on the surface of the unit sphere;
[0100] Based on the above formula, it can be concluded that the compression rate of the point cloud data of this embodiment on the sphere is 41%, indicating that the point cloud compression method provided in this embodiment can significantly improve the compression accuracy without losing the structural integrity of the point cloud data, thereby improving the storage efficiency and processing performance of the point cloud data.
[0101] Furthermore, the original spherical coordinates of each point cloud data consist of three floating point numbers (32-bit float type), while this embodiment uses the encoding path structure to make the point cloud data as a path encoding field. (32-bit int type), a node depth field (8-bit int type) and a depth value field Assuming (32-bit float type) for storage, compared with three 32-bit float types, it can greatly reduce the space required for compressed point cloud data storage. The point cloud data has a 75% compression rate in storage. Combining the compression rates of the point cloud data on the sphere and storage, the point cloud data compression method based on the spherical quadtree provided in this embodiment has a total compression rate of 30%.
[0102] Therefore, this embodiment, through the combination of spherical quadtrees and spherical triangles, and the dynamic partitioning of spherical triangles, is more suitable for the structure of point cloud data generated by ground-based laser radars. This improves the compression accuracy of point cloud data while ensuring the structural consistency and spatial coherence of the point cloud data. Compared to the existing cube octree scheme's axis-aligned recursive subdivision method in a three-dimensional Cartesian coordinate system, this method avoids directional bias in point cloud data and enables uniform mapping of the point cloud data. Using a unit sphere for spatial partitioning of spherical triangles results in a more uniform angular distribution and more natural adjacency relationships, facilitating a more precise fitting of irregular surface geometry. This achieves higher geometric fidelity of point cloud data, particularly in ground scenes (such as slopes, road edges, and natural terrain). Furthermore, by subdividing spherical triangles, a nearly uniform directional partitioning can be achieved on the unit sphere, effectively reducing the directional bias of the axis-aligned method. This allows point cloud data to maintain higher expression accuracy and structural consistency in anisotropic regions (such as inclined surfaces and curved structures), thereby improving the compression accuracy of point cloud data.
[0103] This embodiment initializes several spherical triangles and spherical quadtree nodes, and then accurately locates the first spherical triangle to which the point cloud data belongs based on the spherical half-space detection method. Then, based on the side length of the first spherical triangle and the amount of point cloud data inside, the first spherical triangle is dynamically divided to determine the second spherical triangle to which the point cloud data ultimately belongs. After all the point cloud data are assigned to the second spherical triangle, a path encoding structure of the point cloud data is constructed, thereby achieving high-precision compression of the point cloud data. The present invention combines spherical triangles with spherical quadtree nodes, so that the spherical triangles are more in line with the spherical point cloud scanning characteristics of the laser radar, can eliminate the directional bias problem of cube octree point cloud compression in the prior art, and distribute point cloud data to spherical triangles with spherical coordinates, which can achieve coherent distribution of point cloud data in three-dimensional space; by dynamically dividing the spherical triangles, not only can the spherical triangles be more adapted to the non-uniform or highly structured characteristics of the point cloud data, but also can avoid the bloated structure caused by excessive division; by constructing a coding structure, the compressed point cloud data integrates the spatial information and depth information of the point cloud data, thereby improving the accuracy of point cloud compression.
[0104] Example 2
[0105] Please refer to Figure 4 , Figure 4 A schematic structural diagram of a point cloud data compression device based on a spherical quadtree provided in an embodiment of the present invention includes: a data acquisition module 201, a spherical half-space detection module 202, a spherical triangle division judgment module 203, a spherical triangle division module 204 and a point cloud data encoding module 205.
[0106] The data acquisition module 201 is used to acquire a number of point cloud data to be compressed, initialize a number of spherical triangles and a spherical quadtree node corresponding to each spherical triangle.
[0107] In this embodiment, the data acquisition module 201 includes: a data initialization unit;
[0108] The data initialization unit is used to obtain a unit sphere and a golden section number, and divide the spherical surface of the unit sphere according to the golden section number to obtain a number of initial vertex coordinates; normalize the initial vertex coordinates to obtain a number of first vertex coordinates; combine the first vertex coordinates according to a preset vertex connection order to obtain a number of spherical triangles and the triangle vertex coordinates of each spherical triangle; encode the spherical triangles based on the vertex connection order to obtain the encoding information of each spherical triangle; construct an index of each triangle vertex coordinate to determine the triangle vertex coordinate index of each spherical triangle; construct a spherical triangle vertex coordinate index table based on the triangle vertex coordinate index and the triangle vertex coordinates; construct a spherical triangle index table according to the encoding information of the spherical triangle and the triangle vertex coordinate index; construct and initialize a spherical quadtree node corresponding to each spherical triangle according to the triangle vertex coordinate index of each spherical triangle, wherein the spherical quadtree node includes: a triangle vertex coordinate index, a parent node pointer, a child node pointer and a leaf node flag.
[0109] The spherical half-space detection module 202 is used to determine the first spherical triangle and the first spherical quadtree node corresponding to the point cloud data according to a preset spherical half-space detection method, combining spherical triangles, spherical quadtree nodes and spherical coordinates.
[0110] In this embodiment, the spherical half-space detection module 202 includes: a spherical half-space detection unit;
[0111] The spherical half-space detection unit is used to determine a number of spherical quadtree root nodes and a spherical root triangle corresponding to each spherical quadtree root node based on a parent node pointer of the spherical quadtree node;
[0112] Determine the triangle vertex coordinates of each spherical root triangle according to the triangle vertex coordinate index of each spherical quadtree root node and the spherical triangle vertex coordinate index table;
[0113] Perform cross product calculation on the triangle vertex coordinates of each spherical root triangle to obtain the edge normal vector of each spherical root triangle;
[0114] According to the edge normal vector of each spherical root triangle, the spherical quadtree root node and the spherical coordinates of the point cloud data, a first spherical triangle and a first spherical quadtree node corresponding to the point cloud data are determined.
[0115] In this embodiment, the spherical half-space detection unit includes: a spherical half-space detection subunit;
[0116] The spherical half-space detection subunit is used to perform dot multiplication of the spherical coordinates of the point cloud data with the edge normal vector of each spherical root triangle to obtain the dot multiplication result of the point cloud data;
[0117] According to the dot product result of the point cloud data, the spherical root triangle and the spherical quadtree root node are screened to determine the third spherical triangle of the point cloud data and the third spherical quadtree node corresponding to the third spherical triangle;
[0118] If the leaf node flag of the third spherical quadtree node is not a preset value, determining a plurality of fourth spherical quadtree nodes of the point cloud data based on the child node pointer of the third spherical quadtree node, and determining a fourth spherical triangle corresponding to each fourth spherical quadtree node;
[0119] Determine the edge normal vector of each fourth spherical triangle according to the triangle vertex coordinate index of each fourth spherical quadtree node and the spherical triangle vertex coordinate index table;
[0120] Perform dot multiplication of the spherical coordinates of the point cloud data with the edge normal vector of each fourth spherical triangle, and update the dot multiplication result of the point cloud data;
[0121] According to the dot product result of the updated point cloud data, the fourth spherical triangle and the fourth spherical quadtree node are screened to re-determine the third spherical triangle and the third spherical quadtree node of the point cloud data, and then re-determine several fourth spherical quadtree nodes and several fourth spherical triangles of the point cloud data until the leaf node flag of the third spherical triangle of the point cloud data reaches a preset value, thereby completing the iteration of the third spherical triangle and the third spherical quadtree node of the point cloud data;
[0122] The third spherical triangle obtained by the last iteration of the point cloud data is used as the first spherical triangle corresponding to the point cloud data;
[0123] The third spherical quadtree node obtained from the last iteration of the point cloud data is used as the first spherical quadtree node corresponding to the point cloud data.
[0124] The spherical triangle division judgment module 203 is used to obtain the side length of the first spherical triangle and the number of point cloud data within the first spherical triangle, and determine the division judgment result of the first spherical triangle according to the side length of the first spherical triangle and the number of point cloud data within the first spherical triangle.
[0125] The spherical triangle partitioning module 204 is used to partition the first spherical triangle according to the partitioning judgment result and the first spherical quadtree node, determine the second spherical triangle and the second spherical quadtree node corresponding to the point cloud data, and allocate the point cloud data to the second spherical triangle.
[0126] In this embodiment, the spherical triangle division module 204 includes: a spherical triangle division unit;
[0127] The spherical triangle division unit is configured to divide the first spherical triangle according to the first spherical quadtree node if the division judgment result indicates that spherical triangle division is required;
[0128] According to a preset spherical half-space detection method, the first spherical triangle and the first spherical quadtree node corresponding to the point cloud data are re-determined, and then the division judgment result of the first spherical triangle is re-determined until the division judgment result of the first spherical triangle is that spherical triangle division is not required, the first spherical triangle of the point cloud data is used as the second spherical triangle corresponding to the point cloud data, and the first spherical quadtree node of the point cloud data is used as the second spherical quadtree node corresponding to the point cloud data, and then the point cloud data is allocated to the second spherical triangle;
[0129] If the division judgment result is that spherical triangle division is not required, the first spherical triangle of the point cloud data is used as the second spherical triangle corresponding to the point cloud data, and the first spherical quadtree node of the point cloud data is used as the second spherical quadtree node corresponding to the point cloud data, and then the point cloud data is allocated to the second spherical triangle.
[0130] In this embodiment, the spherical triangle division unit includes: a spherical triangle division sub-unit;
[0131] The spherical triangle division subunit is used to calculate the midpoint coordinates of each side of the first spherical triangle according to the triangle vertex coordinates of the first spherical triangle, so as to obtain the initial side midpoint coordinates of the first spherical triangle;
[0132] Combining the triangle vertex coordinates of the first spherical triangle and the initial side midpoint coordinates according to the vertex connection order to divide the first spherical triangle into a plurality of spherical triangles, and determining the triangle vertex coordinates of each divided spherical triangle;
[0133] Determine the index corresponding to the initial edge midpoint coordinate according to a preset floating point error correction method and a preset hash mapping table;
[0134] Determine the triangle vertex coordinate index of each spherical triangle obtained by dividing based on the index corresponding to the coordinate of the midpoint of the initial side and the triangle vertex coordinate index of the first spherical triangle;
[0135] Based on the triangle vertex coordinate index and triangle vertex coordinates of each spherical triangle obtained by division, the spherical triangle vertex coordinate index table is updated;
[0136] Based on the vertex connection order and in combination with the coding information of the first spherical triangle, encoding each spherical triangle obtained by the division to determine the coding information of each spherical triangle obtained by the division;
[0137] Based on the encoding information of each spherical triangle obtained by division and the triangle vertex coordinate index, the spherical triangle index table is updated;
[0138] Based on the triangle vertex coordinate index of each spherical triangle obtained by the division, combined with the first spherical quadtree node, a spherical quadtree node of each spherical triangle obtained by the division is constructed and initialized; based on the spherical quadtree node of each spherical triangle obtained by the division, a child node pointer and a leaf node flag of the first spherical quadtree node are updated;
[0139] According to the spherical half-space detection method, the first spherical triangle and the first spherical quadtree node corresponding to each point cloud data in the first spherical triangle are re-determined, and then the second spherical triangle and the second spherical quadtree node corresponding to each point cloud data in the first spherical triangle are re-determined; then each point cloud data in the first spherical triangle is reallocated to the corresponding second spherical triangle to complete the division of the first spherical triangle.
[0140] In this embodiment, the spherical triangle division subunit includes: a floating point error correction component;
[0141] The floating-point error correction component is used to correct the initial side midpoint coordinates according to a preset floating-point error correction method to obtain the first side midpoint coordinates of the first spherical triangle;
[0142] Query the preset hash mapping table according to the coordinates of the midpoint of the first side;
[0143] If the first edge midpoint coordinates exist in the hash map, get the index corresponding to the initial edge midpoint coordinates;
[0144] If the first side midpoint coordinates do not exist in the hash mapping table, construct the index corresponding to the initial side midpoint coordinates, and store the index corresponding to the initial side midpoint coordinates and the first side midpoint coordinates in the hash mapping table.
[0145] In this embodiment, the spherical triangle division module 204 further includes: a point cloud data discarding unit;
[0146] The point cloud data discarding unit is configured to calculate a normal vector of the point cloud data based on a preset principal component analysis method and the spherical coordinates of the point cloud data if the side length of the second spherical triangle is less than a preset second side length threshold;
[0147] Calculate the normal vector of each point cloud data in the second spherical triangle according to a preset principal component analysis method and in combination with the spherical coordinates of each point cloud data in the second spherical triangle;
[0148] Compare the normal vector of the point cloud data and the angle between the normal vector of each point cloud data in the second spherical triangle in turn;
[0149] If the angle is greater than or equal to the preset angle threshold, the point cloud data is assigned to the second spherical triangle; otherwise, the point cloud data is discarded.
[0150] The point cloud data encoding module 205 is used to generate an encoding path structure for each point cloud data based on the radial depth, the second spherical quadtree node and the second spherical triangle after all point cloud data are assigned to the second spherical triangle to complete the compression of the point cloud data.
[0151] In this embodiment, the point cloud data encoding module 205 includes: a point cloud data encoding unit;
[0152] The point cloud data encoding unit is used to generate a depth value field for each point cloud data based on the radial depth of each point cloud data after allocating all point cloud data to the second spherical triangle;
[0153] Determine the node depth of the second spherical quadtree node of each point cloud data based on the parent node pointer of the second spherical quadtree node of each point cloud data;
[0154] Generate a node depth field for each point cloud data based on the node depth of the second spherical quadtree node of each point cloud data;
[0155] Generate a path coding field for each point cloud data based on the coding information of the second spherical triangle of each point cloud data;
[0156] Generate a coding path structure for each point cloud data based on the depth value field, node depth field and path coding field of each point cloud data;
[0157] According to the path coding field, the coding path structure is sorted, the coding path structure array is constructed, and the coding path structure array is used as the point cloud data compression data to complete the compression of the point cloud data.
[0158] This embodiment initializes several spherical triangles and spherical quadtree nodes, and then accurately locates the first spherical triangle to which the point cloud data belongs based on the spherical half-space detection method. Then, based on the side length of the first spherical triangle and the amount of point cloud data inside, the first spherical triangle is dynamically divided to determine the second spherical triangle to which the point cloud data ultimately belongs. After all the point cloud data are assigned to the second spherical triangle, a path encoding structure of the point cloud data is constructed, thereby achieving high-precision compression of the point cloud data. The present invention combines spherical triangles with spherical quadtree nodes, so that the spherical triangles are more in line with the spherical point cloud scanning characteristics of the laser radar, can eliminate the directional bias problem of cube octree point cloud compression in the prior art, and distribute point cloud data to spherical triangles with spherical coordinates, which can achieve coherent distribution of point cloud data in three-dimensional space; by dynamically dividing the spherical triangles, not only can the spherical triangles be more adapted to the non-uniform or highly structured characteristics of the point cloud data, but also can avoid the bloated structure caused by excessive division; by constructing a coding structure, the compressed point cloud data integrates the spatial information and depth information of the point cloud data, thereby improving the accuracy of point cloud compression.
[0159] In summary, the embodiment of the present invention initializes several spherical triangles and spherical quadtree nodes, and then accurately locates the first spherical triangle to which the point cloud data belongs based on the spherical half-space detection method. Then, based on the side length of the first spherical triangle and the amount of point cloud data inside, the first spherical triangle is dynamically divided to determine the second spherical triangle to which the point cloud data ultimately belongs. After all the point cloud data are assigned to the second spherical triangle, a path coding structure of the point cloud data is constructed, thereby achieving high-precision compression of the point cloud data. The present invention combines spherical triangles with spherical quadtree nodes, so that the spherical triangles are more in line with the spherical point cloud scanning characteristics of the laser radar, can eliminate the directional bias problem of cube octree point cloud compression in the prior art, and distribute point cloud data to spherical triangles with spherical coordinates, which can achieve coherent distribution of point cloud data in three-dimensional space; by dynamically dividing the spherical triangles, not only can the spherical triangles be more adapted to the non-uniform or highly structured characteristics of the point cloud data, but also can avoid the bloated structure caused by excessive division; by constructing a coding structure, the compressed point cloud data integrates the spatial information and depth information of the point cloud data, thereby improving the accuracy of point cloud compression.
[0160] The specific embodiments described above further illustrate the objectives, technical solutions, and beneficial effects of the present invention. It should be understood that the above descriptions are merely specific embodiments of the present invention and are not intended to limit the scope of protection of the present invention. In particular, it should be noted that any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included within the scope of protection of the present invention for those skilled in the art.
Claims
1. A point cloud data compression method based on spherical quadtree, characterized in that: include: Acquire a number of point cloud data to be compressed, initialize a number of spherical triangles and a spherical quadtree node corresponding to each of the spherical triangles, including: acquiring a unit sphere and a golden section number, and dividing the spherical surface of the unit sphere according to the golden section number to obtain a number of initial vertex coordinates; normalizing the initial vertex coordinates to obtain a number of first vertex coordinates; combining the first vertex coordinates according to a preset vertex connection order to obtain a number of spherical triangles and the triangle vertex coordinates of each spherical triangle; encoding the spherical triangles based on the vertex connection order to obtain the coordinates of each of the spherical triangles. Encoding information; constructing an index of each triangle vertex coordinate to determine the triangle vertex coordinate index of each spherical triangle; constructing a spherical triangle vertex coordinate index table based on the triangle vertex coordinate index and the triangle vertex coordinate; constructing a spherical triangle index table according to the encoding information of the spherical triangle and the triangle vertex coordinate index; constructing and initializing a spherical quadtree node corresponding to each spherical triangle according to the triangle vertex coordinate index of each spherical triangle, wherein the spherical quadtree node includes: a triangle vertex coordinate index, a parent node pointer, a child node pointer and a leaf node flag; Determine, according to a preset spherical half-space detection method, a first spherical triangle and a first spherical quadtree node corresponding to the point cloud data in combination with the spherical triangle, the spherical quadtree node and the spherical coordinates; Obtaining the side length of the first spherical triangle and the amount of point cloud data within the first spherical triangle, and determining a division judgment result of the first spherical triangle according to the side length of the first spherical triangle and the amount of point cloud data within the first spherical triangle; According to the division judgment result, the first spherical triangle is divided in combination with the first spherical quadtree node to determine the second spherical triangle and the second spherical quadtree node corresponding to the point cloud data, and the point cloud data is allocated to the second spherical triangle, including: if the division judgment result is that spherical triangle division is required, the first spherical triangle is divided according to the first spherical quadtree node; according to a preset spherical half-space detection method, the first spherical triangle and the first spherical quadtree node corresponding to the point cloud data are re-determined, and then the division judgment result of the first spherical triangle is re-determined until the division judgment result of the first spherical triangle is not It is necessary to perform spherical triangle division, use the first spherical triangle of the point cloud data as the second spherical triangle corresponding to the point cloud data, use the first spherical quadtree node of the point cloud data as the second spherical quadtree node corresponding to the point cloud data, and then allocate the point cloud data to the second spherical triangle; wherein, the division of the first spherical triangle according to the first spherical quadtree node includes: according to the triangle vertex coordinates of the first spherical triangle, calculating the midpoint coordinates of each side of the first spherical triangle to obtain the initial side midpoint coordinates of the first spherical triangle; according to the vertex connection order, dividing the triangle vertex of the first spherical triangle The method comprises the steps of: combining the point coordinates and the initial side midpoint coordinates to divide the first spherical triangle into a plurality of spherical triangles, and determining the triangle vertex coordinates of each spherical triangle obtained by the division; determining the index corresponding to the initial side midpoint coordinates according to a preset floating point error correction method and a preset hash mapping table; determining the triangle vertex coordinate index of each spherical triangle obtained by the division based on the index corresponding to the initial side midpoint coordinates and the triangle vertex coordinate index of the first spherical triangle; updating the spherical triangle vertex coordinate index table based on the triangle vertex coordinate index and the triangle vertex coordinates of each spherical triangle obtained by the division; and updating the spherical triangle vertex coordinate index table based on the vertex connection sequence. Sequence, combine the coding information of the first spherical triangle, encode each of the spherical triangles obtained by the division, and determine the coding information of each of the spherical triangles obtained by the division; based on the coding information of each of the spherical triangles obtained by the division and the triangle vertex coordinate index, update the spherical triangle index table; based on the triangle vertex coordinate index of each of the spherical triangles obtained by the division, combine the first spherical quadtree node, construct and initialize the spherical quadtree node of each of the spherical triangles obtained by the division; based on the spherical quadtree node of each of the spherical triangles obtained by the division, update the child node pointer and leaf node flag of the first spherical quadtree node;Re-determining, according to the spherical half-space detection method, the first spherical triangle and the first spherical quadtree node corresponding to each point cloud data within the first spherical triangle, and then re-determining the second spherical triangle and the second spherical quadtree node corresponding to each point cloud data within the first spherical triangle; and then reallocating each point cloud data within the first spherical triangle to the corresponding second spherical triangle, thereby completing the division of the first spherical triangle; After all the point cloud data are assigned to the second spherical triangle, an encoding path structure for each point cloud data is generated based on the radial depth of each point cloud data, the second spherical quadtree node and the second spherical triangle to complete the compression of the point cloud data.
2. The point cloud data compression method based on spherical quadtree according to claim 1, characterized in that: The method of determining a first spherical triangle and a first spherical quadtree node corresponding to the point cloud data in combination with the spherical triangle, the spherical quadtree node, and the spherical coordinates according to a preset spherical half-space detection method includes: Determine, based on the parent node pointer of the spherical quadtree node, a plurality of spherical quadtree root nodes and a spherical root triangle corresponding to each of the spherical quadtree root nodes; Determine the triangle vertex coordinates of each spherical root triangle according to the triangle vertex coordinate index of each spherical quadtree root node and the spherical triangle vertex coordinate index table; Performing a cross product calculation on the triangle vertex coordinates of each spherical root triangle to obtain an edge normal vector of each spherical root triangle; A first spherical triangle and a first spherical quadtree node corresponding to the point cloud data are determined according to the edge normal vector of each spherical root triangle, the spherical quadtree root node, and the spherical coordinates of the point cloud data.
3. The point cloud data compression method based on spherical quadtree according to claim 2, characterized in that: The determining, based on the edge normal vector of each spherical root triangle, the spherical quadtree root node, and the spherical coordinates of the point cloud data, a first spherical triangle and a first spherical quadtree node corresponding to the point cloud data comprises: Performing dot multiplication calculation on the spherical coordinates of the point cloud data and the edge normal vector of each spherical root triangle, respectively, to obtain a dot multiplication result of the point cloud data; screening the spherical root triangle and the spherical quadtree root node according to the dot product result of the point cloud data to determine a third spherical triangle of the point cloud data and a third spherical quadtree node corresponding to the third spherical triangle; If the leaf node flag of the third spherical quadtree node is not a preset value, determining a plurality of fourth spherical quadtree nodes of the point cloud data based on the child node pointer of the third spherical quadtree node, and determining a fourth spherical triangle corresponding to each of the fourth spherical quadtree nodes; Determining an edge normal vector of each of the fourth spherical triangles according to a triangle vertex coordinate index of each of the fourth spherical quadtree nodes and the spherical triangle vertex coordinate index table; Performing dot multiplication calculations on the spherical coordinates of the point cloud data and the edge normal vector of each of the fourth spherical triangles, respectively, to update the dot multiplication results of the point cloud data; Filtering the fourth spherical triangle and the fourth spherical quadtree node according to the updated dot product result of the point cloud data to re-determine the third spherical triangle and the third spherical quadtree node of the point cloud data, and further re-determining a plurality of fourth spherical quadtree nodes and a plurality of fourth spherical triangles of the point cloud data until the leaf node flag of the third spherical triangle of the point cloud data reaches a preset value, thereby completing iteration of the third spherical triangle and the third spherical quadtree node of the point cloud data; The third spherical triangle obtained by the last iteration of the point cloud data is used as the first spherical triangle corresponding to the point cloud data; The third spherical quadtree node obtained by the last iteration of the point cloud data is used as the first spherical quadtree node corresponding to the point cloud data.
4. The point cloud data compression method based on a spherical quadtree according to any one of claims 1 to 3, characterized in that: The method further comprises dividing the first spherical triangle according to the division judgment result and combining the first spherical quadtree node to determine a second spherical triangle and a second spherical quadtree node corresponding to the point cloud data, and allocating the point cloud data to the second spherical triangle. If the division judgment result is that spherical triangle division is not required, the first spherical triangle of the point cloud data is used as the second spherical triangle corresponding to the point cloud data, and the first spherical quadtree node of the point cloud data is used as the second spherical quadtree node corresponding to the point cloud data, and then the point cloud data is allocated to the second spherical triangle.
5. The point cloud data compression method based on spherical quadtree according to claim 1, characterized in that: The determining, according to a preset floating-point error correction method and a preset hash mapping table, an index corresponding to the coordinates of the initial edge midpoint includes: Correcting the initial side midpoint coordinates according to a preset floating-point error correction method to obtain the first side midpoint coordinates of the first spherical triangle; Querying a preset hash mapping table according to the coordinates of the midpoint of the first side; If the first side midpoint coordinates exist in the hash mapping table, obtain the index corresponding to the initial side midpoint coordinates; If the first side midpoint coordinates do not exist in the hash mapping table, construct an index corresponding to the initial side midpoint coordinates, and store the index corresponding to the initial side midpoint coordinates and the first side midpoint coordinates in the hash mapping table.
6. The point cloud data compression method based on spherical quadtree according to claim 4, characterized in that: Before allocating the point cloud data to the second spherical triangle, the method further includes: If the side length of the second spherical triangle is less than a preset second side length threshold, calculating the normal vector of the point cloud data based on the spherical coordinates of the point cloud data according to a preset principal component analysis method; Calculate the normal vector of each point cloud data in the second spherical triangle according to a preset principal component analysis method and in combination with the spherical coordinates of each point cloud data in the second spherical triangle; Comparing the angles between the normal vector of the point cloud data and the normal vector of each point cloud data in the second spherical triangle in sequence; If the angle is greater than or equal to a preset angle threshold, the point cloud data is allocated to the second spherical triangle; otherwise, the point cloud data is discarded.
7. The point cloud data compression method based on spherical quadtree according to claim 1, characterized in that: After allocating all the point cloud data to the second spherical triangle, generating an encoding path structure for each point cloud data based on the radial depth of each point cloud data, the second spherical quadtree node, and the second spherical triangle to complete the compression of the point cloud data, including: After allocating all the point cloud data to the second spherical triangle, generating a depth value field for each of the point cloud data based on the radial depth of each of the point cloud data; Determining a node depth of each of the second spherical quadtree nodes of the point cloud data based on a parent node pointer of the second spherical quadtree node of each of the point cloud data; generating a node depth field for each point cloud data based on the node depth of the second spherical quadtree node of each point cloud data; generating a path coding field for each of the point cloud data based on the coding information of the second spherical triangle of each of the point cloud data; Generate a coding path structure for each of the point cloud data based on the depth value field, the node depth field, and the path coding field of each of the point cloud data; According to the path coding field, the coding path structures are sorted to construct a coding path structure array, and the coding path structure array is used as point cloud data compression data to complete the compression of the point cloud data.
8. A point cloud data compression device based on spherical quadtree, characterized in that: A point cloud data compression method based on a spherical quadtree according to any one of claims 1 to 7, comprising: a data acquisition module, a spherical half-space detection module, a spherical triangle division judgment module, a spherical triangle division module, and a point cloud data encoding module; The data acquisition module is used to acquire a number of point cloud data to be compressed, initialize a number of spherical triangles and a spherical quadtree node corresponding to each of the spherical triangles; The spherical half-space detection module is used to determine the first spherical triangle and the first spherical quadtree node corresponding to the point cloud data according to a preset spherical half-space detection method, in combination with the spherical triangle, the spherical quadtree node and the spherical coordinates; The spherical triangle division judgment module is used to obtain the side length of the first spherical triangle and the number of point cloud data within the first spherical triangle, and determine the division judgment result of the first spherical triangle according to the side length of the first spherical triangle and the number of point cloud data within the first spherical triangle; The spherical triangle division module is used to divide the first spherical triangle according to the division judgment result and in combination with the first spherical quadtree node, determine the second spherical triangle and the second spherical quadtree node corresponding to the point cloud data, and assign the point cloud data to the second spherical triangle; The point cloud data encoding module is used to generate an encoding path structure for each point cloud data based on the radial depth of each point cloud data, the second spherical quadtree node and the second spherical triangle after all the point cloud data are assigned to the second spherical triangle, so as to complete the compression of the point cloud data.
Citation Information
Patent Citations
Quadtree-based massive laser scanning point cloud real-time drawing method
CN101908068A
Spherical image compression method and device based on spherical deep neural network
CN119071494A