A pipeline leakage positioning method and system based on a physical information constraint multi-scale attention network, a medium and a program product

By using a multi-scale attention network based on physical information constraints, and combining physical laws and attention mechanisms, the problem of insufficient positioning accuracy of existing models in ship fire-fighting pipeline networks is solved, and higher accuracy pipeline leak location is achieved.

CN122333146APending Publication Date: 2026-07-03HARBIN ENG UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610341368.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-03-19
Publication Date
2026-07-03

AI Technical Summary

Technical Problem

Existing deep learning-based pipeline leak location models fail to effectively utilize the physical laws of pipeline leak sound waves, resulting in insufficient location accuracy. Furthermore, single-scale convolutional networks are prone to losing feature information, making it difficult to quickly and accurately locate leak points in ship fire-fighting pipeline networks.

Method used

A multi-scale attention network based on physical information constraints is adopted. The features of the acoustic signal are extracted by a multi-scale convolutional neural network. The physical information constraint module and the self- and spatial attention mechanisms are combined to enhance feature processing. Finally, the fully connected layer is used to predict the leakage location.

Benefits of technology

It improves the accuracy and adaptability of pipeline leak location, ensures the consistency of model output features, and enables rapid and accurate location in complex environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122333146A_ABST
    Figure CN122333146A_ABST
Patent Text Reader

Abstract

This invention discloses a pipeline leak localization method, system, medium, and program product based on a physical information-constrained multi-scale attention network, belonging to the field of pipeline leak prediction technology. The method includes: acquiring the pipeline leak acoustic signal as the raw acoustic signal; establishing the physical relationship between the leak location and sound pressure, setting the attenuation coefficient, transmission coefficient, and refraction coefficient in the model as learnable parameters, and extracting multi-scale features of the signal using three-channel convolution; combining a physical information constraint module and introducing self-attention and spatial attention mechanisms to enhance the fused features; unfolding the features into three sets of one-dimensional vectors, concatenating them, and inputting them into a fully connected layer; and using the sigmoid function to predict the leak location. This invention improves the quality of the input features by combining multi-scale convolution with physical constraints, significantly improving the accuracy and reliability of leak localization.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of pipeline leak location and prediction technology, specifically relating to a pipeline leak location method, system, medium, and program product based on a physical information-constrained multi-scale attention network. Background Technology

[0002] As a core system ensuring ship safety, the ship's fire protection piping network typically runs throughout the entire vessel over extremely long distances. Furthermore, for safety and space optimization, the vast majority of pipe sections are pre-encased within bulkheads, decks, and other structural elements. This inherent characteristic makes it difficult to quickly locate leaks or other malfunctions through direct observation. Currently, traditional methods relying on manual inspections and pressure point monitoring are not only slow to respond and have limited location accuracy, but also fail to effectively address the diagnostic challenges posed by the complex shipboard environment and concealed piping sections. If a leak cannot be quickly and accurately located, it will severely impact the immediate availability of the fire protection system and pose a significant threat to the overall safety of the ship.

[0003] Convolutional neural networks (CNNs), a type of deep learning, are widely used in pipeline leak location due to their weight sharing, local computation, and powerful autonomous feature extraction capabilities. The propagation of leaking acoustic signals in ship fire-fighting pipelines follows certain physical laws. However, previous deep learning-based pipeline leak location models have neglected this characteristic, leading to insufficient understanding of the real-world physical meaning and thus affecting model performance. Furthermore, the selection of convolutional kernels in CNNs is fixed, while the data points representing leak characteristics in pipeline leak signals are not fixed in position or size and exhibit multi-scale characteristics. Using a single-scale CNN can easily result in the loss of some feature information during convolution and pooling, thus affecting the accuracy of leak location. Summary of the Invention

[0004] The purpose of this invention is to provide a pipeline leak location method, system, medium, and program product based on a physical information-constrained multi-scale attention network, which can be used to improve the accuracy of pipeline location prediction for ship fire protection networks.

[0005] The objective of this invention is achieved through the following technical solution:

[0006] A pipeline leak localization method based on a physical information-constrained multi-scale attention network includes the following steps:

[0007] Step 1: Collect the acoustic signal of the pipeline leak as the raw acoustic signal;

[0008] Step 2: By establishing a physical relationship between leakage distance and sound pressure, which takes into account the attenuation, transmission and refraction effects of sound waves propagating in the pipe, the attenuation coefficient, transmission coefficient and refraction coefficient in the physical relationship are set as learnable parameters.

[0009] Step 3: Extract multi-scale features of the original acoustic signal using a multi-scale convolutional neural network. The multi-scale convolutional neural network includes at least two parallel convolutional channels, each of which uses a convolutional kernel of a different scale.

[0010] Step 4: Combining the physical information constraint module, the physical relationships established in Step 2 are introduced into the multi-scale features extracted in Step 3 in the form of learnable weights to obtain fused features; and self-attention and spatial attention mechanisms are introduced to enhance the fused features.

[0011] Step 5: Input the enhanced features into the fully connected layer, use the activation function to predict the leak location, and output the pipeline leak location.

[0012] Furthermore, in step 1, two sensors are used to collect the acoustic signal of the pipeline leak, and the two signals are normalized and then merged into one original acoustic signal; the normalization process is to linearly map the signal value at each moment to the interval [0,1].

[0013] Furthermore, the physical relationship between the leakage distance and sound pressure described in step 2 includes:

[0014] In the straight pipe model, the sound pressure at any point A Sound pressure at leak point M It satisfies the exponential decay relationship. ,in, Represents the sound wave attenuation coefficient. This represents the distance between points A and M in a straight pipe;

[0015] In a pipe model with branches, a branch transmission coefficient is introduced; the sound pressure at point B after the sound wave is transmitted through the branch point is considered. ,in, Represents the branch transmission coefficient; This represents the distance between leak point M and point B;

[0016] In a pipe model with a bend, a refraction coefficient for the bend is introduced; the sound pressure at point W after the sound wave is refracted through the bend is considered. ,in, This represents the sound pressure level when the sound wave propagates from the bent pipe structure to pipe W. This represents the refractive index of the bent pipe.

[0017] Furthermore, a model of a zigzag pipe network with branches and bends was constructed, the sound pressure relationship between the leak point and the sensors at both ends of the pipe was established, and the physical relationship between arbitrary leak distance and sound pressure was derived.

[0018] Furthermore, the multi-scale convolutional neural network in step 3 includes three parallel convolution channels, which convolve the original acoustic signal respectively to extract leakage signal features at different scales.

[0019] Furthermore, the physical information constraint module in step 4 is used to introduce the physical relationship between the leakage distance and the sound pressure into the three-channel convolution process with preset weights to correct the convolution output.

[0020] Furthermore, in step 5, the activation function is used to predict the leak location. Specifically, the output of the fully connected layer is mapped to the [0,1] interval through the sigmoid function. An output value of 1 indicates that the leak point is located at the farthest point from hydrophone A, and an output value of 0 indicates that the leak point is located at hydrophone A. Other output values ​​are mapped to the actual leak location in a linear proportion.

[0021] A computer system includes a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the steps of a pipe leak localization method based on a physical information-constrained multi-scale attention network.

[0022] A computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of a pipe leak localization method based on a physically constrained multi-scale attention network.

[0023] A computer program product includes a computer program that, when executed by a processor, implements the steps of a pipe leak localization method based on a physically constrained multi-scale attention network.

[0024] The beneficial effects of this invention are as follows:

[0025] 1. Key parameters in the model can be adaptively optimized based on the received data, thereby more accurately reflecting the actual physical environment and signal propagation characteristics;

[0026] 2. Combine the information calculated by the physical information constraint layer with the output features of the convolutional network to ensure that the final output features are consistent in dimensionality.

[0027] 3. A learnable parameter is introduced to adjust the influence of the physical information constraint layer throughout the network. This enables the model to not only leverage data-driven learning capabilities but also incorporate physics-driven logic, enhancing its interpretability and adaptability. Attached Figure Description

[0028] Figure 1 This invention relates to a multi-scale attention network model based on physical information constraints.

[0029] Figure 2 This is a schematic diagram of a straight pipe model.

[0030] Figure 3 This is a schematic diagram of a pipe model with a branching structure.

[0031] Figure 4 This is a schematic diagram of a pipe model with a bend in the pipe.

[0032] Figure 5 This is a schematic diagram of the ship fire-fighting pipeline network structure in an embodiment of the present invention.

[0033] Figure 6 This is a diagram showing the pipeline leak location results in an embodiment of the present invention.

[0034] Figure 7 This is a graph showing the number of sample points for locating leaks in the pipeline in an embodiment of the present invention. Detailed Implementation

[0035] The present invention will now be further described with reference to the accompanying drawings.

[0036] Depend on Figure 1 As shown, a pipeline leak localization method based on a physical information-constrained multi-scale attention network is described, and the specific implementation steps are as follows:

[0037] Step 1: Acquire sound wave signals of pipe leakage using two capacitive hydrophones. After normalizing the two signals, merge them into a single original sound wave signal. The first and second halves of this original sound wave signal correspond to the signals acquired by the two hydrophones, respectively. The normalization process is as follows:

[0038]

[0039]

[0040]

[0041] in, and These are the acoustic signal values ​​of pipe leakage at time t, collected by two capacitive hydrophones. Indicates time, ; and The first data collected by two capacitive hydrophones The normalized value of the acoustic signal of pipeline leakage at each moment; and They are respectively and The minimum value in the signal; and They are respectively and The maximum value in the signal; The two signals are normalized and then merged into a single original acoustic signal.

[0042] Step two, according to Figure 2 - Figure 4 The pipe models shown—straight pipe, pipe with branches, and pipe with bends—are used to derive the physical relationship between the leakage location and sound pressure when sound waves pass through branches and bends. Specifically, in the straight pipe model, the relationship between the leakage point and sound pressure is:

[0043]

[0044] in, This represents the sound pressure at any point A in the straight pipe. The sound pressure at the leak point M; Represents the sound wave attenuation coefficient; This represents the distance between point A and point M in a straight pipe.

[0045] In a pipe model with branching structures, the relationship between the leakage point and the sound pressure is as follows:

[0046]

[0047] in, This represents the sound pressure level when the sound wave propagates to pipe B after passing through the branch structure. Represents the branch transmission coefficient; This represents the distance between the leak point M and point B.

[0048] In a pipe model with a bend, the relationship between the leakage point and the sound pressure is as follows:

[0049]

[0050] in, This represents the sound pressure level of the sound wave as it propagates through the curved pipe structure to pipe W. This represents the refractive index of the bent pipe.

[0051] Design a zigzag pipe network system that simultaneously features branching and bends, such as... Figure 5 As shown, based on the relationship between the leakage point and the sound pressure in the above three pipe models, it can be obtained that when the leakage point M is in section CE, the leakage sound wave propagates to both sides of the pipe in the form of a plane wave. During its propagation towards point A, the sound wave passes through a branch and bend structure. The sound pressure generated by the transmission at the branch point C is:

[0052]

[0053] The sound pressure generated by refraction at bend D is:

[0054]

[0055] Combining the two formulas above, we can deduce the sound pressure at point A. for:

[0056]

[0057] The sound pressure at point B after passing through the bend in the pipe. for:

[0058]

[0059] Similarly, when the leak point M is in section BE, the leakage sound wave propagates to both sides of the pipe in the form of a plane wave. When the sound wave propagates at point A, it passes through one branch structure and two bends. When the leakage sound wave propagates to point B, it does not pass through any branch or bend structure. The sound pressure at point A and the sound pressure at point B can be expressed as follows:

[0060]

[0061]

[0062] From the above formulas, we can deduce that when a leak occurs at a certain point in the pipeline, the relationship between the sound pressure at points A and B in the pipeline and the location of the leak is as follows:

[0063]

[0064]

[0065]

[0066]

[0067] Where x represents the distance from the leak point M to the hydrophone A.

[0068] The above leakage locations, along with the attenuation coefficient, transmission coefficient, and refractive index in the sound pressure, are set as learnable parameters. Multi-scale features of the signal are extracted using three-channel convolution. The multi-scale convolutional branch network structure in the model is shown in Table 1.

[0069] Table 1. Multi-scale convolutional branch network structure

[0070]

[0071] Step 3: Add self-attention mechanism and spatial attention mechanism to the network to enhance the fused features. The network structures of self-attention mechanism and spatial attention mechanism are shown in Table 2 and Table 3.

[0072] Table 2. Network structure of self-attention mechanism in the model

[0073]

[0074] Table 3. Spatial attention mechanism network structure in the model

[0075]

[0076] Step four: Expand the features into three sets of one-dimensional vectors, concatenate them, and input them into the fully connected layer.

[0077] Step 5: Use the sigmoid function to predict the location of the leak.

[0078]

[0079] Among them, M s (F) represents the characteristic value of the leak location. is the sigmoid non-linear activation function, Conv is the convolution operation, AvgPool(F) is the average value of each spatial location in feature map F, and MaxPool(F) is the maximum value of each spatial location in feature map F.

[0080] Based on the normalization processing of the input acoustic signal in step one, when M s When (F) is 1, it indicates that the predicted leak location is at the farthest point from hydrophone A; other output values ​​correspond to leak locations distributed in a linear proportion.

[0081] Example 1

[0082] Set up Figure 5 A pipeline leak location experiment was conducted on the ship's fire-fighting pipeline system shown. The sampling frequency was configured to 1280Hz, and the signal sampling length was 1024. During training, the signals from sensors A and B were spliced ​​(meeting the input layer network size of 2048*1) and then input into a physical information-constrained multi-scale attention network. Pipeline leak acoustic signals from six leak points in the experimental system were used to train and test the model. 162 sets of signals were collected for each leak point, with the training set accounting for 77.8% (756 signals) and the test set accounting for 22.2% (216 signals). The leak locations for each leak point are shown in Table 4. When collecting pipeline leak acoustic signals, the leak valve opening was configured to 30%, 50%, and 75%, respectively.

[0083] Table 4. Experimental data for locating pipeline leaks

[0084]

[0085] The accuracy of the model was verified by using four evaluation indicators: mean square error, root mean square error, mean relative error, and coefficient of determination.

[0086]

[0087]

[0088]

[0089]

[0090] Where MSE is the mean square error; RMSE is the root mean square error; and MRE is the mean relative error. The coefficient of determination; This is a predicted location of the pipeline leak. The actual location of the pipeline leak is n; n is the total number of sample points. This represents the average of the actual locations of pipeline leaks. The lower the MSE, RMSE, and MRE values, the better. A higher value indicates a better prediction result.

[0091] Comparison of actual location and predicted location results, for example Figure 6 As shown, the model's predicted location closely matches the actual location, with the predicted values ​​for the vast majority of sample points falling within the vicinity of the actual location. Further statistical analysis of the leak location error yielded the following distribution of sample point numbers across different error intervals: Figure 7 As shown, the positioning error is mainly concentrated in the range of 0-4m. The specific calculation results of the model evaluation indicators are listed in Table 5, and the values ​​of each indicator all show that the model has excellent prediction accuracy.

[0092] Table 5 Model Evaluation Indicators

[0093]

[0094] In particular, in some preferred embodiments of the present invention, a computer device is also provided, including a memory and a processor and a computer program stored in the memory, wherein the processor executes the computer program to implement the steps of the pipeline leak localization method based on physical information constrained multi-scale attention network described in any of the above embodiments.

[0095] In some other preferred embodiments of the present invention, a computer-readable storage medium is also provided, on which a computer program / instruction is stored, wherein when the computer program is executed by a processor, the steps of the pipeline leak localization method based on a physical information-constrained multi-scale attention network described in any of the above embodiments are implemented.

[0096] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the above embodiments of the pipeline leak location method based on physical information constrained multi-scale attention network, which will not be repeated here.

[0097] Computer-readable storage media encompass a variety of types, including persistent and non-persistent, portable and fixed. These media store information using different technologies, and the content can be machine instructions, data structures, program modules, or other types of data. Some typical examples of computer storage media include: phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), various types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory and other storage technologies, optical storage media such as CD-ROM and digital video disc (DVD), magnetic storage devices such as magnetic tape and disks, and other non-transferable media used to store information accessible to computing devices. It is important to note that the computer-readable media described herein do not include temporary storage media, such as modulated data signals and carrier waves.

[0098] Those skilled in the art will further recognize that the operation of the module can be achieved using existing technical protocols or programs, without relying on new computer programs themselves. The units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this invention.

[0099] The steps of the methods or algorithms described in conjunction with the embodiments disclosed herein can be implemented in hardware, a software module executed by a processor, or a combination of both. The software module can be located in random access memory (RAM), main memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, removable disk, CD-ROM, or any other form of storage medium known in the art.

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

Claims

1. A method for pipeline leakage localization based on a physically information constrained multi-scale attention network, characterized in that, Includes the following steps: Step 1: Collect the acoustic signal of the pipeline leak as the raw acoustic signal; Step 2: By establishing a physical relationship between leakage distance and sound pressure, which takes into account the attenuation, transmission and refraction effects of sound waves propagating in the pipe, the attenuation coefficient, transmission coefficient and refraction coefficient in the physical relationship are set as learnable parameters. Step 3: Extract multi-scale features of the original acoustic signal using a multi-scale convolutional neural network. The multi-scale convolutional neural network includes at least two parallel convolutional channels, each of which uses a convolutional kernel of a different scale. Step 4: Combining the physical information constraint module, the physical relationships established in Step 2 are introduced into the multi-scale features extracted in Step 3 in the form of learnable weights to obtain fused features; Furthermore, self-attention and spatial attention mechanisms are introduced to enhance the fused features; Step 5: Input the enhanced features into the fully connected layer, use the activation function to predict the leak location, and output the pipeline leak location.

2. The pipeline leak localization method based on a physical information-constrained multi-scale attention network according to claim 1, characterized in that, In step 1, two sensors are used to collect the acoustic signal of the pipeline leak. The two signals are normalized and then merged into one original acoustic signal. The normalization process is to linearly map the signal value at each moment to the interval [0,1].

3. The pipeline leak localization method based on a physical information-constrained multi-scale attention network according to claim 1, characterized in that, The physical relationship between leakage distance and sound pressure mentioned in step 2 includes: In the straight pipe model, the sound pressure at any point A Sound pressure at leak point M It satisfies the exponential decay relationship. ,in, Represents the sound wave attenuation coefficient. This represents the distance between points A and M in a straight pipe; In a pipe model with branches, a branch transmission coefficient is introduced; the sound pressure at point B after the sound wave is transmitted through the branch point is considered. ,in, Represents the branch transmission coefficient; This represents the distance between leak point M and point B; In a pipe model with a bend, a refraction coefficient for the bend is introduced; the sound pressure at point W after the sound wave is refracted through the bend is considered. ,in, This represents the sound pressure level when the sound wave propagates from the bent pipe structure to pipe W. This represents the refractive index of the bent pipe.

4. The pipeline leak localization method based on a physical information-constrained multi-scale attention network according to claim 3, characterized in that, A model of a zigzag pipe network with branches and bends was constructed. The relationship between the sound pressure at the leak point and the sensors at both ends of the pipe was established, and the physical relationship between arbitrary leak distance and sound pressure was derived.

5. The pipeline leak localization method based on a physical information-constrained multi-scale attention network according to claim 1, characterized in that, The multi-scale convolutional neural network in step 3 includes three parallel convolution channels, which convolve the original acoustic signal respectively to extract leakage signal features at different scales.

6. The pipeline leak localization method based on a physical information-constrained multi-scale attention network according to claim 5, characterized in that, The physical information constraint module in step 4 is used to introduce the physical relationship between the leakage distance and the sound pressure into the three-channel convolution process with preset weights to correct the convolution output.

7. The pipeline leak localization method based on a physical information-constrained multi-scale attention network according to claim 1, characterized in that, In step 5, the activation function is used to predict the leak location. Specifically, the output of the fully connected layer is mapped to the [0,1] interval through the sigmoid function. The output value 1 indicates that the leak point is located at the farthest end from hydrophone A, and the output value 0 indicates that the leak point is located at hydrophone A. Other output values ​​are mapped to the actual leak location in a linear proportion.

8. A computer system comprising a memory, a processor, and a computer program stored in the memory, characterized in that: The processor executes the computer program to implement the steps of the method according to any one of claims 1 to 7.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When executed by a processor, the computer program implements the steps of the method according to any one of claims 1 to 7.

10. A computer program product, comprising a computer program, characterized in that: When executed by a processor, the computer program implements the steps of the method according to any one of claims 1 to 7.