Digital intelligent detection method and system for integrity of buried natural gas pipeline
By deploying sensing units and machine learning models in buried natural gas pipelines, collecting data in real time and performing incremental updates, the problems of low accuracy and poor real-time performance of traditional detection methods are solved, efficient and accurate stress prediction and risk assessment are achieved, safety hazards are reduced, and pipeline safety management efficiency is improved.
Patent Information
- Application Number
- CN202511070104.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-31
- Publication Date
- 2025-09-16
AI Technical Summary
Existing technologies make it difficult to efficiently and accurately monitor stress changes caused by non-uniform settlement in buried natural gas pipelines, making it difficult to identify safety hazards. Traditional detection methods have low accuracy, poor real-time performance and high costs, and cannot meet modern safety monitoring needs.
By deploying sensing units to collect pipeline data in real time, using machine learning models to predict equivalent stress, adopting an incremental update mechanism and a composite loss function, combined with physical constraint penalty terms, safety assessment results are generated to achieve efficient and accurate monitoring of buried natural gas pipelines.
It achieves efficient and accurate monitoring of buried natural gas pipelines under complex geological conditions, reduces safety hazards, provides graded early warnings, improves operation and maintenance efficiency, reduces accidents, is easy to operate and compatible with existing equipment.
Smart Images

Figure CN120650659A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of gas pipeline detection technology, and in particular to a method and system for digitally detecting the integrity of buried natural gas pipelines. Background Art
[0002] With the acceleration of urbanization and the continuous growth of natural gas demand, the safety and reliability of buried natural gas pipelines, as critical infrastructure for energy transportation, have become a focus of public attention. These pipelines are typically laid underground, exposed to complex geological environments and external interference factors. Among them, uneven settlement is one of the main hidden dangers leading to pipeline failure, especially in soft soils, coastal areas, or geologically active areas. Uneven foundation settlement can cause additional stress and deformation in the pipeline, such as increased axial tension or bending stress, which in turn amplifies the hoop stress and overall uneven stress distribution on the pipeline wall. If these stresses exceed the yield limit of the pipeline material, serious accidents such as leakage, rupture, and even explosion may occur, resulting in casualties, economic losses, and environmental pollution.
[0003] Traditional detection methods rely primarily on manual inspections, excavation verification, or simple physical measurement methods, such as electrical measurement, magnetic flux leakage detection, and ultrasonic testing. These methods have many limitations in practical applications. First, their accuracy is low. Limited by sensor resolution and environmental interference, they cannot accurately capture stress changes caused by small settlements, making it difficult to identify early hidden dangers. Second, their real-time performance is poor. Most of them use offline or periodic detection modes, which cannot achieve continuous monitoring. In particular, under dynamic working conditions, such as seasonal soil changes or external loads, the response lag is significant. In addition, these methods are complex and costly to operate, requiring a large amount of manpower and equipment investment. During the detection process, they may damage the ground structure or interrupt pipeline operation, affecting normal gas supply efficiency. With the expansion and aging of pipeline networks, existing technologies are no longer able to meet the needs of modern safety monitoring, including the rapid processing of massive data, early warning of potential risks, and intelligent analysis.
[0004] To address these challenges, the industry urgently needs to develop more advanced detection technologies to enhance the integrity assessment of buried natural gas pipelines and ensure their long-term stable operation under complex geological conditions. However, current research remains limited to basic theoretical discussions or local optimization, lacking a comprehensive and effective solution to the multivariate coupled stresses caused by non-uniform settlement. This not only hinders improvements in pipeline operation and maintenance efficiency but also increases the risk of safety incidents. Summary of the Invention
[0005] The purpose of the present invention is to address the shortcomings of the existing technology and propose a digital intelligent detection method and system for the integrity of buried natural gas pipelines. To achieve the above purpose, the embodiment of the present invention adopts the following technical solutions:
[0006] In a first aspect, an embodiment of the present invention provides a method for digitally detecting the integrity of a buried natural gas pipeline, comprising the following steps:
[0007] The pipeline data is collected through the sensing units deployed on the pipeline, including pipeline stress, pipeline internal pressure and foundation settlement;
[0008] The pipeline data is used as input and a preset machine learning model is used to predict the pipeline's equivalent stress. When new pipeline data is collected, the machine learning model is incrementally updated. The incremental update is trained using a composite loss function. The composite loss function includes a mean square error loss term used to measure the prediction error and a physical constraint penalty term that imposes a penalty when the equivalent stress prediction value exceeds the allowable stress of the pipeline material.
[0009] The safety assessment results of the pipeline are generated based on the comparison results of the equivalent stress prediction value and the preset allowable stress of the pipeline material.
[0010] Preferably, before the step of predicting the equivalent stress prediction value of the pipeline using a preset machine learning model, the pipeline data is preprocessed, and the preprocessing includes:
[0011] An adaptive window algorithm is used to detect whether there is concept drift in the data distribution of foundation settlement, and when concept drift is detected, an incremental update of the machine learning model is triggered;
[0012] The pipeline data is normalized using an online normalization method with incremental extreme value updating.
[0013] By calculating the settlement rate and the ratio of axial to hoop stress, automated feature engineering is performed to generate derived features, which are then used as input to the machine learning model.
[0014] Preferably, the machine learning model is a deep neural network model, which includes at least two hidden layers, wherein:
[0015] The first hidden layer uses the Swish activation function to enhance nonlinear feature representation and numerical stability, and applies L2 weight regularization and Dropout to constrain parameter norms and improve the generalization performance of the deep neural network model in intermittent sensor failure scenarios.
[0016] The second hidden layer uses the LeakyReLU activation function to alleviate the eigenvalue offset problem caused by mechanical vibration, and combines it with L1-L2 activation value regularization to constrain feature sparsity and smoothness at the neuron output level to suppress high-frequency noise in the sensor data.
[0017] Preferably, the Adam optimizer is used for incremental updates of the deep neural network model, and the gradient value is range-climed to improve stability during training.
[0018] Preferably, the machine learning model is a polynomial regression model, which fits the equivalent stress prediction value through a polynomial relationship including linear terms, quadratic terms and cross terms between foundation settlement and pipeline internal pressure.
[0019] Preferably, the incremental update of the polynomial regression model includes:
[0020] Use a sliding window mechanism to continuously retain the latest pipeline data and eliminate outdated samples;
[0021] Based on the data in the sliding window, the coefficients of the polynomial relationship are solved online using weighted least squares estimation with L2 regularization;
[0022] The newly solved coefficients are weighted and fused with the historical coefficients according to a preset ratio to achieve a smooth transition of the coefficients and maintain the stability of the polynomial regression model.
[0023] Preferably, after the incremental update of the machine learning and before the deployment, a machine learning model verification step is also included, and the machine learning model verification step includes:
[0024] Evaluate the root mean square error, mean absolute error, coefficient of determination, and stress exceedance rate of the updated machine learning model on a test set that is continuously rolled out with new data;
[0025] The updated machine learning model is allowed to be deployed only when the root mean square error and stress exceedance rate are both less than their respective preset safety admission thresholds.
[0026] Preferably, the deployment of the machine learning model adopts a canary release mechanism, which includes:
[0027] The updated machine learning model that has passed verification is selected as a candidate model and assigned an initial traffic weight. It is then used together with the current production model to process real-time prediction requests.
[0028] Dynamically adjust the traffic weight of the candidate model based on its prediction success rate in real data; when the success rate of the candidate model is higher than the preset target threshold, its weight is increased, otherwise its weight is reduced;
[0029] When the traffic weight of a candidate model exceeds the preset upgrade threshold, it is set as the new production model, completing the zero-downtime switch.
[0030] Preferably, the method further comprises a feedback closed-loop optimization step, which comprises:
[0031] Generate maintenance recommendations based on safety assessment results and historical maintenance data;
[0032] Receive maintenance processing results from operation and maintenance feedback and use them as reward signals for reinforcement learning to optimize the strategy for generating maintenance recommendations;
[0033] Based on the predicted needs or abnormal situations of the machine learning model, instructions are sent to the sensor unit to dynamically adjust the data sampling frequency of the sensor unit.
[0034] In a second aspect, an embodiment of the present invention proposes a digital intelligent detection system for the integrity of a buried natural gas pipeline, comprising: a data acquisition module, an equivalent stress prediction module, and a safety assessment module; wherein,
[0035] A data acquisition module is used to collect pipeline data through sensor units deployed on the pipeline. The pipeline data includes pipeline stress, pipeline internal pressure and foundation settlement;
[0036] The equivalent stress prediction module uses pipeline data as input and a preset machine learning model to predict the pipeline's equivalent stress. When new pipeline data is collected, the machine learning model is incrementally updated. This incremental update is trained using a composite loss function that includes a mean square error (MSE) loss term, used to measure prediction error, and a physical constraint penalty term that imposes a penalty when the equivalent stress prediction exceeds the allowable stress of the pipeline material.
[0037] The safety assessment module is used to generate a safety assessment result of the pipeline based on the comparison result between the equivalent stress prediction value and the preset allowable stress of the pipeline material.
[0038] Beneficial effects:
[0039] By deploying sensing units to collect real-time data such as pipeline stress, internal pressure, and foundation settlement, and using machine learning models to predict equivalent stress, this method enables efficient and accurate monitoring of buried natural gas pipelines under conditions of non-uniform settlement. This overcomes the limitations of traditional electrical measurement methods, such as low accuracy and poor real-time performance, and avoids safety hazards caused by untimely capture of stress changes. This method incorporates an incremental update mechanism. As new data is collected, the model is trained using a composite loss function, consisting of a mean squared error loss term and a physical constraint penalty term. This ensures that the model, while measuring prediction error, adheres to the physical limits of the pipeline material and avoids predicted values exceeding the allowable stress range. This improves the model's robustness and reliability, allowing it to adapt to dynamic changes in complex geological environments. Comparing the predicted equivalent stress with the allowable stress generates a safety assessment result, providing graded early warnings and enabling operations and maintenance personnel to quickly respond to potential risks, significantly reducing the probability of pipeline failure and minimizing the economic losses and environmental impacts associated with accidents. Furthermore, this method is simple to operate, requires no ground damage, and is compatible with existing equipment, making it easy to scale and apply, thereby improving overall pipeline safety management efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0040] Various other advantages and benefits will become apparent to those skilled in the art upon reading the detailed description of the preferred embodiment below. The accompanying drawings are for illustration purposes only and are not to be considered as limiting the present invention. The same reference numerals are used throughout the accompanying drawings to denote the same components. In the accompanying drawings:
[0041] Figure 1 A schematic diagram of a flow chart of a method for digitally detecting the integrity of a buried natural gas pipeline provided in one embodiment of the present invention;
[0042] Figure 2 This is a structural diagram of a digital intelligent detection system for underground natural gas pipeline integrity provided by one embodiment of the present invention. DETAILED DESCRIPTION
[0043] Embodiments of the present invention are described in detail below, examples of which are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended only to explain the present invention and are not to be construed as limiting the present invention. It should be noted that similar reference numerals and letters represent similar items in the following drawings, and therefore, once an item is defined in one drawing, it does not need to be further defined or explained in subsequent drawings.
[0044] First, see Figure 1As shown, a digital intelligent detection method for the integrity of a buried natural gas pipeline proposed in an embodiment of the present invention is applied to a digital intelligent detection system for the integrity of a buried natural gas pipeline; wherein, the digital intelligent detection system for the integrity of a buried natural gas pipeline can be, but is not limited to, executed by a computer device with certain computing resources, such as a personal computer (Personal Computer, PC, refers to a multi-purpose computer with a size, price and performance suitable for personal use; desktops, laptops to small laptops and tablets and ultrabooks are all personal computers), smart phones, personal digital assistants (Personal digital assistant, PAD) or platform server and other electronic devices. An embodiment of the present invention provides a digital intelligent detection method for the integrity of a buried natural gas pipeline, which is particularly suitable for the safety monitoring of buried natural gas pipelines under non-uniform settlement conditions, and can achieve efficient and accurate stress prediction and risk assessment. The following describes the method in detail in conjunction with specific implementation methods:
[0045] Step S1: collecting pipeline data through sensor units deployed on the pipeline. The pipeline data includes pipeline stress, pipeline internal pressure and foundation settlement.
[0046] Specifically, the sensing unit is a core hardware component, including high-precision strain sensors, pressure sensors and displacement sensors, which are used to collect key parameters such as pipeline axial stress, hoop stress, pipeline working internal pressure and foundation settlement in real time. These sensors are mainly installed in key parts of the pipeline, such as elbows, straight pipe sections and areas prone to uneven settlement, such as soft soil foundations or coastal geologically active areas. The sensing unit also integrates a wireless communication module that supports 5G or LoRa communication protocols to ensure the real-time and stability of data collection. During the data collection process, auxiliary information such as ambient temperature and humidity is collected regularly to assist in subsequent analysis. The collection frequency can be set according to actual needs, for example, once every 15 minutes, to capture dynamic changes.
[0047] To ensure data quality and security, the sensor unit uses an embedded chip for initial processing. This chip integrates multi-channel signal acquisition, filtering, and compression algorithms, enabling rapid processing of sensor data and reducing noise interference. This chip, called "PipeSense," is based on ARM architecture or FPGA technology, supporting edge computing and reducing cloud load. Furthermore, the smart port provides standardized interfaces, supports multiple sensor connections, is compatible with diverse pipeline environments, and supports hot-swappable functionality for easy on-site maintenance.
[0048] During the data collection process, data is uploaded to the cloud server via the wireless communication module. Security is ensured during the transmission phase, and encryption algorithms are used to protect data privacy. The encryption scheme is selected based on the communication protocol: For 5G transmission, a dual encryption scheme at the application layer and transport layer is used, including TLS 1.3 with AES_256_GCM and application-layer ECDSA signatures. For LoRa transmission, data link layer encryption is used, based on the Semtech standard-based AES-CTR mode enhanced to GCM mode, with a dynamic key rotation period of ≤ 15 minutes. This ensures the integrity and confidentiality of data from the sensor unit to the cloud.
[0049] In step S2, the pipeline data is used as input and the preset machine learning model is used to predict the equivalent stress prediction value of the pipeline. When new pipeline data is collected, the machine learning model is incrementally updated. The incremental update is trained using a composite loss function. The composite loss function includes a mean square error loss term for measuring the prediction error and a physical constraint penalty term. The physical constraint penalty term imposes a penalty when the equivalent stress prediction value exceeds the allowable stress of the pipeline material.
[0050] Specifically, the machine learning model uses collected pipeline stress (including axial and hoop stresses, with axial stress primarily caused by internal pipeline pressure and foundation settlement, and hoop stress primarily caused by internal pipeline pressure), internal pipeline pressure (the pressure of natural gas transported internally, which directly affects stress distribution), and foundation settlement (indicating the degree of non-uniform settlement; greater settlement means greater additional stress) as core inputs. Auxiliary information such as ambient temperature and humidity can be optionally included. The output is a predicted Von-Mises equivalent stress value, which comprehensively reflects the overall stress state of the pipeline and is used to determine whether it is approaching the yield limit.
[0051] The machine learning model can be a deep neural network (DNN) model, consisting of at least two hidden layers, designed to handle complex nonlinear relationships and multivariate inputs. The input layer configuration includes pre-processed data parameters such as axial stress, hoop stress, pipeline internal pressure, settlement, and ambient temperature. The DNN processing process consists of data pre-processing (normalization), forward propagation (multi-layer nonlinear transformation), physical constraint verification, and safety assessment.
[0052] The specific hidden layer design is as follows: The first hidden layer uses a 128-dimensional fully connected layer (Dense) combined with the Swish activation function (Swish(x) = x·σ(βx)) to enhance nonlinear feature representation capabilities. Its smooth gradient property is more conducive to numerical stability of embedded chips than ReLU. L2 weight regularization (λ = 0.001) is also applied to constrain parameter norms to prevent overfitting. This is followed by a 30% probability dropout layer. By randomly masking neuron outputs during training, the network is forced to learn redundant feature representations, thereby improving generalization performance, especially for intermittent sensor failure scenarios. The second hidden layer uses a 64-dimensional fully connected layer, combined with a LeakyReLU activation function (α = 0.3), to retain small gradient flows in negative regions, effectively alleviating the eigenvalue shift caused by mechanical vibration in pipeline monitoring data. Combined with hybrid L1-L2 activation value regularization (L1 coefficient 0.001, L2 coefficient 0.002), this constrains feature sparsity and smoothness at the neuron output level. This is particularly suitable for suppressing the impact of high-frequency noise (such as electromagnetic interference) in sensor data on Von-Mises stress prediction. Through hierarchical dimensionality reduction (128→64) and nonlinear transformation, this module ultimately outputs a feature vector adapted to the complex operating conditions of the pipeline, providing input data with a high signal-to-noise ratio for the subsequent regression prediction layer. Its regularization strength parameter has been verified by the PipeSense chip to balance model complexity and prediction accuracy within an RMSE error range of <5%.
[0053] The output layer is configured with a linear activation function (suitable for regression tasks) and the initialization method is the He normal distribution (suitable for ReLU family activation functions). Model evaluation indicators include root mean square error (RMSE), mean absolute error (MAE) and coefficient of determination (R 2 ) to ensure prediction accuracy.
[0054] When new pipeline data is collected, the machine learning model is incrementally updated, where the incremental update is trained using a composite loss function. The composite loss function includes a mean square error loss term for measuring the prediction error, and a physical constraint penalty term that imposes a penalty when the equivalent stress prediction value exceeds the allowable stress of the pipeline material. Specifically, the composite loss function is designed to have an MSE ratio of 80% and a physical constraint loss ratio of 20% (penalty when the predicted value exceeds 300MPa). Physical constraint fusion includes stress field boundary conditions (retraining is triggered when the predicted value exceeds 120% of the maximum value of the finite element simulation) and material property embedding (constitutive relationship constraints of pipeline steel, Young's modulus, yield strength). Training strategy optimization includes data enhancement methods (such as adding Gaussian noise and elastic deformation to simulate foundation micro-deformation) and optimizer configuration.
[0055] The Adam optimizer is used for incremental updates of the deep neural network model, and gradient values are clipped to improve stability during training. The Adam optimizer is configured with an initial learning rate of 0.001, a 4% decay every 10,000 steps, and momentum parameters β1 = 0.9 (first-order moment estimation) and β2 = 0.999 (second-order moment estimation). Gradient clipping uses the clip_by_value function to clip gradients within the range [-0.5, 0.5] to prevent gradient explosion. Furthermore, an incremental learning mechanism supports dynamic access to real-time sensor data streams for model fine-tuning, while maintaining the stability of the original model by cloning the base model. This design is suitable for reliable stress prediction in pipeline monitoring scenarios. When the cloud-based model detects that the Von-Mises stress caused by settlement is approaching a critical value, the trainer automatically suppresses overfitting predictions under dangerous conditions, stabilizing the prediction error within a safe threshold of 5%. Furthermore, gradient amplitude constraints (dual control of clipnorm and clip_by_value) ensure sustainable training on embedded chips with limited computing power.
[0056] During the incremental update process, continuous data collection and caching reliably receives and manages real-time monitoring data from buried pipeline sensors through cryptographic verification and a circular buffer storage mechanism. The specific process is as follows: When a new data packet arrives, the _verify_signature method is first called to verify the packet's digital signature (using the preset public key PUB_KEY) based on the Elliptic Curve Digital Signature Algorithm (ECDSA) to ensure the authenticity and integrity of the data source. Once verified, the packet content is parsed using _parse_packet to extract key parameters such as axial stress (stress_axial), hoop stress (stress_hoop), pipeline internal pressure (pressure), foundation settlement (settlement), and ambient temperature (temp), and a precise timestamp is appended. Finally, this structured data is stored in a 5000-byte circular buffer (CircularBuffer). This buffer uses a first-in-first-out policy to avoid memory overflows in resource-constrained embedded device scenarios while retaining the latest data for subsequent analysis. Metadata, such as sensor location, is recorded in a metadata list to support data traceability. The entire process implements full-link protection from data reception, security verification to temporary storage management, providing a reliable real-time data source for the pipeline monitoring system.
[0057] Dynamic data preprocessing is mainly used to process the raw data collected by buried pipeline sensors in real time. Its core functions include:
[0058] 1) Concept drift detection: The ADWIN algorithm is used to monitor the distribution changes of key parameters such as foundation settlement. When abnormal fluctuations are detected (such as a sudden change in settlement rate exceeding a threshold), the model retraining mechanism is automatically triggered.
[0059] 2) Online dynamic normalization: using the OnlineMinMaxScaler with incremental extreme value updates to normalize multi-source heterogeneous data, eliminating dimensional differences and adapting to dynamic changes in data distribution;
[0060] 3) Automated feature engineering: By calculating derived features such as settlement rate (settlement change per unit time) and stress ratio (the ratio of axial stress to hoop stress), this module enhances data characterization capabilities by integrating physical mechanisms. This provides high-quality input, encompassing both temporal dynamics and mechanical relationships, for subsequent machine learning models. This module utilizes encryption algorithms to secure data transmission and implements low-latency processing in edge computing chips, ultimately improving the accuracy and robustness of pipeline stress prediction models.
[0061] The incremental learning engine further supports online deep model learning. The physics-based incremental deep learning trainer (DNNTrainer) is specifically designed for online updates of buried pipeline stress prediction models. Its core function is to ensure real-time model updates while meeting engineering safety constraints through selective gradient clipping and a physics-aware loss function. Specific implementations include:
[0062] 1) When using the Adam optimizer for parameter updates, the gradient is clipped by clip_by_value to prevent gradient explosion and improve training stability;
[0063] 2) Constructing a composite loss function that combines the MSE with a physical constraint penalty term. The latter imposes an exponentially increasing penalty on predicted values exceeding the allowable stress through the ReLU function, forcing the model to comply with the mechanical properties of the material.
[0064] 3) An incremental learning mechanism is employed to support dynamic access to real-time sensor data streams for model fine-tuning, while maintaining the stability of the original model by cloning the base model. This design is particularly suitable for reliable stress prediction in pipeline monitoring scenarios. When the cloud-based model detects that the Von-Mises stress caused by settlement is approaching a critical value, the trainer automatically suppresses overfitting predictions under hazardous conditions, stabilizing the prediction error within a safe threshold. Gradient amplitude constraints also ensure sustainable training of the embedded chip within limited computing power.
[0065] The machine learning model can also be a polynomial regression model, which fits the equivalent stress prediction value through a polynomial relationship containing linear terms, quadratic terms, and cross terms between foundation settlement and pipeline internal pressure. The incremental update of the polynomial regression model includes: using a sliding window mechanism to continuously retain the latest pipeline data and eliminate obsolete samples; based on the data in the sliding window, using weighted least squares estimation with L2 regularization to solve the coefficients of the polynomial relationship online; weighted fusion of the newly solved coefficients and historical coefficients according to a preset ratio to achieve a smooth transition of the coefficients and maintain the stability of the polynomial regression model. Specifically, a sliding window of 2000 samples is used to continuously retain the latest monitoring data (including features such as the square of foundation settlement and the square of pipeline internal pressure), and obsolete samples are dynamically eliminated by intercepting the data at the end of the window to ensure that the model adapts to non-stationary data distribution; performing weighted least squares estimation with L2 regularization (lambda*eye term) to solve the polynomial coefficient θ=(X T X+λI) - 1X T y, where θ is the polynomial coefficient vector, representing the coefficients fitted by the model, used to describe the polynomial relationship between the Von-Mises equivalent stress and input features (such as foundation settlement and pipeline internal pressure). X is the input feature matrix, whose rows correspond to samples in the sliding window and columns correspond to polynomial features, including linear terms, quadratic terms, and cross terms of foundation settlement and pipeline internal pressure (such as foundation settlement, foundation settlement squared, pipeline internal pressure, pipeline internal pressure squared, and the product of settlement and internal pressure). These features are derived from pipeline data collected by sensors and are used to capture nonlinear relationships and coupling effects. X T is the transposed matrix of X, used to calculate the Gram matrix X T X. y is the output vector, corresponding to the actual or observed Von-Mises equivalent stress of each sample in the sliding window, which is used as the target of model fitting to train the polynomial regression model to predict the equivalent stress. λ is the L2 regularization parameter, which is used to control the model complexity and prevent overfitting and feature collinearity problems, such as matrix singularity caused by the coupling effect of settlement and internal pressure. I is the identity matrix, whose dimension is the same as X TX is the same as the L2 regularization term. The overall formula implements online model updates, triggering a calculation every 50 new data points. A coefficient smoothing strategy (new coefficients are merged with historical coefficients in a ratio of 0.2:0.8) maintains stability and ensures that the prediction error remains within a threshold. The regularization parameter λ controls model complexity and prevents matrix singularity problems caused by feature collinearity (such as the coupling effect of settlement and internal pressure). A coefficient smoothing strategy is used to merge the new coefficient θ with the historical coefficient current_coef in a ratio of 0.2:0.8, integrating new data features while maintaining model stability and avoiding sudden changes in predictions caused by abnormal single batch data. The algorithm integrates sensor data streams in real time and accurately fits the nonlinear relationship between Von-Mises stress, settlement, and internal pressure through the construction of characteristic quadratic terms. An update is triggered every 50 new data points on the edge computing chip, ensuring that the model prediction error remains within a threshold. The dual mechanisms of regularization and coefficient smoothing ensure robustness under extreme conditions (such as sudden settlement caused by heavy rain).
[0066] Preferably, after the incremental update of machine learning and before deployment, a machine learning model validation step is also included. The machine learning model validation step includes: evaluating the root mean square error, mean absolute error, coefficient of determination, and stress exceedance rate of the updated machine learning model on a test set that continuously rolls with new data; only when the root mean square error and stress exceedance rate are both less than their respective preset safety access thresholds, the updated machine learning model is allowed to be deployed. Specifically, a dynamic validation system (Validator) for pipeline stress prediction models is implemented. Its core function is to ensure the reliability and safety of the updated model through rolling test set evaluation and multiple safety threshold detection. The operation process is as follows:
[0067] 1) Maintain a rolling test set (deque structure) with a capacity of 1,000 samples, continuously incorporate the latest monitoring data and eliminate old data, and reflect the current working condition distribution in real time;
[0068] 2) Perform a quantitative evaluation of concept drift by calculating the KL divergence between the candidate model and the baseline model prediction results to detect the degree of data distribution shift;
[0069] 3) Perform multi-dimensional performance verification and calculate RMSE, MAE, R after sampling from the test set 2 and stress excess rate (ViolationRate, the ratio of the statistically predicted value exceeding the allowable stress);
[0070] 4) Implementing safety access control, returning validation as passed only when the RMSE is less than 8.0 MPa and the exceedance rate is less than 5%, prevents dangerous assessment results due to model degradation. The system seamlessly integrates with cloud-based analysis modules, automatically triggering validation before each model update to ensure the engineering reliability of Von-Mises stress predictions. A rolling test set mechanism also adapts to data distribution changes caused by soft soil foundation settlement (such as sensor reading drift caused by seasonal humidity changes).
[0071] Preferably, the deployment of machine learning models adopts a canary release mechanism, which includes: taking the updated machine learning model that has passed verification as a candidate model and assigning it an initial traffic weight, and processing real-time prediction requests together with the current production model; dynamically adjusting its traffic weight based on the candidate model's prediction success rate in real data; when the candidate model's success rate is higher than the preset target threshold, its weight is increased, and vice versa; when the candidate model's traffic weight exceeds the preset upgrade threshold, it is set as the new production model, completing zero-downtime switching. The specific process includes:
[0072] 1) During initialization, the new candidate model (which has passed the Validator verification) is added to the candidate pool with an initial traffic weight of 10%, and the current production model is retained as the baseline;
[0073] 2) During the real-time request distribution phase, prediction tasks are assigned based on the weight ratio of each model, while the model success rate is monitored (e.g., whether the prediction result triggers a security alarm retry);
[0074] 3) Perform dynamic weight adjustment based on performance, with a 95% success rate as the target threshold. If the actual success rate of the candidate model is higher than the threshold, its traffic weight is proportionally increased, otherwise its weight is reduced;
[0075] 4) When a candidate model's weight exceeds 95%, an automatic upgrade mechanism is triggered, setting it as the new production model and clearing the candidate pool, completing a zero-downtime switch. This system, linked to the Validator module, ensures that only models that have passed rigorous verification enter the release process. It also continuously monitors prediction metrics during the traffic switch. If a candidate model exhibits performance degradation in real-world data, the system automatically reduces its weight until it is rolled back, thus ensuring the continuity of pipeline safety assessment results and avoiding the risk of misjudgment due to model mutations.
[0076] In step S3, the safety assessment result of the pipeline is generated based on the comparison result of the equivalent stress prediction value and the preset allowable stress of the pipeline material. Specifically, the Von-Mises equivalent stress prediction value is compared with the allowable stress of the pipeline material (for example, 300MPa): if the predicted value is less than the allowable stress, the pipeline is in a "safe" state; if the predicted value is close to the allowable stress, a "warning" signal is issued; if the predicted value exceeds the allowable stress, it is determined to be in a "dangerous" state. The results are displayed in a visual form, including stress distribution diagrams, safety warning information and improvement suggestions (such as adjusting the pipeline burial depth and adding support structures). The assessment takes into account the impact of settlement on Von-Mises equivalent stress: non-uniform foundation settlement will cause additional bending stress and tensile and compressive stresses, changing the stress distribution; and the impact of pipeline internal pressure: the greater the internal pressure, the higher the annular and axial stresses, and the equivalent stress increases accordingly.
[0077] Preferably, the method also includes a feedback closed-loop optimization step, which includes: the cloud server generates maintenance recommendations based on safety assessment results and historical maintenance data; the cloud server receives the maintenance processing results fed back by the operation and maintenance system, and uses them as a reward signal for reinforcement learning to optimize the strategy for generating maintenance recommendations; the cloud server issues instructions to the sensor unit based on the model's predicted needs or abnormal conditions to dynamically adjust the data sampling frequency of the sensor unit. This closed-loop mechanism introduces a deep learning algorithm, combines historical and real-time data, accurately identifies abnormal working conditions, and provides a multi-dimensional visual interface to help operation and maintenance personnel quickly locate problems. It is suitable for natural gas pipelines on coastal or soft soil foundations, has strong adaptability, is compatible with existing equipment, has high practicality, is cost-effective, is easy to operate, and provides an integrated solution. It can be widely used in the field of natural gas transportation and provides technical support for pipeline safety management.
[0078] For the second aspect, please see Figure 2 The present invention also proposes a digital and intelligent detection system for the integrity of buried natural gas pipelines, which is compatible with the aforementioned digital and intelligent detection method for the integrity of buried natural gas pipelines. This system is suitable for safety monitoring of buried natural gas pipelines under conditions of uneven settlement, and enables efficient and accurate stress prediction and risk assessment. The system is described in detail below in conjunction with specific implementation methods. The system includes a data acquisition module, an equivalent stress prediction module, and a safety assessment module, each of which works collaboratively to form an integrated digital and intelligent detection framework.
[0079] The data acquisition module collects pipeline data, including pipeline stress, internal pressure, and foundation settlement, through sensing units deployed along the pipeline. Specifically, the module's core hardware comprises an intelligent sensing unit, which integrates high-precision strain sensors, pressure sensors, and displacement sensors. These sensors are used to collect real-time data on key parameters, including pipeline axial stress, hoop stress, internal operating pressure, and foundation settlement. These sensors are deployed primarily at critical locations along the pipeline, such as elbows, straight sections, and areas prone to uneven settlement, such as soft soil foundations or geologically active coastal areas, to ensure comprehensive coverage of potential risk nodes. The sensing unit also integrates a wireless communication module, supporting 5G or LoRa communication protocols, enabling real-time data transmission and ensuring stability. During the data collection process, the module regularly collects auxiliary information, such as ambient temperature and humidity, to aid subsequent analysis. The data collection frequency can be dynamically adjusted based on actual needs, for example, every 15 minutes, to capture dynamic changes such as foundation settlement.
[0080] To improve data quality and security, the data acquisition module uses an embedded chip for preliminary processing. This chip integrates multi-channel signal acquisition, filtering, and compression algorithms, enabling rapid processing of sensor data and reducing noise interference. Named "PipeSense," the chip is based on ARM architecture or FPGA technology, supports edge computing, and significantly reduces the load on cloud servers. At the same time, the module is equipped with a standardized intelligent port, provides a universal interface, supports the access of multiple sensors, is compatible with different types of pipeline environments, and supports hot-swappable functions for easy on-site maintenance and upgrades. This makes the system highly adaptable to complex geological conditions, avoiding the problems of low accuracy and poor real-time performance of traditional detection methods such as electrical measurement.
[0081] The data acquisition module ensures data integrity and privacy during transmission, uploading collected data to a cloud server via a wireless communication module. Encryption schemes are selected based on the communication protocol: For 5G transmission, a dual encryption scheme at the application and transport layers is employed, including TLS 1.3 with AES_256_GCM and application-layer ECDSA signatures. For LoRa transmission, data link layer encryption is used, using Semtech's improved AES-CTR mode enhanced to GCM mode, with a dynamic key rotation period of ≤15 minutes. This multi-layered encryption mechanism effectively mitigates the risk of data leakage and ensures reliable monitoring of buried natural gas pipeline security amidst accelerating urbanization.
[0082] The equivalent stress prediction module is used to take pipeline data as input and use a preset machine learning model to predict the equivalent stress prediction value of the pipeline. Specifically, the module uses the collected pipeline stress (including axial stress and hoop stress, of which axial stress is mainly caused by pipeline internal pressure and foundation settlement, and hoop stress is mainly caused by pipeline internal pressure), pipeline internal pressure (the pressure value of internal natural gas transportation, which directly affects the stress distribution) and foundation settlement (characterizing the degree of non-uniform settlement, the greater the settlement, the greater the additional stress) as core inputs, and can optionally include auxiliary information such as ambient temperature and humidity. The output is the Von-Mises equivalent stress prediction value, which comprehensively reflects the overall stress state of the pipeline and is used to determine whether it is close to the yield limit.
[0083] The machine learning model for this module is preferably a deep neural network (DNN) model, consisting of at least two hidden layers, designed to handle complex nonlinear relationships and multivariate inputs. The input layer configuration includes pre-processed data parameters such as axial stress, hoop stress, pipeline internal pressure, settlement, and ambient temperature. The DNN processing process consists of data pre-processing (normalization to the range [0.12, 0.87]), forward propagation (multi-layer nonlinear transformation), physical constraint verification, and prediction output.
[0084] The safety assessment module generates a pipeline safety assessment based on a comparison of the predicted equivalent stress with the preset allowable stress of the pipeline material. Specifically, the module compares the predicted Von-Mises equivalent stress with the allowable stress of the pipeline material (e.g., 300 MPa). If the predicted value is less than the allowable stress, the pipeline is considered "safe." If the predicted value is close to the allowable stress, a "warning" signal is issued. If the predicted value exceeds the allowable stress, the pipeline is considered "dangerous." The assessment results are provided to operation and maintenance personnel in a visual format, including stress distribution diagrams, safety warning information, and improvement suggestions (such as adjusting the pipeline burial depth or adding support structures). The module considers the impact of settlement on Von-Mises equivalent stress: uneven foundation settlement can cause additional bending, tensile, and compressive stresses, altering the stress distribution; and the impact of internal pipeline pressure: higher internal pressure increases the hoop and axial stresses, leading to increased equivalent stress. Using a polynomial prediction model or machine learning algorithm, the maximum Von-Mises equivalent stress is calculated, ensuring a prediction error of less than 5%.
[0085] Suitable for natural gas pipelines located along coastal areas or on soft soil, this method offers strong adaptability, compatibility with existing equipment, high practicality, significant cost-effectiveness, and ease of operation, providing an integrated solution. This invention can be widely used in the natural gas transportation sector, providing strong technical support for pipeline safety management. It overcomes the limitations of traditional methods, such as low precision and poor real-time performance, and ensures reliable assessment of pipeline integrity under conditions of uneven settlement.
[0086] While embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions, and variations may be made to the embodiments without departing from the principles and spirit of the invention, and that the scope of the invention is defined by the claims and their equivalents.
Claims
1. A digital intelligence detection method for the integrity of buried natural gas pipelines, characterized by: The following steps are involved: Collecting pipeline data through sensing units deployed on the pipeline, the pipeline data including pipeline stress, pipeline internal pressure and foundation settlement; The pipeline data is used as input and a preset machine learning model is used to predict an equivalent stress prediction value of the pipeline; when new pipeline data is collected, the machine learning model is incrementally updated, wherein the incremental update is trained using a composite loss function, the composite loss function including a mean square error loss term for measuring the prediction error and a physical constraint penalty term, wherein the physical constraint penalty term imposes a penalty when the equivalent stress prediction value exceeds the allowable stress of the pipeline material; A safety assessment result of the pipeline is generated based on a comparison result of the equivalent stress prediction value and a preset allowable stress of the pipeline material.
2. The method according to claim 1, characterized in that Before the step of predicting the equivalent stress prediction value of the pipeline using a preset machine learning model, the pipeline data is preprocessed, and the preprocessing includes: Adopting an adaptive window algorithm to detect whether there is concept drift in the data distribution of the foundation settlement, and triggering an incremental update of the machine learning model when concept drift is detected; Normalizing the pipeline data using an online normalization method with incremental extreme value updating; By calculating the settlement rate and the ratio of axial to hoop stress, automated feature engineering is performed to generate derived features, which are then used as input to the machine learning model.
3. The method according to claim 2, characterized in that The machine learning model is a deep neural network model, which includes at least two hidden layers, wherein: The first hidden layer uses a Swish activation function to enhance nonlinear feature representation and numerical stability, and applies L2 weight regularization and Dropout to constrain parameter norms and improve the generalization performance of the deep neural network model in intermittent sensor failure scenarios, respectively. The second hidden layer uses the LeakyReLU activation function to alleviate the eigenvalue offset problem caused by mechanical vibration, and combines it with L1-L2 activation value regularization to constrain feature sparsity and smoothness at the neuron output level to suppress high-frequency noise in the sensor data.
4. The method according to claim 3, characterized in that The Adam optimizer is used for incremental updates of deep neural network models, and the gradient values are clipped to improve stability during training.
5. The method according to claim 2, characterized in that The machine learning model is a polynomial regression model, which fits the equivalent stress prediction value through a polynomial relationship including linear terms, quadratic terms and cross terms between foundation settlement and pipeline internal pressure.
6. The method according to claim 5, characterized in that Incremental updates to the polynomial regression model include: Use a sliding window mechanism to continuously retain the latest pipeline data and eliminate outdated samples; Based on the data in the sliding window, using weighted least squares estimation with L2 regularization, the coefficients of the polynomial relationship are solved online; The newly solved coefficients are weighted and fused with the historical coefficients according to a preset ratio to achieve a smooth transition of the coefficients and maintain the stability of the polynomial regression model.
7. The method according to claim 1, characterized in that After the incremental update of the machine learning and before deployment, a machine learning model verification step is also included, and the machine learning model verification step includes: Evaluate the root mean square error, mean absolute error, coefficient of determination, and stress exceedance rate of the updated machine learning model on a test set that is continuously rolled out with new data; The updated machine learning model is allowed to be deployed only when the root mean square error and the stress exceedance rate are both less than their respective preset safety access thresholds.
8. The method according to claim 7, characterized in that The machine learning model is deployed using a canary release mechanism, which includes: The updated machine learning model that has passed verification is selected as a candidate model and assigned an initial traffic weight. It is then used together with the current production model to process real-time prediction requests. Dynamically adjust the traffic weight of the candidate model based on its prediction success rate in real data; when the success rate of the candidate model is higher than the preset target threshold, increase its weight, otherwise decrease its weight; When the traffic weight of the candidate model exceeds the preset upgrade threshold, it is set as the new production model to complete zero-downtime switching.
9. The method according to claim 1, characterized in that The method further includes a feedback closed-loop optimization step, wherein the feedback closed-loop optimization step includes: generating maintenance recommendations based on the safety assessment results and historical maintenance data; Receive maintenance processing results from operation and maintenance feedback, and use the maintenance processing results as reward signals for reinforcement learning to optimize the strategy for generating maintenance recommendations; According to the predicted demand or abnormal situation of the machine learning model, instructions are sent to the sensing unit to dynamically adjust the data sampling frequency of the sensing unit.
10. A digital intelligent detection system for the integrity of buried natural gas pipelines, characterized by: include: Data acquisition module, equivalent stress prediction module and safety assessment module; among them, A data acquisition module is used to collect pipeline data through sensor units deployed on the pipeline, wherein the pipeline data includes pipeline stress, pipeline internal pressure and foundation settlement; an equivalent stress prediction module, configured to take the pipeline data as input and predict an equivalent stress prediction value of the pipeline using a preset machine learning model; and incrementally update the machine learning model when new pipeline data is collected, wherein the incremental update is trained using a composite loss function, the composite loss function including a mean square error loss term for measuring the prediction error and a physical constraint penalty term for applying a penalty when the equivalent stress prediction value exceeds the allowable stress of the pipeline material; The safety assessment module is used to generate a safety assessment result of the pipeline based on a comparison result of the equivalent stress prediction value and a preset allowable stress of the pipeline material.
Citation Information
Cited By
Safety assessment method for differential settlement of power transmission tower
CN122088208A
Uneven settlement safety evaluation method for power transmission tower
CN122088208B