Sequential detection method and device for pipeline leakage based on sequential probability ratio test

CN122920358APending Publication Date: 2026-10-16HUANENG CLEAN ENERGY RES INST +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611243754.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-17
Publication Date
2026-10-16

AI Technical Summary

Technical Problem

[0003]然而,现有基于固定阈值或固定样本量的检测方法,但固定阈值法难以兼顾检测灵敏度与虚警率:阈值设置过低,则压力正常波动(如泵启停、阀门调节)易引发频繁虚警;阈值设置过高,则对缓慢发展的微小泄漏不敏感,导致漏报

Benefits of technology

[0014]本申请实施例提供的基于序贯概率比检验的管道泄漏序贯检测方法及装置,该方法通过每类传感器的时间序列预测模型计算当前采样时刻的采集值对应的预测值,获取该类传感器的采集值与预测值间的残差;基于每类传感器的残差,利用配置的泄漏状态概率模型和正常状态概率模型,获取相应残差的泄漏概率值和正常概率值,及相应传感器的个体似然比;将当前采样时刻每类传感器的个体似然比进行加权,得到当前采样时刻的综合似然比;基于预设时间段内的综合似然比和预设泄漏阈值,触发泄漏报警。该方法通过序贯概率比检验加权融合多类传感器的残差似然比,实现了管道泄漏的快速、精准序贯检测与低误报率报警。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122920358A_ABST
    Figure CN122920358A_ABST
Patent Text Reader

Abstract

The application provides a pipeline leakage sequential detection method and device based on sequential probability ratio test. The method calculates a prediction value corresponding to a collection value at a current sampling time through a time series prediction model of each type of sensor, and obtains a residual between the collection value and the prediction value of the sensor. Based on the residual of each type of sensor, a leakage probability value and a normal probability value of the corresponding residual are obtained by using a configured leakage state probability model and a normal state probability model, and an individual likelihood ratio of the corresponding sensor is obtained. The individual likelihood ratios of each type of sensor at the current sampling time are weighted to obtain a comprehensive likelihood ratio at the current sampling time. Based on the comprehensive likelihood ratio in a preset time period and a preset leakage threshold, a leakage alarm is triggered. The method fuses the residual likelihood ratios of multiple types of sensors by sequential probability ratio test weighting, and realizes rapid, accurate sequential detection and low false alarm rate alarm of pipeline leakage.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of pipeline safety monitoring technology, and more specifically, to a pipeline leakage sequential detection method and device based on sequential probability ratio test. Background Technology

[0002] Currently, commonly used pipeline leak detection methods mainly include negative pressure wave method, flow balance method, acoustic wave method, and model-based state estimation method. Taking the negative pressure wave method as an example, its basic principle is: when a pipeline leaks, a negative pressure wave propagating upstream and downstream is instantaneously generated at the leak point. This method captures this pressure waveform using pressure sensors placed at both ends of the pipeline and calculates the leak location using the pressure drop point and the relationship between wave velocity and distance. In practical applications, the system usually sets a fixed threshold for the pressure signal; when the pressure drop exceeds this threshold, a leak is determined. Alternatively, the system collects a fixed-length signal window, calculates its statistical characteristics (such as mean and variance), and then compares it with a statistical model under normal operating conditions.

[0003] However, existing detection methods are based on fixed thresholds or fixed sample sizes, but the fixed threshold method is difficult to balance detection sensitivity and false alarm rate: if the threshold is set too low, normal pressure fluctuations (such as pump start-up and shutdown, valve adjustment) can easily trigger frequent false alarms; if the threshold is set too high, it will not be sensitive to slowly developing small leaks, resulting in missed detections. Summary of the Invention

[0004] The purpose of this application is to provide a pipeline leakage sequential detection method and device based on sequential probability ratio test, which can realize rapid and accurate pipeline leakage sequential detection and low false alarm rate alarm by weighted fusion of the residual likelihood ratios of multiple types of sensors through sequential probability ratio test.

[0005] Firstly, a sequential detection method for pipeline leaks based on sequential probability ratio testing is provided, which may include: The predicted value corresponding to the current sampling time is calculated by using the time series prediction model of each type of sensor, and the residual between the collected value and the predicted value of that type of sensor is obtained. Based on the residuals of each type of sensor, the leakage probability value and normal probability value of the corresponding residuals are obtained using the configured leakage state probability model and normal state probability model, as well as the individual likelihood ratio of the corresponding sensor. The individual likelihood ratios of each type of sensor at the current sampling time are weighted to obtain the comprehensive likelihood ratio at the current sampling time. A leakage alarm is triggered based on the comprehensive likelihood ratio within a preset time period and a preset leakage threshold.

[0006] In one possible implementation, the time series prediction model is an autoregressive moving average model; At the current sampling time, the predicted value for the current time is calculated based on historical signal values ​​using the time series prediction model for each type of sensor, including: For each type of sensor, the autoregressive coefficients and moving average coefficients of the model are obtained by fitting historical signal data of at least one complete cycle collected under normal pipeline operation conditions using the least squares method or the maximum likelihood method. During real-time detection, each time a new collected value is obtained, the collected value and historical collected values ​​from multiple previous times are input into the autoregressive moving average model, and the predicted value for the current time is output.

[0007] In one possible implementation, both the leakage state probability model and the normal state probability model adopt a Gaussian distribution model; The mean and variance of the normal state probability model are obtained by maximum likelihood estimation of the residual data during the historical normal operation of the pipeline; the mean and variance of the leakage state probability model are estimated by the historical leakage event data of the pipeline or the leakage residual data generated by pressure-flow simulation.

[0008] In one possible implementation, before weighting the individual likelihood ratios of each type of sensor at the current sampling time, the method further includes: For each type of sensor, calculate the arithmetic mean or variance of the absolute values ​​of its residuals within the sliding time window, which is taken as the instantaneous activity of the sensor. The instantaneous activity of all sensors is normalized to obtain the initial weights; The initial weights are subjected to exponential smoothing filtering to obtain the fused weights at the current sampling time; The smoothing factor of the exponential smoothing filter is dynamically adjusted according to the stability of the pipeline operating conditions.

[0009] In one possible implementation, the preset leakage threshold includes a first threshold and a second threshold, and the first threshold is greater than the second threshold; A leakage alarm is triggered based on a comparison of all comprehensive likelihood ratios within a time period including the current sampling time and a preset leakage threshold, including: The cumulative test statistic is obtained by multiplying the comprehensive likelihood ratios calculated at each sampling time within the time period. If the cumulative statistic is greater than or equal to the first threshold, a leakage alarm is triggered and the cumulative statistic is reset to 1.

[0010] In one possible implementation, after triggering the leak alarm, the method further includes: The system acquires the original pressure signal waveforms from multiple sampling times prior to the alarm triggering time. By detecting the negative pressure wave inflection point in the original pressure signal waveform, and combining the time difference between the sensors at both ends of the pipeline with the propagation speed of sound waves in the pipeline medium, the location of the leak point is calculated.

[0011] Secondly, a pipeline leakage sequential detection device based on sequential probability ratio test is provided, the device may include: The acquisition unit is used to calculate the predicted value corresponding to the collected value at the current sampling time through the time series prediction model of each type of sensor, and to obtain the residual between the collected value and the predicted value of that type of sensor. Furthermore, based on the residuals of each type of sensor, the leakage probability value and normal probability value of the corresponding residuals are obtained using the configured leakage state probability model and normal state probability model, as well as the individual likelihood ratio of the corresponding sensor. The weighting unit is used to weight the individual likelihood ratios of each type of sensor at the current sampling time to obtain the comprehensive likelihood ratio at the current sampling time; The triggering unit is used to trigger a leakage alarm based on the comprehensive likelihood ratio within a preset time period and a preset leakage threshold.

[0012] Thirdly, an electronic device is provided, which includes a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other through the communication bus; Memory, used to store computer programs; When a processor executes a program stored in memory, it implements any of the steps described in the first aspect above.

[0013] Fourthly, a computer-readable storage medium is provided, wherein a computer program is stored therein, and when executed by a processor, the computer program implements the steps of any of the methods described in the first aspect above.

[0014] The sequential detection method and apparatus for pipeline leaks based on sequential probability ratio testing provided in this application embodiment calculate the predicted value corresponding to the collected value at the current sampling time through the time series prediction model of each type of sensor, and obtain the residual between the collected value and the predicted value of that type of sensor; based on the residual of each type of sensor, using the configured leakage state probability model and normal state probability model, obtain the leakage probability value and normal probability value of the corresponding residual, as well as the individual likelihood ratio of the corresponding sensor; weight the individual likelihood ratios of each type of sensor at the current sampling time to obtain the comprehensive likelihood ratio at the current sampling time; trigger a leak alarm based on the comprehensive likelihood ratio within a preset time period and a preset leak threshold. This method achieves rapid and accurate sequential detection of pipeline leaks and low false alarm rate alarms by weighted fusion of the residual likelihood ratios of multiple types of sensors through sequential probability ratio testing. Attached Figure Description

[0015] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments of this application will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.

[0016] Figure 1 A flowchart illustrating a sequential detection method for pipeline leakage based on sequential probability ratio testing, provided in an embodiment of this application; Figure 2 A schematic diagram of a pipeline leakage sequential detection device based on sequential probability ratio test provided in an embodiment of this application; Figure 3 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0017] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of the embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application. Unless otherwise defined, the technical or scientific terms used in this application should have the ordinary meaning understood by those skilled in the art. The words "first," "second," and similar terms used in this application do not indicate any order, quantity, or importance, but are only used to distinguish different components. The words "comprising" or "including," etc., mean that the element or object preceding the word covers the element or object listed after the word and its equivalents, but do not exclude other elements or objects. The words "connected," "coupled," or "connected," etc., are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect. "Up," "down," "left," "right," etc., are only used to indicate relative positional relationships. When the absolute position of the described object changes, the relative positional relationship may also change accordingly.

[0018] The sequential detection method for pipeline leakage based on sequential probability ratio test provided in this application embodiment is applied to a pipeline leakage sequential detection system, which includes: a multi-type sensor group, a data acquisition unit, a data processing unit, a storage unit, and an alarm output unit.

[0019] Sensor array: A set of sensors is installed upstream and downstream of the pipeline, including at least a pressure sensor, a flow sensor, and a temperature sensor. The pressure sensor is used to collect the pressure signal within the pipeline, the flow sensor is used to collect the medium flow signal, and the temperature sensor is used to collect the medium temperature signal. All sensors operate synchronously at a fixed sampling rate (e.g., 100Hz).

[0020] Data acquisition unit: Connects to each sensor via a multi-channel synchronous data acquisition card (such as NI PXIe-1073), converts analog signals into digital signals, and adds timestamps.

[0021] Data processing unit: This is an embedded industrial computer or a high-performance digital signal processor (DSP) that runs the sequential detection method described in this invention. This unit is connected to the data acquisition unit via a high-speed bus (such as PCIe) to read the timing data from each sensor in real time.

[0022] Storage unit: Used to store historical normal operating condition data, model parameters, leakage templates, intermediate calculation results and alarm logs.

[0023] Alarm output unit: When a leak is detected, an alarm message is issued through an audible and visual alarm, a remote terminal unit (RTU), or a host computer interface, and the location of the leak is displayed.

[0024] The connections between the components are as follows: the sensor output is connected to the data acquisition unit input, the data acquisition unit output is connected to the data processing unit input, the data processing unit and the storage unit are bidirectionally connected, and the data processing unit output is connected to the alarm output unit.

[0025] The preferred embodiments of this application are described below with reference to the accompanying drawings. It should be understood that the preferred embodiments described herein are for illustration and explanation only and are not intended to limit this application. Furthermore, the embodiments and features in the embodiments of this application can be combined with each other without conflict.

[0026] Figure 1 This is a schematic flowchart illustrating a sequential detection method for pipeline leaks based on sequential probability ratio testing, provided as an embodiment of this application. Figure 1 As shown, the method may include: Step S110: At the current sampling time, calculate the predicted value corresponding to the current sampling value based on the historical sampling value using the time series prediction model of each type of sensor, and obtain the residual between the sampling value and the predicted value of that type of sensor.

[0027] For each type of sensor (pressure, flow, temperature), a time series prediction model under normal operating conditions is pre-established. In a preferred embodiment, the time series prediction model is an autoregressive moving average (ARMA) model. The order of this model (autoregressive order) is... and moving average order The Bayesian Information Criterion (BIC) is used to determine the parameters offline during normal pipeline operation. The estimation method for the model parameters is as follows: Using historical signal data from at least one complete cycle collected during normal pipeline operation (e.g., 24 consecutive hours of leak-free data), autoregressive coefficients are obtained by fitting data using the least squares method or the maximum likelihood method. and moving average coefficient For a pressure sensor, its ARMA model can be expressed as:

[0028] in: For the first Sensor-like devices at all times The actual collected value; For the first Sensor-like moments in history The actual collected value; These are the autoregressive coefficients; The moving average coefficient; For the first Sensor-like moments in history The prediction error (residual); The predicted value output by the model; Let the prediction error (residual) be the current time step, and satisfy the following condition: ; The order of the model.

[0029] During real-time detection, each new collected value is obtained The collected value and previous values Historical data collected at a given time and before Prediction error at each time point Input the ARMA model to calculate the predicted value at the current time. Thus, the residual is obtained: .

[0030] Furthermore, to adapt to the slow, time-varying characteristics of the pipeline (such as scaling and aging), the ARMA model parameters are updated online recursively every fixed time period (e.g., 1 hour) using normal operating condition signals from the most recent time period. The update employs a recursive least squares method with a forgetting factor. Based on the short-time variance of pipeline pressure fluctuations Dynamic adjustment: ,in This represents the reference variance under steady-state conditions. When the short-time variance is small, the forgetting factor is close to 1, and the model retains long-term memory. When the short-time variance exceeds the steady-state threshold, the forgetting factor automatically decreases, allowing the model to quickly adapt to unsteady-state conditions.

[0031] Step S120: Based on the residuals of each type of sensor, use the configured leakage state probability model and normal state probability model to obtain the leakage probability value and normal probability value of the corresponding residuals, as well as the individual likelihood ratio of the corresponding sensor.

[0032] For the residual of each type of sensor Establish normal state probability models respectively and leakage state probability model In this embodiment, both adopt a Gaussian distribution model: Normal state:

[0033] Leakage status:

[0034] Normal state parameters: It is set as the long-term statistical mean of the residuals during normal pipeline operation; This is set as the long-term statistical variance of the residuals. Specifically, it is obtained by maximum likelihood estimation of the residual data from seven consecutive days of leak-free pipeline operation.

[0035] Leakage status parameters: The preset leakage characteristic residual amplitude is set. This amplitude is obtained through pipeline leakage simulation experiments (such as CFD-based pressure-flow coupling simulations) or historical real leakage data calibration. For example, for pressure sensors, the mean value of the leakage residual is taken as... MPa (negative pressure wave amplitude); for flow sensors, take as... m³ / s (flow rate increases). To simplify the model, variance... Set the variance to the same as the normal state, i.e. .

[0036] Then, for the current sampling time The Sensor-like residual The individual likelihood ratio is defined as:

[0037] in, For the first Sensor-like devices at all times The individual likelihood ratio.

[0038] like This indicates that the current residual of the sensor is more likely to be in a leaking state; if If so, it tends to be in a normal state.

[0039] Furthermore, to prevent minor leaks or transient disturbances in historical data from contaminating the estimation of normal-state parameters, in the calculation... and Previously, the interquartile range of the residuals within the sliding window could be calculated. It will exceed the average. The residual points were identified as outliers and removed. Then, the mean and variance were recalculated based on the clean data after the removal. Meanwhile, the length of the sliding window decreases exponentially with pipeline operating time, making the contribution of recent data to the model parameters greater than that of long-term data.

[0040] Step S130: Weight the individual likelihood ratios of each type of sensor at the current sampling time to obtain the comprehensive likelihood ratio at the current sampling time.

[0041] Before performing this step, in order to dynamically evaluate the reliability and sensitivity of each sensor at the current moment, the fusion weights are adaptively determined based on the variation of the residuals of various sensors within the current time window. The specific steps are as follows: (1) Calculate instantaneous activity: For the first For sensor-like devices, calculate their residuals within a sliding time window. (length The arithmetic mean or variance of the absolute values ​​within a range of 50 sampling points (e.g., 50 sampling points) is used as the instantaneous activity of the sensor.

[0042] (2) Normalization yields the initial weights: ,in, The total number of sensors (in this example) (corresponding to pressure, flow rate, and temperature). For the first The initial fusion weights for the sensor-like structures are dimensionless, and . This represents the total number of sensors.

[0043] (3) Exponential smoothing filter: In order to suppress the drastic fluctuation of the weights, the initial weights are exponentially smoothed: This is used to obtain the fusion weights at the current sampling time.

[0044] in, This is a smoothing factor, which is dynamically adjusted based on the stability of the pipeline operating conditions. Under steady-state operating conditions, take (A larger smoothing factor) is used to suppress weight jitter; under unsteady operating conditions (such as valve regulation and pump start-up), a larger smoothing factor is used. (Smaller smoothing factor) to improve the weights’ response speed to leakage.

[0045] Operating conditions can be identified using the rate of change of pressure. and flow rate Threshold judgment: When both are below the preset threshold, it is a steady state; otherwise, it is an unsteady state.

[0046] Furthermore, to more precisely adapt to signal trends, the smoothing factor can be dynamically adjusted based on the residual sign change rate. Define the sign change rate: ; when When the value is below 0.1, the signal is determined to be in a unidirectional trend of continuous rise or fall. In this case, the smoothing factor is forcibly set to a minimum value (e.g., 0.9) to make the weights quickly track the trend; when When the value is higher than 0.5, the signal is determined to be in a state of random oscillation, and the smoothing factor is forced to be set to the maximum value (such as 0.1) to suppress weight noise.

[0047] For step S130, after obtaining the fusion weights of each sensor, the current sampling time... The overall likelihood ratio is: ; Or, equivalently, compute in the logarithmic field: ; Step S140: Trigger a leakage alarm based on the comprehensive likelihood ratio within a preset time period and a preset leakage threshold.

[0048] A leakage alarm is triggered based on the comparison results of all comprehensive likelihood ratios within a time period including the current sampling time and a preset leakage threshold.

[0049] First, multiply the composite likelihood ratios calculated at each sampling time point within this time period consecutively to obtain the cumulative test statistic; specifically: starting from the beginning of this test... Starting from this point, the comprehensive likelihood ratio calculated at each sampling time point... By multiplying them consecutively, we obtain the cumulative test statistic:

[0050] Initial time For each new sample obtained, update: In practical calculations, logarithmic form is usually used to avoid numerical overflow: .

[0051] Then, two leakage thresholds are preset: the first threshold Second threshold ,satisfy The threshold size is determined based on the desired false alarm rate. and underreporting rate The setting is theoretically acceptable. , .

[0052] At each sampling time The following comparison logic is executed: Case 1: If If this occurs, a leak alarm is triggered, the current sampling time is recorded as the leak occurrence time, and then the cumulative statistics are reset. Then, begin the next round of testing (i.e., start again from the next sampling point).

[0053] Scenario 2: If If no leakage is found in the current process, the cumulative statistics are reset directly. Now, let's begin the next round of testing.

[0054] Scenario 3: If If the current cumulative statistics remain unchanged, continue collecting data at the next sampling time and return to step S110.

[0055] Furthermore, in practical applications, the first threshold Second threshold It is not a fixed value, but rather can be adaptively adjusted based on the pipeline's current operating pressure, flow rate, and historical false alarm rate. The specific strategy is as follows: When the pipeline is in steady-state operation and the historical false alarm rate is lower than the target value (e.g., 1%), the upper threshold is lowered (e.g., from 100 to 50) to improve leak detection sensitivity, while the lower threshold is raised (e.g., from 0.01 to 0.05) to shorten the number of samples required to determine no leaks.

[0056] When the pipeline is in a non-steady-state operation such as valve adjustment or pump start-up, the upper threshold is increased (e.g., from 100 to 500) to prevent false alarms, while the lower threshold is decreased (e.g., from 0.01 to 0.001) to avoid premature reset of statistics due to short-term fluctuations.

[0057] In some embodiments, when a leak alarm is triggered or no leak is detected and the system is reset... Subsequently, a reset silence period mechanism was introduced. Specifically, before the reset... Within each sampling time, the alarm should not be triggered or reset again (i.e., no final decision should be output). It is dynamically correlated with the fluctuation period of the pipeline pressure signal, and its value is taken as the most recent normal fluctuation period. The normal fluctuation cycle is estimated using the autocorrelation function of historical pressure signals.

[0058] During the silent period, the cumulative statistics are still calculated and compared with the threshold, but the comparison results are only used to update the internal state (e.g., for subsequent threshold adaptation) and no alarms are output or decisions are reset. After the silent period ends, normal decision output resumes.

[0059] In some embodiments, after a leak alarm is triggered, the following location steps are performed: (1) Extract negative pressure wave waveform: obtain the waveform before the alarm trigger time. Each sampling time (e.g.) The original pressure signal waveform (Note: Use the original pressure signal without predictive residual calculation).

[0060] (2) Detection of negative pressure wave inflection point: The starting time of pressure drop caused by leakage is determined by detecting the negative pressure wave inflection point in the pressure waveform. This embodiment adopts a mutation point detection submodule based on sequential likelihood ratio test. This submodule runs independently after triggering the leakage alarm: using a pressure signal before the alarm time as a reference, the starting point of pressure drop is searched backward step by step using sequential probability ratio test. Specifically, it traverses backward from the alarm time, calculates the current backward cumulative statistic for each previous sampling point, and determines the point as the negative pressure wave inflection point when it exceeds a preset threshold.

[0061] (3) Calculate the leak location: Assume the inflection point of the negative pressure wave detected by the upstream sensor is _____. The inflection point detected by the downstream sensor is The speed of sound wave propagation in the pipe medium is (Given constants, such as those used in liquids) The length of the pipe is The distance from the leak point to the upstream sensor is... for: in It could be negative, indicating that the upstream sensor detected the negative pressure wave first.

[0062] (4) Output results: The leak location and alarm information are output together, and the degree of leak can be qualitatively assessed by combining the cumulative number of recorded samples (e.g., small, medium, large leaks).

[0063] Corresponding to the above method, this application also provides a pipeline leakage sequential detection device based on sequential probability ratio test, such as... Figure 2 As shown, the device includes: The acquisition unit 210 is used to calculate the predicted value corresponding to the collected value at the current sampling time through the time series prediction model of each type of sensor, and to obtain the residual between the collected value and the predicted value of that type of sensor. Furthermore, based on the residuals of each type of sensor, the leakage probability value and normal probability value of the corresponding residuals are obtained using the configured leakage state probability model and normal state probability model, as well as the individual likelihood ratio of the corresponding sensor. The weighting unit 220 is used to weight the individual likelihood ratios of each type of sensor at the current sampling time to obtain the comprehensive likelihood ratio at the current sampling time; Triggering unit 230 is used to trigger a leakage alarm based on the comprehensive likelihood ratio within a preset time period and a preset leakage threshold.

[0064] The functions of each functional unit of the pipeline leakage sequential detection device based on sequential probability ratio test provided in the above embodiments of this application can be implemented through the above method steps. Therefore, the specific working process and beneficial effects of each unit in the pipeline leakage sequential detection device based on sequential probability ratio test provided in the embodiments of this application will not be repeated here.

[0065] This application also provides an electronic device, such as... Figure 3 As shown, it includes a processor 310, a communication interface 320, a memory 330, and a communication bus 340, wherein the processor 310, the communication interface 320, and the memory 330 communicate with each other through the communication bus 340.

[0066] Memory 330 is used to store computer programs; When the processor 310 executes the program stored in the memory 330, it performs the following steps: The predicted value corresponding to the current sampling time is calculated by using the time series prediction model of each type of sensor, and the residual between the collected value and the predicted value of that type of sensor is obtained. Based on the residuals of each type of sensor, the leakage probability value and normal probability value of the corresponding residuals are obtained using the configured leakage state probability model and normal state probability model, as well as the individual likelihood ratio of the corresponding sensor. The individual likelihood ratios of each type of sensor at the current sampling time are weighted to obtain the comprehensive likelihood ratio at the current sampling time. A leakage alarm is triggered based on the comprehensive likelihood ratio within a preset time period and a preset leakage threshold.

[0067] The communication bus mentioned above can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. This communication bus can be divided into address bus, data bus, control bus, etc. For ease of illustration, only one thick line is used to represent it in the diagram, but this does not mean that there is only one bus or one type of bus.

[0068] The communication interface is used for communication between the aforementioned electronic devices and other devices.

[0069] The memory may include random access memory (RAM) or non-volatile memory (NVM), such as at least one disk storage device. Optionally, the memory may also be at least one storage device located remotely from the aforementioned processor.

[0070] The processors mentioned above can be general-purpose processors, including central processing units (CPUs), network processors (NPs), etc.; they can also be digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.

[0071] The implementation methods and beneficial effects of the various components of the electronic device in the above embodiments for solving the problem can be found in [reference needed]. Figure 1 The steps in the illustrated embodiments are used to implement the electronic device. Therefore, the specific working process and beneficial effects of the electronic device provided in this application will not be repeated here.

[0072] In another embodiment provided in this application, a computer-readable storage medium is also provided, which stores instructions that, when executed on a computer, cause the computer to perform any of the pipeline leakage sequential detection methods based on sequential probability ratio testing described in the above embodiments.

[0073] In another embodiment provided in this application, a computer program product containing instructions is also provided, which, when run on a computer, causes the computer to execute any of the pipeline leakage sequential detection methods based on sequential probability ratio testing described in the above embodiments.

[0074] Those skilled in the art will understand that the embodiments in this application can be provided as methods, systems, or computer program products. Therefore, the embodiments in this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the embodiments in this application can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0075] This application describes embodiments of methods, apparatus (systems), and computer program products according to embodiments of this application with reference to flowchart illustrations and / or block diagrams. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0076] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0077] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0078] Although preferred embodiments have been described in this application, those skilled in the art, upon learning the basic inventive concept, can make other changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments as well as all changes and modifications falling within the scope of the embodiments of this application.

[0079] Obviously, those skilled in the art can make various modifications and variations to the embodiments of this application without departing from the spirit and scope of the embodiments of this application. Therefore, if these modifications and variations to the embodiments of this application fall within the scope of the claims in this application and their equivalents, then this application also intends to include these modifications and variations.

Claims

1. A sequential detection method for pipeline leakage based on sequential probability ratio testing, characterized in that, The method includes: The predicted value corresponding to the current sampling time is calculated by using the time series prediction model of each type of sensor, and the residual between the collected value and the predicted value of that type of sensor is obtained. Based on the residuals of each type of sensor, the leakage probability value and normal probability value of the corresponding residuals are obtained using the configured leakage state probability model and normal state probability model, as well as the individual likelihood ratio of the corresponding sensor. The individual likelihood ratios of each type of sensor at the current sampling time are weighted to obtain the comprehensive likelihood ratio at the current sampling time. A leakage alarm is triggered based on the comprehensive likelihood ratio within a preset time period and a preset leakage threshold.

2. The method as described in claim 1, characterized in that, The time series prediction model is an autoregressive moving average model; At the current sampling time, the predicted value for the current time is calculated based on historical signal values ​​using the time series prediction model for each type of sensor, including: For each type of sensor, the autoregressive coefficients and moving average coefficients of the model are obtained by fitting historical signal data of at least one complete cycle collected under normal pipeline operation conditions using the least squares method or the maximum likelihood method. During real-time detection, each time a new collected value is obtained, the collected value and historical collected values ​​from multiple previous times are input into the autoregressive moving average model, and the predicted value for the current time is output.

3. The method as described in claim 1, characterized in that, Both the leakage state probability model and the normal state probability model adopt a Gaussian distribution model. The mean and variance of the normal state probability model are obtained by maximum likelihood estimation of the residual data during the historical normal operation of the pipeline; the mean and variance of the leakage state probability model are estimated by the historical leakage event data of the pipeline or the leakage residual data generated by pressure-flow simulation.

4. The method as described in claim 1, characterized in that, Before weighting the individual likelihood ratios of each type of sensor at the current sampling time, the method further includes: For each type of sensor, calculate the arithmetic mean or variance of the absolute values ​​of its residuals within the sliding time window, which is taken as the instantaneous activity of the sensor. The instantaneous activity of all sensors is normalized to obtain the initial weights; The initial weights are subjected to exponential smoothing filtering to obtain the fused weights at the current sampling time; The smoothing factor of the exponential smoothing filter is dynamically adjusted according to the stability of the pipeline operating conditions.

5. The method as described in claim 1, characterized in that, The preset leakage thresholds include a first threshold and a second threshold, and the first threshold is greater than the second threshold; A leakage alarm is triggered based on a comparison of all comprehensive likelihood ratios within a time period including the current sampling time and a preset leakage threshold, including: The cumulative test statistic is obtained by multiplying the comprehensive likelihood ratios calculated at each sampling time within the time period. If the cumulative statistic is greater than or equal to the first threshold, a leakage alarm is triggered and the cumulative statistic is reset to 1.

6. The method as described in claim 5, characterized in that, After triggering the leak alarm, the method further includes: The system acquires the original pressure signal waveforms from multiple sampling times prior to the alarm triggering time. By detecting the negative pressure wave inflection point in the original pressure signal waveform, and combining the time difference between the sensors at both ends of the pipeline with the propagation speed of sound waves in the pipeline medium, the location of the leak point is calculated.

7. A pipeline leakage sequential detection device based on sequential probability ratio test, characterized in that, The device includes: The acquisition unit is used to calculate the predicted value corresponding to the collected value at the current sampling time through the time series prediction model of each type of sensor, and to obtain the residual between the collected value and the predicted value of that type of sensor. Furthermore, based on the residuals of each type of sensor, the leakage probability value and normal probability value of the corresponding residuals are obtained using the configured leakage state probability model and normal state probability model, as well as the individual likelihood ratio of the corresponding sensor. The weighting unit is used to weight the individual likelihood ratios of each type of sensor at the current sampling time to obtain the comprehensive likelihood ratio at the current sampling time; The triggering unit is used to trigger a leakage alarm based on the comprehensive likelihood ratio within a preset time period and a preset leakage threshold.

8. The apparatus as claimed in claim 7, characterized in that, Both the leakage state probability model and the normal state probability model adopt a Gaussian distribution model. The mean and variance of the normal state probability model are obtained by maximum likelihood estimation of the residual data during the historical normal operation of the pipeline; the mean and variance of the leakage state probability model are estimated by the historical leakage event data of the pipeline or the leakage residual data generated by pressure-flow simulation.

9. An electronic device, characterized in that, The electronic device includes a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other through the communication bus; Memory, used to store computer programs; A processor, when executing a program stored in memory, implements the method of any one of claims 1-6.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the method described in any one of claims 1-6.