Leak detection method and device for underground pipe network based on acoustic image feature recognition and storage medium

By converting acoustic signals into time-frequency images and using deep learning models for image-level feature recognition, the accuracy and adaptability issues of existing leakage detection technologies have been resolved, achieving efficient and intelligent underground pipeline leakage detection.

CN122384010APending Publication Date: 2026-07-14CHONGQING SHUYI DATA OPERATION MANAGEMENT CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CHONGQING SHUYI DATA OPERATION MANAGEMENT CO LTD
Filing Date
2026-04-20
Publication Date
2026-07-14

AI Technical Summary

Technical Problem

Existing underground pipe network leakage detection technologies suffer from low efficiency, susceptibility to environmental noise interference, poor model generalization ability, and difficulty in accurately identifying leakage points under different pipe materials, diameters, and pressure conditions.

Method used

The acoustic wave signal is converted into a two-dimensional time-frequency image, and image-level feature recognition is performed using a convolutional neural network or visual Transformer. Iterative optimization is then performed using a leak soundprint image database to construct a closed-loop learning mechanism.

Benefits of technology

It significantly improves the accuracy and robustness of leakage detection, adapts to different working conditions, realizes trenchless, highly sensitive intelligent leakage detection, and reduces leakage rate and operation and maintenance costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122384010A_ABST
    Figure CN122384010A_ABST
Patent Text Reader

Abstract

The application discloses a kind of underground pipe network leak detection method, device and storage medium based on acoustic image feature recognition.The method includes: the acoustic signal of underground pipeline is preprocessed to obtain standardized one-dimensional acoustic segment;Time-frequency transform is carried out on the acoustic segment to generate a two-dimensional time-frequency image;The image is input into the pre-trained deep learning classification model, and the discrimination result of "leakage" or "non-leakage" is output;The discrimination result is compared with the field verification result, and the consistent sample and its metadata are stored in the leakage acoustic print image database, and the model is periodically iteratively optimized based on the new sample.The application converts acoustic signal into image and combines advanced deep learning technology, significantly improves the accuracy, anti-interference ability and generalization performance of leakage identification, simultaneously establishes database updating mechanism, realizes model continuous evolution, and is suitable for large-scale urban water supply pipe network intelligent, non-excavation, high-sensitivity leak detection application.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of non-destructive testing technology for underground pipe networks, specifically to a method, apparatus, and storage medium for leak detection of underground pipe networks based on acoustic image feature recognition. Background Technology

[0002] Urban underground water supply networks are crucial infrastructure for ensuring residents' lives and industrial production. However, due to factors such as pipe aging, construction defects, foundation settlement, and external loads, leakage problems in these networks are becoming increasingly prominent. Statistics show that the average leakage rate of urban water supply networks in my country has long remained above 15%, and in some older urban areas it even exceeds 30%. This not only results in a significant waste of water resources but can also trigger secondary disasters such as road collapses and foundation erosion, seriously threatening public safety and urban operational efficiency. To promptly detect and locate leaks, the industry has developed various leak detection technologies. Traditional methods mainly include: (1) Manual listening method: Inspectors use listening rods or electronic leak detectors to listen to the pipeline point by point. This method relies on operational experience, is inefficient, subjective, and difficult to effectively identify small leaks in high-noise environments; (2) Correlation analysis method: The location is calculated by measuring the time difference of the arrival of the leak sound wave between two sensors. Although it can achieve a certain accuracy in positioning, it requires a high signal-to-noise ratio and is easily affected by interference from water flow, pump station start-up and shutdown, etc., and cannot directly determine whether there is a leak; (3) Pressure / flow monitoring method: The leakage is indirectly inferred by analyzing the minimum flow or pressure abnormal changes of the regional metering unit at night. However, the spatial resolution is low, and it can only reflect the overall leakage level and cannot accurately locate the specific leak point.

[0003] In recent years, with the development of sensor technology and signal processing algorithms, automatic leak detection technology based on acoustic signals has gradually become a research hotspot. This type of method utilizes acoustic sensors installed on valves, fire hydrants, or pipe walls to collect characteristic sound waves (typically in the frequency range of 100 Hz–5 kHz) generated by leaking fluid, and constructs discrimination rules based on time-domain or frequency-domain features (such as mean energy, dominant frequency, kurtosis, spectral entropy, etc.). For example, some schemes use support vector machines or random forests to classify the extracted manual features, achieving automated discrimination to a certain extent. However, these methods still have significant technical bottlenecks: due to the complex characteristics of leaking sound waves, such as non-stationarity, wide bandwidth, and transient impact, they often highly overlap with normal water flow noise, mechanical vibration, and traffic coupling noise in the time-frequency domain, making it difficult to effectively distinguish them using single or combined statistical features; simultaneously, because the propagation characteristics of leaking sound vary significantly under different pipe materials (such as ductile iron, PVC, and steel pipes), pipe diameters, burial depths, and water pressures, models trained in one scenario are difficult to transfer to other scenarios. Although some studies have attempted to introduce deep learning techniques to directly process raw acoustic signals, the lack of spatial context information in one-dimensional signals makes it difficult for models to capture the unique time-frequency coupling patterns of leakage sound (such as high-frequency attenuation tails and periodic modulation). In contrast, converting acoustic signals into two-dimensional time-frequency images allows them to be treated as texture images, naturally adapting to mature computer vision models.

[0004] In recent years, convolutional neural networks and visual Transformers have demonstrated outstanding feature extraction and generalization capabilities in image classification tasks, providing new ideas for solving the pattern recognition problem in acoustic leak detection. However, there is currently no mature technology that systematically applies the complete link of sound wave → time-frequency image → deep image classification → closed-loop database construction to the field of underground pipe network leak detection. Summary of the Invention

[0005] This invention proposes a novel method for detecting leaks in underground pipe networks that integrates acoustic sensing, time-frequency image generation, and deep learning classification, in order to overcome the limitations of existing technologies in terms of accuracy, robustness, and intelligence.

[0006] This invention discloses a method for leak detection in underground pipe networks based on acoustic image feature recognition, comprising the following steps:

[0007] S1. Acquire acoustic signals from underground water supply pipelines and preprocess the acoustic signals to obtain standardized one-dimensional acoustic segments.

[0008] S2. Perform time-frequency transformation on the sound wave segment to generate a two-dimensional time-frequency image, where the horizontal axis represents time, the vertical axis represents frequency, and the pixel gray value represents the energy intensity at that time-frequency point.

[0009] S3. Input the time-frequency image into the deep learning classification model to obtain the leakage status judgment result of the time-frequency image. The leakage status includes "leakage" or "non-leakage".

[0010] S4. Compare the discrimination result with the on-site verification result. If they match, store the time-frequency image and its metadata in the leakage soundprint image database. Based on the newly added samples in the leakage soundprint image database, iteratively optimize the deep learning classification model periodically.

[0011] Furthermore, time-frequency transformation includes short-time Fourier transform, continuous wavelet transform, or Mel-spectrum transform. Using short-time Fourier transform, continuous wavelet transform, or Mel-spectrum transform as time-frequency transformation methods can flexibly generate high-information-density time-frequency images based on the different characteristics of leakage sound waves (such as transient impulsivity, wideband distribution, or human auditory perception characteristics). This effectively preserves the coupling characteristics of the leakage signal in the time and frequency dimensions, providing more discriminative visual input for subsequent deep learning models and significantly improving the sensitivity and adaptability of leakage identification.

[0012] Furthermore, deep learning classification models, including convolutional neural networks (CNNs) or visual Transformer architectures, are used for binary classification of leakage states in time-frequency images. CNNs and visual Transformer architectures can fully leverage their advantages in local image feature extraction and global context modeling, enabling the model to automatically learn complex texture patterns in leakage voiceprint images. This avoids the limitations of traditional manual feature design and improves the accuracy and robustness of leakage state classification.

[0013] Furthermore, when the deep learning classification model is a convolutional neural network (CNN), the CNN adopts a residual network structure, including an initial convolutional layer, a max-pooling layer, multiple residual block groups, and a global average pooling layer connected sequentially. The last fully connected layer has an output dimension of 2, corresponding to the "leaking" and "non-leaking" categories, respectively. The number of residual block groups is 3 to 5, each group containing 2 to 6 residual units, and each residual unit contains at least two convolutional layers and skip connections. When using a convolutional neural network with a residual network structure, the introduction of multi-level residual block groups and skip connections effectively alleviates the gradient vanishing problem in deep network training and enhances the model's ability to express multi-scale leakage features in time-frequency images. At the same time, the standardized network hierarchy facilitates transfer learning and engineering deployment, ensuring high accuracy while taking into account computational efficiency, which is suitable for real-time leak detection scenarios in edge devices.

[0014] Furthermore, when the deep learning classification model uses a visual Transformer architecture, the visual Transformer architecture divides the input time-frequency image into non-overlapping image blocks of fixed size. Each image block undergoes linear embedding followed by positional encoding, and then feature extraction is performed through a multi-layer Transformer encoder. Finally, the output vector corresponding to the class label is fed into the classification head to obtain the binary classification result. Using the visual Transformer architecture, through image segmentation, positional encoding, and a self-attention mechanism, it can model the spectral-temporal dependencies between distant pixels in the time-frequency image, overcoming the limitation of the receptive field in traditional CNNs. This allows for a more comprehensive capture of the unique propagation patterns of leakage sounds, thereby achieving higher-precision leakage identification even in complex noise environments.

[0015] Furthermore, the input to the deep learning classification model is a single-channel grayscale time-frequency image with a uniform size of 224×224 pixels or 256×256 pixels. The pixel values ​​are normalized before being input into the model. The model output is converted into a leakage probability using the Softmax function. When the leakage probability is greater than a preset threshold p, it is determined to be a leakage state. Standardizing the input image size and performing normalization ensures consistency in spatial dimension and numerical range for time-frequency images under different acquisition conditions, improving model training stability and inference generalization ability. Simultaneously, the decision based on the leakage probability output by Softmax and the adjustable threshold p allows the system to flexibly balance the false negative rate and false positive rate according to the actual application scenario, enhancing the practicality of this method.

[0016] Furthermore, the deep learning classification model employs Focal Loss or weighted cross-entropy loss function during training to alleviate the class imbalance problem between leaking and non-leaking samples. This is combined with random image enhancement strategies, including horizontal flipping, brightness perturbation, and Gaussian noise injection, to improve the model's generalization performance. Using Focal Loss or weighted cross-entropy loss function during model training can mitigate the class imbalance problem caused by the scarcity of leaking samples, making the model focus more on the difficult-to-classify leaking samples. Combining image enhancement strategies such as horizontal flipping, brightness perturbation, and Gaussian noise injection simulates signal variations in the real environment, significantly improving the model's adaptability to different pipe conditions, noise interference, and differences in acquisition equipment.

[0017] Furthermore, the metadata includes sensor location, pipe material, pipe diameter, water pressure, and verification tags. Storing key information such as sensor location, pipe material, pipe diameter, water pressure, and verification tags as metadata along with image samples not only supports filtering and analyzing leakage acoustic signatures based on operating conditions, but also provides a data foundation for fine-grained model optimization and fault tracing, greatly enhancing the database's structure and intelligent operation and maintenance value.

[0018] To achieve the above objectives, the present invention also provides an underground pipe network leak detection device based on acoustic image feature recognition, comprising a first sound acquisition module for acquiring acoustic signals from underground water supply pipes; a second data preprocessing module for preprocessing the acoustic signals to obtain standardized one-dimensional acoustic segments; a third time-frequency transformation module for performing time-frequency transformation on the acoustic segments to generate a two-dimensional time-frequency image, wherein the horizontal axis represents time, the vertical axis represents frequency, and the pixel grayscale value represents the energy intensity at that time-frequency point; and a fourth image discrimination module for inputting the time-frequency image into a deep learning classification model to obtain the leakage status discrimination result of the time-frequency image, wherein the leakage status includes "leaking" or "non-leaking".

[0019] To achieve the above objectives, the present invention also provides a storage medium storing a plurality of computer programs, which, when executed, are used to implement the above-described method for detecting leaks in underground pipe networks based on acoustic image feature recognition.

[0020] Beneficial Effects: The underground pipe network leak detection device method based on acoustic image feature recognition disclosed in this invention converts the acoustic signals generated by underground water supply pipeline leakage into time-frequency images, and combines them with deep learning models such as convolutional neural networks or visual Transformers for image-level feature recognition. This effectively overcomes the shortcomings of traditional leak detection methods, such as reliance on human experience, susceptibility to environmental noise interference, weak feature expression ability, and poor generalization, significantly improving the accuracy and robustness of leakage detection. At the same time, by constructing a leakage acoustic image database containing real verification results and multi-dimensional metadata, a closed-loop learning mechanism of "collection-recognition-verification-feedback-optimization" is formed, enabling the model to have continuous evolution capabilities and adapt to complex working conditions such as different pipe materials, pipe diameters, pressures, and burial depths. This achieves trenchless, highly sensitive, and intelligent underground pipe network leakage detection, significantly reducing leakage rates and operation and maintenance costs.

[0021] It should be noted that the terms "first," "second," and similar terms used in this article are merely for describing the constituent elements of the technical solution and do not constitute a limitation on the technical solution, nor should they be interpreted as an indication or implication of the importance of the corresponding elements; elements with terms such as "first," "second," or similar terms indicate that at least one of the elements is included in the corresponding technical solution. Attached Figure Description

[0022] To more clearly illustrate the technical solution of the present invention and facilitate a further understanding of its technical effects, features, and objectives, the present invention will be described in detail below with reference to the accompanying drawings. The drawings constitute an essential part of the specification and are used together with Embodiment 1 of the present invention to illustrate the technical solution of the present invention, but do not constitute a limitation on the present invention.

[0023] Figure 1 This is a schematic flowchart of the method of the present invention;

[0024] Figure 2 This is a structural block diagram of the device of the present invention; Detailed Implementation

[0025] The present invention will be further described in detail below with reference to the accompanying drawings and embodiments. Of course, the specific embodiments described below are merely illustrative of the technical solutions of the present invention, and not intended to limit the present invention. Furthermore, the parts described in the embodiments or drawings are merely illustrative examples of relevant parts of the present invention, and not the entirety of the present invention. At the same time, all other embodiments obtained by those skilled in the art based on the embodiments of the present invention should naturally fall within the protection scope of the present invention.

[0026] like Figure 1 As shown in the figure, the underground pipe network leak detection method based on acoustic image feature recognition disclosed in this embodiment includes the following steps:

[0027] S1. Use an acoustic wave acquisition device to collect acoustic signals from underground water supply pipes in suspected leakage areas or at regular monitoring points. Ideally, collect continuous acoustic signals during low background noise periods at night, with a recommended duration of ≥10 seconds. Simultaneously record environmental parameters such as water pressure, temperature, pipe type, burial depth, and surrounding traffic noise levels. Then, denoise the collected acoustic signals using wavelet thresholding, adaptive filtering, or spectral subtraction. Divide long signals into fixed-length window signals, with a 30% overlap between adjacent signals to preserve transient characteristics. Finally, normalize the amplitude of each signal segment to obtain a standardized one-dimensional acoustic segment. S2. For the preprocessed one-dimensional acoustic signal The image is converted into a two-dimensional time-frequency image using short-time Fourier transform, continuous wavelet transform, or Mel spectrogram method, where the horizontal axis represents time, the vertical axis represents frequency, and the pixel gray value represents the energy intensity at that time-frequency point; S3, the time-frequency image is input into a deep learning classification model to obtain the leakage status discrimination result of the time-frequency image, which includes "leaking" or "non-leaking"; S4, the discrimination result is compared with the on-site verification result. If they match, the time-frequency image and its metadata are stored in the leakage voiceprint image database. Based on the newly added samples in the leakage voiceprint image database, the deep learning classification model is periodically iterated and optimized.

[0028] It is worth noting that the initial establishment of the leakage acoustic image database includes the following key steps:

[0029] First, an initial training dataset needs to be constructed through manual annotation and controlled experimental data acquisition. For example, controlled leakage simulations can be conducted in a laboratory or on-site environment. Typical leakage conditions are artificially created in the test pipe section (such as an abandoned pipe section or a dedicated test platform): different pipe materials (ductile iron, PVC, steel pipe), different pipe diameters (DN100–DN600), different pressures (0.2–0.6MPa), and different leakage forms (micropores, cracks, loose joints). High-precision acoustic sensors are then used to synchronously acquire leakage sound wave signals. ≥50 valid signal segments are repeatedly acquired for each condition, and images are generated through time-frequency transformation, uniformly labeled as "leakage." Background noise signals are acquired in a known leak-free normal water supply pipe section (verified by pressure testing), including: normal water flow sound, transient sound from valve opening and closing, pump station vibration, and interference from surrounding traffic and construction noise coupled to the pipeline. Time-frequency images are also generated and labeled as "non-leakage."

[0030] Second, initial model training and semi-automatic annotation are performed. First, an initial classification model is trained: a basic model is trained using the aforementioned "leaking" and "non-leaking" datasets. Due to the limited data volume, strong data augmentation (rotation, pruning, noise addition) and early stopping strategies are employed to prevent overfitting. Although the model has limited accuracy (e.g., approximately 80% accuracy on the test set), it possesses preliminary discrimination capabilities. Second, the initial classification model is deployed for pilot inspections: the initial classification model is deployed in a small-scale pipeline network (e.g., a residential area or a main pipeline); predictions are made on all collected time-frequency images, outputting a "suspected leak" list; maintenance personnel manually verify high-confidence samples (through excavation verification or pressure decay testing). Finally, the first batch of real-world labeled samples is obtained: if the model predicts "leaking" and on-site verification confirms it, it is labeled as a positive sample; if the model predicts "non-leaking" and long-term monitoring shows no abnormalities, it is labeled as a negative sample; all verified samples and their metadata (location, pipe material, pressure, time, etc.) are stored in the initial leak acoustic image database.

[0031] Third, iteration and database expansion, which actually leads into step S4 mentioned above. Specifically, after each leak detection task, the "suspected leak" points output by the model are verified; the verification results (regardless of whether they are correct) are fed back into the database; the database supports version management, recording the sample source (simulation / real), verification method (excavation / stress test / expert judgment), confidence level, etc.; when the database sample size grows to a certain scale (e.g., >10,000 images), the model is retrained, continuously forming updated iterative versions, so that the entire model continues to evolve.

[0032] In this embodiment, a standardized one-dimensional sound wave segment is used. Its length is Number of sampling points, sampling frequency is Methods for performing time-frequency transformation include short-time Fourier transform, continuous wavelet transform, or Mel spectrum transform.

[0033] The method for short-time Fourier transform is as follows:

[0034] Select Function Window Window length L, frame shift H;

[0035] Divide the signal into overlapping frames:

[0036]

[0037]

[0038] in For frame indexing;

[0039] Perform an FFT transform on each frame and calculate the... Discrete Fourier Transform of a Frame:

[0040]

[0041]

[0042] Extract the amplitude spectrum and convert it into an energy and power spectrum:

[0043]

[0044] To enhance visual contrast, you can optionally convert to a dB scale:

[0045]

[0046] in For reference energy, such as ;

[0047] Finally, images are generated: indexed by frame. The horizontal axis represents time, and the frequency represents... The vertical axis is For pixel grayscale values, form Two-dimensional time-frequency image.

[0048] The method of continuous wavelet transform is as follows:

[0049] Selecting the mother wavelet: ,in The center frequency is usually taken as 6 based on general experience;

[0050] Based on the target frequency range Convert to scale a

[0051]

[0052]

[0053] like Hz, corresponding scale ;

[0054] For each scale and time location Calculate CWT

[0055]

[0056] The square of the modulus is used as the energy representation:

[0057]

[0058] Convert the scale axis to the frequency axis:

[0059]

[0060] Finally, an image is generated: in time. The horizontal axis represents frequency. The vertical axis is After dB conversion, the grayscale value is used to generate a two-dimensional time-frequency image.

[0061] The method for generating two-dimensional time-frequency images using Mel-frequency transform is as follows:

[0062] First, perform a short-time Fourier transform to obtain the complex spectrum. Then calculate the power spectrum:

[0063]

[0064] Define a Mel filter bank: First, determine the Mel frequency; then, uniformly select M triangular filters (e.g., M=128) in the Mel domain to cover... Finally, each filter is mapped back to the linear frequency domain to obtain the filter response. The Mel frequency is:

[0065]

[0066] Using Mel filter banks:

[0067]

[0068]

[0069] right Take the logarithm. , To prevent small constants from taking the logarithm of zero;

[0070] Finally, use the frame index. The horizontal axis represents time, and the Mel channel is used for this purpose. The vertical axis represents the nonlinear frequency. As pixel grayscale values, a two-dimensional Mel-spectrum is formed.

[0071] Example 1:

[0072] In this embodiment, the deep learning classification model adopts a convolutional neural network based on the Residual Network (ResNet) architecture, specifically ResNet-34 as the preferred implementation scheme, for binary classification of leakage status in time-frequency images generated by acoustic signals from underground water supply pipelines.

[0073] The two-dimensional time-frequency images obtained through short-time Fourier transform, continuous wavelet transform, or Mel-frequency transform are uniformly adjusted to 224×224 pixel single-channel grayscale images, and the pixel values ​​are normalized to the range [0,1] before being input into the model. The convolutional neural network structure includes the following in sequence:

[0074] An initial 7×7 convolutional layer (stride=2, output channels=64) is followed by batch normalization and ReLU activation function; a 3×3 max pooling layer (stride=2) is used for initial downsampling; four residual block groups (i.e., residual stages) correspond to layers 1 to 4 in the original ResNet, with 3, 4, 6, and 3 residual units in each group respectively, for a total of 16 residual units; each residual unit consists of two 3×3 convolutional layers (with batch normalization and ReLU sandwiched in between) and a skip connection. When the input and output dimensions are inconsistent, channel matching is performed through 1×1 convolution; after the last residual block group, a global average pooling layer is connected to compress the spatial dimension to 1×1 while preserving channel features; finally, a fully connected layer is connected, with an output dimension of 2, corresponding to the "leaking" and "non-leaking" discrimination results respectively.

[0075] It is worth noting that during model training, the ResNet-34 weights pre-trained on the ImageNet dataset were used as initialization parameters (except for the last fully connected layer), and subsequently fine-tuned on the leaky voiceprint image database constructed in this invention. The AdamW optimizer was used, with an initial learning rate of... The batch size is 32, and data augmentation strategies such as horizontal flipping and random brightness adjustment are used during training to improve generalization ability.

[0076] In actual leak detection tasks, the model performs forward inference on the input time-frequency image and outputs logits values ​​for two categories, which are then converted into probability distributions using a Softmax function. If the probability of the "leakage" category is greater than a preset threshold, a leak is determined to exist at the monitoring point, and an early warning process is triggered.

[0077] Example 2:

[0078] In this embodiment, the deep learning classification model adopts the visual Transformer architecture to perform binary classification of leakage status on the two-dimensional time-frequency image generated by the acoustic signal of the underground water supply pipeline.

[0079] First, the two-dimensional time-frequency images obtained through short-time Fourier transform, continuous wavelet transform, or Mel-frequency transform are uniformly adjusted to 224×224 pixel single-channel grayscale images, which are then used as model inputs. This image is divided into 196 fixed-size non-overlapping image patches, each patch being 16×16 pixels (i.e., 224 / 16=14, 224 / 16=14, for a total of 14×14=196 patches).

[0080] Next, each 16×16 image patch is flattened into a vector of length 256; this vector is then projected into a 768-dimensional embedding space through a learnable linear embedding layer (i.e., a fully connected mapping) to obtain the token representation of the image patch. .

[0081] Then, a learnable category label is introduced at the beginning of the sequence, denoted as . This is then concatenated to the beginning of the image patch token sequence to form an input sequence of length 197.

[0082]

[0083] in Predefined or learnable positional encodings are used to preserve the spatial order information of image patches;

[0084] The input sequence is fed into a 12-layer stacked Transformer encoder. Each encoder layer contains a multi-head self-attention mechanism and a feedforward neural network, with Layer Normalization and residual connections used in between. After all encoder layers, the output sequence is... .

[0085] Finally, only the output vector corresponding to the category label is taken. (Right now The first element of the input classifier is a classification head consisting of a fully connected layer with two output neurons, corresponding to the two classification results of "leakage" and "non-leakage".

[0086] It is worth noting that during the training phase, the ViT-Base weights pre-trained on a large image dataset (such as ImageNet-21k) were loaded as initialization parameters and fine-tuned on the leaky voiceprint image database constructed in this invention. Focal Loss was used as the loss function to address the imbalance between positive and negative samples, and the AdamW optimizer was selected with a learning rate of [value missing]. The batch size is 16.

[0087] In practical leak detection applications, the system inputs the time-frequency image to be tested into the model to obtain the predicted probability of the "leakage" category. If the probability exceeds a preset threshold, it is determined that there is a leak at the monitoring point, and an early warning process is triggered.

[0088] like Figure 2 As shown, to achieve the above objectives, the present invention also provides an underground pipe network leak detection device based on acoustic image feature recognition, which includes a first sound acquisition module for acquiring acoustic signals from underground water supply pipes; a second data preprocessing module for preprocessing the acoustic signals to obtain standardized one-dimensional acoustic segments; a third time-frequency transformation module for performing time-frequency transformation on the acoustic segments to generate a two-dimensional time-frequency image, wherein the horizontal axis represents time, the vertical axis represents frequency, and the pixel grayscale value represents the energy intensity at that time-frequency point; and a fourth image discrimination module for inputting the time-frequency image into a deep learning classification model to obtain the leakage status discrimination result of the time-frequency image, wherein the leakage status includes "leaking" or "non-leaking".

[0089] To achieve the above objectives, the present invention also provides a storage medium storing a plurality of computer programs, which, when executed, are used to implement the above-described method for detecting leaks in underground pipe networks based on acoustic image feature recognition.

[0090] It should be noted that the above embodiments are only for more clearly illustrating the technical solution of the present invention. Those skilled in the art will understand that the implementation of the present invention is not limited to the above content. Any obvious changes, substitutions or replacements made based on the above content do not exceed the scope of the technical solution of the present invention. Other implementations will also fall within the scope of the present invention without departing from the concept of the present invention.

Claims

1. A method for leak detection in underground pipe networks based on acoustic image feature recognition, characterized in that, Includes the following steps: S1. Acquire acoustic signals from underground water supply pipelines and preprocess the acoustic signals to obtain standardized one-dimensional acoustic segments. S2. Perform time-frequency transformation on the sound wave segment to generate a two-dimensional time-frequency image, where the horizontal axis represents time, the vertical axis represents frequency, and the pixel gray value represents the energy intensity at that time-frequency point. S3. Input the time-frequency image into a deep learning classification model to obtain the leakage status discrimination result of the time-frequency image, wherein the leakage status includes "leakage" or "non-leakage"; S4. Compare the discrimination result with the on-site verification result. If they match, store the time-frequency image and its metadata in the leakage soundprint image database. Based on the newly added samples in the leakage soundprint image database, periodically iterate and optimize the deep learning classification model.

2. The method for detecting leaks in underground pipe networks based on acoustic image feature recognition as described in claim 1, characterized in that: The time-frequency transformation includes short-time Fourier transform, continuous wavelet transform, or Mel spectrum transform.

3. The method for detecting leaks in underground pipe networks based on acoustic image feature recognition as described in claim 1, characterized in that: The deep learning classification model includes a convolutional neural network or a visual Transformer architecture, used to perform binary classification of the leakage state in the time-frequency image.

4. The method for detecting leaks in underground pipe networks based on acoustic image feature recognition as described in claim 3, characterized in that: When the deep learning classification model is a convolutional neural network, the convolutional neural network adopts a residual network structure, including an initial convolutional layer, a max pooling layer, multiple residual block groups, and a global average pooling layer connected in sequence. The last fully connected layer has an output dimension of 2, corresponding to the "leaking" and "non-leaking" categories respectively. The number of residual block groups is 3 to 5, each group contains 2 to 6 residual units, and each residual unit contains at least two convolutional layers and a skip connection structure.

5. The method for detecting leaks in underground pipe networks based on acoustic image feature recognition as described in claim 3, characterized in that: When the deep learning classification model is a visual Transformer architecture, the visual Transformer architecture divides the input time-frequency image into non-overlapping image blocks of fixed size, performs linear embedding on each image block and then superimposes position encoding, and then performs feature extraction through a multi-layer Transformer encoder. Finally, the output vector corresponding to the category label is sent to the classification head to obtain the binary classification result.

6. The method for leak detection in underground pipe networks based on acoustic image feature recognition as described in any one of claims 4 or 5, characterized in that: The input to the deep learning classification model is a single-channel grayscale time-frequency image with a uniform size of 224×224 pixels or 256×256 pixels. The pixel values ​​are normalized before being input into the model. The model output is converted into a leakage probability by the Softmax function. When the leakage probability is greater than a preset threshold p, it is determined to be a leakage state.

7. The method for detecting leaks in underground pipe networks based on acoustic image feature recognition as described in claim 3, characterized in that: The deep learning classification model employs Focal Loss or weighted cross-entropy loss function during training to alleviate the class imbalance problem between leaked and non-leaked samples, and combines random image enhancement strategies, including horizontal flipping, brightness perturbation, and Gaussian noise injection, to improve the model's generalization performance.

8. The method for leak detection in underground pipe networks based on acoustic image feature recognition as described in any one of claims 1-7, characterized in that: The metadata includes sensor location, pipe material, pipe diameter, water pressure, and verification label.

9. A leak detection device for underground pipe networks based on acoustic image feature recognition, characterized in that, include: The first sound acquisition module is used to acquire sound wave signals from underground water supply pipes; The second data preprocessing module is used to preprocess the acoustic signal to obtain a standardized one-dimensional acoustic segment. The third time-frequency transformation module is used to perform time-frequency transformation on the sound wave segment to generate a two-dimensional time-frequency image, where the horizontal axis represents time, the vertical axis represents frequency, and the pixel gray value represents the energy intensity of the time-frequency point. The fourth image discrimination module is used to input the time-frequency image into a deep learning classification model to obtain the leakage status discrimination result of the time-frequency image, wherein the leakage status includes "leakage" or "non-leakage".

10. A storage medium, characterized in that: The system contains several computer programs, which, when executed, are used to implement the underground pipe network leak detection method based on acoustic image feature recognition as described in any one of claims 1-8.