Three-dimensional primitive extraction method and device based on building laser point cloud
By plane division and optimization of building laser point cloud data, normal vector and vector field intensity are calculated, and merging processing is performed, the problems of insufficient versatility and accuracy of 3D primitive extraction in the prior art are solved, and three-dimensional primitive extraction with high accuracy and reliability are achieved.
Patent Information
- Application Number
- CN202510056627.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-14
- Publication Date
- 2025-05-30
- Estimated Expiration
- 2045-01-14
AI Technical Summary
The existing three-dimensional primitive extraction methods have problems of insufficient universality and accuracy when processing building laser point cloud data, especially when processing different types of buildings and large amounts of point cloud data.
By obtaining the point cloud data of the building, dividing it into multiple initial planes and optimizing it, the normal vector of the midpoint of each plane is calculated, the initial intensity of the vector field is calculated based on the normal vector, and the vector field intensity is optimized through the energy function. Finally, the planes are merged based on the vector field intensity to obtain three-dimensional primitives.
It improves the accuracy and reliability of 3D primitive extraction, and is suitable for LiDAR point cloud data acquired by airborne and ground equipment.
Smart Images

Figure CN120070459A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of point cloud processing, and particularly to a method, device, storage medium and electronic device for extracting three-dimensional primitives based on building laser point clouds. Background Art
[0002] In the field of urban three-dimensional space data processing, point clouds generated by Light Detection and Ranging (LiDAR) have become an important type of data. By extracting primitives with clear features or shapes from discrete point clouds, it can provide an important basis for subsequent applications such as building model reconstruction, point cloud registration, and positioning and mapping. However, point cloud data has the characteristics of disorder, discreteness, and inconsistent density, which makes the boundaries between different three-dimensional primitives inside buildings often become blurred and difficult to define. In addition, buildings are usually composed of multiple different types of primitives, and a single predefined primitive template cannot effectively cover all possible primitive types, further increasing the complexity of the extraction process.
[0003] In existing primitive-level point cloud segmentation technologies, the methods can be roughly divided into two categories: supervised learning and unsupervised learning. Supervised learning methods are usually designed for specific scenarios, but there are significant deficiencies in accuracy when dealing with different types of building scenarios. Especially in outdoor building scenarios, limited by the performance of computer hardware, it is often difficult to process a large amount of point cloud data. Although unsupervised learning methods can be independent of labeled data and have better generality, they usually require preset primitive types, so they lack flexibility when facing different types of buildings. These challenges lead to deficiencies in the generality and accuracy of existing three-dimensional primitive extraction methods. Summary of the Invention
[0004] Embodiments of the present application provide a method, device, storage medium and electronic device for extracting three-dimensional primitives based on building laser point clouds, which can improve the accuracy of three-dimensional primitive extraction.
[0005] Embodiments of the present application provide a method for extracting three-dimensional primitives based on building laser point clouds, including: Obtaining the point cloud data of a building; Dividing the point cloud data into multiple initial planes and optimizing the initial planes to obtain optimized planes; Calculating the normal vectors of each point in each of the optimized planes respectively; Calculating the initial intensity of the vector field where each point is located based on the normal vectors and constructing an energy function to optimize the intensity of the vector field; Merging the optimized planes based on the vector field intensity to obtain three-dimensional primitives.
[0006] As a further improvement of the present invention, in the above three-dimensional primitive extraction method based on building laser point cloud, optimizing the initial plane includes: Merging two adjacent initial planes in the initial plane into one plane; Redividing one initial plane in the initial plane into two planes; Inserting the points without a belonging plane into the plane closest to the points; Removing a point that has been assigned an initial plane from the plane to which the point belongs.
[0007] As a further improvement of the present invention, in the above three-dimensional primitive extraction method based on building laser point cloud, calculating the initial intensity of the vector field where each point is located based on the normal vector includes: Calculating the initial intensity of the vector field where the target point is located through the first formula, and the first formula is:
[0008] Wherein, is the target point in its neighborhood is an adjacent point within it, is located at is the normal vector of point is located at is the normal vector of point is the point is the initial intensity of the vector field where the point is located.
[0009] As a further improvement of the present invention, in the above three-dimensional primitive extraction method based on building laser point cloud, the calculation formula of the energy function is:
[0010] Wherein, is the optimized vector field intensity of the point in the vector field, is the gradient of the vector field intensity, represents the transpose, represents the sum of the gradients of the vector field intensities of all points, represents the difference between the optimized vector field intensity and the initial intensity of the vector field, is the regularization term for balancing and .
[0011] As a further improvement of the present invention, in the above three-dimensional primitive extraction method based on building laser point cloud, the intensity of the optimized vector field is expressed as:
[0012]
[0013] Among them, is the point - based intensity Laplacian operator, representing the intensity difference of the vector field between the central point and the surrounding points, is the vector field intensity of the central point, are the K nearest neighboring points around the central point, is the average distance from the K neighboring points to the central point.
[0014] As a further improvement of the present invention, in the above - mentioned three - dimensional primitive extraction method based on building laser point cloud, wherein, the method further includes: To ensure that the energy function can be solved on a computer, add time to , so that the energy function is converted into a function related to time :
[0015]
[0016] Among them, represents the time interval of iterative solution, makes the partial differential function with respect to ; Combined with the definition of , finally, the numerical solution is expressed in the following form: .
[0017] As a further improvement of the present invention, in the above - mentioned three - dimensional primitive extraction method based on building laser point cloud, wherein, the merging of the optimized planes based on the vector field intensity to obtain three - dimensional primitives includes: Generate an adjacency relation table according to the adjacency between the optimized planes, and divide the points in the optimized planes into boundary points and internal points based on the adjacency relation table; Calculate the merging factor based on the vector field intensities of the boundary points and internal points, and merge the optimized planes with the merging factor less than the merging factor threshold; Taking the merged plane as the starting point, continue to find planes that can grow until there are no planes that can be merged, and the final merging result obtained is the three - dimensional primitive.
[0018] As a further improvement of the present invention, in the above - mentioned three - dimensional primitive extraction method based on building laser point cloud, wherein, after the step of dividing the point cloud data into multiple initial planes, it includes: Calculate the confidence of the initial plane, where the confidence includes fidelity, simplification degree, and integrity; The calculation formula for the fidelity is:
[0019] The calculation formula for the simplification degree is:
[0020] The calculation formula for the integrity is:
[0021] Among them, is the number of points covered within a plane , is the point to its corresponding plane Euclidean distance, is the total number of all planes segmented, is the number of segments of the initial plane segmentation, is the total number of points in the point cloud.
[0022] The embodiment of the present application also provides a three-dimensional primitive extraction device based on building laser point cloud, including: An acquisition module, configured to acquire the point cloud data of the building; A plane segmentation module, configured to divide the point cloud data into multiple initial planes and optimize the initial planes to obtain optimized planes; A first calculation module, configured to calculate the normal vector of each point in each of the optimized planes respectively; A second calculation module, configured to calculate the initial intensity of the vector field where each point is located based on the normal vector and construct an energy function to optimize the intensity of the vector field; A merging and generating module, configured to merge the optimized planes based on the vector field intensity to obtain three-dimensional primitives.
[0023] The embodiment of the present application also provides a computer-readable storage medium, in which multiple instructions are stored, and the instructions are suitable for being loaded by a processor to execute any one of the above three-dimensional primitive extraction methods based on building laser point cloud.
[0024] The embodiment of the present application also provides an electronic device, including a processor and a memory, the processor is electrically connected to the memory, the memory is used to store instructions and data, and the processor is used for the steps in any one of the above three-dimensional primitive extraction methods based on building laser point cloud.
[0025] The 3D primitive extraction method, device, storage medium and electronic device based on building laser point cloud provided by this application first divides the point cloud data into planes; then, uses confidence as the evaluation criterion for plane segmentation and iteratively performs four plane operations to optimize the segmentation result; then, takes the plane as the basic unit, estimates the normal vectors of the point cloud in the plane respectively and adjusts the normal vector directions of adjacent points. Next, calculates the initial value of the vector field intensity where the point cloud is located according to the normal vector of the point, and optimizes the vector field intensity by solving the energy function, so that the high-intensity region is located at the junction of 3D primitives, and the low-intensity region is located inside the 3D primitives. Finally, based on the difference in vector field intensity inside and at the boundary of the plane, obtains the final segmentation result through region growing. The method of the present invention realizes the automatic segmentation of different 3D primitives from the 3D point cloud of a building, has high accuracy and reliability, and is applicable to LiDAR point clouds obtained by airborne and ground equipment. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] The following will, with reference to the accompanying drawings, through a detailed description of the specific embodiments of this application, make the technical solutions and other beneficial effects of this application obvious.
[0027] Figure 1 It is a flowchart of the 3D primitive extraction method based on building laser point cloud provided by an embodiment of this application.
[0028] Figure 2 It is another flowchart of the 3D primitive extraction method based on building laser point cloud provided by an embodiment of this application.
[0029] Figure 3 It is a schematic structural diagram of the 3D primitive extraction device based on building laser point cloud provided by an embodiment of this application.
[0030] Figure 4 It is a schematic structural diagram of the electronic device provided by an embodiment of this application. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0031] The following will, with reference to the accompanying drawings in the embodiments of this application, clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the described embodiments are only a part of the embodiments of this application, rather than all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative efforts fall within the scope of protection of this application.
[0032] The embodiments of the present application provide a three-dimensional primitive extraction method, device, storage medium, and electronic device based on building laser point clouds. A three-dimensional primitive extraction device based on building laser point clouds provided by the embodiments of the present application can be integrated in an electronic device, which can be a device such as a terminal, a server, etc. Among them, the terminal can include a tablet computer, a laptop computer, a personal computer (PC), a microprocessing box, or other devices, etc.
[0033] Please refer to Figure 1 With Figure 2 , Figure 1 which is a flowchart of the three-dimensional primitive extraction method based on building laser point clouds provided by the embodiments of the present application. Figure 2 which is another flowchart of the three-dimensional primitive extraction method based on building laser point clouds provided by the embodiments of the present application. It is applied to an electronic device. The three-dimensional primitive extraction method based on building laser point clouds includes the following steps: S1. Obtain the point cloud data of the building.
[0034] S2. Divide the point cloud data into multiple initial planes and optimize the initial planes to obtain optimized planes.
[0035] First, use the RANSAC (Random Sample Consensus) algorithm to divide the obtained point cloud data of the building into multiple initial planes.
[0036] Then, use the plane confidence evaluation algorithm to judge the reliability of plane extraction. The calculation of confidence is composed of the sum of three parts: fidelity , simplification , and integrity . The calculation formulas of these three parts are as follows:
[0037]
[0038]
[0039] Among them, is the number of points covered within a plane , is the Euclidean distance from a point to its corresponding plane , is the total number of all planes segmented, is the number of initial plane segmentations, is the total number of points in the point cloud. The lower the confidence value, the higher the reliability of the segmentation result.
[0040] To improve the reliability of the plane extraction results, four plane optimization operations are designed in the embodiments of this application: (1) Merging between adjacent planes: Merging two adjacent initial planes in the initial planes into one plane; (2) Subdivision within a plane: Re-dividing one initial plane in the initial planes into two planes; (3) Inserting unassigned points: Inserting points without a belonging plane into the plane closest to them; (4) Removing assigned points: Removing a point that has been assigned an initial plane from its belonging plane. By repeatedly applying these four operations until no operation can improve the reliability of the segmentation result, the plane segmentation ends at this time.
[0041] According to the evaluation index of plane confidence, iteratively apply the above four plane optimization methods to improve the reliability of the segmentation result.
[0042] S3. Calculate the normal vectors of each point in each optimized plane respectively.
[0043] Taking the plane as a unit, use singular value decomposition (SVD) to estimate the normal vector of each point in the plane respectively. For the possible problem of inconsistent normal vector directions, taking the plane as a unit, gradually adjust the normal vectors of adjacent planes in a growing manner to ensure that in the final result, the normal vector directions of adjacent planes are consistent and continuous.
[0044] S4. Calculate the initial intensity of the vector field where each point is located based on the normal vector, and construct an energy function to optimize the intensity of the vector field.
[0045] First, based on the point cloud normal vector information, establish a vector field of the point cloud in space, where the direction of each point in the vector field is the normal vector direction of the point, and the initial intensity of the point is calculated by the following formula:
[0046] Where, is the target point in its neighborhood of adjacent points, is located at the normal vector of the point, is located at the normal vector of the point, is the point the initial intensity of the vector field where it is located.
[0047] Then, establish an energy function to optimize the intensity of the vector field, so that the points located at the junction of the primitives have a greater vector field intensity, and the intensity of the points located inside the primitives tends to 0. The energy function The calculation formula is as follows:
[0048] Where is the intensity after optimization at a point in the vector field, is the gradient of the vector field intensity, represents the transpose. represents the sum of the gradients of the vector field intensities at all points, and its goal is to use the gradient information to reduce the intensity of the vector field within the primitive. represents the difference between the optimized intensity and the initial intensity, and its goal is to increase the intensity of the vector field in the junction region of the primitive. is the regularization term used to balance and .
[0049] The optimization result of the energy function is:
[0050]
[0051] Where is the Laplacian operator based on the intensity of the point, which represents the difference in the vector field intensities between the central point and the surrounding points. is the vector field intensity of the central point, are the K nearest neighboring adjacent points around this point, is the average distance from the K adjacent points to the central point.
[0052] To ensure that the energy function can be solved on a computer, time is added to , so that the energy function is transformed into a function related to time , and then its numerical solution can be obtained as a partial differential equation:
[0053]
[0054] Where, represents the time interval for iterative solution, makes the partial differential function with respect to . Combining with the definition of , the numerical solution can finally be expressed in the following form:
[0055] S5. Merge the optimized planes based on the vector field intensity to obtain a three-dimensional primitive.
[0056] Specifically, step S5 includes the following steps: S51. Generate an adjacency relation table according to the adjacency between the optimized planes, and divide the points in the optimized planes into boundary points and interior points based on the adjacency relation table.
[0057] Specifically, generate an adjacency relation table according to the adjacency relation between the planes, and divide the points in the plane into two categories: boundary points and interior points. A boundary point is a point whose K-nearest neighbors include points belonging to other planes. An interior point is a point whose K-nearest neighbors all belong to the same plane as this point.
[0058] S52. Calculate a merging factor based on the vector field intensities of the boundary points and interior points, and merge the optimized planes with the merging factor less than the merging factor threshold.
[0059] Based on the vector field intensity at the boundary between the planes, merge the planes belonging to the same primitive. The judgment criterion for the merging factor The calculation formula is:
[0060] Wherein, and are the vector field intensities of the boundary points and interior points respectively, and are the numbers of the boundary points and interior points. If the of a pair of adjacent planes are both less than the merging factor threshold, they can be merged.
[0061] S53. Starting from the merged plane, continue to find the planes that can be grown until there are no planes that can be merged. The final merging result obtained is the three-dimensional primitive.
[0062] In this application, the point cloud data is first segmented into planes; then, using the confidence as the evaluation criterion for plane segmentation, four plane operations are iteratively performed to optimize the segmentation result; then, taking the plane as the basic unit, the normal vectors of the point clouds in the plane are estimated respectively and the normal vector directions of adjacent points are adjusted. Next, the initial value of the vector field intensity where the point cloud is located is calculated according to the normal vector of the point, and the vector field intensity is optimized by solving the energy function, so that the high-intensity region is located at the junction of the three-dimensional primitives and the low-intensity region is located inside the three-dimensional primitives. Finally, based on the difference in the vector field intensities inside and at the boundary of the plane, the final segmentation result is obtained through the region growing method. The method of the present invention realizes the automatic segmentation of different three-dimensional primitives from the three-dimensional point cloud of the building, has high accuracy and reliability, and is applicable to the LiDAR point cloud obtained by airborne and ground equipment.
[0063] According to the method described in the above embodiments, this embodiment will be further described from the perspective of a three-dimensional primitive extraction device based on building laser point cloud. The three-dimensional primitive extraction device based on building laser point cloud can be specifically implemented as an independent entity, or integrated in an electronic device, which can be a device such as a terminal, a server, etc. Among them, the terminal can include a tablet computer, a notebook computer, a personal computer (PC), a microprocessing box, or other devices, etc.
[0064] Please refer to Figure 3 , Figure 3 which specifically describes the three-dimensional primitive extraction device based on building laser point cloud provided in the embodiments of the present application, applied in an electronic device. The three-dimensional primitive extraction device based on building laser point cloud may include: An acquisition module, configured to acquire the point cloud data of a building; A plane segmentation module, configured to divide the point cloud data into multiple initial planes, and optimize the initial planes to obtain optimized planes; A first calculation module, configured to calculate the normal vectors of each point in each of the optimized planes respectively; A second calculation module, configured to calculate the initial intensity of the vector field where each point is located based on the normal vectors, and construct an energy function to optimize the intensity of the vector field; A merging and generating module, configured to merge the optimized planes based on the vector field intensity to obtain three-dimensional primitives.
[0065] In specific implementation, each of the above modules and / or units can be implemented as an independent entity, or can be combined arbitrarily to be implemented as the same or several entities. The specific implementation of each of the above modules and / or units can refer to the foregoing method embodiments, and the specific beneficial effects that can be achieved can also be referred to the beneficial effects in the foregoing method embodiments, which will not be elaborated herein.
[0066] In addition, the embodiments of the present application further provide an electronic device, which can be a device such as a computer, a tablet computer, etc. The electronic device can implement the steps in any of the embodiments of the three-dimensional primitive extraction method based on building laser point cloud provided in the embodiments of the present application. Therefore, it can achieve the beneficial effects that any of the three-dimensional primitive extraction methods based on building laser point cloud provided in the embodiments of the present invention can achieve. For details, please refer to the foregoing embodiments, which will not be elaborated herein.
[0067] Figure 4The specific structural block diagram of the electronic device provided by the embodiment of the present invention is shown. This electronic device can be used to implement the three-dimensional primitive extraction method based on the building laser point cloud provided in the above embodiment. The electronic device 500 can be a device such as a terminal or a server. Among them, the terminal can include a tablet computer, a notebook computer, a personal computer (PC), a microprocessing box, or other devices, etc.
[0068] The RF circuit 510 is used to receive and send electromagnetic waves, realize the mutual conversion between electromagnetic waves and electrical signals, so as to communicate with a communication network or other devices. The RF circuit 510 may include various existing circuit elements for performing these functions. For example, antennas, radio frequency transceivers, digital signal processors, encryption / decryption chips, subscriber identity module (SIM) cards, memories, and so on. The RF circuit 510 can communicate with various networks such as the Internet, enterprise intranets, wireless networks, or communicate with other devices through a wireless network. The above wireless network may include a cellular phone network, a wireless local area network, or a metropolitan area network. The above wireless network can use various communication standards, protocols, and technologies, including but not limited to the Global System for Mobile Communication (GSM), Enhanced Data GSM Environment (EDGE), Wideband Code Division Multiple Access (WCDMA), Code Division Access (CDMA), Time Division Multiple Access (TDMA), Wireless Fidelity (Wi-Fi) (such as the Institute of Electrical and Electronics Engineers standards IEEE 802.11a, IEEE 802.11b, IEEE 802.11g, and / or IEEE 802.11n), Voice over Internet Protocol (VoIP), Worldwide Interoperability for Microwave Access (Wi-Max), other protocols for email, instant messaging, and short messages, and any other suitable communication protocols, and even those protocols that have not been developed yet.
[0069] The memory 520 can be used to store software programs and modules, such as the corresponding program instructions / modules in the above embodiments. The processor 580 executes various functional applications and data processing by running the software programs and modules stored in the memory 520, that is, to implement functions such as taking pictures with the front camera, processing the captured images, and switching the display colors of the display content on the display screen. The memory 520 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memories, or other non-volatile solid-state memories. In some instances, the memory 520 may further include a memory remotely disposed relative to the processor 580, and these remote memories can be connected to the electronic device 500 through a network. Examples of the above network include but are not limited to the Internet, enterprise intranet, local area network, mobile communication network, and combinations thereof.
[0070] The input unit 530 can be used to receive input digital or character information, and generate a keyboard and a mouse related to user settings and function controls. The display unit 540 can be used to display information input by the user or information provided to the user, as well as various graphical user interfaces, and these graphical user interfaces can be composed of graphics, text, icons, videos, and any combination thereof. The display unit 540 may include a display panel 541. Optionally, the display panel 541 can be configured in the form of an LCD (Liquid Crystal Display) or an OLED (Organic Light-Emitting Diode).
[0071] The audio circuit 560, the speaker 561, and the microphone 562 can provide an audio interface between the user and the electronic device 500. The audio circuit 560 can transmit the converted electrical signal of the received audio data to the speaker 561, and the speaker 561 converts it into a sound signal for output; on the other hand, the microphone 562 converts the collected sound signal into an electrical signal, which is received by the audio circuit 560 and then converted into audio data. After the audio data is output to the processor 580 for processing, it is sent to another terminal, such as through the RF circuit 510, or the audio data is output to the memory 520 for further processing. The audio circuit 560 may also include an earphone jack to provide communication between the peripheral earphone and the electronic device 500.
[0072] The electronic device 500 can help the user receive requests, send information, etc. through the transmission module 570 (such as a Wi-Fi module), and it provides the user with wireless broadband Internet access. Although the transmission module 570 is shown in the figure, it can be understood that it does not belong to the essential composition of the electronic device 500 and can be omitted completely as needed without changing the essence of the invention.
[0073] The processor 580 is the control center of the electronic device 500, connecting various parts of the entire mobile phone through various interfaces and circuits. By running or executing software programs and / or modules stored in the memory 520, and by calling the data stored in the memory 520, it executes various functions of the electronic device 500 and processes data, thereby monitoring the electronic device as a whole. Optionally, the processor 580 may include one or more processing cores; in some embodiments, the processor 580 may integrate an application processor and a modem processor. Among them, the application processor mainly processes the operating system, user interface, application programs, etc., and the modem processor mainly processes wireless communication. It can be understood that the above-mentioned modem processor may not be integrated into the processor 580 either.
[0074] The electronic device 500 further includes a power supply 590 (such as a battery) for supplying power to each component. In some embodiments, the power supply can be logically connected to the processor 580 through a power management system, so as to realize functions such as management of charging, discharging, and power consumption management through the power management system. The power supply 590 may also include any components such as one or more DC or AC power supplies, a recharge system, a power failure detection circuit, a power converter or inverter, and a power status indicator.
[0075] Although not shown, the electronic device 500 further includes a camera (such as a front camera and a rear camera), a Bluetooth module, etc., which will not be elaborated here. Specifically, in this embodiment, the display unit of the electronic device is a touch screen display, and the mobile terminal further includes a memory, and one or more programs, where one or more programs are stored in the memory and are configured to be executed by one or more processors. One or more programs include instructions for performing the following operations: Obtain the point cloud data of the building; Divide the point cloud data into multiple initial planes, and optimize the initial planes to obtain optimized planes; Calculate the normal vectors of each point in each of the optimized planes respectively; Based on the normal vectors, calculate the initial intensity of the vector field where each point is located, and construct an energy function to optimize the intensity of the vector field; Based on the vector field intensity, merge the optimized planes to obtain three-dimensional primitives.
[0076] In specific implementation, the above-mentioned each module can be implemented as an independent entity, or can be combined arbitrarily to be implemented as the same or several entities. For the specific implementation of the above-mentioned each module, reference can be made to the foregoing method embodiments, which will not be elaborated here.
[0077] Those of ordinary skill in the art can understand that all or part of the steps in the various methods of the above embodiments can be completed by instructions or by controlling relevant hardware through instructions. The instructions can be stored in a computer-readable storage medium and loaded and executed by a processor. To this end, an embodiment of the present invention provides a storage medium storing multiple instructions that can be loaded by a processor to execute the steps of any one of the embodiments of the three-dimensional primitive extraction method based on building laser point clouds provided by the embodiments of the present invention.
[0078] Among them, the computer-readable storage medium may include: read-only memory (ROM, Read Only Memory), random access memory (RAM, Random Access Memory), magnetic disk or optical disc, etc.
[0079] Since the instructions stored in the storage medium can execute the steps in any one of the embodiments of the three-dimensional primitive extraction method based on building laser point clouds provided by the embodiments of the present invention, the beneficial effects achievable by any of the three-dimensional primitive extraction methods based on building laser point clouds provided by the embodiments of the present invention can be realized. For details, see the previous embodiments and will not be elaborated here.
[0080] The above has introduced in detail a three-dimensional primitive extraction method, device, storage medium, and electronic device based on building laser point clouds provided by the embodiments of the present application. Specific examples are used in this article to elaborate on the principle and implementation manner of the present application. The description of the above embodiments is only used to help understand the method and its core idea of the present application; at the same time, for those skilled in the art, according to the idea of the present application, there will be changes in the specific implementation manner and application scope. In summary, the content of this specification should not be construed as a limitation to the present application.
Claims
1. A three-dimensional primitive extraction method based on building laser point cloud, characterized in that: The method comprises: Get point cloud data of buildings; Dividing the point cloud data into a plurality of initial planes, and optimizing the initial planes to obtain optimized planes; Calculating respectively the normal vector of each point in each optimized plane; Calculating the initial strength of the vector field at each point based on the normal vector, and constructing an energy function to optimize the strength of the vector field; The optimized planes are merged based on the vector field strength to obtain a three-dimensional primitive.
2. The method for extracting three-dimensional primitives based on building laser point cloud according to claim 1, characterized in that: Optimizing the initial plane includes: Merging two adjacent initial planes among the initial planes into one plane; Re-dividing one of the initial planes into two planes; Insert the point that does not belong to a plane into the plane closest to the point; Removes a point that has been assigned an initial plane from the plane to which the point belongs.
3. The method for extracting three-dimensional primitives based on building laser point cloud according to claim 1, characterized in that: The calculating the initial strength of the vector field at each point based on the normal vector comprises: The initial strength of the vector field where the target point is located is calculated by the first formula, and the first formula is: in, It is the target point In its neighborhood The adjacent points within is located in The normal vector of a point, is located in The normal vector of a point, For point The initial strength of the vector field.
4. The method for extracting three-dimensional primitives based on building laser point cloud according to claim 1, characterized in that: The calculation formula of the energy function is: in, is the vector field strength after optimization of the points in the vector field, is the gradient of the vector field strength, represents transpose, represents the gradient sum of the vector field strength at all points, To represent the difference between the optimized vector field strength and the initial strength of the vector field, is a regular term used to balance and .
5. The method for extracting three-dimensional primitives based on building laser point cloud according to claim 1, characterized in that: The strength of the optimized vector field is expressed as: in, It is a point-based intensity Laplace operator, which represents the difference in the vector field intensity between the center point and the surrounding points. is the vector field strength at the center point, are the K nearest neighboring points around the center point, is the average distance from K adjacent points to the center point.
6. The method for extracting three-dimensional primitives based on building laser point cloud according to claim 5, characterized in that: The method further comprises: To ensure that the energy function can be solved in the computer, Add time , so that the energy function Turn to time Related functions: in, represents the time interval of iterative solution, Make about The partial differential function of ; Combination The definition of , finally the numerical solution is expressed as follows: 。 7. The method for extracting three-dimensional primitives based on building laser point cloud according to claim 1, characterized in that: The step of merging the optimized planes based on the vector field strength to obtain a three-dimensional primitive comprises: According to the adjacency between the optimized planes, an adjacency relationship table is generated, and based on the adjacency relationship table, the points in the optimized plane are divided into boundary points and internal points; Calculating a merging factor based on the vector field strength of the boundary points and the internal points, and merging the optimized planes whose merging factors are less than a merging factor threshold; Taking the merged plane as the starting point, continue to look for planes that can grow until there are no planes that can be merged. The final merged result is the three-dimensional primitive.
8. The method for extracting three-dimensional primitives based on building laser point cloud according to claim 1, characterized in that: After the step of dividing the point cloud data into a plurality of initial planes, the method further comprises: Calculating the confidence of the initial plane, wherein the confidence includes fidelity, simplification and completeness; The calculation formula of the fidelity is: The calculation formula of the simplification degree is: The calculation formula of the completeness is: in, Is a plane The number of points covered in Yes To its corresponding plane The Euclidean distance of is the number of all planes segmented, is the number of initial plane splits, is the total number of points in the point cloud.
9. A three-dimensional primitive extraction device based on building laser point cloud, characterized in that: include: An acquisition module, used to acquire point cloud data of buildings; A plane segmentation module, used for dividing the point cloud data into a plurality of initial planes, and optimizing the initial planes to obtain optimized planes; A first calculation module, used for respectively calculating the normal vector of each point in each optimized plane; In the second calculation module, the user calculates the initial strength of the vector field at each point based on the normal vector, and constructs an energy function to optimize the strength of the vector field; The merging generation module is used to merge the optimized planes based on the vector field strength to obtain a three-dimensional primitive.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a plurality of instructions, and the instructions are suitable for being loaded by a processor to execute the three-dimensional primitive extraction method based on building laser point cloud according to any one of claims 1 to 8.
Citation Information
Patent Citations
Three-dimensional primitive data extraction method and device and storage medium
CN112070005A
Building roof automatic modeling method based on airborne LiDAR point cloud
CN113313835A
Systems and methods for processing 2D / 3D data for structures of interest in a scene and wireframes generated therefrom
US11043026B1
Single building three-dimensional reconstruction method based on point cloud semantic segmentation and structure fitting
WO2024077812A1