Pipe reverse modeling system and method based on point cloud data

By improving filtering and feature extraction algorithms and using an operating condition adaptation optimization unit, the problems of noise processing, feature extraction, and operating condition matching in reverse modeling of petrochemical pipelines are solved, achieving efficient and accurate reverse modeling of petrochemical pipelines. This model is applicable to industrial pipeline modeling in industries such as petrochemical, chemical, power, and metallurgy.

CN122115743APending Publication Date: 2026-05-29智汇(天津)工程设计院有限公司
View PDF 10 Cites 0 Cited by

Patent Information

Application Number
CN202610552085.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-04-24
Publication Date
2026-05-29

AI Technical Summary

Technical Problem

Existing reverse modeling technologies for petrochemical pipelines suffer from severe noise interference in point cloud data, low accuracy in pipeline feature extraction, poor matching between the model and actual operating conditions, and low automation of the modeling process, making it difficult to meet the needs of large-scale pipeline reverse modeling for petrochemical plants.

Method used

An improved bilateral filtering algorithm is used to dynamically adjust the filtering parameters. Combined with an improved RANSAC algorithm and PointNet++ model, high-quality processing of point cloud data and pipeline feature extraction are achieved. The model parameters are adjusted through a working condition adaptation optimization unit to match the model with the actual working conditions. Multi-source point cloud acquisition and parametric model reconstruction technology are used to improve modeling accuracy and efficiency.

Benefits of technology

It significantly improves point cloud quality and pipeline feature extraction accuracy, increases modeling efficiency, achieves high-precision working condition adaptation, meets engineering simulation and strength verification requirements, and shortens the modeling cycle by more than 60%.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122115743A_ABST
    Figure CN122115743A_ABST
Patent Text Reader

Abstract

The application provides a pipeline reverse modeling system and method based on point cloud data, relates to the fields of three-dimensional modeling and petrochemical engineering, and comprises a plurality of source point cloud acquisition units, a point cloud preprocessing unit, a pipeline feature extraction unit, a parameterized model reconstruction unit, a working condition adaptation optimization unit, a model verification unit and a database unit connected with the above units in sequence. According to the application, the filtering parameters are dynamically adjusted according to the local density of the point cloud, the noise processing effect is excellent, the quality of the point cloud is improved, the precise fitting of the axis is realized by improving the RANSAC algorithm, the curved pipeline is adapted by combining the segmented processing, the pipeline feature extraction precision is improved, the improved PointNet++ model is used to realize the automatic identification of the auxiliary components, the local density correction is introduced into the pipe diameter measurement, the measurement precision is improved, the working condition adaptation optimization unit is introduced to make the model deeply adapt to the actual working condition, and the high-precision, high-efficiency and working condition-adapted petrochemical pipeline reverse modeling is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of 3D modeling and petrochemical engineering technology, and specifically to a pipeline reverse modeling system and method based on point cloud data. Background Technology

[0002] Petrochemical pipelines, as core infrastructure of the petrochemical industry, are responsible for transporting materials such as crude oil, natural gas, and chemical media. Their operational safety and stability directly affect the production efficiency and safety of the entire petrochemical plant. With the rapid development of the petrochemical industry, many pipelines built in the early stages have entered a critical period of operation and maintenance. It is necessary to establish accurate digital models of the pipelines using 3D modeling technology to provide data support for pipeline inspection, corrosion detection, and capacity expansion.

[0003] Reverse modeling is an effective means of obtaining 3D models of existing solid structures. It reconstructs a 3D model consistent with the physical object by collecting its geometric data. Currently, reverse modeling of petrochemical pipelines mainly employs point cloud data acquisition and processing technology. Point cloud data of the pipeline surface is acquired using equipment such as laser scanning, and then processed through point cloud processing, feature extraction, and model reconstruction to complete the reverse modeling. However, existing technologies face the following challenges in practical applications: 1. Severe noise interference in point cloud data: Petrochemical pipelines are mostly located in complex industrial environments. The scanning process is easily affected by factors such as equipment vibration, ambient light, dust, and oil stains on the pipeline surface, resulting in a large number of noise points and outliers in the point cloud data. Existing filtering algorithms (such as traditional bilateral filtering and Gaussian filtering) mostly use fixed parameters and cannot be dynamically adjusted according to the density distribution and surface features of the pipeline point cloud, resulting in incomplete noise removal or loss of effective features.

[0004] 2. Low accuracy in extracting pipeline features: Petrochemical pipelines are mostly cylindrical structures and contain various auxiliary components such as welds, flanges, and valves. Existing axis fitting methods (such as the traditional RANSAC algorithm) are easily affected by local point cloud deviations, resulting in a large deviation between the axis direction and the actual direction. Pipe diameter measurement often uses the simple average distance method, which does not consider factors such as pipe surface roughness and local deformation, resulting in insufficient measurement accuracy. The identification of auxiliary components often relies on manual annotation or simple geometric feature matching, which is inefficient and prone to missed detections and false detections.

[0005] 3. Poor matching between model and actual operating conditions: Existing modeling methods only focus on the geometric reconstruction of pipelines and do not consider the operating conditions of petrochemical pipelines in actual operation, such as temperature, pressure, and media corrosion. This results in differences between the reconstructed model and the physical state of the actual pipeline (such as thermal expansion deformation and wall thickness reduction due to corrosion), which cannot meet the high-precision application requirements of engineering simulation, strength verification, etc.

[0006] 4. Low level of automation in the modeling process: In existing technologies, multi-view point cloud registration, feature extraction, component assembly and other steps often require manual intervention and adjustment, resulting in long modeling cycles and low efficiency, which is difficult to meet the reverse modeling needs of large-scale pipelines in petrochemical plants.

[0007] To address the aforementioned issues, some improvements have been proposed in existing technologies. For example, patent CN121280509A discloses a pipeline detection method based on laser point clouds, which uses point cloud data of pipe diameters from different pipe sections to perform AI reconstruction of the pipeline and employs the RANSAC algorithm to fit the pipeline axis. However, this method has not been adapted and optimized for the complex operating conditions of petrochemical pipelines, and the cross-sectional diagram error and IMU drift error of the AI ​​reconstruction are relatively large, as well as the recognition accuracy for auxiliary components (such as welds, flanges, valves, etc.) is insufficient. Patent CN121353546A discloses a pipeline modeling method based on adaptive statistical filtering, which uses adaptive threshold filtering to remove noise. However, the adjustment logic of the filtering parameters is simple, and there are still significant deficiencies in the feature extraction accuracy and operating condition adaptability of pipeline modeling. Summary of the Invention

[0008] In view of this, the purpose of this invention is to address the aforementioned deficiencies in existing technologies by developing a pipeline reverse modeling system and method based on point cloud data. This system employs an improved bilateral filtering algorithm, dynamically adjusting filtering parameters according to the local density of the point cloud. This effectively eliminates noise and outliers while preserving key pipeline features, improving noise processing and point cloud quality. An improved RANSAC algorithm achieves accurate axis fitting, and a segmented processing mechanism adapts to curved pipelines, enhancing pipeline feature extraction accuracy. An improved PointNet++ model enables automatic identification of auxiliary components, and local density correction is introduced for pipe diameter measurement to improve measurement accuracy. A working condition adaptation optimization unit is introduced, adjusting parameters such as thermal expansion, wall thickness, and corrosion thinning based on actual working condition data such as temperature, pressure, and media type. This ensures the model deeply adapts to actual working conditions, reflecting not only the pipeline's geometry but also matching its physical state during actual operation, enhancing engineering practicality. This invention solves the technical problems of poor point cloud noise processing, low accuracy in pipeline feature extraction, insufficient model-to-actual-condition matching, and low modeling efficiency in existing technologies, achieving high-precision, high-efficiency, and working-condition-adaptive reverse modeling of petrochemical pipelines.

[0009] This invention provides a pipeline reverse modeling system based on point cloud data, comprising: a multi-source point cloud acquisition unit, a point cloud preprocessing unit, a pipeline feature extraction unit, a parametric model reconstruction unit, a working condition adaptation and optimization unit, and a model verification unit connected in sequence, as well as a database unit connected to each of the aforementioned units respectively. The multi-source point cloud acquisition unit is the source of modeling data. It uses a multi-source acquisition device composed of a laser scanner, a structured light scanner, and an industrial camera to achieve all-round, high-precision scanning of petrochemical pipelines and their auxiliary components, acquire multi-view point cloud data including the pipeline body, welds, flanges, and valves, and transmit the data to the database unit for storage. Specifically, laser scanners are used to acquire long-distance, large-area point cloud data of pipelines, with a scanning accuracy of ±0.1mm; structured light scanners are used for close-range scanning of detailed components such as pipeline welds and flanges to acquire high-density point clouds; industrial cameras simultaneously acquire pipeline surface image information, providing data support for subsequent point cloud intensity value analysis. During the acquisition process, the multi-source point cloud acquisition unit simultaneously records the GPS coordinates and attitude information of the scanning equipment to ensure the basis for registration of multi-view point cloud data; after acquisition, the multi-source point cloud data is transmitted to the database unit for storage, supporting subsequent retrieval and backtracking.

[0010] The parametric model reconstruction unit is used to construct a parametric three-dimensional model of the petrochemical pipeline by calling the standard pipeline model library and component model library in the database unit according to the pipeline axis, pipe diameter and auxiliary component characteristic parameters, and through Boolean operation and surface stitching technology. Specifically, the parametric model reconstruction unit constructs a complete 3D model of the petrochemical pipeline based on the extracted feature parameters. First, it calls the standard pipeline model library in the database unit and generates a 3D curved surface model of the pipeline body according to the axis parameters and pipe diameter: for straight pipelines, a cylindrical surface is directly generated using the axis and pipe diameter; for curved pipelines, multiple cylindrical surfaces are generated by segmenting the axis and pipe diameter, and then a smooth transition is achieved through surface stitching technology. Then, based on the feature parameters of auxiliary components, it calls the corresponding standard component model library (such as the HG / T20615 flange standard library and the GB / T12224 valve standard library), and assembles components such as welds, flanges, and valves to their corresponding positions in the pipeline body model through coordinate positioning (aligning the component's center point with the identified position coordinates) and attitude adjustment (adjusting the installation angle according to the component's normal vector). Finally, Boolean operations are used to fuse the component models, eliminate assembly gaps, optimize the model surface smoothness, and generate a parametric 3D model of the petrochemical pipeline. All features of the model (axis, pipe diameter, component dimensions) can be modified through parameter adjustment, facilitating subsequent engineering applications.

[0011] The operating condition adaptation and optimization unit is a key technical aspect of this invention for adapting to the actual needs of petrochemical engineering. It is used to acquire actual operating condition data (temperature, pressure, medium type, and service life) of petrochemical pipelines, and based on finite element analysis algorithms, adjusts the pipe wall thickness, weld strength, and flange sealing performance of the three-dimensional model to ensure consistency between the model and the physical state of the pipeline under actual operating conditions. By combining actual operating condition data, the model parameters are adjusted to ensure consistency between the model and the physical state of the actual pipeline. Preferably, the optimization method of the operating condition adaptation and optimization unit is as follows: calculating the thermal expansion of the pipeline based on temperature data. ΔL = α·L0·ΔT (α is the coefficient of linear expansion of the pipe material) L0 This is the original length of the pipe. ΔT The model's axis length is adjusted based on the difference between the actual temperature and ambient temperature. According to the pressure data and medium type, and in accordance with the "Design Code for Industrial Metal Pipelines," the pipe wall thickness is checked to ensure it meets strength requirements. If not, the model's wall thickness parameters are adjusted. The specific optimization process is as follows: The first step is to obtain the actual operating data of the target pipeline, including operating temperature T, operating pressure P, type of transported medium M (such as crude oil, natural gas, corrosive chemical media), and years of operation Y. This data can be obtained through the production management system and pipeline monitoring equipment of petrochemical enterprises, or manually entered.

[0012] The second step is thermal expansion adaptation: based on the linear expansion coefficient α of the pipe material (e.g., α = 11.5 × 10⁻⁶ for carbon steel). -6 / ℃), original length of pipeline L0 The difference between actual temperature and room temperature ΔT = T Calculate the thermal expansion of the pipeline at -25℃. Adjust the axis length of the model to make the model reflect the thermal expansion state of the pipeline under actual working conditions.

[0013] The third step is strength adaptation: based on the working pressure P and the medium type M, and in accordance with the "Code for Design of Industrial Metal Piping" (GB50316), the strength calculation formula is used. ,in, s For pipe wall stress, D The inner diameter of the pipe. d For wall thickness, For weld coefficient; check whether the pipe wall thickness meets the strength requirements; if s If [σ]t (where [σ]t is the allowable stress of the material at temperature T) is greater than or equal to the allowable stress of the material at temperature T, then the wall thickness parameter of the model should be increased appropriately, or the weld size should be adjusted to ensure that the strength characteristics of the model are consistent with those of the actual pipeline.

[0014] Step 4, Corrosion Adaptation: Based on the corrosion level (e.g., mild, moderate, severe corrosion) of the medium type M and the service life Y, refer to the "Design Code for Corrosion Protection of Coatings for Petrochemical Equipment and Pipelines" to calculate the corrosion thinning amount Δ of the pipeline. d =k·Y (k is the annual corrosion rate, determined according to the type of medium), adjust the wall thickness parameters of the model to match the corrosion state of the actual pipeline; for components such as flanges and valves, adjust their sealing surface dimensions and bolt strength parameters according to the corrosion level.

[0015] The database unit is used to store multi-source point cloud data, preprocessed point cloud data, feature parameter data, standard model library (pipes, welds, flanges, valves), operating condition data, and the final reconstructed model.

[0016] The database unit provides data support for the entire system, storing the following: raw point cloud data and image data acquired by the multi-source point cloud acquisition unit; registered point clouds, denoised point clouds, and downsampled point clouds output by the point cloud preprocessing unit; axis parameters, pipe diameter data, and auxiliary component feature parameters output by the pipeline feature extraction unit; a standard model library (containing standard pipe models of different diameters and materials, as well as standard models of components such as welds, flanges, and valves, conforming to national and industry standards); operating condition data (temperature, pressure, media type, operating years, etc.); and the final reconstructed 3D model data. The database unit supports adding, deleting, modifying, querying, backing up, and exporting data, facilitating subsequent model updates and maintenance.

[0017] Furthermore, the point cloud preprocessing unit is used to improve the quality of point cloud data and lay the foundation for subsequent feature extraction, including a coordinate alignment module, an adaptive noise filtering module, and a data downsampling module; The coordinate alignment module is used to convert multi-view point cloud data to a unified world coordinate system; Specifically, the coordinate alignment module uses the GPS coordinates and attitude information recorded during the acquisition process and employs the ICP (Iterative Closest Point) algorithm to register multi-view point cloud data to a unified world coordinate system. The specific process is as follows: select one set of point clouds as the target point cloud and the remaining point clouds as the source point clouds. By iteratively calculating the optimal transformation matrix (rotation matrix + translation matrix) between the source and target point clouds, the average distance between the source and target point clouds is minimized, ultimately achieving coordinate unification of all point cloud data and eliminating viewpoint bias.

[0018] The adaptive noise filtering module employs an improved bilateral filtering algorithm, which, combined with the density distribution characteristics of pipeline point clouds, dynamically adjusts the filtering parameters to achieve accurate removal of noise and outliers. The adaptive noise filtering module dynamically adjusts the filtering parameters based on the local density of the pipeline point cloud, solving the problem of incomplete noise removal or feature loss caused by fixed parameters in traditional filtering algorithms.

[0019] Preferably, the filtering parameter adjustment strategy of the improved bilateral filtering algorithm is as follows: Calculate the local point cloud density ρ (the number of points within a preset radius r0 centered on that point) for each point, and set a density threshold ρ0. When ρ > ρ0 (dense point cloud regions, such as the main body of a pipe), decrease the spatial domain weight coefficient σs and increase the value domain weight coefficient σr to enhance the filtering effect of intensity value differences and avoid excessive smoothing that leads to loss of detail. When ρ < ρ0 (sparse point cloud regions, such as the edges of components), increase σs and decrease σr to expand the spatial neighborhood range and improve the stability of noise removal. σs and σr satisfy σs + σr = C (C is a fixed constant, preset to 5-10 mm based on the pipe size) to ensure the consistency of filtering intensity.

[0020] The data downsampling module uses a voxel grid downsampling algorithm to reduce the amount of point cloud data while preserving the key features of the pipeline.

[0021] Specifically, the point cloud space is divided into a uniform voxel grid, with only one representative point (such as the centroid) retained within each voxel, thereby reducing the amount of point cloud data. The voxel size is set to 1 / 50 to 1 / 30 of the pipe diameter. For example, for a pipe with a diameter of 500 mm, the voxel size is set to 10 to 16.7 mm. This ensures that key features such as the pipe body and welds are not lost, while reducing the amount of point cloud data by 60% to 80%, significantly improving the efficiency of subsequent processing.

[0022] Furthermore, the pipeline feature extraction unit is used to extract the geometric features and auxiliary component features of the pipeline, which is an important guarantee for the modeling accuracy. The pipeline feature extraction unit includes: an axis fitting module, a pipe diameter measurement module, and an auxiliary component identification module. The axis fitting module employs a cylindrical surface fitting method based on an improved RANSAC algorithm to accurately extract the spatial coordinates and orientation of the pipe's central axis. While the RANSAC algorithm boasts strong anti-interference capabilities, the traditional RANSAC algorithm has a fixed number of iterations, resulting in low efficiency. This invention optimizes algorithm performance by dynamically calculating the number of iterations. The specific steps are as follows: Step A1: Randomly select 3 non-collinear points from the preprocessed point cloud data, based on the cylindrical surface equation. ,in p For point cloud coordinates, a Let be a point on the axis. n The axis direction vector. r Initialize the cylindrical surface parameters (axis direction vector, coordinates of a point on the axis, radius) for the pipe radius. Step A2: Calculate the distance from all points to the initial cylindrical surface, and count the number of inner points whose distance is less than the preset threshold d0 (which can be set to 0.2-0.5mm depending on the scanning accuracy); Step A3: Based on the confidence level α (set to 0.99) and the inlier ratio β (estimated to be 0.6-0.8 based on prior knowledge), calculate the number of iterations N=log(1-α) / log(1-β3), avoid invalid iterations, and repeat steps A1-A2; Step A4: Select the cylindrical surface parameter with the most interior points, optimize it using the least squares method to obtain the final cylindrical surface model of the pipe, and then extract the spatial coordinates and orientation of the central axis. ,in It is a spatial coordinate function of any position on the central axis of the pipeline. It is the vector function of the direction of the central axis of the pipeline at the corresponding position.

[0023] This invention also adds a segmented processing mechanism for curved pipes: calculating the curvature of the axis. k : ; n′ ( t )yes n ( t ) parameters t The first derivative of represents the rate of change of the slope of the tangent to the axis. It is a curvature correction term, used to balance the influence of tangent slope on curvature calculation and improve the accuracy of curvature calculation for curved pipes.

[0024] Set curvature threshold k 0 (can be set to 0.01~0.05m⁻¹ depending on the degree of pipe curvature), when k > k At 0, the curved pipe is divided into multiple straight pipe segments for axis fitting, and then the axes of each segment are smoothly connected by cubic spline curves to ensure the continuity and accuracy of the curved pipe axis.

[0025] The pipe diameter measurement module calculates the average distance from the pipe point cloud to the axis and, combined with local point cloud density correction, obtains the actual inner and outer diameter of the pipe. Specifically, based on the extracted central axis, it calculates the distance from each pipe point cloud to the axis. ( i (where is the angle between the point cloud and the axis), where It is the first i The actual radial vertical distance from the pipe point cloud to the central axis is the basic data for pipe diameter calculation; It is the first i Spatial coordinates of a pipeline point cloud; Is the central axis of the pipe at The spatial coordinates of the corresponding position For point clouds Points corresponding to the axis The straight-line distance in space; i yes The angle between the vector pointing from the point cloud to the corresponding point on the axis and the central axis is used to correct measurement deviations caused by non-perpendicular distances, ensuring the accuracy of distance calculations.

[0026] Form a distance set { d 1 , d 2 ,..., d n First, remove the extreme values ​​(the largest and smallest 5% of values) from the set to avoid the influence of local deformation and noise points on the measurement results; then calculate the average value of the remaining distance as the pipe radius. r Finally, the radius is corrected based on the density distribution of the point cloud on the pipe surface: when the local point cloud density is greater than the overall average density, the radius value is adjusted appropriately to compensate for the measurement deviation caused by surface roughness, and the actual inner diameter of the pipe is finally obtained. rin With outer diameter route ( route = rin +2h, where h is the pipe wall thickness).

[0027] The auxiliary component identification module uses a deep learning semantic segmentation model to achieve automatic identification and feature extraction of auxiliary components such as welds, flanges, and valves. It identifies auxiliary components such as welds, flanges, and valves in point cloud data and extracts the position, size, and orientation features of the auxiliary components.

[0028] Preferably, the deep learning semantic segmentation model adopts an improved PointNet++ model. The improved PointNet++ deep learning model enhances the feature response of small-sized components such as welds and flanges by introducing an attention mechanism in the feature extraction layer, thereby improving recognition accuracy. The model training samples consist of more than 1000 sets of petrochemical pipeline point cloud data and corresponding component annotation information, covering pipeline scenarios with different pipe diameters and component types. The annotation categories include pipeline body, circumferential weld, longitudinal weld, flange, gate valve, ball valve, etc. After training, the preprocessed point cloud data is input into the model, and the model outputs the category label of each point. A clustering algorithm is used to extract the point cloud sets of various components, and then the position coordinates (center point coordinates), dimensional parameters (weld length and width, flange outer diameter, number of bolt holes, valve height), and attitude information (angle between the component normal vector and the pipeline axis) of the components are calculated.

[0029] Furthermore, the model verification unit is used to verify the accuracy and engineering applicability of the model, including: a point cloud-model deviation analysis module and an engineering accuracy verification module; The point cloud-model deviation analysis module calculates the average and maximum deviations between the original point cloud data and the reconstructed model to determine whether the model accuracy meets the preset threshold. The point cloud-model deviation analysis module registers the original point cloud data with the reconstructed model and calculates the Euclidean distance from each point cloud to the model surface. yes Statistical mean deviation With maximum deviation Set a precision threshold: For the main body of the pipe, ≤0.5mm and ≤1.0mm; for detailed components such as welds and flanges, ≤0.3mm and ≤0.8mm. If the deviation exceeds the threshold, return to the point cloud preprocessing unit for noise filtering again, or return to the feature extraction unit to re-extract feature parameters until the accuracy requirements are met.

[0030] The engineering accuracy verification module, in accordance with petrochemical industry modeling standards, verifies the dimensional tolerances and assembly relationships of the model. Specifically, it refers to the "Guidelines for 3D Digital Design of Petrochemical Engineering" (T / CPCIF0213-2022), for example, verifying whether the number and spacing of bolt holes on flanges meet the standards. Only after passing the verification can the model be used for subsequent engineering applications.

[0031] This invention also provides a pipeline reverse modeling method based on point cloud data, applied to the pipeline reverse modeling system based on point cloud data as described above, including the following steps: S1. Multi-source point cloud acquisition: The acquisition system, consisting of a laser scanner, a structured light scanner, and an industrial camera, performs multi-view and all-round scanning of the target petrochemical pipeline to obtain point cloud data of the pipeline body, welds, flanges, and valves, and simultaneously records the GPS coordinates and attitude information of the scanning position. S2. Preprocess the point cloud data; S3. Extract pipeline features, including: S31. Axis Fitting: An improved RANSAC cylindrical surface fitting method is used to extract the spatial coordinates of the pipe's central axis from the preprocessed point cloud data. x(t),y(t),z(t) ) and direction vector n =( a,b,c ); S32, Pipe Diameter Measurement: Calculate the set of distances from the pipe point cloud to the central axis. d1,d2,...,dn After removing extreme values, the average value is taken as the pipe radius r. Combined with the pipe material thickness standard, the inner diameter is determined. With outer diameter ; S33. Auxiliary component identification: Input the preprocessed point cloud data into the improved PointNet++ semantic segmentation model to identify auxiliary components such as welds, flanges, and valves, and extract feature parameters such as the position coordinates, length, and width of the welds, the outer diameter of the flanges, the number and distribution of bolt holes, and the model and installation angle of the valves. S4. Reconstruct the parametric model of the pipeline, including: S41. Call the standard pipe model library in the database and generate a three-dimensional curved surface model of the main body of the pipe based on the axis parameters and pipe diameter; S42. Based on the characteristic parameters of the auxiliary components, call the corresponding standard component model library, and assemble the auxiliary components such as welds, flanges, and valves to the corresponding positions of the main pipeline model through coordinate positioning and attitude adjustment. S43. Boolean operations are used to fuse the models of each component, and surface smoothness of the model is optimized through surface stitching technology to generate a complete three-dimensional model of the petrochemical pipeline. S5, operating condition adaptation optimization, including: S51. Obtain the actual operating condition data of the target pipeline, including operating temperature T, operating pressure P, type of transported medium M, and service life Y; S52. Based on the finite element analysis method, simulate the stress distribution and deformation of the pipeline under working conditions, and adjust the parameters such as the wall thickness and weld size of the model to make the model consistent with the physical state of the actual pipeline. S53. Based on the corrosion level of the medium type, add the anti-corrosion layer thickness parameter to the model to match the actual pipeline protection status. S6. Model Validation and Output, including: S61. Point Cloud-Model Deviation Analysis: Calculate the Euclidean distance between the original point cloud data and the reconstructed model, and statistically calculate the average deviation. With maximum deviation ,like ≤0.5mm and If the result is ≤1.0mm, the accuracy requirement is met; otherwise, return to step S2 or S3 for reprocessing. S62. Engineering accuracy verification: Verify whether the number and spacing of bolt holes on the flange meet the standards in accordance with the "Guidelines for Three-Dimensional Digital Design of Petrochemical Engineering". S63. Export the verified 3D model to a common format (STEP, IGES, STL) for engineering applications such as pipeline maintenance, modification, and simulation analysis.

[0032] Furthermore, the method for preprocessing the point cloud data in step S2 includes: S21. Coordinate Alignment: Based on GPS coordinates and attitude information, the ICP algorithm is used to register multi-view point cloud data to a unified world coordinate system to eliminate viewpoint deviation. S22. Adaptive noise filtering: An improved bilateral filtering algorithm is used to dynamically adjust the filtering parameters according to the local point cloud density, eliminating outliers such as scanning noise and environmental interference points, while retaining the effective point cloud of the pipeline. S23. Data downsampling: A voxel grid downsampling algorithm is adopted, and the voxel size is set to 1 / 50 to 1 / 30 of the pipe diameter. This reduces the amount of point cloud data while ensuring feature integrity and improves the efficiency of subsequent processing.

[0033] Furthermore, the calculation formula for the improved bilateral filtering algorithm in step S22 is as follows: ; in, p′ These are the coordinates of the filtered points. q For point p Points within the neighborhood, S For the set of neighborhood points, K These are the normalization coefficients; Weighting function: ; in, For point p and q Spatial distance, For point p and q Differences in intensity values, For spatial domain standard deviation, Let be the standard deviation of the range, and and The local point cloud density ρ is dynamically adjusted.

[0034] Furthermore, the extraction of the pipe's central axis in step S31 also includes segmentation of the curved pipe: When the actual curvature value of the central axis of the curved pipe k Conform When the curved pipe is divided into multiple straight pipe segments for axis fitting, the axes of each segment are then smoothly connected using spline curves. in, k 0 represents the preset curvature threshold. Let be the vector function representing the direction of the central axis of the curved pipe. t Parametric variables (such as axis length) for the center axis of the curved pipe; To move towards the vector For parameters t The first derivative of represents the rate of change of the slope of the tangent to the central axis of the curved pipe.

[0035] Furthermore, the method for correcting the positional accuracy of the auxiliary component assembly in step S42 is as follows: The installation position of the component is determined by the projection relationship between the center point coordinates of the component point cloud and the pipeline axis; the installation posture of the component is adjusted based on the angle between the normal vector of the component point cloud and the pipeline axis so that the component is perpendicular to the pipeline body or at a preset angle.

[0036] This invention supports multiple point cloud formats (PLY, PCD, LAS) and is compatible with mainstream laser scanning equipment (FARO, Artec, Trimble). The model can be exported to common formats such as STEP, IGES, and STL, and is compatible with engineering tools such as CAD design software and finite element analysis software. The system has strong compatibility and a wide range of applications, suitable for reverse modeling of petrochemical pipelines with different diameters, materials, and operating conditions, as well as industrial pipelines in the chemical, power, and metallurgical industries, and has a wide range of application scenarios.

[0037] The present invention also provides a computer device, the computer device including a readable storage medium, a memory, a processor, and a computer program stored on the readable storage medium and the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the pipeline reverse modeling method based on point cloud data as described above.

[0038] Compared with the prior art, the beneficial effects of the present invention are as follows: The pipeline reverse modeling system and method based on point cloud data provided by this invention employs an improved bilateral filtering algorithm. The filtering parameters are dynamically adjusted according to the local density of the point cloud, thoroughly eliminating noise and outliers while preserving key pipeline features. This results in excellent noise reduction and significantly improved point cloud quality, with the effective point ratio after denoising exceeding 98%. An improved RANSAC algorithm achieves accurate axis fitting, providing a solid modeling foundation. Combined with a segmented processing mechanism to adapt to curved pipelines, the accuracy of pipeline feature extraction is improved. An improved PointNet++ model is used for automatic identification of auxiliary components, and local density correction is introduced for pipe diameter measurement, achieving an identification accuracy of over 95%, significantly improving measurement accuracy and outperforming traditional manual annotation or geometric matching methods. The innovative design incorporates a working condition adaptation and optimization unit, which combines actual working condition data such as temperature, pressure, and medium type to adjust parameters such as thermal expansion, wall thickness, and corrosion thinning in the model. This allows the model to not only reflect the geometry of the pipeline but also match the physical state during actual operation, meeting the high-precision application requirements for engineering simulation and strength verification. The model is deeply adapted to actual working conditions, enhancing its engineering practicality. From multi-source point cloud acquisition, preprocessing, and feature extraction to model reconstruction, working condition optimization, and verification output, the entire process is highly automated, requiring only minimal manual intervention (such as working condition data entry). The modeling cycle is shortened by more than 60% compared to traditional methods. It can adapt to the reverse modeling needs of large-scale petrochemical pipelines, and the high degree of automation in the modeling process significantly improves modeling efficiency. Attached Figure Description

[0039] Various other advantages and benefits will become apparent to those skilled in the art upon reading the following detailed description of preferred embodiments. The accompanying drawings are for illustrative purposes only and are not intended to limit the invention.

[0040] In the attached diagram: Figure 1 This is a flowchart of a pipeline reverse modeling method based on point cloud data, according to an embodiment of the present invention. Detailed Implementation

[0041] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numerals in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this disclosure. Rather, they are merely examples of apparatuses and products consistent with some aspects of this disclosure as detailed in the appended claims.

[0042] The terminology used in this disclosure is for the purpose of describing particular embodiments only and is not intended to be limiting of the disclosure. The singular forms “a,” “the,” and “the” as used in this disclosure and the appended claims are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term “and / or” as used herein refers to and includes any and all possible combinations of one or more of the associated listed items.

[0043] It should be understood that although the terms first, second, third, etc., may be used in this disclosure to describe various information, such information should not be limited to these terms. These terms are used only to distinguish information of the same type from one another. For example, without departing from the scope of this disclosure, first information may also be referred to as second information, and similarly, second information may also be referred to as first information. Depending on the context, the word "if" as used herein may be interpreted as "when," "when," or "in response to determination."

[0044] The embodiments of the present invention will be further described in detail below with reference to the accompanying drawings. Example

[0045] This invention provides a pipeline reverse modeling system based on point cloud data, comprising: a multi-source point cloud acquisition unit, a point cloud preprocessing unit, a pipeline feature extraction unit, a parametric model reconstruction unit, a working condition adaptation optimization unit, a model verification unit, and a database unit connected in sequence to the aforementioned units respectively; The multi-source point cloud acquisition unit is the source of modeling data. It uses a multi-source acquisition device composed of laser scanners, structured light scanners, and industrial cameras to achieve all-round, high-precision scanning of petrochemical pipelines and their auxiliary components, acquire multi-view point cloud data including the pipeline body, welds, flanges, and valves, and transmit the data to the database unit for storage. Laser scanners are used to acquire long-distance, large-area point cloud data of pipelines, with a scanning accuracy of ±0.1mm; structured light scanners are used for close-range scanning of detailed components such as pipeline welds and flanges to acquire high-density point clouds; industrial cameras simultaneously acquire pipeline surface image information, providing data support for subsequent point cloud intensity value analysis. During the acquisition process, the multi-source point cloud acquisition unit simultaneously records the GPS coordinates and attitude information of the scanning equipment, ensuring the basis for registration of multi-view point cloud data; after acquisition, the multi-source point cloud data is transmitted to the database unit for storage, supporting subsequent retrieval and backtracking.

[0046] The parametric model reconstruction unit is used to construct a parametric 3D model of the petrochemical pipeline by calling the standard pipeline model library and component model library in the database unit according to the pipeline axis, pipe diameter, and auxiliary component feature parameters. It then uses Boolean operations and surface stitching technology. Based on the extracted feature parameters, the parametric model reconstruction unit constructs a complete 3D model of the petrochemical pipeline. First, it calls the standard pipeline model library in the database unit to generate a 3D curved surface model of the pipeline body according to the axis parameters and pipe diameter: for straight pipelines, a cylindrical surface is directly generated from the axis and pipe diameter; for curved pipelines, multiple cylindrical surfaces are generated by segmenting the axis and pipe diameter, and then a smooth transition is achieved through surface stitching technology. Then, based on the feature parameters of the auxiliary components, it calls the corresponding standard component model library (HG / T20615 flange standard library, GB / T12224 valve standard library, etc.) and assembles components such as welds, flanges, and valves to the corresponding positions on the pipeline body model through coordinate positioning (aligning the component center point with the identified position coordinates) and attitude adjustment (adjusting the installation angle according to the component normal vector). Finally, Boolean operations are used to merge the models of each component, eliminate assembly gaps, optimize the surface smoothness of the model, and generate a parametric 3D model of the petrochemical pipeline. All features of the model (axis, pipe diameter, component dimensions) can be modified by adjusting parameters, which is convenient for subsequent engineering applications.

[0047] The operating condition adaptation and optimization unit is a key technical aspect of this invention, designed to adapt to the actual needs of petrochemical engineering. It acquires actual operating condition data (temperature, pressure, medium type, and service life) of petrochemical pipelines and, based on finite element analysis algorithms, adjusts the pipe wall thickness, weld strength, and flange sealing performance of the 3D model to ensure consistency between the model and the actual physical state of the pipeline under real-world operating conditions. By combining actual operating condition data, the model parameters are adjusted to ensure consistency between the model and the actual pipeline's physical state. The optimization method of the operating condition adaptation and optimization unit is as follows: It calculates the thermal expansion of the pipeline based on temperature data. ΔL = α·L0·ΔT (α is the linear expansion coefficient of the pipe material, L0 is the original length of the pipe, and ΔT is the difference between the actual temperature and the ambient temperature). Adjust the axis length of the model; based on the pressure data and medium type, and in accordance with the "Design Code for Industrial Metal Pipelines," verify whether the pipe wall thickness meets the strength requirements. If not, adjust the model wall thickness parameters. The optimization process is as follows: (1) Obtain actual operating data of the target pipeline, including operating temperature T, operating pressure P, type of transported medium M (such as crude oil, natural gas, corrosive chemical media), and years of operation Y; these data can be obtained through the production management system of petrochemical enterprises, pipeline monitoring equipment, or manually entered.

[0048] (2) Thermal expansion adaptation: Based on the linear expansion coefficient α of the pipe material (e.g., carbon steel α=11.5×10). -6 / ℃), original length of pipeline L0The difference between actual temperature and room temperature ΔT = T Calculate the thermal expansion of the pipeline at -25℃. Adjust the axis length of the model to make the model reflect the thermal expansion state of the pipeline under actual working conditions.

[0049] (3) Strength Adaptation: Based on the working pressure P and the medium type M, and in accordance with the "Code for Design of Industrial Metal Piping" (GB50316), the strength calculation formula is adopted. ,in, s For pipe wall stress, D The inner diameter of the pipe. d For wall thickness, For weld coefficient; check whether the pipe wall thickness meets the strength requirements; if s If [σ]t (where [σ]t is the allowable stress of the material at temperature T) is greater than or equal to the allowable stress of the material at temperature T, then the wall thickness parameter of the model should be increased appropriately, or the weld size should be adjusted to ensure that the strength characteristics of the model are consistent with those of the actual pipeline.

[0050] (4) Corrosion compatibility: Based on the corrosion level (e.g., light, moderate, severe corrosion) of the medium type M and the service life Y, refer to the "Design Specification for Corrosion Protection of Coatings for Petrochemical Equipment and Pipelines" to calculate the corrosion thinning amount Δ of the pipeline. d =k·Y (k is the annual corrosion rate (determined according to the type of medium), Y is the number of years of operation), adjust the wall thickness parameters of the model to match the corrosion state of the actual pipeline; for components such as flanges and valves, adjust their sealing surface dimensions and bolt strength parameters according to the corrosion level.

[0051] The database unit is used to store multi-source point cloud data, preprocessed point cloud data, feature parameter data, standard model library (pipes, welds, flanges, valves), operating condition data, and the final reconstructed model.

[0052] The database unit stores the following: raw point cloud data and image data acquired by the multi-source point cloud acquisition unit; registered point clouds, denoised point clouds, and downsampled point clouds output by the point cloud preprocessing unit; axis parameters, pipe diameter data, and auxiliary component feature parameters output by the pipeline feature extraction unit; a standard model library (containing standard pipe models of different diameters and materials, as well as standard models of components such as welds, flanges, and valves, conforming to national and industry standards); operating condition data (temperature, pressure, medium type, operating years, etc.); and the final reconstructed 3D model data. The database unit supports adding, deleting, modifying, querying, backing up, and exporting data, facilitating subsequent model updates and maintenance.

[0053] The point cloud preprocessing unit is used to improve the quality of point cloud data and lay the foundation for subsequent feature extraction. It includes a coordinate alignment module, an adaptive noise filtering module, and a data downsampling module. The coordinate alignment module is used to transform multi-view point cloud data to a unified world coordinate system. Based on the GPS coordinates and attitude information recorded during the acquisition process, the module uses the ICP (Iterative Closest Point) algorithm to register the multi-view point cloud data to the unified world coordinate system. The specific process is as follows: select one set of point clouds as the target point cloud, and the remaining point clouds as the source point clouds. By iteratively calculating the optimal transformation matrix (rotation matrix + translation matrix) between the source point clouds and the target point clouds, the average distance between the source point clouds and the target point clouds is minimized, ultimately achieving coordinate unification of all point cloud data and eliminating viewpoint deviation.

[0054] The adaptive noise filtering module employs an improved bilateral filtering algorithm, which dynamically adjusts the filtering parameters based on the density distribution characteristics of the pipeline point cloud to achieve accurate removal of noise and outliers. The adaptive noise filtering module dynamically adjusts the filtering parameters according to the local density of the pipeline point cloud, solving the problem of incomplete noise removal or feature loss caused by fixed parameters in traditional filtering algorithms.

[0055] The improved bilateral filtering algorithm's parameter adjustment strategy is as follows: Calculate the local point cloud density ρ (the number of points within a preset radius r0 centered on that point) for each point, and set a density threshold ρ0. When ρ > ρ0 (dense point cloud regions, such as the main body of a pipe), decrease the spatial domain weight coefficient σs and increase the value domain weight coefficient σr to enhance the filtering effect of intensity value differences and avoid excessive smoothing leading to detail loss. When ρ < ρ0 (sparse point cloud regions, such as component edges), increase σs and decrease σr to expand the spatial neighborhood range and improve the stability of noise removal. σs and σr satisfy σs + σr = C (C is a fixed constant, preset to 5-10 mm based on the pipe size) to ensure consistent filtering intensity.

[0056] The data downsampling module employs a voxel grid downsampling algorithm to reduce the amount of point cloud data while preserving key pipe features. The point cloud space is divided into a uniform voxel grid, with only one representative point (such as the centroid) retained within each voxel, thus reducing the amount of point cloud data. The voxel size is set to 1 / 50 to 1 / 30 of the pipe diameter. For example, for a pipe with a diameter of 500mm, the voxel size is set to 10 to 16.7mm. This ensures that key features such as the pipe body and welds are not lost, while reducing the amount of point cloud data by 60% to 80%, significantly improving subsequent processing efficiency.

[0057] The pipeline feature extraction unit is used to extract the geometric features and features of the pipeline and its auxiliary components, which is an important guarantee for the modeling accuracy. The pipeline feature extraction unit includes: axis fitting module, pipe diameter measurement module, and auxiliary component identification module. The axis fitting module employs a cylindrical surface fitting method based on an improved RANSAC algorithm to accurately extract the spatial coordinates and orientation of the pipe's central axis. This embodiment optimizes the RANSAC algorithm performance by dynamically calculating the number of iterations. The specific steps are as follows: Step A1: Randomly select 3 non-collinear points from the preprocessed point cloud data, based on the cylindrical surface equation. ,in p For point cloud coordinates, a Let be a point on the axis. n The axis direction vector. r Initialize the cylindrical surface parameters (axis direction vector, coordinates of a point on the axis, radius) for the pipe radius. Step A2: Calculate the distance from all points to the initial cylindrical surface, and count the number of inner points whose distance is less than the preset threshold d0 (which can be set to 0.2-0.5mm depending on the scanning accuracy); Step A3: Based on the confidence level α (set to 0.99) and the inlier ratio β (estimated to be 0.6-0.8 based on prior knowledge), calculate the number of iterations N=log(1-α) / log(1-β3), avoid invalid iterations, and repeat steps A1-A2; Step A4: Select the cylindrical surface parameter with the most interior points, optimize it using the least squares method to obtain the final cylindrical surface model of the pipe, and then extract the spatial coordinates and orientation of the central axis. ,in It is a spatial coordinate function of any position on the central axis of the pipeline. It is the vector function of the direction of the central axis of the pipeline at the corresponding position.

[0058] This invention also adds a segmentation mechanism for curved pipes: calculating the curvature of the axis. k : ; n′ ( t )yes n ( t ) parameters t The first derivative of represents the rate of change of the slope of the tangent to the axis. It is a curvature correction term, used to balance the influence of tangent slope on curvature calculation and improve the accuracy of curvature calculation for curved pipes.

[0059] Set curvature threshold k 0 (can be set to 0.01~0.05m⁻¹ depending on the degree of pipe curvature), when k > k At 0, the curved pipe is divided into multiple straight pipe segments for axis fitting, and then the axes of each segment are smoothly connected by cubic spline curves to ensure the continuity and accuracy of the curved pipe axis.

[0060] The pipe diameter measurement module calculates the average distance from the pipe point cloud to the axis and, combined with local point cloud density correction, obtains the actual inner and outer diameter of the pipe; based on the extracted central axis, it calculates the distance from each pipe point cloud to the axis. ( i (where is the angle between the point cloud and the axis), where It is the first i The actual radial vertical distance from the pipe point cloud to the central axis is the basic data for pipe diameter calculation; It is the first i Spatial coordinates of a pipeline point cloud; Is the central axis of the pipe at The spatial coordinates of the corresponding position For point clouds Points corresponding to the axis The straight-line distance in space; i yes The angle between the vector pointing from the point cloud to the corresponding point on the axis and the central axis is used to correct measurement deviations caused by non-perpendicular distances, ensuring the accuracy of distance calculations.

[0061] Form a distance set { d 1 , d 2 ,..., d n First, remove the extreme values ​​(the largest and smallest 5% of values) from the set to avoid the influence of local deformation and noise points on the measurement results; then calculate the average value of the remaining distance as the pipe radius. r Finally, the radius is corrected based on the density distribution of the point cloud on the pipe surface: when the local point cloud density is greater than the overall average density, the radius value is adjusted appropriately to compensate for the measurement deviation caused by surface roughness, and the actual inner diameter of the pipe is finally obtained. rin With outer diameter route ( route = rin +2h, where h is the pipe wall thickness).

[0062] The auxiliary component identification module uses a deep learning semantic segmentation model to achieve automatic identification and feature extraction of auxiliary components such as welds, flanges, and valves. It identifies auxiliary components such as welds, flanges, and valves in point cloud data and extracts the position, size, and orientation features of the auxiliary components.

[0063] The deep learning semantic segmentation model employs an improved PointNet++ model. This improved model enhances the feature response of small components such as welds and flanges by introducing an attention mechanism in the feature extraction layer, thereby improving recognition accuracy. The model training samples consist of over 1000 sets of petrochemical pipeline point cloud data and corresponding component annotation information, covering pipeline scenarios with different pipe diameters and component types. Annotation categories include pipeline body, circumferential welds, longitudinal welds, flanges, gate valves, and ball valves. After training, the preprocessed point cloud data is input into the model, which outputs the category labels for each point. A clustering algorithm is used to extract point cloud sets for each type of component, and then the component's position coordinates (center point coordinates), dimensional parameters (weld length and width, flange outer diameter, number of bolt holes, valve height), and attitude information (angle between the component's normal vector and the pipeline axis) are calculated.

[0064] The model validation unit is used to verify the accuracy and engineering applicability of the model, including: point cloud-model deviation analysis module and engineering accuracy verification module; The point cloud-model deviation analysis module calculates the average and maximum deviations between the original point cloud data and the reconstructed model, and determines whether the model accuracy meets the preset threshold. The point cloud-model deviation analysis module registers the original point cloud data with the reconstructed model and calculates the Euclidean distance from each point cloud to the model surface. yes Statistical mean deviation With maximum deviation Set a precision threshold: For the main body of the pipe, ≤0.5mm and ≤1.0mm; for detailed components such as welds and flanges, ≤0.3mm and ≤0.8mm. If the deviation exceeds the threshold, return to the point cloud preprocessing unit for noise filtering again, or return to the feature extraction unit to re-extract feature parameters until the accuracy requirements are met.

[0065] The engineering accuracy verification module, in accordance with petrochemical industry modeling standards, verifies the dimensional tolerances and assembly relationships of the model. It also verifies, against the "Guidelines for 3D Digital Design of Petrochemical Engineering" (T / CPCIF0213-2022), whether the number and spacing of bolt holes on the flanges meet the standards. Only after successful verification can the model be used for subsequent engineering applications.

[0066] This invention also provides a pipeline reverse modeling method based on point cloud data, applicable to the pipeline reverse modeling system based on point cloud data as described above. See [link to relevant documentation]. Figure 1 As shown, it includes the following steps: S1. Multi-source point cloud acquisition: The acquisition system, consisting of a laser scanner, a structured light scanner, and an industrial camera, performs multi-view and all-round scanning of the target petrochemical pipeline to obtain point cloud data of the pipeline body, welds, flanges, and valves, and simultaneously records the GPS coordinates and attitude information of the scanning position. Preferably, during scanning, the distance between the acquisition device and the pipeline is controlled at 1-5m to ensure point cloud density and accuracy. For densely piped areas, the scanning angle is increased to avoid point cloud loss due to occlusion. The GPS coordinates and attitude information of the scanning position are recorded simultaneously to provide data for subsequent coordinate alignment. After acquisition, the point cloud data (in PLY and PCD formats) and image data are transferred to the database unit for storage.

[0067] S2. Preprocessing the point cloud data, including: S21. Coordinate Alignment: Based on GPS coordinates and attitude information, the ICP algorithm is used to register multi-view point cloud data to a unified world coordinate system to eliminate viewpoint deviation. Specifically, the flange face at one end of the pipe is selected as the registration reference surface. The reference surfaces of the point clouds from each viewpoint are aligned. Then, the overall registration accuracy is optimized through iterative calculation so that the average registration error of the multi-view point clouds is less than 0.1mm. S22. Adaptive noise filtering: An improved bilateral filtering algorithm is used to dynamically adjust the filtering parameters according to the local point cloud density, eliminating outliers such as scanning noise and environmental interference points, while retaining the effective point cloud of the pipeline. The calculation formula for the improved bilateral filtering algorithm is as follows: ; in, p′ These are the coordinates of the filtered points. q For point p Points within the neighborhood, S For the set of neighborhood points, K These are the normalization coefficients; Weighting function: ; in, For point p and q Spatial distance, For point p and q Differences in intensity values, For spatial domain standard deviation, Let be the standard deviation of the range, and and The local point cloud density ρ is dynamically adjusted.

[0068] In this embodiment, the local point cloud density ρ of each point is first calculated, and a density threshold ρ0 is set to 50 points / mm³ (which can be adjusted according to the actual scanning density). Then, based on the relationship between ρ and ρ0, σs and σr are dynamically adjusted. For example, when ρ = 80 points / mm³ (ρ > ρ0), σs = 2mm and σr = 8mm are set; when ρ = 30 points / mm³ (ρ < ρ0), σs = 8mm and σr = 2mm are set. Finally, the new coordinates of each point are calculated using a filtering formula to remove noise points and outliers. S23. Data downsampling: A voxel grid downsampling algorithm is adopted, and the voxel size is set to 1 / 40 of the pipe diameter. For example, for a pipe with a diameter of 300mm, the voxel size is set to 7.5mm. The denoised point cloud is downsampled to reduce the amount of data.

[0069] S3. Extract pipeline features, including: S31. Axis Fitting: An improved RANSAC cylindrical surface fitting method is used to extract the spatial coordinates of the pipe's central axis from the preprocessed point cloud data. x(t),y(t),z(t) ) and direction vector n =( a,b,c ); Extracting the central axis of the pipeline includes segmentation of curved pipelines: When the actual curvature value of the central axis of the curved pipe k Conform When the curved pipe is divided into multiple straight pipe segments for axis fitting, the axes of each segment are then smoothly connected using spline curves. in, k 0 represents the preset curvature threshold. Let be the vector function representing the direction of the central axis of the curved pipe. t Parametric variables (such as axis length) for the center axis of the curved pipe; To move towards the vector For parameters t The first derivative of represents the rate of change of the slope of the tangent to the central axis of the curved pipe.

[0070] With a confidence level of α = 0.99 and an estimated inlier ratio of β = 0.7, the number of iterations N = log(1 - 0.99) / log(1 - 0.73) ≈ 20 is calculated. After iteration, the cylindrical surface parameter with the most inliers is selected, and the cylindrical surface model of the pipe is obtained through least squares optimization. For curved pipes, the axial curvature is calculated. k ,when k >0.03m -1 When the pipeline is divided into three straight pipeline segments, the axis is fitted, and then the axes of each segment are connected by a cubic spline curve. S32, Pipe Diameter Measurement: Calculate the set of distances from the pipe point cloud to the central axis. d1,d2,...,dn After removing extreme values, the average value is taken as the pipe radius r. Combined with the pipe material thickness standard, the inner diameter is determined. With outer diameter ; The set of distances from the pipe point cloud to the central axis is calculated, and the average value after removing extreme values ​​is taken as the initial radius r=150mm. Combined with local point cloud density correction, the final pipe outer diameter is obtained. =152mm, inner diameter =148mm (wall thickness h=2mm); S33. Auxiliary component identification: Input the preprocessed point cloud data into the improved PointNet++ semantic segmentation model to identify auxiliary components such as welds, flanges, and valves, and extract feature parameters such as the position coordinates, length, and width of the welds, the outer diameter of the flanges, the number and distribution of bolt holes, and the model and installation angle of the valves. In this embodiment, the downsampled point cloud data is input into the improved PointNet++ semantic segmentation model, and the model outputs the category label for each point; the weld point cloud set is extracted using a clustering algorithm, and the weld's position coordinates (x=1000mm, y=500mm, z=300mm), length L=50mm, and width W=5mm are calculated; the flange point cloud set is extracted, and the flange outer diameter is calculated. D =200mm, number of bolt holes n=8, diameter of bolt hole distribution circle d=170mm; extract valve point cloud set, identify valve model as gate valve, installation angle is 90°.

[0071] S4. Reconstruct the parametric model of the pipeline, including: S41. Call the standard pipe model library in the database and generate a three-dimensional curved surface model of the main body of the pipe based on the axis parameters and pipe diameter; In this embodiment, the standard model library of carbon steel pipes in the database is called, and a cylindrical pipe body model is generated based on the axis parameters (length L=5000mm) and the outer diameter of 152mm and the inner diameter of 148mm. S42. Based on the characteristic parameters of the auxiliary components, call the corresponding standard component model library, and assemble the auxiliary components such as welds, flanges, and valves to the corresponding positions of the main pipeline model through coordinate positioning and attitude adjustment. The installation position of the component is determined by the projection relationship between the center point coordinates of the component point cloud and the pipeline axis; the installation posture of the component is adjusted based on the angle between the normal vector of the component point cloud and the pipeline axis so that the component is perpendicular to the pipeline body or at a preset angle.

[0072] Call the flange standard model library (HG / T20615), select a flange model with an outer diameter of 200mm and 8 bolt holes, and assemble it to the corresponding position at one end of the pipeline (coordinates x=0mm, y=500mm, z=300mm). Adjust the flange posture to make it perpendicular to the pipeline axis. Call the weld standard model library, generate a circumferential weld model according to the position, length, and width of the weld, and assemble it at the connection between the pipeline and the flange. Call the gate valve standard model library, select the corresponding gate valve model, and assemble it to the preset position on the pipeline. S43. Boolean operations are used to fuse the models of each component, and surface smoothness of the model is optimized through surface stitching technology to generate a complete three-dimensional model of the petrochemical pipeline. Specifically, Boolean operations are used to integrate the pipeline body, flange, weld, and gate valve models into one, and surface stitching technology is used to optimize the model surface and eliminate assembly gaps.

[0073] S5, operating condition adaptation optimization, including: S51. Obtain the actual operating condition data of the target pipeline, including operating temperature T, operating pressure P, type of transported medium M, and service life Y; The target pipeline operates at a temperature of T=150℃, a working pressure of P=2.5MPa, transports crude oil (slightly corrosive), and has a service life of Y=5 years. S52. Based on the finite element analysis method, simulate the stress distribution and deformation of the pipeline under working conditions, and adjust the parameters such as the wall thickness and weld size of the model to make the model consistent with the physical state of the actual pipeline. Thermal expansion compatibility: The pipe material is carbon steel, with a linear expansion coefficient α = 11.5 × 10⁻⁶ / ℃, and the original length... L0 =5000mm, ΔT =150-25=125℃, thermal expansion ΔL =11.5×10-6×5000×125=0.71875mm, adjust the model axis length to 5000.72mm; Strength compatibility: According to the "Design Code for Industrial Metal Piping", the allowable stress of carbon steel at 150℃ is […]. s ] t =130MPa, weld coefficient =0.85, pipe inner diameter D =148mm, calculated using the strength formula s =2.5×148 / (2×2×0.85)≈108.8MPa<130MPa, which meets the strength requirements and does not require adjustment of the wall thickness; S53. Based on the corrosion level of the medium type, add the anti-corrosion layer thickness parameter to the model to match the actual pipeline protection status. The crude oil is mildly corroded; the corrosion thinning amount Δ over 5 years is [not specified]. d=0.02×5=0.1mm, adjust the model wall thickness to 2-0.1=1.9mm, and adjust the inner diameter to 148.2mm.

[0074] S6. Model Validation and Output, including: S61. Point Cloud-Model Deviation Analysis: Calculate the Euclidean distance between the original point cloud data and the reconstructed model, and statistically calculate the average deviation. With maximum deviation ,like ≤0.5mm and If the result is ≤1.0mm, the accuracy requirement is met; otherwise, return to step S2 or S3 for reprocessing. In this embodiment, the average deviation is obtained by calculating the Euclidean distance between the original point cloud and the reconstructed model. =0.35mm, maximum deviation =0.8mm, which meets the accuracy threshold requirement; S62. Engineering accuracy verification: In accordance with the "Guidelines for 3D Digital Design of Petrochemical Engineering", the parameters such as the number of bolt holes, distribution spacing, valve installation angle, and pipeline slope of the flange were verified and found to meet the engineering requirements. S63. Export the verified 3D model as STEP format (general engineering format) for engineering applications such as pipeline maintenance scheme design, modification, and simulation analysis.

[0075] Application examples

[0076] The main implementation steps of this invention in practical application scenarios are as follows: 1. Multi-source point cloud acquisition: A data acquisition system consisting of a laser scanner (model: FAROFocusM70), a structured light scanner (model: ArtecEva), and an industrial camera is used to scan the target pipeline from multiple perspectives. The laser scanner covers the entire pipeline with a scanning accuracy of ±0.1mm; the structured light scanner focuses on scanning detailed components such as flanges, welds, and gate valves, with a point cloud density of 100 points / mm²; the industrial camera simultaneously acquires images of the pipeline surface. After acquisition, 12 sets of point cloud data from different perspectives are obtained in PCD format and transmitted to the database for storage.

[0077] 2. Point cloud preprocessing: Coordinate alignment: The ICP algorithm was used to register 12 sets of point clouds to a unified world coordinate system, with the flange face at one end of the pipe as the reference. The average deviation after registration was 0.08mm. Adaptive noise filtering: Calculate the local point cloud density ρ for each point, set ρ0 = 60 points / mm³, and dynamically adjust σs and σr. After filtering, the proportion of noise points decreases from 15% to 2%. Data downsampling: Setting the voxel size to 7.5mm (1 / 40 of the 300mm diameter tube) reduced the point cloud data volume from 8 million points to 1.5 million points after downsampling, improving efficiency by 81.25%.

[0078] 3. Pipeline feature extraction: Axis fitting: An improved RANSAC algorithm was used with a confidence level of α=0.99, an interior point ratio of β=0.75, and 15 iterations (N=15) to extract the central axis of the pipe. The axis runs from coordinates (0,0,0) to (10000,0,0), with a curvature of... k =0.01m-1< k 0 = 0.03m⁻¹, no segmentation required; Pipe diameter measurement: Calculate the distance from the point cloud to the axis. After removing extreme values, the average radius is 150mm. After correction, the outer diameter is 154mm and the inner diameter is 148mm (wall thickness 3mm). Auxiliary component identification: The improved PointNet++ model identified 2 flanges, 3 circumferential welds, and 1 gate valve. The flange outer diameter is 280mm and the number of bolt holes is 12. The weld length is 60mm and the width is 6mm. The gate valve is installed at (5000,0,0) at an installation angle of 90°.

[0079] 4. Parametric model reconstruction: The standard model library for carbon steel pipes is used to generate a main pipe model with a length of 10m, an outer diameter of 154mm, and an inner diameter of 148mm. Use the standard model library for flanges (HG / T20615), welds, and gate valves to assemble the components into their corresponding positions; Boolean operations are used to fuse the model, and after surface stitching optimization, a complete 3D model is generated.

[0080] 5. Optimization of operating conditions: Thermal expansion compatibility: Carbon steel α = 11.5 × 10⁻⁶ / ℃ ΔT =120-25=95℃, thermal expansion ΔL =11.5×10-6×10000×95=1.0925mm, adjust the model length to 10001.09mm; Strength matching: [ s ] t =140MPa =0.85, s =2.5×148 / (2×3×0.85)≈72.5MPa<140MPa, which meets the strength requirements; Corrosion compatibility: Slight corrosion of crude oil, 8-year corrosion thinning Δ d =0.16mm, adjust the wall thickness to 3-0.16=2.84mm.

[0081] 6. Model Validation and Output: Deviation analysis: average deviation =0.32mm, maximum deviation =0.75mm, which meets the accuracy requirements; Engineering verification: Complies with the "Guidelines for Three-Dimensional Digital Design of Petrochemical Engineering"; Export the STEP format model for pipeline corrosion detection simulation and maintenance scheme design.

[0082] This embodiment successfully constructed a 3D model of the target petrochemical pipeline. The model accuracy meets engineering requirements, and the modeling cycle is 8 hours (compared to about 24 hours for traditional methods), improving efficiency by 66.7%. The dimensional deviation between the model and the actual pipeline is less than 0.8mm, and the model has good adaptability to working conditions. It can be directly used for subsequent maintenance, simulation analysis, and other work, effectively solving the shortcomings of existing technologies.

[0083] The technical solution of the present invention has been described above with reference to the preferred embodiments shown in the accompanying drawings. However, it will be readily understood by those skilled in the art that the scope of protection of the present invention is obviously not limited to these specific embodiments. Without departing from the principles of the present invention, those skilled in the art can make equivalent changes or substitutions to the relevant technical features, and the technical solutions after these changes or substitutions will all fall within the scope of protection of the present invention.

[0084] The above description is merely a preferred embodiment of the present invention and is not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.

Claims

1. A pipeline reverse modeling system based on point cloud data, characterized in that, include: The system consists of a multi-source point cloud acquisition unit, a point cloud preprocessing unit, a pipeline feature extraction unit, a parametric model reconstruction unit, a working condition adaptation and optimization unit, a model verification unit, and a database unit connected to each of the aforementioned units in sequence. The multi-source point cloud acquisition unit is used to perform all-round scanning of petrochemical pipelines and their auxiliary components through a multi-source acquisition device composed of a laser scanner, a structured light scanner, and an industrial camera, to obtain multi-view point cloud data including the pipeline body, welds, flanges, and valves, and to transmit the data to the database unit for storage. The parametric model reconstruction unit is used to construct a parametric three-dimensional model of the petrochemical pipeline by calling the standard pipeline model library and component model library in the database unit according to the pipeline axis, pipe diameter and auxiliary component characteristic parameters, and through Boolean operation and surface stitching technology. The working condition adaptation and optimization unit is used to acquire actual working condition data of petrochemical pipelines and to adapt and adjust the pipe wall thickness, weld strength and flange sealing performance of the three-dimensional model based on the finite element analysis algorithm so that the model is consistent with the physical state of the pipeline under actual working conditions. The database unit is used to store multi-source point cloud data, preprocessed point cloud data, feature parameter data, standard model library, operating condition data, and the final reconstructed model.

2. The pipeline reverse modeling system based on point cloud data according to claim 1, characterized in that, The point cloud preprocessing unit includes a coordinate alignment module, an adaptive noise filtering module, and a data downsampling module; The coordinate alignment module is used to convert multi-view point cloud data to a unified world coordinate system; The adaptive noise filtering module uses an improved bilateral filtering algorithm, combined with the density distribution characteristics of pipeline point clouds, to dynamically adjust the filtering parameters and achieve accurate removal of noise and outliers. The data downsampling module employs a voxel grid downsampling algorithm to reduce the amount of point cloud data while preserving the key features of the pipeline.

3. The pipeline reverse modeling system based on point cloud data according to claim 1, characterized in that, The pipeline feature extraction unit includes: an axis fitting module, a pipe diameter measurement module, and an auxiliary component identification module; The axis fitting module is based on a cylindrical surface fitting method improved by the RANSAC algorithm to extract the spatial coordinates and orientation of the pipeline's central axis. The pipe diameter measurement module calculates the average distance from the pipe point cloud to the axis and combines it with local point cloud density correction to obtain the actual inner and outer diameter of the pipe. The auxiliary component identification module uses a deep learning semantic segmentation model to identify welds, flanges, and valve auxiliary components in point cloud data, and extracts the position, size, and orientation features of the auxiliary components.

4. The pipeline reverse modeling system based on point cloud data according to claim 1, characterized in that, The model verification unit includes: a point cloud-model deviation analysis module and an engineering accuracy verification module; The point cloud-model deviation analysis module calculates the average and maximum deviations between the original point cloud data and the reconstructed model to determine whether the model accuracy meets the preset threshold. The engineering accuracy verification module, in conjunction with petrochemical industry modeling standards, verifies the dimensional tolerances and assembly relationships of the model.

5. A pipeline reverse modeling method based on point cloud data, applied to the pipeline reverse modeling system based on point cloud data as described in any one of claims 1-4, characterized in that, Includes the following steps: S1. An acquisition system consisting of a laser scanner, a structured light scanner, and an industrial camera is used to perform multi-view and all-round scanning of the target petrochemical pipeline, acquire point cloud data of the pipeline body, welds, flanges, and valves, and simultaneously record the GPS coordinates and attitude information of the scanning position. S2. Preprocess the point cloud data; S3. Extract pipeline features, including: S31. Using the improved RANSAC cylindrical surface fitting method, the spatial coordinates of the pipe's central axis are extracted from the preprocessed point cloud data. x(t), y(t), z(t) ) and direction vector n =( a,b,c ); S32. Calculate the set of distances from the pipeline point cloud to the central axis { d1,d2,...,dn After removing extreme values, the average value is taken as the pipe radius r. Combined with the pipe material thickness standard, the inner diameter is determined. With outer diameter ; S33. Input the preprocessed point cloud data into the improved PointNet++ semantic segmentation model to identify welds, flanges, valve accessories, and extract the position coordinates, length, and width of the welds, the outer diameter of the flanges, the number and distribution of bolt holes, and the model and installation angle characteristic parameters of the valves. S4. Reconstruct the parametric model of the pipeline, including: S41. Call the standard pipe model library in the database and generate a three-dimensional curved surface model of the main body of the pipe based on the axis parameters and pipe diameter; S42. Based on the characteristic parameters of the auxiliary components, call the corresponding standard component model library, and assemble the weld, flange, and valve auxiliary components to the corresponding positions of the pipeline main body model through coordinate positioning and attitude adjustment. S43. Boolean operations are used to fuse the models of each component, and surface smoothness of the model is optimized through surface stitching technology to generate a complete three-dimensional model of the petrochemical pipeline. S5, operating condition adaptation optimization, including: S51. Obtain the actual operating condition data of the target pipeline, including operating temperature T, operating pressure P, type of transported medium M, and service life Y; S52. Based on the finite element analysis method, simulate the stress distribution and deformation of the pipeline under working conditions, and adjust the wall thickness and weld size parameters of the model to make the model consistent with the physical state of the actual pipeline. S53. Based on the corrosion level of the medium type, add the anti-corrosion layer thickness parameter to the model to match the actual pipeline protection status. S6. Model Validation and Output, including: S61. Calculate the Euclidean distance between the original point cloud data and the reconstructed model, and calculate the average deviation. With maximum deviation ,like ≤0.5mm and If the result is ≤1.0mm, the accuracy requirement is met; otherwise, return to step S2 or S3 for reprocessing. S62. In accordance with the guidelines for three-dimensional digital design of petrochemical engineering, verify whether the number and spacing of bolt holes on the flange meet the standards. S63. Export the verified 3D model into a universal format for use in pipeline maintenance, renovation, and simulation analysis engineering applications.

6. The pipeline reverse modeling method based on point cloud data according to claim 5, characterized in that, The method for preprocessing the point cloud data in step S2 includes: S21. Based on GPS coordinates and attitude information, the ICP algorithm is used to register multi-view point cloud data to a unified world coordinate system to eliminate view deviation. S22. An improved bilateral filtering algorithm is adopted to dynamically adjust the filtering parameters according to the local point cloud density, remove scanning noise and environmental interference points and retain the effective point cloud of the pipeline. S23. Use a voxel grid downsampling algorithm and set the voxel size to 1 / 50 to 1 / 30 of the pipe diameter.

7. The pipeline reverse modeling method based on point cloud data according to claim 6, characterized in that, The calculation formula for the improved bilateral filtering algorithm in step S22 is as follows: ; in, p′ These are the coordinates of the filtered points. q For point p Points within the neighborhood, S For the set of neighborhood points, K These are the normalization coefficients; Weighting function: ; in, For point p and q Spatial distance, For point p and q Differences in intensity values, For spatial domain standard deviation, Let be the standard deviation of the range, and and The local point cloud density ρ is dynamically adjusted.

8. The pipeline reverse modeling method based on point cloud data according to claim 5, characterized in that, The extraction of the pipe's central axis in step S31 also includes segmentation of the curved pipe: When the actual curvature value of the central axis of the curved pipe k Conform When the curved pipe is divided into multiple straight pipe segments for axis fitting, the axes of each segment are then smoothly connected using spline curves. in, k 0 represents the preset curvature threshold. Let be the vector function representing the direction of the central axis of the curved pipe. t The parameterized variable for the center axis of the curved pipe; To move towards the vector For parameters t The first derivative of represents the rate of change of the slope of the tangent to the central axis of the curved pipe.

9. The pipeline reverse modeling method based on point cloud data according to claim 5, characterized in that, The method for correcting the positional accuracy of the auxiliary component assembly in step S42 is as follows: The installation position of the component is determined by the projection relationship between the center point coordinates of the component point cloud and the pipeline axis; the installation posture of the component is adjusted based on the angle between the normal vector of the component point cloud and the pipeline axis so that the component is perpendicular to the pipeline body or at a preset angle.

10. A computer device, the computer device comprising a readable storage medium, a memory, a processor, and a computer program stored on the readable storage medium and the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the pipeline reverse modeling method based on point cloud data as described in any one of claims 5-9.

Citation Information

Patent Citations

  • Municipal pipeline detection method and detection system based on nondestructive detection and artificial intelligence

    CN121280509A

  • Pipeline three-dimensional modeling method based on adaptive statistical filtering and ground constraint pose

    CN121353546A

  • Automatic reconstruction method for pipeline facility BIM model based on point cloud data

    CN108898662A

  • Data and model hybrid driven Lidar point cloud transmission tower three-dimensional modeling method

    CN116129074A

  • Pipeline splicing method based on laser radar vision assistance

    CN119379540A