Improved method and system for organizing large-scale multibeam strip point clouds using quadtrees

By improving the directional quadtree structure and binary index file, and combining principal component analysis and memory mapping technology, the problems of memory occupation of massive multibeam bathymetry point cloud data and low efficiency of traditional index structures are solved, and efficient point cloud organization and retrieval are achieved.

CN120374853BActive Publication Date: 2025-11-14SHANDONG UNIV OF SCI & TECH +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510466066.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-04-15
Publication Date
2025-11-14
Estimated Expiration
2045-04-15

AI Technical Summary

Technical Problem

Existing technologies suffer from excessive memory consumption leading to system lag when processing massive multibeam bathymetry point cloud data, and external storage dependency causing performance degradation. Traditional index structures are redundant and inefficient in processing seabed topographic data, and do not take into account the main directional characteristics of point clouds in multibeam scanning, resulting in excessive index depth and an increase in empty nodes.

Method used

An improved directional quadtree structure and binary index file are adopted. The principal axis direction of the point cloud is determined by principal component analysis, an external storage index of the directional quadtree is established, and memory mapping and multi-threading techniques are used to optimize the organization and retrieval of the point cloud.

Benefits of technology

It effectively reduces index building time and retrieval time, reduces the number of nodes, improves data processing efficiency, and achieves efficient point cloud management and retrieval, especially in large-scale multi-beam strip point cloud data processing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120374853B_ABST
    Figure CN120374853B_ABST
Patent Text Reader

Abstract

This invention belongs to the field of data structure technology and discloses an improved method and system for organizing large-scale multibeam strip point clouds using a directional quadtree. The method obtains the directional bounding boxes of the original point cloud by performing principal component analysis (PCA) on the original point cloud and determining the bounding boxes based on the PCA results. According to the spatial distribution characteristics of the multibeam strip point cloud, an external storage index file for the directional quadtree is established, and the index file is organized using a binary method. The improved directional quadtree structure and the defined binary index file are used to organize and store the original multibeam scan points. By improving the calculation process of the directional bounding boxes of nodes other than the root node in the directional quadtree, the index construction time is significantly reduced. The improved directional quadtree takes about twice as long as the traditional quadtree, but more than three times less time than the conventional directional quadtree. Memory mapping and multithreading techniques are used to read the point cloud from the index file, improving reading efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of data structure technology, and in particular relates to an improved method and system for organizing large-scale multibeam strip point clouds using a directional quadtree. Background Technology

[0002] Multibeam bathymetry is widely used in underwater topographic surveying and seabed classification due to its high efficiency, wide coverage, high accuracy, and automation. However, its large data volume presents challenges for data storage and processing. It is impractical to store all the data in computer memory alone; therefore, a suitable data structure must be constructed to improve retrieval efficiency.

[0003] To achieve efficient point cloud processing, a common approach is to create a point cloud data index in computer memory to optimize data spatial organization, improve processing speed, and reduce disk I / O bottlenecks. However, in processing massive point clouds, even with data stored in memory, excessive memory usage can still cause system lag. Therefore, it's necessary to combine external storage to optimize resource utilization. Adopting a hybrid data organization strategy can fully leverage the high speed of memory while utilizing the capacity of external storage, ensuring efficient processing of large-scale data. For this purpose, a carefully designed data scheduling system between memory and external storage is essential to achieve fast and stable point cloud computing and management.

[0004] The key to effectively managing spatial data lies in creating well-structured data indexes. Spatial indexes typically use data structures such as KD-trees, R-trees, quadtrees, and octrees to organize spatial point clouds. To facilitate operations such as loading, displaying, and rendering large point cloud datasets, modern methods primarily utilize octree structures for data organization, combined with core-outside and level-of-detail (LOD) techniques, thereby achieving efficient point cloud operations with minimal memory usage. Compared to land topography obtained from 3D LiDAR, seabed topography typically consists of large flat areas with relatively small elevation variations and few prominent features. Using octree structures to organize multibeam sonar point clouds would lead to storage redundancy in the Z-direction. Therefore, using quadtree structures to index and organize multibeam sonar data is more suitable. Furthermore, according to the principles of multibeam field operations, to ensure comprehensive coverage of seabed topography, survey vessels must conduct surveys along designed survey lines to acquire long scan band data. Since the direction of the survey lines is usually consistent with the isobaths, relatively uniform point cloud data can be obtained, especially in MBES where real-time motion compensation technology is widely used. When constructing a traditional quadtree index, the bounding box calculation does not take into account the principal orientation of the point cloud. Therefore, especially in the case of point clouds in multibeam scan strips (long coverage areas formed by the number of pings when a ship sails along a survey line), using a traditional quadtree index may lead to an increase in empty nodes and excessive index depth.

[0005] While some progress has been made in the organization and management of multibeam point cloud data, several problems and shortcomings remain: First, memory-dependent pre-indexing methods can easily lead to excessive memory consumption and system lag when processing massive amounts of data, while relying solely on external storage results in performance degradation and increased latency. Second, traditional spatial indexing structures (such as KD-trees, R-trees, and octrees) have limitations when processing seabed topographic data. For example, KD-trees consume a lot of memory, overlapping intermediate nodes in R-trees reduce efficiency, and octrees have storage redundancy in the Z-direction. Furthermore, traditional quadtree indexes do not consider the main directional characteristics of point clouds in multibeam scanning bands, which may lead to an increase in empty nodes and excessive index depth, affecting processing efficiency. Overall, existing solutions still have room for improvement in areas such as balancing memory and external storage, optimizing index structures, adapting to the characteristics of multibeam data, and efficiently retrieving search points.

[0006] Based on the above analysis, the problems and shortcomings of the existing technology are as follows:

[0007] (1) The current memory-dependent pre-indexing method is prone to excessive memory usage when processing massive amounts of data, causing system lag, while relying solely on external storage will lead to performance degradation and increased latency.

[0008] (2) Traditional spatial indexing structures have limitations when processing seabed topographic data, such as the large memory consumption of KD trees, the reduced efficiency of overlapping intermediate nodes in R trees, and the storage redundancy in the Z direction of octrees.

[0009] (3) Traditional quadtree indexes do not take into account the main direction characteristics of point clouds in multi-beam scanning, resulting in excessive redundancy of axial bounding boxes. When building the index, there may be an increase in empty nodes and excessive index depth, which affects processing efficiency. Summary of the Invention

[0010] To overcome the problems existing in related technologies, the present invention discloses an improved method and system for organizing large-scale multibeam strip point clouds using directional quadtrees. The technical solution is as follows:

[0011] This invention is implemented as follows: an improved method for organizing large-scale multibeam strip point clouds using directional quadtrees, comprising the following steps:

[0012] S1, Oriented bounding box calculation: Perform principal component analysis on the original point cloud, determine the bounding box algorithm based on the principal component analysis results, and obtain the orientation bounding box of the original point cloud;

[0013] S2, Construction of the external storage index of the directional quadtree: Based on the spatial distribution characteristics of the multibeam strip point cloud, a directional quadtree external storage index file is established, and the index file of the quadtree is organized using a binary method;

[0014] S3, Multibeam Strip Point Cloud Organization: An improved directional quadtree structure and a defined binary index file are used to organize and store the original multibeam scan points and perform point cloud retrieval.

[0015] In step S1, the calculation of the orientation bounding box includes:

[0016] (1) By performing principal component analysis on the original point cloud data, the principal axis direction of the point cloud is determined;

[0017] (2) The original point cloud P i Rotate the point cloud along its principal axis from its centroid until the principal direction of the rotated point cloud is aligned with the coordinate axes, thus obtaining the rotated point cloud P'. i ';

[0018] (3) The rotated point cloud P' i 'Calculate the axial bounding box;'

[0019] (4) Rotate the obtained axial bounding box in the opposite direction to the corresponding angle and return it to the position corresponding to the original point cloud. The bounding box obtained after rotating the axial bounding box is the directional bounding box of the original point cloud.

[0020] In step (1), principal component analysis includes:

[0021] ① Calculate the centroid of the point cloud

[0022]

[0023] In the formula, Let x be the location of the centroid of the point cloud. i ,y i Let n be the planar coordinates of the point cloud, and n be the number of points.

[0024] ② Transfer point cloud data P i Translate to the center of mass so that the center of mass is located at the origin;

[0025]

[0026] In the formula, P' i For centralized point cloud data;

[0027] ③ Construct the covariance matrix C of the centralized point cloud data and calculate the covariance matrix;

[0028]

[0029] In the formula, T is the matrix transpose;

[0030] ④ Perform eigenvalue decomposition on the covariance matrix and solve for the eigenvectors;

[0031] Cvj =λ j v j

[0032] In the formula, λ j For eigenvalues, v j The corresponding feature vector;

[0033] ⑤ Sort the feature values ​​in descending order to obtain the corresponding feature vectors and the principal axis directions of the point cloud data.

[0034] In step S2, a directional quadtree external storage index file is created. The quadtree index file is organized using a binary method, including:

[0035] The quadtree index file is organized using a binary method, with a pre-designed fixed-length node structure. Each node contains child node offsets, region ranges, and metadata. The file header stores global metadata, the root node starts from a fixed position, and child nodes are laid out according to a static pre-allocation or dynamic allocation strategy. During construction, data is recursively inserted from the root node. If a node needs to be split, four child node blocks are allocated and the parent node offset is updated. The child nodes are directly associated with data block pointers. During querying, the root node is located through the file header, and the offset is calculated layer by layer to jump to the target child node. Combined with random access, data is retrieved quickly. The data block area is dynamically expanded at the end of the file, supporting the reuse of idle nodes and batch writing optimization. Through a compact binary format, fixed-length nodes, and direct offset calculation, efficient spatial indexing and cross-platform compatibility are achieved. Based on the spatial distribution characteristics of multi-beam strip point clouds, when dividing a single strip point cloud into a quadtree, the main direction of the root node is used to replace the main direction of each child node.

[0036] Furthermore, the construction of the directional quadtree external memory index includes:

[0037] (1) Read multibeam bathymetry point cloud data by memory mapping, define the point cloud structure, call the system function to map the file to the process memory pointer, and access the coordinate data through zero-copy index; if the file byte order is inconsistent with the system, the end order needs to be converted field by field, and the rationality of the depth value is verified to eliminate the anomaly; when reading, traverse all points or combine the pre-mapped quadtree index to quickly filter the spatial region, improve efficiency by multi-threaded block parallel processing, and unmap and close the file by munmap; set the coordinates of the first point read as the reference offset, subtract the offset from all points to obtain the offset data, and then initialize the segmentation threshold;

[0038] (2) Calculate the bounding box of the point cloud and divide the space into four equal parts. Recalculate the bounding box of the child node of the directional quadtree and determine whether the number of point clouds of the child node is greater than the threshold.

[0039] (3) Write the directional quadtree index information and iteratively serialize it to the computer hard disk to generate the directional quadtree index file on the external storage, and finally complete the establishment of the directional quadtree spatial index.

[0040] In step (2), the directional bounding box of the point cloud is calculated and the main axis direction is recorded. The directional bounding box is used as the root node of the quadtree. The space is divided into four equal parts according to the directional bounding box, and the point set corresponding to each region is used as the four child nodes of the current node. The bounding box of the child node of the directional quadtree is recalculated according to the main axis direction of the original point cloud, and it is determined whether the number of point clouds of the child node is greater than the threshold.

[0041] Furthermore, the comparison between the number of nodes and the threshold is as follows:

[0042] If the number of point clouds in a child node is greater than the threshold, the quadtree continues to be split until the number of point clouds in all leaf nodes is less than the threshold. If the number of point clouds in a child node is less than the threshold, it is determined whether the number of stored point clouds is non-zero. If so, the leaf node of the directional quadtree is determined.

[0043] In step (3), writing the directional quadtree index information includes:

[0044] When constructing a directional quadtree index, the offset, the directional bounding box information of the root node, and the information of the corresponding child nodes are written in the root node file; the directional bounding box information of the nodes and the information of the corresponding child nodes are written in the child node file; and the directional bounding box information of the nodes, the information of the adjacent nodes, and the point set information of the leaf nodes are written in the leaf node file.

[0045] In step S3, the point cloud retrieval process includes:

[0046] (1) Read the root node file of the directional quadtree and determine the search range;

[0047] (2) Determine whether the search range intersects with the bounding box of the root node. If the search range intersects with the bounding box of the root node, then determine whether the bounding box of the root node is within the search range.

[0048] (3) If the bounding box of the root node is within the search range, then read all leaf node files under the root node, load the point sets in all leaf node files and form the point set information within the search range.

[0049] (4) If the root node's bounding box is not within the search range, then read the child node files of the current node and determine whether the search range intersects with the child node's bounding box;

[0050] (5) If the search range intersects with the bounding box of the child node, determine whether the bounding box of the child node is within the search range; if the bounding box of the child node is within the search range, read all leaf node files under the node, load the point sets in all leaf node files and form the point set information within the search range.

[0051] (6) If the bounding box of the child node is not within the search range, determine whether the current node is a leaf node. If the current node is not a leaf node, return to step (4). If the current node is a leaf node, determine whether the node is within the search range. If so, output the point set information within the search range.

[0052] Another object of the present invention is to provide an improved directional quadtree large-scale multibeam strip point cloud organization system, which is used to control the improved directional quadtree large-scale multibeam strip point cloud organization method. The system includes:

[0053] The orientation bounding box calculation module is used to perform principal component analysis on the original point cloud, determine the bounding box algorithm based on the principal component analysis results, and obtain the orientation bounding box of the original point cloud.

[0054] The directional quadtree external storage index building module is used to build directional quadtree external storage index files based on the spatial distribution characteristics of multibeam strip point clouds, and organizes the quadtree index files using a binary method.

[0055] The multibeam strip point cloud organization module is used to organize and store the original multibeam scan points using an improved directional quadtree structure and a defined binary index file, and to perform point cloud retrieval.

[0056] Combining all the above technical solutions, the beneficial effects of this invention are as follows:

[0057] First, this invention employs an improved directional quadtree structure and a defined binary index file to organize and store the original multibeam scan points, which are then stored on a hard disk. Simultaneously, this invention also utilizes memory mapping and multithreading techniques to read point clouds from the index file, improving reading efficiency.

[0058] Secondly, regarding the number of points in multi-beam stripes, the directional quadtree has fewer nodes and a shallower tree depth compared to the traditional quadtree, resulting in shorter retrieval time. Within the same retrieval range, the conventional and improved directional quadtrees take roughly the same amount of time, with the directional quadtree reducing the time by up to 27% compared to the traditional quadtree, demonstrating the high efficiency of the improved directional quadtree in index creation and point cloud retrieval.

[0059] Third, by improving the calculation process of the bounding boxes of nodes other than the root node in the directional quadtree, the index construction time is greatly reduced. The improved directional quadtree takes about twice as long as the traditional quadtree, but more than three times less than the conventional directional quadtree.

[0060] Fourth, memory mapping and multi-threading technologies are used to read point clouds from index files, improving reading efficiency. This invention can effectively divide massive multibeam bathymetry point cloud data, achieve efficient point cloud retrieval, improve the efficiency of data preprocessing, and provide an effective solution to the problem of efficient organization and management of large-scale multibeam strip point clouds.

[0061] Fifth, this invention designs an improved external storage data organization method for a directional quadtree index structure. First, based on the spatial characteristics of multibeam strip point cloud data, directional bounding boxes are introduced into the traditional quadtree structure to form a directional quadtree for point cloud segmentation. Second, based on the distribution characteristics of multibeam strip point clouds, when segmenting point cloud data, the main direction of the root node's directional bounding box is used to replace the main direction of all child node directional bounding boxes to form the child node's directional bounding box, thereby improving the conventional directional quadtree. Finally, the information of the root node, child nodes, and leaf nodes is stored in the external storage index file. Attached Figure Description

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

[0063] Figure 1 This is a flowchart of the improved directional quadtree method for organizing large-scale multibeam strip point clouds provided in this embodiment of the invention;

[0064] Figure 2 This is a schematic diagram of a quadtree structure provided in an embodiment of the present invention;

[0065] Figure 3 This is a comparative diagram of a quadtree and a directional quadtree provided in an embodiment of the present invention; wherein, (a) is a quadtree index structure and (b) is a directional quadtree index structure;

[0066] Figure 4 This is a flowchart of the index construction and retrieval process provided in an embodiment of the present invention;

[0067] Figure 5 This is a schematic diagram illustrating different search ranges provided in the embodiments of the present invention. Detailed Implementation

[0068] To make the above-mentioned objects, features, and advantages of the present invention more apparent and understandable, specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings. Many specific details are set forth in the following description to provide a thorough understanding of the present invention. However, the present invention can be practiced in many other ways different from those described herein, and those skilled in the art can make similar modifications without departing from the spirit of the present invention. Therefore, the present invention is not limited to the specific embodiments disclosed below.

[0069] The innovation of this invention lies in the following: This invention uses a traditional quadtree structure and directional bounding boxes to construct an index for multibeam stripe point cloud data, and improves the calculation process of directional bounding boxes for nodes other than the root node. The improved directional quadtree structure and a defined binary index file are used to organize and store the original multibeam scan points, and these are stored on a hard disk.

[0070] Example 1, as Figure 1 As shown, the improved directional quadtree method for organizing large-scale multibeam strip point clouds provided in this embodiment of the invention includes the following steps:

[0071] S1, Oriented bounding box calculation: Perform principal component analysis on the original point cloud, determine the bounding box algorithm based on the principal component analysis results, and obtain the orientation bounding box of the original point cloud;

[0072] S2, Construction of the external storage index of the directional quadtree: Based on the spatial distribution characteristics of the multibeam strip point cloud, a directional quadtree external storage index file is established, and the index file of the quadtree is organized using a binary method;

[0073] S3, Multibeam Strip Point Cloud Organization: An improved directional quadtree structure and a defined binary index file are used to organize and store the original multibeam scan points and perform point cloud retrieval.

[0074] 1. Quadtree Structure: A quadtree index, proposed by Tayeb in 1998, is a tree-like data index structure. It's a tree-like data structure where each node has at most four child nodes, consisting of three types of elements: root node, child nodes, and leaf nodes. The root node represents the entire domain of interest. It is the entry point of the quadtree hierarchy, storing all data points before any further subdivision. Figure 2 The topmost node is shown. Child nodes are direct branches of the root node. Each child node represents a quadrant of the parent node's spatial region, such as... Figure 2 The second level of nodes is shown in the diagram. Quadtree leaf nodes are terminal nodes without further subdivision; they have no child nodes and are the "endpoint" of the tree traversal, representing the lowest level in the hierarchical structure, such as... Figure 2The lowest-level node in the hierarchy is shown. It represents the smallest spatial unit in the hierarchy, containing the final set of data points. The idea behind quadtree indexing is to partition each two-dimensional object in the space into a recursive frame. In this process, the two-dimensional object at the root node is divided into four equal child nodes through a recursive procedure. To avoid infinite recursion, a threshold must be set to limit the number of recursive partitions. The termination criterion for hierarchical partitioning is this threshold. Setting a maximum or minimum partition depth for each node in the set are two common methods. Once the threshold is reached, the quadtree indexing process ends. A schematic diagram of a two-level complete quadtree partition and its structure is shown below. Figure 2 As shown.

[0075] 2. Oriented Bounding Box: An Oriented Bounding Box (OBB) is the smallest bounding box generated along the principal component directions of an object, enclosing the object. An Axis-Aligned Bounding Box (AABB) is the smallest rectangle (or a rectangular prism in 3D space) aligned with the coordinate axes and completely enclosing all data points. The edges of the bounding box are always parallel to the X and Y axes (Z in 3D space). Compared to AABB, OBB can approximate the object with the highest possible accuracy based on its shape characteristics, making it more suitable for data with strong directionality.

[0076] Since multibeam bathymetry point clouds are uniformly distributed along the trajectory line, and most of them are not perpendicular to the axis direction, the orientation bounding box is the optimal choice for the root node of the quadtree partitioning of the multibeam bathymetry point cloud. A comparison of data quadtrees and orientation quadtrees can be found in [link to documentation]. Figure 3 The example data consists of real-world multibeam bathymetry data, with a total of approximately 500,000 data points. The threshold for quadtree partitioning is no more than 50,000 data points per node. Figure 3 (a) and Figure 3 The comparison in (b) shows that directional quadtrees create quadtrees that are shallower and have fewer nodes than standard quadtrees. This successfully reduces the number of redundant and empty nodes, improving query efficiency.

[0077] Calculating the oriented bounding box primarily utilizes the first and second-order statistical properties of vertex coordinates to determine the optimal orientation and find the minimum size of the bounding box in that orientation. This invention first performs principal component analysis on the original point cloud, using the results to determine the algorithm for the final bounding box. Since only the oriented bounding box corresponding to the point cloud plane needs to be calculated and quadtree indexing performed, the influence of the Z-axis orientation can be ignored. The specific steps are as follows:

[0078] (1) By performing principal component analysis on the original point cloud data, the principal axis direction of the point cloud is determined;

[0079] The main steps of PCA (Principal Component Analysis) are as follows:

[0080] ① Calculate the centroid of the point cloud

[0081]

[0082] In the formula, Let x be the location of the centroid of the point cloud. i ,y i Let n be the planar coordinates of the point cloud, and n be the number of points.

[0083] ② Transfer point cloud data P i Translate to the center of mass so that the center of mass is located at the origin;

[0084]

[0085] In the formula, P' i For centralized point cloud data;

[0086] ③ Construct the covariance matrix C of the centralized point cloud data and calculate the covariance matrix;

[0087]

[0088] In the formula, T is the matrix transpose;

[0089] ④ Perform eigenvalue decomposition on the covariance matrix and solve for the eigenvectors;

[0090] Cv j =λ j v j

[0091] In the formula, λ j For eigenvalues, v j The corresponding feature vector;

[0092] ⑤ Sort the feature values ​​in descending order to obtain the corresponding feature vectors and the principal axis directions of the point cloud data.

[0093] (2) The original point cloud P i Rotate along the principal axis of the point cloud's centroid until the principal direction of the rotated point cloud aligns with the coordinate axes, resulting in the rotated point cloud P″. i ;

[0094] (3) Rotate the point cloud P″ i Calculate the axial bounding box;

[0095] At this point, the rotated point cloud P″ iThe principal direction is already aligned with the coordinate axes, so the AABB of the rotated point is calculated.

[0096] (4) Rotate the obtained axial bounding box in the opposite direction to the corresponding angle and return it to the position corresponding to the original point cloud. The bounding box obtained after rotating the axial bounding box is the directional bounding box of the original point cloud.

[0097] Rotate the obtained AABB in reverse to the corresponding angle and return it to the position of the original point cloud. The bounding box obtained after rotating the AABB is the OBB of the original point cloud.

[0098] In step S2, a directional quadtree external storage index file is created. The quadtree index file is organized using a binary method, including:

[0099] The quadtree index file is organized using a binary method, with a pre-designed fixed-length node structure. Each node contains child node offsets (four 8-byte unsigned integers), a region range (four double-precision floating-point numbers), and metadata (flag bits and data pointers), typically aligned to 80 bytes for improved access efficiency. The file header stores global metadata (such as root node offset, node size, space range, and version identifier). The root node starts at a fixed position (e.g., after byte 1024), and child nodes are laid out according to either a static pre-allocation or dynamic allocation strategy (the latter managing node space through a free list). During construction, data is recursively inserted from the root node. If a node needs to be split, four child node blocks are allocated and the parent node offset is updated. Leaf nodes are directly associated with data block pointers. During queries, the root node is located through the file header, and the offset is calculated layer by layer to jump to the target child node, combined with random access for fast data retrieval. The data block area is dynamically expanded at the end of the file, supporting free node reuse and batch write optimization. Ultimately, efficient spatial indexing and cross-platform compatibility are achieved through a compact binary format, fixed-length nodes, and direct offset calculation. Based on the spatial distribution characteristics of multibeam strip point clouds, when dividing a single strip point cloud into a quadtree, the main direction of the root node is used to replace the main direction of each child node.

[0100] The construction of the directional quadtree external storage index includes:

[0101] (1) Read multibeam bathymetry point cloud data through memory mapping. When reading multibeam bathymetry point cloud data efficiently through memory mapping, the point cloud structure must first be defined (e.g., each point contains a 24-byte continuous storage format of planar coordinates x, y and water depth, and memory alignment without padding is ensured by #pragmapack(1)). Then, the system function (e.g. mmap or MapViewOfFile) is called to map the file to the process memory pointer, and the coordinate data is accessed directly through the index (e.g. points[i].x) with zero copy. If the file byte order is inconsistent with the system (e.g., big endian storage), the endian order must be converted field by field, and the rationality of the depth value must be checked to eliminate the anomaly. When reading, all points can be traversed or the spatial region (e.g., x / y range) can be quickly filtered by combining the pre-mapped quadtree index. Efficiency is improved by multi-threaded block parallel processing. Finally, the mapping is removed and the file is closed by munmap. The paging mechanism of the operating system is used to realize the on-demand loading and efficient memory management of ultra-large-scale data, taking into account nanosecond-level random access and low memory overhead. Set the coordinates of the first point read as the reference offset, subtract this offset from all points to obtain the offset data, and then initialize the segmentation threshold;

[0102] (2) Calculate the bounding box of the point cloud and divide the space into four equal parts. Recalculate the bounding box of the child node of the directional quadtree and determine whether the number of point clouds of the child node is greater than the threshold.

[0103] (3) Write the directional quadtree index information and iteratively serialize it to the computer hard disk to generate the directional quadtree index file on the external storage, and finally complete the establishment of the directional quadtree spatial index.

[0104] In step (2), the directional bounding box of the point cloud is calculated and the main axis direction is recorded. The directional bounding box is used as the root node of the quadtree. The space is divided into four equal parts according to the directional bounding box, and the point set corresponding to each region is used as the four child nodes of the current node. The bounding box of the child node of the directional quadtree is recalculated according to the main axis direction of the original point cloud, and it is determined whether the number of point clouds of the child node is greater than the threshold.

[0105] In step (3), writing the directional quadtree index information includes:

[0106] When constructing a directional quadtree index, the offset, the directional bounding box information of the root node, and the information of the corresponding child nodes are written in the root node file; the directional bounding box information of the nodes and the information of the corresponding child nodes are written in the child node file; and the directional bounding box information of the nodes, the information of the adjacent nodes, and the point set information of the leaf nodes are written in the leaf node file.

[0107] The writing process of directional quadtree index information must start from the root node. First, define the global space range (e.g., [x_min, y_min, x_max, y_max]) and direction partitioning rules (e.g., dividing the node into four directional sub-regions based on the median coordinates), and set a node capacity threshold (e.g., each leaf node can store a maximum of N data points). When inserting data, recursively determine the direction of the sub-region to which the point to be inserted belongs. If the current leaf node is not full, write the data entry directly; if the node data volume exceeds the limit, trigger a split: allocate space for four child nodes, reallocate the parent node data to the corresponding child nodes according to the direction, update the child node pointers of the parent node (e.g., file offset or memory address), and mark the parent node as a non-leaf node. During the writing process, the node information (including space range, child node pointers, data volume, and data list) needs to be serialized and persistently stored to a file or database in fixed block sizes (e.g., 256 bytes / node). When dynamically allocating, node space reuse is managed through a free list. In terms of optimization, lazy splitting strategy can be used to delay splitting, batch insertion of pre-sorted data to reduce the number of splits, and clear rules for the ownership of boundary data (such as left-closed and right-open intervals) to avoid ambiguity. Finally, metadata such as the root node position and tree depth are updated in the file header to achieve efficient construction and maintenance of spatial indexes.

[0108] 3. Construction of External Index for Oriented Quadtree: Oriented quadtree is a tree structure model that combines oriented bounding boxes and traditional quadtrees to describe two-dimensional space. It uses the oriented bounding boxes of the original point cloud as the root node to divide the quadtree. Each non-leaf node represents the oriented bounding box of the corresponding current spatial data along the direction of the principal component of the original point cloud.

[0109] To reduce the memory consumption of large-scale data, this invention, based on the concept of internal and external memory scheduling, constructs a directional quadtree index file in external memory. To reduce file storage space usage and improve the read / write efficiency of external memory files, a binary method is used to organize the quadtree index file. The index construction, directional quadtree external memory organization, and retrieval process are as follows: Figure 4 As shown. Based on the spatial distribution characteristics of multibeam strip point clouds, this invention proposes an improved directional quadtree method, that is, when dividing a single strip point cloud into a quadtree, the main direction of the root node is used to replace the main direction of each child node.

[0110] The specific steps for creating a directional quadtree external storage index are as follows:

[0111] (1) Multibeam bathymetry point cloud data was read using memory mapping. The first point read was set as the offset, and the offset was subtracted from all points to obtain the offset data. Then, the segmentation threshold was initialized. In this experiment, the segmentation threshold was 2.5% of the original point cloud data.

[0112] (2) Calculate the bounding box of the point cloud and record its main axis direction. Use the bounding box as the root node of the quadtree. Then divide the space into 4 equal parts according to the bounding box and use the point set corresponding to each region as the 4 child nodes of the current node. Recalculate the bounding box of the child node according to the main axis direction of the original point cloud. If the number of point clouds in the child node is greater than the threshold, continue to divide the quadtree until the number of point clouds in all leaf nodes is less than the threshold.

[0113] (3) When constructing the directional quadtree index, write the offset, the directional bounding box information of the root node and the information of the corresponding child node in the root node file; write the directional bounding box information of the node and the information of the corresponding child node in the child node file; write the directional bounding box information of the node, the information of the adjacent node and the point set information of the leaf node in the leaf node file. The format of the directional quadtree index node file is shown in Table 1. Iteratively serialize these directional quadtree index information to the computer hard disk to generate the directional quadtree index file on the external storage, and finally complete the establishment of the directional quadtree spatial index.

[0114] Table 1. Information on the external storage index file of the directional quadtree.

[0115] root node child nodes leaf nodes Point cloud offset Directional bounding box information Directional bounding box information Directional bounding box information Child node file information Adjacent node file information Child node file information Current node set information

[0116] Example 2, the improved directional quadtree large-scale multibeam strip point cloud organization system provided in this embodiment of the invention includes:

[0117] The orientation bounding box calculation module is used to perform principal component analysis on the original point cloud, determine the bounding box algorithm based on the principal component analysis results, and obtain the orientation bounding box of the original point cloud.

[0118] The directional quadtree external storage index building module is used to build directional quadtree external storage index files based on the spatial distribution characteristics of multibeam strip point clouds, and organizes the quadtree index files using a binary method.

[0119] The multibeam strip point cloud organization module is used to organize and store the original multibeam scan points using an improved directional quadtree structure and a defined binary index file, and to perform point cloud retrieval.

[0120] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail or recorded in a certain embodiment, please refer to the relevant descriptions of other embodiments.

[0121] To further demonstrate the positive effects of the above embodiments, the present invention conducts the following experiments based on the above technical solutions.

[0122] This section utilizes experimental data acquired using a Kongsberg EM2040 multibeam echo sounder (maximum ranging distance 600 meters; ranging resolution 1.25 cm; the angular sector used in this survey is approximately ±60°; 512 beams). Ten multibeam strip datasets were selected, each with a point cloud size exceeding one million. The experimental tests primarily included the indexing time of traditional quadtrees, conventional directional quadtrees, and improved directional quadtrees; the time required to retrieve point clouds; and the indexing and retrieval times under different thresholds.

[0123] Quadtree index files for the selected multibeam strip data were constructed using traditional quadtrees, conventional directional quadtrees, and improved directional quadtrees based on external storage, with a segmentation threshold of 2.5% of the original point cloud count. Table 2 shows the time consumption and external storage requirements during the index construction process using different methods, and Table 3 shows the number of layers and effective nodes of the quadtrees generated using different index construction methods.

[0124] Table 2 Index construction time for each method (unit: seconds)

[0125]

[0126]

[0127] Traditional oriented quadtrees require the longest construction time, significantly exceeding that of both traditional and improved oriented quadtrees. This time difference becomes more pronounced as the amount of point cloud data increases. Including orientation information leads to longer construction times for both traditional and improved oriented quadtrees compared to traditional quadtrees, primarily due to the time-consuming PCA process required for identifying the main orientation of the point cloud. However, the improved oriented quadtree requires only one PCA process, significantly reducing construction time compared to traditional oriented quadtrees.

[0128] Table 3 shows the number of quadtree levels and child nodes for each method (the bold text in the table represents the number of child nodes).

[0129]

[0130] To verify the performance of the proposed method in point cloud retrieval, this invention selected the 10th group of multibeam scanning bands in Table 2 (containing more than 10 million points), calculated the time consumption under different retrieval ranges, and compared it with the traditional quadtree, the traditional directional quadtree, and the traversal method. Figure 5 Eleven search areas are presented. Except for area 1, the other areas are rectangular regions starting from points A and B. Area 1 does not intersect the survey line, while the ranges of areas 2 to 11 gradually increase uniformly until they encompass the entire survey line. The comparison results obtained by searching these 11 areas are shown in Table 3.

[0131] As shown in Table 4, when the search range does not intersect with the multibeam scanning band (see Table 4), Figure 5 In region 1 of the image (see image 1), the quadtree-based retrieval time is approximately 0.10 milliseconds, significantly lower than the time required for traversal retrieval. When the number of point clouds increases to half of the total scan range, the quadtree retrieval method is more advantageous than the traversal retrieval method. However, as the number of point clouds within the retrieval range continues to increase, the time required for quadtree indexing gradually approaches the time required for traversal retrieval. When retrieving all point clouds (see image 1), the time required for quadtree indexing gradually approaches that required for traversal retrieval. Figure 5 In region 11 of the data, due to the deep tree structure and empty child nodes, the time required for traditional quadtree retrieval is even longer than that of traversal. However, directional quadtrees and improved directional quadtrees do not have this problem, because the time consumption of these two methods is similar and lower than that of traditional quadtrees, especially when dealing with a large number of points.

[0132] Table 4. Search times for different search ranges using various methods (unit: ms)

[0133] Search area Search point cloud quantity Traditional quadtree conventional directional quadtree Improvement direction: quadtree Traversal 1 0 0.11 0.10 0.10 212 2 1,075,204 53 51 52 241 3 2,176,067 94 79 82 259 4 3,393,547 145 118 118 282 5 4,219,178 192 159 162 315 6 5,003,093 214 173 180 331 7 6,220,027 277 238 233 363 8 7,047,486 311 248 251 378 9 8,021,641 391 321 320 401 10 9,028,699 429 333 335 426 11 10,776,400 456 360 361 453

[0134] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any modifications, equivalent substitutions and improvements made by those skilled in the art within the scope of the technology disclosed in the present invention and within the spirit and principles of the present invention should be covered within the scope of protection of the present invention.

Claims

1. A method for organizing large-scale multibeam strip point clouds using an improved directional quadtree, characterized in that, The method includes the following steps: S1, Oriented bounding box calculation: Perform principal component analysis on the original point cloud, determine the bounding box algorithm based on the principal component analysis results, and obtain the orientation bounding box of the original point cloud; S2, Construction of the external storage index of the directional quadtree: Based on the spatial distribution characteristics of the multibeam strip point cloud, a directional quadtree external storage index file is established, and the index file of the quadtree is organized using a binary method; The quadtree index file is organized using a binary method, with a pre-designed fixed-length node structure. Each node contains child node offsets, region ranges, and metadata. The file header stores global metadata, the root node starts from a fixed position, and child nodes are laid out according to a static pre-allocation or dynamic allocation strategy. During construction, data is recursively inserted from the root node. If a node needs to be split, four child node blocks are allocated and the parent node offset is updated. Child nodes are directly associated with data block pointers. During querying, the root node is located through the file header, and the offset is calculated layer by layer to jump to the target child node, combined with random access for fast data retrieval. The data block area is dynamically expanded at the end of the file, supporting the reuse of idle nodes and batch writing optimization. This is achieved through a compact binary format, fixed-length nodes, and direct offset calculation. Based on the spatial distribution characteristics of multi-beam strip point clouds, when dividing a single strip point cloud into a quadtree, the main direction of the root node is used to replace the main direction of each child node. The construction of the directional quadtree external storage index includes: (1) Read multibeam bathymetry point cloud data by memory mapping, define point cloud structure, call system function to map file to process memory pointer, and access coordinate data by index zero copy; if file byte order is inconsistent with system, the end order needs to be converted field by field, and the rationality of depth value is checked to eliminate abnormalities; when reading, traverse all points or combine pre-mapped quadtree index to quickly filter spatial regions, improve efficiency by multi-threaded block parallel processing, and unmap and close file by munmap; set the coordinates of the first point read as reference offset, subtract the offset from all points to obtain the offset data, and then initialize the segmentation threshold; (2) Calculate the bounding box of the point cloud and divide the space into four equal parts. Recalculate the bounding box of the child node of the directional quadtree and determine whether the number of point clouds of the child node is greater than the threshold. (3) Write the directional quadtree index information and iteratively serialize it to the computer hard disk to generate the directional quadtree index file on the external storage, and finally complete the establishment of the directional quadtree spatial index; S3, Multibeam Strip Point Cloud Organization: An improved directional quadtree structure and a defined binary index file are used to organize and store the original multibeam scan points and perform point cloud retrieval.

2. The method for organizing large-scale multibeam strip point clouds using an improved directional quadtree according to claim 1, characterized in that, In step S1, the calculation of the orientation bounding box includes: (1) The principal axis direction of the point cloud is determined by performing principal component analysis on the original point cloud data; (2) The original point cloud Rotate the point cloud along its centroid along the principal axis until the principal direction of the rotated point cloud is aligned with the coordinate axes, thus obtaining the rotated point cloud. ; (3) Rotated point cloud Calculate the axial bounding box; (4) Rotate the obtained axial bounding box in reverse by the corresponding angle back to the position corresponding to the original point cloud. The bounding box obtained after rotating the axial bounding box is the directional bounding box of the original point cloud.

3. The method for organizing large-scale multibeam strip point clouds using an improved directional quadtree according to claim 2, characterized in that, In step (1), principal component analysis includes: ① Calculate the centroid of the point cloud ; ; ; ; In the formula, The location of the centroid of the point cloud. Let the point cloud be in planar coordinates. The number of points; ② Point cloud data Translate to the center of mass so that the center of mass is located at the origin; ; In the formula, For centralized point cloud data; ③ Construct the covariance matrix of centralized point cloud data Calculate the covariance matrix; ; In the formula, This is the matrix transpose. ④ Perform eigenvalue decomposition on the covariance matrix and solve for the eigenvectors; ; In the formula, For eigenvalues, The corresponding feature vector; ⑤ Sort the feature values ​​in descending order to obtain the corresponding feature vectors and the principal axis directions of the point cloud data.

4. The method for organizing large-scale multibeam strip point clouds using an improved directional quadtree according to claim 1, characterized in that, In step (2), the orientation bounding box of the point cloud is calculated and the main axis direction is recorded. The orientation bounding box is used as the root node of the quadtree. The space is divided into four equal parts according to the directional bounding box, and the point set corresponding to each region is taken as the four child nodes of the current node; the bounding box of the directional quadtree child node is recalculated according to the main axis direction of the original point cloud, and it is determined whether the point cloud number of the child node is greater than the threshold.

5. The method for organizing large-scale multibeam strip point clouds using an improved directional quadtree according to claim 4, characterized in that, The comparison of the relationship between the number of nodes and the threshold is as follows: If the number of point clouds in a child node is greater than the threshold, the quadtree continues to be split until the number of point clouds in all leaf nodes is less than the threshold. If the number of point clouds in a child node is less than the threshold, it is determined whether the number of stored point clouds is non-zero. If so, the leaf node of the directional quadtree is determined.

6. The method for organizing large-scale multibeam strip point clouds using an improved directional quadtree according to claim 1, characterized in that, In step (3), writing the directional quadtree index information includes: When constructing a directional quadtree index, the offset, the directional bounding box information of the root node, and the information of the corresponding child nodes are written in the root node file; the directional bounding box information of the nodes and the information of the corresponding child nodes are written in the child node file; and the directional bounding box information of the nodes, the information of the adjacent nodes, and the point set information of the leaf nodes are written in the leaf node file.

7. The method for organizing large-scale multibeam strip point clouds using an improved directional quadtree according to claim 1, characterized in that, In step S3, the point cloud retrieval process includes: (1) Read the root node file of the directional quadtree and determine the search range; (2) Determine whether the search range intersects with the bounding box of the root node. If the search range intersects with the bounding box of the root node, then determine whether the bounding box of the root node is within the search range. (3) If the bounding box of the root node is within the search range, then read all leaf node files under the root node, load the point sets in all leaf node files and form the point set information within the search range; (4) If the root node's bounding box is not within the search range, then read the child node files of the current node and determine whether the search range intersects with the child node's bounding box; (5) If the search range intersects with the bounding box of the child node, determine whether the bounding box of the child node is within the search range; if the bounding box of the child node is within the search range, read all leaf node files under the node, load the point sets in all leaf node files and form the point set information within the search range. (6) If the bounding box of the child node is not within the search range, determine whether the current node is a leaf node. If the current node is not a leaf node, return to step (4). If the current node is a leaf node, determine whether the node is within the search range. If so, output the point set information within the search range.

8. A large-scale multibeam strip point cloud organization system with an improved directional quadtree, characterized in that, This system is used to control the large-scale multibeam strip point cloud organization method of the improved directional quadtree as described in any one of claims 1-7. The system includes: The orientation bounding box calculation module is used to perform principal component analysis on the original point cloud, determine the bounding box algorithm based on the principal component analysis results, and obtain the orientation bounding box of the original point cloud. The directional quadtree external storage index building module is used to build directional quadtree external storage index files based on the spatial distribution characteristics of multibeam strip point clouds, and organizes the quadtree index files using a binary method. The multibeam strip point cloud organization module is used to organize and store the original multibeam scan points using an improved directional quadtree structure and a defined binary index file, and to perform point cloud retrieval.

Citation Information

Patent Citations

  • Height commanding analysis method and system based on double spatial indexes

    CN119648927A

  • System and method for rendering of texel imagery

    US20080238919A1