A drawing method for making a three-dimensional model based on a three-dimensional laser point cloud
By employing a rendering method based on 3D laser point clouds and utilizing octree structure and topological feature noise rank optimization, the memory consumption problem caused by uneven point cloud data density is solved, achieving efficient 3D model construction, improving the preservation of model details and structural stability, and making it suitable for industrial design and cultural heritage protection.
Patent Information
- Application Number
- CN202511026173.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-24
- Publication Date
- 2026-02-13
- Estimated Expiration
- 2045-07-24
AI Technical Summary
When using existing technologies to construct 3D models for complex or large-scale scenes, uneven point cloud data density leads to a sharp increase in memory usage and reduced data loading and processing efficiency, making it difficult to meet the needs of practical applications.
A rendering method based on 3D laser point clouds is adopted. Point cloud data is managed through an octree structure, a hierarchical aggregated attribute octree is constructed, an adaptive multi-level detail mesh model is generated, and the topological feature noise rank is used to identify and optimize the topological structure, remove noisy data, and form a topology-optimized 3D model.
It improves the efficiency of point cloud data processing, reduces memory usage, enhances the model's detail retention and rendering accuracy, and improves the model's realism and structural stability, making it suitable for fields such as precision industrial design and cultural heritage protection.
Smart Images

Figure CN120807802B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of three-dimensional model, and particularly to a drawing method for making a three-dimensional model based on three-dimensional laser point cloud. BACKGROUND
[0002] The technical field of three-dimensional model refers to using computer graphics, computer vision, geometric modeling, spatial analysis and other related technologies to create, describe, store and display the three-dimensional geometric structure and attribute characteristics of objects or scenes in the real world or virtual world in a digital form through mathematical expression or data representation, thereby providing basic data and visualization support for various industrial design, architectural design, urban planning, film and television animation production, virtual reality, augmented reality, robot navigation, autonomous driving, cultural heritage protection, medical image analysis and other application fields.
[0003] The prior art often uses direct point cloud data processing and grid generation method when constructing a three-dimensional model for a complex or large-scale scene. This method can cause a sharp increase in memory occupation, reduce data loading and processing efficiency, and frequently cause memory overflow or processing efficiency bottleneck in actual application, which is difficult to meet the application requirements of large-scale data scenes. Therefore, improvement is needed. SUMMARY
[0004] The purpose of the present application is to solve the shortcomings in the prior art and provide a drawing method for making a three-dimensional model based on three-dimensional laser point cloud.
[0005] In order to achieve the above-mentioned purpose, the present application adopts the following technical scheme, a drawing method for making a three-dimensional model based on three-dimensional laser point cloud, comprising the following steps:
[0006] Sequentially read the point cloud data file of the three-dimensional laser point cloud, insert the coordinate value of each point into the octree structure, when the octree node buffer in the memory is full, write the node data in the buffer to the hard disk, traverse the hard disk octree node set from bottom to top, and establish a hierarchical aggregated attribute octree;
[0007] Based on the hierarchical aggregated attribute octree, select a coarse level and call the representative point and average normal in the node, construct a function field covering the three-dimensional model, obtain a basic implicit function field, perform isosurface extraction on the basic implicit function field, and generate an adaptive multi-detail level grid model according to the viewpoint distance and memory limit;
[0008] Based on the adaptive multi-detail level grid model, construct a sequence of cell complex, obtain cell complex basic data, traverse each point in the cell complex basic data, calculate the topological noise rank, and obtain a topological feature noise rank list;
[0009] Based on the topology feature noise rank list, each topology noise rank in the topology feature noise rank list is compared with a preset rank value threshold, a classified topology feature set is obtained, and a topology optimization three-dimensional model is established according to the classified topology feature set.
[0010] Preferably, the step of obtaining the hierarchical aggregated attribute octree is:
[0011] The point cloud data file of the three-dimensional laser point cloud is sequentially read, the three-dimensional coordinate values of each point in the file are parsed one by one, the parsed coordinate values of each point are sequentially inserted into the octree structure created in advance, when the insertion process causes the storage amount of the octree node buffer in the memory to reach the memory limit threshold, the buffer writing mechanism is triggered, all octree node data in the current buffer is written to the hard disk storage space as a whole, and a hard disk octree node set is formed;
[0012] Based on the hard disk octree node set, the node data stored in the hard disk is traversed layer by layer in a bottom-up order according to the octree structure, the spatial geometric data information contained by all child nodes under each parent node is extracted one by one, the coordinate values and normal vector information of the child nodes are merged, and the representative point coordinate values, average normal values and error measurement values of each parent node are calculated according to the merged geometric data information, and a parent node geometric information aggregation set is generated;
[0013] Based on the parent node geometric information aggregation set, the representative point coordinate values, average normal values and error measurement values of all parent nodes in the parent node geometric information aggregation set are re-inserted into the corresponding positions of the parent nodes of the octree structure layer by layer, and the calculation is repeated layer by layer upwards until the hierarchical aggregation of the entire octree structure is completed, and a hierarchical aggregated attribute octree is formed.
[0014] Preferably, the step of obtaining the basis implicit function field is:
[0015] Based on the hierarchical aggregated attribute octree, all nodes of the rough level are located, the representative point coordinate vectors and average normal vectors stored in the nodes are extracted one by one, all representative point coordinate vectors and average normal vectors are traversed, each query position in the three-dimensional space is mapped, an initial function field covering the three-dimensional model is established, and initial data of the function field is obtained.
[0016] According to the initial data of the function field, the basis implicit function field is calculated.
[0017] Preferably, the step of obtaining the adaptive multi-detail level grid model is:
[0018] Based on the implicit function field, an isosurface is extracted for each query position in the three-dimensional space, and in combination with the viewpoint distance condition and the memory limit, a deeper level node data of the hierarchical aggregated attribute octree is called to replace the implicit function value of the corresponding region, the local function field is updated and re-partitioned block by block, and an adaptive multi-detail level grid model is generated.
[0019] Preferably, the obtaining step of the cell complex basic data is:
[0020] Based on the adaptive multi-detail level grid model, the geodesic distance of all vertices to a reference point is calculated, the vertices and connected edges and faces are sequentially introduced in order of the geodesic distance value from small to large, and the complete cell complex sequence containing vertices, edges and faces is formed by gradually expanding in order, to obtain the cell complex basic data.
[0021] Preferably, the obtaining step of the topological feature noise rank list is:
[0022] According to the cell complex basic data, the topological feature noise rank is calculated;
[0023] Based on the topological feature noise rank, all topological feature points are traversed, the topological feature noise ranks are summarized, and a topological feature noise rank list is generated.
[0024] Preferably, the obtaining step of the classified topological feature set is:
[0025] Based on the topological feature noise rank list, the noise rank corresponding to each topological feature in the topological feature noise rank list is extracted, and the noise rank of each topological feature is compared with a pre-set rank value threshold one by one. If the noise rank of the topological feature is greater than the rank value threshold, the topological feature is marked as a noise feature, and if the noise rank of the topological feature is less than or equal to the rank value threshold, the topological feature is marked as a significant structure, and a classified topological feature set is generated.
[0026] Preferably, the obtaining step of the topologically optimized three-dimensional model is:
[0027] Based on the classified topological feature set, all topological features marked as noise features are screened, and the spatial position of each noise feature in the adaptive multi-detail level grid model is traced one by one, all edge elements and face elements corresponding to each noise feature are located, and a noise feature positioning set is formed.
[0028] Based on the noise feature positioning set, all edge elements and face elements in the noise feature positioning set are deleted one by one in the adaptive multi-detail level grid model, and the grid elements are reconnected and filled and repaired through the local region boundary after topological cutting, and a topologically optimized three-dimensional model is established.
[0029] Compared with the prior art, the application has the advantages and positive effects that:
[0030] The application effectively improves the point cloud data processing efficiency and reduces the memory occupation pressure by inserting three-dimensional laser point cloud data step by step and using the hierarchical aggregation octree structure; the continuous function field is constructed by fusing the representative points and average normals in the octree structure, and the mesh model is adaptively generated in a multi-detail level manner, which improves the detail retention capability and drawing accuracy of the model; further, the accurate identification and positioning of the topological features are realized by using the calculation of the cell complex sequence and the topological feature noise rank, the noise data and redundant topological structure in the model are removed, and the authenticity and structural stability of the three-dimensional model in the local area are improved; by using the fine topological noise positioning and local reconstruction manner, the three-dimensional model is accurately cut and refilled in the local topological defect area, so that the topological structure of the generated three-dimensional model in the complex area is more reasonable, the overall model quality and visual authenticity are improved, and the reliability and practicality of the model in subsequent application in the fields of precision industrial design, cultural heritage protection, building engineering planning and the like are enhanced. BRIEF DESCRIPTION OF DRAWINGS
[0031] Figure 1 The application is a schematic diagram of the steps. DETAILED DESCRIPTION
[0032] In order to make the purpose, technical scheme and advantages of the application clearer, the application is further described in detail below in combination with the drawings and examples. It should be understood that the specific examples described herein are only used to explain the application, and are not used to limit the application.
[0033] Please refer to Figure 1 The application provides a technical scheme, a drawing method for making a three-dimensional model based on three-dimensional laser point cloud, comprising the following steps:
[0034] The point cloud data file of the three-dimensional laser point cloud is sequentially read, the coordinate value of each point is inserted into the octree structure, when the octree node buffer in the memory is full, the node data in the buffer is written to the hard disk, the hard disk octree node set is traversed from bottom to top, and the hierarchical aggregation attribute octree is established;
[0035] Based on the hierarchical aggregation attribute octree, the representative points and average normals in the nodes are selected and called, the function field covering the three-dimensional model is constructed, the basic implicit function field is obtained, the isosurface extraction is performed on the basic implicit function field, and the adaptive multi-detail level mesh model is generated according to the viewpoint distance and memory limit;
[0036] Based on the adaptive multi-detail level mesh model, the cell complex sequence is constructed, the cell complex basic data is obtained, each point in the cell complex basic data is traversed, the topological noise rank is calculated, and the topological feature noise rank list is obtained;
[0037] Based on the topology feature noise rank list, each topology noise rank in the topology feature noise rank list is compared with a preset rank value threshold, a classified topology feature set is obtained, and a topology optimization three-dimensional model is established according to the classified topology feature set.
[0038] The obtaining step of the hierarchical aggregated attribute octree is:
[0039] The point cloud data file of the three-dimensional laser point cloud is sequentially read, the three-dimensional coordinate values of each point in the file are parsed one by one, the parsed coordinate values of each point are sequentially inserted into the octree structure created in advance, when the insertion process causes the storage amount of the octree node buffer in the memory to reach the memory limit threshold, the buffer writing mechanism is triggered, all octree node data in the current buffer is written to the hard disk storage space as a whole, and a hard disk octree node set is formed;
[0040] Based on the hard disk octree node set, the node data stored in the hard disk is traversed layer by layer in a bottom-up order according to the octree structure, the spatial geometric data information contained by all child nodes under each parent node is extracted one by one, the coordinate values and normal vector information of the child nodes are merged, and the representative point coordinate values, average normal value and error measurement value of each parent node are calculated according to the merged geometric data information, and a parent node geometric information aggregation set is generated;
[0041] Based on the parent node geometric information aggregation set, the representative point coordinate values, average normal value and error measurement value of all parent nodes in the parent node geometric information aggregation set are re-inserted into the corresponding positions of the parent nodes of the octree structure layer by layer, and the calculation is repeated layer by layer upwards until the hierarchical aggregation of the entire octree structure is completed, and a hierarchical aggregated attribute octree is formed.
[0042] Specifically, the point cloud data file of the three-dimensional laser point cloud is read in sequence, specifically, the.xyz format file separated by spaces or commas is scanned line by line, each line of text is parsed, three floating point numbers representing spatial points are extracted, which correspond to X, Y and Z three-dimensional coordinate values respectively, before parsing the first point, the maximum and minimum values of the three-dimensional coordinates of all points are determined by pre-defining a space range or performing a quick pre-scan on the entire point cloud file, so as to establish an initial cubic space that can completely enclose all point cloud data, and based on this cubic space, an octree structure containing only a root node is created in the memory, then the coordinate values of each point parsed, such as point (10.5, 20.3, 5.8), are inserted into the root node of the octree according to their coordinate positions, and recursively inserted down to a leaf node, if there is a data point in the leaf node, the leaf node is split into eight new child nodes, and the data points in the original node and the current data point to be inserted are redistributed to the corresponding new child nodes, the insertion process continues, while the system monitors the special buffer area in the memory for storing octree node data in real time, the size of the buffer area is preset as a memory limit threshold, the setting of the threshold is based on the available physical memory of the current running environment, the specific setting method is to obtain the total physical memory of the current system, subtract the reserved memory occupied by the operating system and other key processes, and take 80% of the remaining available memory as the threshold, for example, if the available memory of the system is 10GB, the threshold is set to 8GB, when the node buffer area used for storage exceeds 8GB for the first time due to the insertion operation, the buffer area write mechanism is triggered, which will pause the new point cloud insertion operation, serialize all node data in the octree node buffer area in the current memory, including the level, space range, parent-child relationship index and point coordinate data contained in the leaf node, and write it as a whole data block to the specified storage area on the hard disk at one time, empty the memory buffer area and continue to process the subsequent point cloud data, repeat the process until all point cloud data files are read and processed, forming one or more ordered node data files on the hard disk, which together constitute a complete hard disk octree node set.
[0043] Based on the hard disk octree node set, a bottom-up aggregation process is started, first locating to the deepest level of the octree structure, that is, the level where the leaf nodes containing the original point cloud data are located, and traversing the node data stored in the hard disk layer by layer in the order of the bottom-up of the octree structure. The specific implementation is to load all the node data of the current processing level into the memory at one time. For a parent node, the spatial geometric data information contained in all eight child nodes under it is extracted one by one. If the child node is a leaf node, the original point cloud coordinate values stored in it are directly extracted. If the normal vector information is not contained in the original point cloud data, the initial normal vector of each point set in the leaf node needs to be calculated first. The calculation method is as follows: for each point, all the points in the leaf node where it is located are selected as the neighborhood, and the covariance matrix of the neighborhood point set is calculated through principal component analysis (PCA). The eigenvector corresponding to the smallest eigenvalue is taken as the initial normal vector of the point. Then, the coordinate values and the calculated normal vector information of all the points contained in all the child nodes under the parent node are merged, and the three core aggregation attributes of the parent node are calculated according to the merged geometric data information. First, the representative point coordinate value is calculated, which is the arithmetic average of the coordinate values of all points contained in the child nodes, that is, the X, Y and Z coordinates of all points are summed and then divided by the total number of points. Second, the average normal value is calculated, which is the vector sum of the normal vectors of all points contained in the child nodes, and then the result vector is normalized to obtain a unit vector. Finally, the error measurement value is calculated, which is used to quantify the deviation of all points in the current node from a fitting plane defined by the representative point and the average normal. The calculation method is as follows: for each point in the child node set, the square of the perpendicular distance from the point to the fitting plane is calculated, then all these squared distance values are accumulated and averaged. The representative point coordinate value, average normal value and error measurement value of each parent node calculated are packaged into an aggregation record. When all the parent nodes of a level are calculated, these aggregation records are summarized to generate a parent node geometric information aggregation set.
[0044] Based on the aggregated set of geometric information of parent nodes, the representative point coordinates, average normal values, and error metric values of all parent nodes recorded in the aggregated set and calculated in the previous stage are updated layer by layer into the disk-based octree structure. Specifically, these aggregated attribute data are written to the storage location of the corresponding parent node, replacing the original placeholder information or low-level data of that node. After completing the update of one level, the program automatically moves up one level, taking the parent node layer that has just completed aggregation as the new "child node layer" and starting a new round of aggregation calculation. In this high-level aggregation process, the calculation method is adjusted. When calculating the representative point coordinates of a higher-level parent node (e.g., L-2 level), the original point cloud is no longer used. Instead, the representative point coordinates of its direct child nodes (L-1 level) are used, and a weighted average method is used for calculation. The weight of the representative point of each child node is the number of original point clouds it represents. Similarly, the same weight is used when calculating the average normal value. The average normals of the child nodes are weighted and summed, then normalized. For the upward propagation of the error metric, the total error metric of a parent node consists of two parts: one part is the self-fitting plane error calculated based on the representative points of all its child nodes (calculated in the same way as described above), and the other part is the maximum value of the error metrics of all its child nodes. Finally, the error metric of the parent node is set to the sum of these two parts. This iterative process of calculation and updating is carried out layer by layer upwards, starting from the deepest non-leaf node level and proceeding upwards until the aggregate attributes of the direct child nodes of the root node are calculated and updated, and finally the aggregate attribute calculation of the root node itself is completed. At this point, each non-leaf node in the entire octree structure stores a condensed representation of the geometric features within its covered space, namely the representative point, average normal, and error metric, thus forming a hierarchical aggregate attribute octree with a complete structure, rich attributes, and support for multi-level detailed queries.
[0045] The steps to obtain the basic implicit function field are as follows:
[0046] Based on the hierarchical aggregated attribute octree, all nodes at the coarse level are located, and the representative point coordinate vector and average normal vector stored in each node are extracted one by one. All representative point coordinate vectors and average normal vectors are traversed and mapped to each query position in the three-dimensional space to establish an initial function field covering the three-dimensional model and obtain the initial data of the function field.
[0047] Based on the initial data of the function field, the fundamental implicit function field is calculated using the following formula:
[0048] ;
[0049] Medium weight function The calculation formula is:
[0050] ;
[0051] wherein, is the basis implicit function value at the query point , is the coordinate vector of the position to be computed in three-dimensional space, is the coordinate vector of the i-th representative point, is the i-th average normal vector, is the i-th node's error metric value, is the maximum error metric value among all nodes, is the error influence factor, is the smoothing radius parameter, is the number of adjacent representative points involved in the computation.
[0052] Specifically, based on the hierarchical aggregation attribute octree, firstly, a suitable rough level needs to be determined. The selection criteria of the rough level is to maximize the reduction of the number of nodes participating in the calculation under the premise of ensuring the integrity of the initial model profile. The specific positioning method is to start from the next layer of the root node of the hierarchical aggregation attribute octree (i.e. level 1) and traverse layer by layer downward, count the total number of nodes at each level, and set a node number threshold, which is dynamically set according to the memory capacity of the processing hardware and the target processing efficiency. For example, in a workstation with 32GB of physical memory, to ensure the smoothness of the initial calculation, the threshold can be set to 30000. The system will select the level whose total number of nodes first exceeds 30000 as the rough level. After selecting the rough level, the system will traverse all nodes in this level and extract the core aggregation attributes from the storage structure of each node, i.e. the calculated representative point coordinate vector and the average normal vector. Then, to establish the initial function field covering the three-dimensional model, a three-dimensional grid needs to be defined as the query space within the bounding box space of the entire model. The size of the grid is determined according to the approximate size of the model and the required initial resolution. For example, for a scanning scene with a size of 10 meters by 10 meters by 5 meters, a 128 by 128 by 64 query grid can be set. Each center point in the grid is a query position. Subsequently, each query position in the three-dimensional grid is traversed. For each query position, a set of representative points that have an impact on it needs to be determined. The implementation method is to use the spatial indexing capability of the hierarchical aggregation attribute octree to quickly retrieve all representative points in the rough level that fall within a preset influence radius range with the current query position as the center. The setting of the influence radius is related to the average size of the octree nodes, and is usually set to 2 to 3 times the average diagonal length of the nodes in the rough level. The coordinate vector, average normal vector and error measurement value attached to each representative point are extracted together to form a data set associated with the current query position. All query positions and their corresponding associated data sets are summarized to finally obtain the initial data of the function field.
[0053] Equation: The calculation formula of the weight function is: ;
[0054] The advantage of the equation is that a smooth scalar field is constructed, and the zero value surface can accurately approximate the surface of the real object represented by the original point cloud. The weight function introduces an error adjustment term in , which uses the error measurement value previously calculated in the hierarchical aggregation attribute octree, so that in areas with poor quality, large noise or complex details of point cloud data (corresponding tohigher), its weight in the function field calculation is actively reduced, thus effectively suppressing the interference of noise on the surface reconstruction, improving the robustness and fairness of the model, while in the flat area with good data quality (corresponding to a lower value), the weight of the representative point is relatively higher, ensuring the accurate expression of the model features. This adaptive weighting mechanism enables the model reconstruction process to intelligently distinguish between signal and noise, ultimately generating a high-quality three-dimensional model with clear details and smooth surface;
[0055] is the coordinate vector of the position to be calculated in three-dimensional space, which represents any point in three-dimensional space for function value query. In specific implementation, these query points are usually the center coordinates of a pre-defined three-dimensional grid, which completely covers the entire model space defined by the hierarchical aggregation attribute octree root node. The resolution of the grid determines the basic accuracy of the final generated model. After obtaining the initial data of the function field, is the coordinates of each query position recorded in the data. For example, in the previous step, a 128x128x64 query grid is created, then the center coordinates of the 128x128x64 grid points are sequentially taken, thus calculating the implicit function value of each position in the entire space to form a complete scalar field. For example, a specific query point coordinate vector is , with units of meters;
[0056] is the number of adjacent representative points participating in the calculation, which defines how many representative points need to be considered around the query point when calculating the function value. The value of this parameter directly affects the locality, smoothness and calculation efficiency of the calculation. The setting method is as follows: first, randomly sample 10% of the representative points from all representative points in the coarse level, for each sample point, use the octree structure to quickly query the number of neighbor representative points within a certain radius (for example, three times the smoothing radius ), and record it down. Then calculate the average and standard deviation of all these number values. Finally, set the value of to the average value plus one standard deviation, and round up. This setting method makes adaptive to the local density of representative points. For example, after statistical calculation, the average number of neighbors is 18.7 and the standard deviation is 4.2, then the set value of is , and after rounding up, we get ;
[0057] is the coordinate vector of the th representative point, is the coordinate vector of the A mean normal vector, For the first The error metric values for each node; these three parameters are all directly derived from the initial data of the function field generated in the previous step, for each query point. The initial data of the function field already stores the associated data. The information of the nearest neighbor represents the point, therefore in the calculation At that time, the program will directly read this from the data structure. Group Triplet data, which is calculated and stored during the aggregation stage of constructing the hierarchical aggregated attribute octree, reflects the local geometric features of the point cloud at different spatial scales. For example, for a query point... The first representative point information read from the initial data of the function field is: coordinate vector.
[0058] Mean normal vector Error measurement value ;
[0059] The maximum error metric value among all nodes is used as a normalization factor to scale the error metric values of all nodes to a controllable range. It is obtained by iterating through all nodes at the selected coarseness level and reading the stored error metric value for each node. The maximum value is recorded, and this process only needs to be performed once before the initial calculation of the function field. All subsequent calculations at this coarse level will use the same method. This ensures the global consistency of the error impact. For example, if the system traverses all 32,768 nodes of the coarse level and finds that the error metric ranges from 0.001 to 0.45, then... The value was set to 0.45;
[0060] The error impact factor is a dimensionless hyperparameter used to adjust the error metric. The strength of the influence of the weighting function is empirically determined and needs to be adjusted based on the noise level of the point cloud data and the smoothness requirements of the target model. The setting process involves selecting a small region with representative features (such as planes, curved surfaces, or sharp corners) and using different weighting functions. Values (e.g., 1.0, 5.0, 10.0, 20.0) are used to generate local models. Through visual inspection or comparison with a high-precision reference model, a model is selected that best preserves geometric details while effectively suppressing noise. For example, for a building point cloud from a terrestrial laser scanner, the noise level is low but sharp features such as corners of walls need to be preserved, it is found through testing that the best results are achieved when ;
[0061] is set to 2.5 times the average distance between the representative points in the rough level, which is calculated as follows: randomly select 1000 representative points from the rough level, for each representative point, calculate its distance to its 5th nearest neighbor using octree, then calculate the average of the 1000 distance values, denoted as , and finally set the smoothing radius to 2.5 times the average distance, i.e. .
[0062] Calculation process:
[0063] Take a query point for example, and for simplicity of demonstration, only use its nearest 3 representative points (i.e. ) for calculation, the parameter values are as follows:
[0064] .
[0065] The information of the three representative points is as follows:
[0066]
[0067] First, calculate the weight of each representative point
[0068] for
[0069] Distance square:
[0070]
[0071] Weight:
[0072]
[0073] for
[0074] Distance squared:
[0075]
[0076] Weight:
[0077]
[0078] For :
[0079] Distance squared:
[0080]
[0081] Weight:
[0082]
[0083] Second step, calculate the weighted directed distance sum in the numerator:
[0084] Term 1:
[0085]
[0086] Term 2:
[0087]
[0088] Term 3:
[0089]
[0090] Numerator sum:
[0091] ;
[0092] Third step, calculate the weight sum in the denominator:
[0093] Denominator sum:
[0094] ;
[0095] Fourth step, calculate the final function value :
[0096] ;
[0097] The result shows that the implicit function value at the query point is 0.0734, since this value is greater than 0, it indicates that the point The value of 0.0734 approximately represents the shortest distance from the point to the implicit surface. By repeating this calculation for all grid query points, a complete three-dimensional scalar field, i.e. the basic implicit function field, can be obtained. Subsequent isosurface extraction algorithms will search for the positions of all to construct the final mesh model.
[0098] The adaptive multi-detail level mesh model acquisition step is as follows:
[0099] Based on the basic implicit function field, isosurface extraction is performed for each query position in the three-dimensional space. In combination with the viewpoint distance condition and the memory limit, deeper level node data of the hierarchical aggregation attribute octree is called to replace the implicit function values of the corresponding region, the local function field is updated and resubdivided block by block, and the adaptive multi-detail level mesh model is generated.
[0100] Specifically, based on the basic implicit function field, first, the Marching Cubes algorithm is used to extract the initial isosurface for each query position in the three-dimensional space. Specifically, each voxel in the three-dimensional grid formed by the basic implicit function field is traversed, the implicit function values of the eight vertices are read, and these values are compared with the isosurface threshold (fixed at 0). According to the sign combination of the function values of the eight vertices, the topology configuration of the triangular patches generated in the cube is determined from a precomputed lookup table containing 256 cases. The positions of the triangular patch vertices are calculated by linear interpolation of the two endpoints of the edge across the isosurface. After traversing all the voxel units, the basic grid covering the entire model is obtained. Subsequently, the system enters a dynamic, adaptive refinement cycle based on the distance of the viewpoint and the memory limit. This cycle monitors the position of the virtual camera, i.e., the viewpoint, in real time and adjusts the level of detail according to the distance of the viewpoint from each part of the model. Specifically, two distance thresholds, the near distance threshold and the far distance threshold, are set. The setting of these two thresholds is based on the diagonal length of the model bounding box. For example, if the diagonal length of the model bounding box is 100 meters, the near distance threshold can be set to 15 meters and the far distance threshold can be set to 60 meters. For any point on the model, if the distance from the viewpoint is less than 15 meters, it is determined to be a high-detail area. If the distance is between 15 meters and 60 meters, it is a medium-detail area. If the distance is greater than 60 meters, it is a low-detail area. At the same time, the system sets a memory limit, which is embodied as a target total number of triangular patches, for example, 3 million triangular patches. During the refinement process, the program will real-time count the total number of faces of the current model. When the total number of faces approaches this limit, the refinement of the near area will be prioritized, and the refinement of the far area may be stopped or simplified. For the local grid determined to be a high-detail area, the system locates the node corresponding to the hierarchical aggregation attribute octree and retrieves the data of the next one or two layers of child nodes. Using these more dense and accurate representative points and average normal data, the basic implicit function field is recalculated only in the corresponding high-detail area, thereby updating the implicit function values of this local area. Finally, the Marching Cubes algorithm is called again to re-subdivide the updated small-range function field, and the generated high-precision grid patches replace the original rough grid patches. This series of "judgment-retrieval-update-subdivision" operations will continue as the viewpoint moves, thereby dynamically generating an adaptive multi-level-of-detail grid model.
[0101] The acquisition step of the cell complex basic data is:
[0102] Based on an adaptive multi-detail mesh model, the geodesic distance from all vertices to the reference point is calculated. Vertices, connected edges, and faces are introduced in ascending order of geodesic distance values, and then gradually expanded in sequence to form a cavity complex. A complete cavity complex sequence containing vertices, edges, and faces is constructed to obtain the basic data of the cavity complex.
[0103] Specifically, based on the adaptive multi-level-of-detail (MLD) mesh model, a unique reference point needs to be determined first. The selection of this reference point is crucial for subsequent calculations. It is chosen by traversing all vertices of the model and finding the vertex with the smallest Z-axis coordinate value in the preset coordinate system, designating it as the reference point. Then, using this reference point as the starting point, the geodesic distance from all other vertices on the model to this reference point is calculated; that is, the shortest path length along the model surface. This calculation is performed using Dijkstra's algorithm on the adaptive MLD mesh model. Specifically, the vertices of the mesh are treated as nodes of a graph, and the edges of the mesh are treated as edges of a graph. The weight of each edge is set to the Euclidean distance between its two endpoints. The algorithm starts from the reference point, setting its distance to 0, and initializing the distances of all other vertices to infinity. Then, a priority queue is used to iteratively access and update the distances of all vertices until the shortest distance to the reference point is calculated for all vertices. After obtaining the geodesic distance value for each vertex, all components of the model, including vertices, edges, and faces, are then processed according to... A filter is constructed by introducing vertices in a specific order, determined entirely by their geodesic distance values. First, all vertices are sorted in ascending order based on their geodesic distance values, forming an ordered list of vertices. Then, the cell complex is gradually expanded according to this vertex order. Specifically, an edge or face is added to the sequence only after all its constituent edges and other vertices have been introduced based on their geodesic distances. A more explicit definition of introduction time is that the introduction time of an edge is the larger of its two endpoints' geodesic distance values, and the introduction time of a face is the largest of its three vertices' geodesic distance values. Finally, all vertices, edges, and faces are uniformly sorted according to their respective introduction times (i.e., geodesic distance values). When the introduction times are the same, they are sorted according to the principle of dimension priority (vertices before edges, edges before faces). This constructs a complete cell complex sequence containing all vertices, edges, and faces of the model, strictly ordered by their geodesic distance values. This sequence is the basic data for the cell complex.
[0104] The steps to obtain the topological feature noise rank list are as follows:
[0105] Based on the basic data of the cell cavity complex, the topological feature noise rank is calculated using the following formula:
[0106] ;
[0107] in, For the first Dimensionless noise rank of a topological feature For the first The birth time value of each topological feature. For the first The death time value of each topological feature. For the first The lifecycle of a topological feature To prevent extremely small positive numbers with a denominator of zero, Sensitivity factor for dimensionless ratio;
[0108] Based on the topological feature noise rank, all topological feature points are traversed, and the topological feature noise ranks are summarized to generate a list of topological feature noise ranks.
[0109] Specifically, the formula: The advantage of the formula is that it provides the topological characteristic noise rank. The calculation formula can quantify and distinguish the true topological structure in a 3D model from false topological features introduced by point cloud noise or reconstruction algorithms, and determine the birth time of the topological features. Its life cycle The ratio, as the core metric, captures the degree of "precocity" of a feature. Typically, tiny bumps or holes caused by noise appear early in the filtering process (i.e., at small geodesic distance values). It is very small and will quickly disappear as it is filled by subsequently introduced units, i.e., its lifespan. It is very short, which leads to its noise rank Very large, on the contrary, the model's real macroscopic structures, such as a real hole or handle, have a birth time Relatively large, and life cycle Very long, calculated noise rank It will be very small, through the sensitivity factor This difference can be further amplified, making noise and salient structures clearly separated in terms of rank. This method does not depend on geometric dimensions, but judges purely from the perspective of topological durability, and therefore has strong robustness to various forms of noise.
[0110] For the first The birth time value of each topological feature. For the first The death time values of the topological features are directly derived from the persistent cohomology calculation of the basic data of the coelom complex obtained in the previous step. The persistent cohomology algorithm tracks the generation and destruction of topological features (such as connected components, loops, and cavities) in the coelom complex sequence during the filtering process. For the ... birth time of a topological feature the birth time of a topological feature the death time of a topological feature These pairs of values constitute the persistence diagram, which is the standard output of persistent homology analysis, for example, when processing the simplicial complex base data, the persistent homology analysis (such as Gudhi, Dionysus) will output a list, each item in the list records a pair of topological features, for example, for a 1-dimensional loop (topological feature) representing a tiny indentation, it is recorded as Here 5.2 and 5.4 are both geodesic distance values, in meters;
[0111] To prevent the denominator from being a very small positive number, this is a numerical stability parameter, used to handle a special case where the birth and death of a topological feature occur at exactly the same filter value , It can be set to ;
[0112] The sensitivity factor is a dimensionless ratio, which is a hyperparameter used to adjust the sensitivity of the noise rank to the ratio of the birth time and the life cycle, its role is to amplify or reduce the distinction between noise and significant structure, The choice of value depends on the specific application scenario and the statistical properties of the noise, the setting method is usually based on experience or determined by cross-validation, an effective setting process is, first prepare a small test model with known topological noise and significant structure annotation, then calculate the noise rank of all features under a series of candidate values (for example ), and use a preset rank threshold for classification, and finally select the value that makes the F1 score of the classification result (compared with the annotation) highest as the final parameter, for a typical three-dimensional laser point cloud reconstruction model, the noise usually manifests as high-frequency, small-scale features, experience shows that when the value is 2.0, it can well distinguish these noises, therefore, in this example, it is set to .
[0113] Calculation process:
[0114] Consider two pairs of topological features obtained from persistent homology analysis, one is a suspected noise feature, and the other is a suspected significant structure feature, and bring them into the formula to calculate their noise ranks.
[0115] Parameter settings: .
[0116] Example 1: Features of suspected noise (denoted as the first feature, k=1);
[0117] Persistence is .
[0118] Birth time value: ;
[0119] Time of death value: ;
[0120] life cycle: ;
[0121] Calculate the noise rank :
[0122] ;
[0123] Example 2: Features of suspected salient structures (denoted as the second feature, k=2);
[0124] Persistence is .
[0125] Birth time value: ;
[0126] Time of death value: ;
[0127] life cycle: ;
[0128] Calculate the noise rank :
[0129] ;
[0130] This result indicates that the noise rank of the first topological feature The calculated result is 676.0, which is a very large number, confirming its early birth. The relatively small size and extremely short lifetime of this characteristic make it a typical topological noise. The second topological feature is the noise rank. The calculated result is 0.1704, which is a very small value, reflecting the characteristic that its life cycle is much longer than its birth time. It is a typical salient topological structure. Through this formula, each topological feature in the model will obtain a noise rank, which will be used in subsequent classification steps.
[0131] Based on the topological feature noise rank, the system first traverses all topological features obtained from persistent homology analysis, and these features are persistent pairs. It exists in the form of, and the corresponding topological feature noise rank has been calculated for each feature. During the traversal, the unique identifier of each topological feature (e.g., its index number k in the persistent homology calculation result) is combined with its calculated topological feature noise rank. It is stored as a key-value pair. At the same time, for subsequent analysis and traceability, the dimension of the feature (0-dimensional represents a connected component, 1-dimensional represents a loop or tunnel, and 2-dimensional represents a cavity) and the birth time value are also recorded. and time of death value All this information (feature ID, noise rank, dimension, birth time, death time) is integrated together to form a series of structured records. After traversing all the topological feature points, these records are aggregated into a single data structure, usually a list or array. This data set, which contains all the topological features of the model and their quantified noise metrics, is called the topological feature noise rank list.
[0132] The steps for obtaining the categorical topological feature set are as follows:
[0133] Based on the list of topological feature noise ranks, the noise rank corresponding to each topological feature in the list is extracted item by item. The noise rank of each topological feature is compared with a pre-set rank threshold. If the noise rank of the topological feature is greater than the rank threshold, it is marked as a noise feature. If the noise rank of the topological feature is less than or equal to the rank threshold, it is marked as a significant structure, thus generating a categorized topological feature set.
[0134] Specifically, based on the topological feature noise rank list, the system begins to classify each topological feature. The core of this classification is comparing its noise rank with a pre-set rank threshold. Setting this threshold is crucial for distinguishing noise from salient structures. The method for setting this threshold is as follows: First, all noise ranks in the topological feature noise rank list are compared... Extract it and perform a logarithmic transformation on it, that is, calculate... Because the distribution of noise ranks is usually highly skewed, taking the logarithm can make its distribution closer to a normal distribution, facilitating analysis. Then, K-means clustering is applied to all log-transformed noise rank data, with a cluster size of 2. The K-means algorithm automatically divides these log values into two clusters: one corresponding to larger log values (high noise rank) and the other to smaller log values (low noise rank). Next, the boundary between these two clusters is found, i.e., the average of the minimum value in the high-value cluster and the maximum value in the low-value cluster is taken. This average is used as the threshold in the logarithmic space. Finally, this logarithmic threshold is subjected to an exponential transformation (i.e.,...). This yields the rank threshold in the original noise rank space. For example, after cluster analysis, the threshold for the logarithmic space is 3.5, so the original rank threshold is set to... After setting the rank threshold value, the program extracts the noise rank corresponding to each topological feature in the topological feature noise rank list one by one, and compares the noise rank of each topological feature with the threshold value 33.1. If the noise rank of the topological feature is greater than 33.1, the feature is marked as a "noise feature"; if the noise rank is less than or equal to 33.1, the feature is marked as a "significant structure". All features and their corresponding classification labels (noise feature or significant structure) are collected to generate a classified topological feature set.
[0135] The acquisition step of the topologically optimized three-dimensional model is:
[0136] Based on the classified topological feature set, all topological features marked as noise features are filtered, and the spatial position of each noise feature in the adaptive multi-detail level grid model is traced one by one. All edge elements and face elements corresponding to each noise feature are located to form a noise feature positioning set.
[0137] Based on the noise feature positioning set, all edge elements and face elements in the noise feature positioning set are deleted one by one in the adaptive multi-detail level grid model, and the grid elements are reconnected and filled and repaired through the local region boundary after topological cutting, to establish a topologically optimized three-dimensional model.
[0138] Specifically, based on the classified topological feature set, the system first starts the filtering program, which traverses each record in the classified topological feature set and only extracts topological features that are explicitly marked as "noise features". For each noise feature filtered out, the system will perform a tracing and positioning operation, which aims to accurately find the specific grid elements that constitute the noise feature in the adaptive multi-detail level grid model. The basis for tracing is the associated information recorded during the calculation of persistent homology. During the calculation of persistent homology, the system not only outputs the birth and death time pairs of each topological feature, but also records the "generator" and "annihilator" of each topological feature, i.e., which edge element or face element leads to the birth and death of the feature. For example, for a 1D ring marked as noise (representing a small hole or recess), the system reads the "generating edge" that leads to the formation of the ring and the "annihilating face" that eventually fills the ring from the associated information. These two elements are the core of the noise feature. Then, to completely locate the entire spatial region affected by the noise feature, the system takes all the vertices of these two core elements (the generating edge and the annihilating face) as the starting point and performs a restricted breadth-first search on the connection relationship graph of the adaptive multi-detail level grid model. The restriction condition of the search range is that only those vertices that have a geodesic distance value less than or equal to the death time value of the noise feature The process will continue to expand until no more adjacent units meeting the conditions can be found. All edge units and surface units visited during this search process are collectively identified as the complete spatial entities constituting the noise feature. The indices or pointers of these units are collected to form an independent set. The tracing and locating process is repeated for all filtered noise features. Finally, all independent unit sets are aggregated to form a noise feature positioning set.
[0139] Based on the noise feature positioning set, the system initiates a mesh optimization process. First, according to the indices of all edge units and surface units recorded in the noise feature positioning set, the system marks these units for deletion in the data structure of the adaptive multi-level detail mesh model. After marking all units to be deleted, the system performs a one-time batch deletion operation to remove all marked edge units and surface units from the model. This operation will create one or more holes at the location of the original topological noise. Each hole is surrounded by a ring of connected boundary edges. The next step is to repair the holes created by the topological cut. The system traverses each hole and first extracts the ordered vertex ring constituting the hole boundary by tracing the connection relationship of its boundary edges. For each unstructured polygon region defined by a vertex ring, the system uses the constrained Delaunay triangulation algorithm to fill it. This algorithm takes the boundary edges of the hole as a hard constraint and generates a series of new triangular facets inside the polygon. These newly generated facets completely cover the hole region and their boundaries match the original boundary edges exactly. During the triangulation process, to ensure the quality of the newly generated mesh, for larger or elongated holes, the algorithm is allowed to add new vertices, i.e., Steiner points, inside the hole to avoid generating poor-quality elongated triangles. After the initial filling, the system performs local smoothing and quality optimization on the newly generated mesh and its adjacent regions. Specifically, it performs 3 to 5 iterations of Laplace smoothing on all newly added Steiner points and vertices on the original boundary ring. Each iteration moves the vertex to the geometric center of its all adjacent vertices. Then, the system performs edge flip operations on the newly generated triangular facets and the original triangular facets sharing edges with them. It iteratively checks each internal edge and flips it if flipping the edge can increase the minimum internal angle of its adjacent two triangles. The process continues until no further mesh quality improvement can be achieved through edge flipping. After all holes have been processed through the deletion and repair process, a topologically optimized 3D model is finally obtained, which has removed minor topological noise, has a smoother surface, and has a more reasonable structure.
[0140] The above merely describes the preferred embodiments of the present application, and is not intended to limit the present application in other forms. Any skilled person in the art can modify or change the disclosed technical content into equivalent embodiments with equivalent changes, and apply them to other fields. However, any simple modification, equivalent change and modification made to the above embodiments according to the technical essence of the present application, without departing from the technical solution content of the present application, still falls within the protection scope of the present application.
Claims
1. A rendering method for creating a three-dimensional model based on a three-dimensional laser point cloud, characterized in that, The method comprises the following steps: The point cloud data file of the three-dimensional laser point cloud is sequentially read, the coordinate values of each point are inserted into an octree structure, when the octree node buffer in the memory is full, the node data in the buffer is written to the hard disk, the hard disk octree node set is traversed from bottom to top, and a hierarchical aggregated attribute octree is established; Based on the hierarchical aggregated attribute octree, a coarse level is selected, the representative point and the average normal in the node are called, a function field covering a three-dimensional model is constructed, a basic implicit function field is obtained, an isosurface of the basic implicit function field is extracted, and an adaptive multi-detail level grid model is generated according to the viewpoint distance and the memory limit; Based on the adaptive multi-detail level grid model, a cell complex sequence is constructed, cell complex basic data is obtained, each point in the cell complex basic data is traversed, the topological feature noise rank is calculated, and a topological feature noise rank list is obtained; Based on the topological feature noise rank list, each topological feature noise rank in the topological feature noise rank list is compared with a preset rank value threshold, a classified topological feature set is obtained, and a topologically optimized three-dimensional model is established according to the classified topological feature set; The obtaining step of the adaptive multi-detail level grid model is: Based on the basic implicit function field, the isosurface of each query position in the three-dimensional space is extracted, the node data of a deeper level of the hierarchical aggregated attribute octree is called to replace the implicit function value of the corresponding region under the condition of the viewpoint distance and the memory limit, the local function field is updated and re-subdivided block by block, and the adaptive multi-detail level grid model is generated; The obtaining step of the cell complex basic data is: Based on the adaptive multi-detail level grid model, the geodesic distance of all vertices to a reference point is calculated, the vertices and the connected edges and faces are sequentially introduced in the order of the geodesic distance value from small to large, and are gradually expanded to form a cell complex under the sequence, a complete cell complex sequence containing the vertices, the edges and the faces is constructed, and the cell complex basic data is obtained.
2. The rendering method of producing a three-dimensional model based on a three-dimensional laser point cloud according to claim 1, characterized in that, The obtaining step of the hierarchical aggregated attribute octree is: The point cloud data file of the three-dimensional laser point cloud is sequentially read, the three-dimensional coordinate values of each point in the file are parsed one by one, the parsed coordinate values of each point are sequentially inserted into a pre-created octree structure, when the storage capacity of the octree node buffer in the memory reaches the memory limit threshold during the insertion process, the buffer writing mechanism is triggered, all octree node data in the current buffer is written to the hard disk storage space as a whole, and a hard disk octree node set is formed; Based on the hard disk octree node set, the node data stored in the hard disk is traversed layer by layer in the order of the octree structure from bottom to top, the spatial geometric data information contained in all child nodes under each parent node is extracted one by one, the coordinate values and the normal vector information of the child nodes are combined, the representative point coordinate values, the average normal values and the error measurement values of each parent node are calculated according to the combined geometric data information, and a parent node geometric information aggregation set is generated; Based on the parent node geometry information aggregation set, the representative point coordinate value, the average normal value and the error measurement value of all parent nodes in the parent node geometry information aggregation set are re-inserted into the corresponding position of the parent node of the octree structure layer by layer, and the calculation is repeated layer by layer upwards until the whole octree structure is aggregated step by step to form a hierarchical aggregation attribute octree.
3. The rendering method of producing a three-dimensional model based on a three-dimensional laser point cloud according to claim 1, characterized in that, The obtaining step of the basic implicit function field is: Based on the hierarchical aggregation attribute octree, all nodes of the coarse level are located, and the representative point coordinate vector and the average normal vector stored in the node are extracted one by one. All representative point coordinate vectors and average normal vectors are traversed, mapped to each query position in the three-dimensional space, an initial function field covering the three-dimensional model is established, and initial function field data is obtained; According to the initial function field data, the basic implicit function field is calculated.
4. The rendering method of producing a three-dimensional model based on a three-dimensional laser point cloud according to claim 1, characterized in that, The obtaining step of the topology feature noise rank list is: According to the cell complex base data, the topology feature noise rank is calculated; Based on the topology feature noise rank, all topology feature points are traversed, the topology feature noise ranks are summarized, and the topology feature noise rank list is generated.
5. The rendering method of producing a three-dimensional model based on a three-dimensional laser point cloud according to claim 1, characterized in that, The obtaining step of the classified topology feature set is: Based on the topology feature noise rank list, the noise rank corresponding to each topology feature in the topology feature noise rank list is extracted one by one, and the noise rank of each topology feature is compared with the pre-set rank value threshold one by one. If the noise rank of the topology feature is greater than the rank value threshold, it is marked as a noise feature, and if the noise rank of the topology feature is less than or equal to the rank value threshold, it is marked as a significant structure, and a classified topology feature set is generated.
6. The rendering method of producing a three-dimensional model based on a three-dimensional laser point cloud according to claim 1, characterized in that, The obtaining step of the topology-optimized three-dimensional model is: Based on the classified topology feature set, all topology features marked as noise features are filtered, and the spatial position of each noise feature in the adaptive multi-detail level grid model is traced one by one. All edge elements and face elements corresponding to each noise feature are located to form a noise feature positioning set; Based on the noise feature positioning set, all edge elements and face elements in the noise feature positioning set are deleted one by one in the adaptive multi-detail level grid model, and the grid elements are reconnected and filled and repaired through the local area boundary after topological cutting to establish a topology-optimized three-dimensional model.
Citation Information
Patent Citations
Point cloud data storage method and apparatus
CN108804714A
Method and system for automatically extracting power tower component based on three-dimensional point cloud model
CN118657898A