Real Time Pipeline Detection
Real Time Pipeline Detection
Abstract: This study introduces an advanced deep-learning framework for the real-time
detection of pipeline leaks in smart city infrastructure. The methodology transforms acous-
tic emission (AE) signals from the time domain into scalogram images using continuous
wavelet transform (CWT) to enhance leak-related features. A Gaussian filter minimizes
background noise and clarifies these features further. The core of the framework combines
convolutional neural networks (CNNs) with long short-term memory (LSTM), ensuring
a comprehensive examination of both spatial and temporal features of AE signals. A
genetic algorithm (GA) optimizes the neural network by isolating the most important
features for leak detection. The final classification stage uses a fully connected neural
network to categorize pipeline health conditions as either ‘leak’ or ‘non-leak’. Experimental
validation on real-world pipeline data demonstrated the framework’s efficacy, achieving
accuracy rates of 99.69%. This approach significantly advances smart city capabilities in
pipeline monitoring and maintenance, offering a durable and scalable solution for proactive
infrastructure management.
Leak detection strategies have evolved over the decades. Traditional methods such
as visual inspection, pressure monitoring, and acoustic-based methods were initially em-
ployed. However, these techniques were limited by delayed detection times, operator
dependency, and the inability to pinpoint leaks in real time. These challenges led to the
adoption of advanced approaches utilizing AE signals and machine learning, which now
focus on real-time leak detection and precise localization. Real-time leak detection sys-
tems continuously monitor pipelines for signals such as pressure fluctuations, acoustic
anomalies, or vibration changes [9]. These systems enable immediate detection and cor-
rective actions, significantly reducing the environmental, economic, and safety impacts of
leaks. By eliminating delays and ensuring continuous surveillance, real-time systems en-
hance pipeline reliability and operational efficiency, making them indispensable in modern
infrastructure. The pipeline industry now focuses on cost-effective methods for repair-
ing minor leaks, replacing encapsulating collars and clamps rather than replacing entire
sections [10,11]. Thus, intelligent leak detection methods are necessary for minimizing
maintenance costs [12,13]. Recent advancements in machine learning and artificial intelli-
gence have greatly improved the efficiency and accuracy of pipeline leak detection [14,15].
Techniques such as vibration-based methods, pressure wave techniques, time-domain re-
flection methods, and AE technology have been developed to ensure pipeline leak detection
reliability [16,17]. AE technology is particularly notable for its high sensitivity, easy instal-
lation, and real-time leak-detection capabilities [18]. Various studies have demonstrated
the potential of AE technology in this domain, and developed the use of AE technology for
detecting the beginning of cracks in pipelines [19,20].
networks are the most popular DL techniques for defect identification. CNNs use local rep-
resentative fields, share weights within the network, and use special domain subsampling
to minimize the danger of overfitting and enable low computing complexity. Moreover,
CNNs have shown promising pattern recognition in pipelines, centrifugal pumps, and
bearing failure diagnosis [30,31].
Various studies have demonstrated the potential of AE technology in leak detection
and have developed methods for detecting cracks and other anomalies in pipelines. Tech-
niques such as principal component analysis, neural networks, and wavelet transforms
have been explored for feature extraction and pattern recognition. Deep learning has gained
significant attention for its ability to solve complex problems in various domains. For ex-
ample, CNN-based transfer learning models have been successfully applied to classify
microseismic event waveforms [32,33]. This study highlights the effectiveness of transfer
learning in handling data scarcity, which can be adapted to pipeline leak detection scenar-
ios with limited leak data by utilizing pre-trained models. A hybrid deep learning and
transfer learning approach for aerosol retrieval [34] showcased the potential of integrat-
ing domain-specific preprocessing with deep learning frameworks. Similarly, our work
incorporates domain-specific preprocessing CWT scalograms and Gaussian filtering to en-
hance signal clarity and feature extraction. Attention U-Net architectures for self-potential
inversion tasks [35] demonstrated how attention mechanisms can enhance model focus
on critical data regions. This inspires potential future extensions of our pipeline monitor-
ing framework to include attention layers for focusing on key time-frequency regions of
AE scalograms.
CNNs excel at extracting spatial features from data, but they do not capture temporal
dependencies effectively. This limitation affects the ability to fully recognize patterns in
uninterrupted data, such as AE signals in pipeline diagnostics. To solve this issue, the
CNN network is incorporated with LSTM. LSTMs are specifically designed to capture long-
range dependencies and temporal sequences in data, making them optimal for analyzing
time-series information. By combining CNN with LSTM, the feature extraction process
is enhanced, using CNN for spatial pattern recognition and LSTM for temporal pattern
recognition. This hybrid approach enhances the precision and efficiency of leak detection
in pipelines, providing a more comprehensive analysis compared to using CNN alone. The
latent spaces derived from the combined CNN and LSTM models are further optimized
using a GA to accurately assess the health state of the pipeline.
The key contributions of this study are outlined below.
1. A Gaussian filter is used to enhance variations in color intensity due to energy change
across different scales and frequencies in AE scalograms.
2. A deep learning framework is introduced, combining enhanced AE scalograms with
CNN-LSTM models and a genetic algorithm (GA) for feature optimization, with the
goal of improving the identification of pipeline operating conditions.
3. The proposed approach is validated using real pipeline data, showcasing its effective-
ness across varying leak scenarios, fluid types, and pressure conditions.
The composition of this work is organized as follows: Section 2 outlines the proposed
model and the sequential DL models for leak identification. The experimental setup
is discussed in Section 3. Section 4 comprises the results, while Section 5 consists of
the discussion. Finally, the conclusion and future directions of this study are described
in Section 6.
2. Proposed Methodology
The proposed approach begins with the collection of AE signals from the pipeline,
followed by a series of preprocessing, feature extraction, and classification steps, ultimately
2. Proposed Methodology
The proposed approach begins with the collection of AE signals from the pipeline,
Appl. Sci. 2025, 15, 185
followed by a series of preprocessing, feature extraction, and classification steps, 4ulti-
of 19
mately leading to an accurate assessment of the pipeline’s health condition. This compre-
hensive workflow ensures that critical signal characteristics are preserved and analyzed
leading to an accurate assessment of the pipeline’s health condition. This comprehensive
effectively. Figure 1 visually represents the step-by-step flow of the proposed methodol-
workflow ensures that critical signal characteristics are preserved and analyzed effectively.
ogy, providing a clear overview of the processes involved. The detailed steps are outlined
Figure 1 visually represents the step-by-step flow of the proposed methodology, providing
below:
a clear overview of the processes involved. The detailed steps are outlined below:
Figure
Figure 1. Proposed methodology
1. Proposed methodology architecture.
architecture.
Step
Step I:I:FromFromthethe pipeline,
pipeline, the AEthe signals
AE signals are collected
are collected during bothduringleakboth leak and
and non-leak
non-leak
conditions. conditions.
Step II: TD
Step II: TD AE AEsignals
signalsareareconverted
convertedintointoimages
images utilizing thethe
utilizing CWT.
CWT. These images
These imagesuse
various colors to represent different energy intensities, illustrating how
use various colors to represent different energy intensities, illustrating how energy levels energy levels vary
across different
vary across time and
different timefrequency
and frequency ranges.
ranges.
Step III: CWT images are pre-processed
Step III: CWT images are pre-processed using using aaGaussian
Gaussianfilter
filtertotosmooth
smoothand andreduce
reduce
noise
noise in
in the
the scalogram
scalogramimages.
images.ThisThisfiltering
filteringenhances
enhancesthe theclarity
clarityofofthe
thekey
keyfeatures,
features,making
mak-
it easier to identify potential leaks.
ing it easier to identify potential leaks.
Step IV: To
Step IV: To extract
extract detailed spatial and
detailed spatial and temporal
temporalfeatures
featuresfrom
fromthe theenhanced
enhancedscalo-
scalo-
grams, a hybrid model combining CNN and LSTM was
grams, a hybrid model combining CNN and LSTM was used. The CNN component effec- used. The CNN component
effectively
tively capturescaptures spatial
spatial features,
features, such such as changes
as changes in energy
in energy at specific
at specific levels,levels, including
including var-
variations in AE amplitude. Meanwhile, the LSTM component
iations in AE amplitude. Meanwhile, the LSTM component is adept at capturing temporalis adept at capturing tem-
poral dependencies,
dependencies, providing
providing information
information about about the sequence
the sequence of events
of events in the in
AEthe AE signal,
signal, such
such as AE intensity over time and frequency distribution. These extracted
as AE intensity over time and frequency distribution. These extracted characteristics are characteristics
are
thenthen
used used for further
for further analysis
analysis to determine
to determine the the distinct
distinct characteristics
characteristics of pipeline
of pipeline leaks.
leaks.
Step V: A feature vector is generated by integrating spatial
Step V: A feature vector is generated by integrating spatial and temporal features and temporal features
extracted from enhanced
extracted from enhanced scalogram
scalogram imagesimages using
usingaahybrid
hybridCNN-LSTM
CNN-LSTMmodel. model.These
Theseex- ex-
tracted features are collected by a genetic algorithm, which then selects
tracted features are collected by a genetic algorithm, which then selects the most im- the most important
ones.
portantBased
ones.on theseon
Based refined features,features,
these refined pipelinepipeline
leaks are detected,
leaks and theand
are detected, health
the state
health of
the pipeline is determined using a fully connected
state of the pipeline is determined using a fully connected layer. layer.
(a) (b)
(a) (b)
FilteredCWT
Figure3.3.Filtered
Figure CWTscalograms
scalograms (a)
(a) normal
normal and
and (b)
(b) leak
leak conditions.
conditions.
This method utilized the Gaussian filter’s capability to maintain the key features of
This method utilized the Gaussian filter’s capability to maintain the key features of
CWT images while reducing noise, thereby improving the visual quality and reliability
CWT images while reducing noise, thereby improving the visual quality and reliability of
of the images for subsequent processing and analysis. This approach is known for its
the images for subsequent processing and analysis. This approach is known for its effec-
effectiveness in noise reduction and image enhancement, making it a valuable tool in the
tiveness in noise reduction and image enhancement, making it a valuable tool in the initial
initial stages of CWT image analysis.
stages of CWT image analysis.
2.3. CNN and LSTM Hybrid Structure
2.3. CNN and LSTM Hybrid Structure
In this study, a hybrid model that integrates CNN and LSTM networks to extract
In
featuresthis study,
from a hybrid
pipeline model
data was that
used. Thisintegrates CNN and
section outlines the LSTM networks
individual to extract
components of
features
CNN and from pipeline
LSTM datadescribes
and then was used. This
their section outlines
combined structure,the individual
specifically components
designed for theof
CNN andextraction
feature LSTM and then describes their combined structure, specifically designed for the
task.
feature extraction task.
2.3.1. Convolutional Neural Network
2.3.1. Convolutional Neuraldeep
CNN is a specialized Network
learning model designed primarily for image processing
tasks, as illustrated in Figure 4.
CNN is a specialized deep learning It efficiently
model captures
designedspatial hierarchies
primarily of features
for image by
processing
applying
tasks, a series of convolutional
as illustrated in Figure 4. Itlayers, whichcaptures
efficiently use learnable filters
spatial to detect of
hierarchies local patterns
features by
such as edges, textures, and shapes within the input data. This automated feature
applying a series of convolutional layers, which use learnable filters to detect local pat- extraction
process
terns suchallows CNNstextures,
as edges, to identify
and intricate
shapesrelationships in image
within the input data.data, making
This them highly
automated feature
effective for tasks involving visual pattern recognition and classification. CNN is primarily
composed of convolutional, pooling, and activation layers. The central component is the
convolutional layer, which performs the convolution operation essentially as an inner
product between sections of the input data and a filter matrix. This process is important
for extracting feature information from the input data. By utilizing different convolutional
Appl. Sci. 2025, 15, 185 7 of 19
kernels, a variety of features can be extracted, with the size of these kernels playing a signif-
icant role in determining the features that are captured. The mathematical representation
of the convolution operation is as follows:
!
Appl. Sci. 2025, 15, 185 C −1 8 of 19
∑
γ γ −1
Xj = f Xi ∗ Kijγ + γ
Bj (3)
i =0
where γ denotes the current layer, X j is the jth eigenmatrix of the current layer, f (·) is the
γ
γ −1 𝑒 𝑒 2
activation function, Xi 𝑓is 𝑥the data element of the γ − 1 layer, C is the
1 number of kernels, (6)
γ 𝑒 𝑒 1 𝑒 γ
Kij is the weight matrix of the corresponding convolution kernel, and Bj is the bias matrix.
𝑓 𝜎 𝑤 ∙ ℎ ,𝑥 𝑏 (7)
Appl. Sci. 2025, 15, 185 8 of 19
The ReLU (rectified linear unit) activation function is applied to the output of each
convolutional layer in a CNN. It is a non-linear function that allows all positive inputs to
pass unchanged while mapping negative inputs to zero. This activation introduces essential
non-linearity into the model, enabling it to learn complex patterns and relationships in the
data. Additionally, ReLU helps to mitigate the vanishing gradient problem, a common
issue with other activation functions like Sigmoid or Tanh, thereby improving the training
efficiency and convergence speed of deep neural networks.
Sigmoid:
1
f (x) = (5)
(1 + e − x )
Tanh:
(e x ) − (e− x )
2
f (x) = x = −1 (6)
Appl. Sci. 2025, 15, 185 (e ) + (e− x ) (1 + e−2x ) 9 of 19
The CNN architecture was designed with a focus on computational efficiency. Con-
volutional layers with small kernel sizes (3 × 3) were used to effectively extract spatial
features while minimizing computational
𝐶 𝑡𝑎𝑛ℎcosts.
𝑤 Max-pooling
∙ ℎ 𝑏 (2 × 2) were employed (9)
, 𝑥 layers
to reduce feature map dimensions progressively, significantly lowering computational over-
head. Here, 𝑤 and
The number 𝑤 are
of filters (32,weight
64, and matrices, 𝑏 andbased
128) were chosen 𝑏 are bias vectors,
on empirical and 𝐶 to
experiments repre-
sents the
balance candidate
feature cell state.
extraction capability and computational complexity. Activation functions,
ReLU
3. Thefor CNN, were
cell state selected the
combines for their effectiveness
previous cell stateininformation
capturing non-linear relationships
with the new one. The cell
and temporal dependencies,
state is updated using: respectively. Training was conducted with mini-batch process-
ing, utilizing GPU acceleration and early stopping to optimize training speed.
𝐶 𝑓 ∙ 𝐶 𝑖 ∙𝐶 (10)
2.3.2. Long Short-Term Memory
LSTM is a type of RNN, specifically𝐶designed
𝑓 ∙ 𝐶to handle
𝑖 ∙ 𝐶and process long-time sequence (11)
information. The LSTM architecture for the proposed model is described below in Table 1.
where 𝐶 is the previous cell state and ∙ denotes element-wise multiplication.
Unlike traditional RNNs, LSTM can handle long-term dependencies more effectively by
4. Output gates
incorporating a gatedetermine
mechanism theand
next
cellhidden state,The
state [34]. andnetwork
from the cell state,
consists which
of three keyinfor-
mation should be output, where the output gate is given by:
gates: the forget gate, input gate, and output gate, which are responsible for controlling the
flow of information through the network. These gates work together to manage memory
ℎ 𝑜 ∙ 𝑡𝑎𝑛ℎ 𝐶 (12)
retention, input updates, and output generation, enabling LSTMs to effectively capture
where 𝑤 dependencies
long-term and 𝑏 are in thesequential data. Figure
weight matrix 5 provides
and bias vector.aThe
visual state ℎ of
representation
hidden is this
the out-
architecture, illustrating
put of the LSTM unit. how these gates interact to regulate the information flow across
different time steps.
1. The forget gate controls which information from the previous cell state should be
discarded or retained. It evaluates the importance of past information using a sigmoid
activation function and is mathematically expressed as:
f t = σ w f ·[ ht −1 , xt ] + b f (7)
where w f is the weight matrix, b f is the bias vector, ht −1 is the output of the previous unit,
and xt is the current input.
2. The input gate controls which new information is added to the cell state, computed as:
it = σ (wi ·[ ht −1 , xt ] + bi ) (8)
Ct = tanh w g ·[ ht −1 , xt ] + bg (9)
Here, wi and w g are weight matrices, bi and bi are bias vectors, and Ct represents the
candidate cell state.
3. The cell state combines the previous cell state information with the new one. The cell
state is updated using:
Ct = f t · Ct −1 + it ·Ct (10)
Ct = f t · Ct −1 + it ·Ct (11)
where w0 and b0 are the weight matrix and bias vector. The hidden state ht is the output of
the LSTM unit.
The CNN-LSTM model processes AE-CWT images through a hybrid architecture that
combines spatial feature extraction and temporal pattern recognition. The workflow begins
with the CNN component, where the input images are passed through three convolutional
layers to extract spatial features. The first convolutional layer applies 32 filters of size 3 × 3,
followed by a 2 × 2 max-pooling layer, reducing the feature map size from 654 × 873 to
327 × 436. In the second convolutional layer, 64 filters of size 3 × 3 are applied, and
another 2 × 2 max-pooling layer further reduces the feature map to 162 × 217. The third
convolutional layer employs 128 filters of size 3 × 3, followed by a final 2 × 2 max-pooling
layer, which compresses the output to 80 × 107. The resulting 3D feature map is then
flattened into a 1D vector of size 1,095,680 and passed into an LSTM layer with 64 units.
The LSTM layer captures temporal dependencies within the sequential data using a tanh
activation function, enabling the model to recognize time-dependent patterns essential for
detecting pipeline faults effectively.
This hybrid CNN-LSTM architecture combines the spatial feature extraction capabili-
ties of the CNN with the temporal sequence modeling strengths of the LSTM. This synergy
allows the model to capture intricate spatial patterns while maintaining an understanding
of time-dependent relationships, making it highly effective for pipeline fault detection
and diagnosis.
Appl. Sci. 2025, 15, 185 10 of 19
6. Experimental
Figure 6.
Figure Experimentalsetup
setupfor
forthe pipeline
the leak
pipeline detection.
leak detection.
The sensitivity and frequency range of the sensors significantly affected the data
quality. Sensors with a higher sensitivity, e.g., 75 kHz resonance frequency, extracted AE
signals more effectively, improving the scalograms clarity and classification performance.
Additionally, sensor placement closer to potential leak sources resulted in better signal
strength, contributing to higher model accuracy.
Initial measurements were conducted with the valve closed for one minute to establish
baseline conditions. Following this, the valve was opened to simulate a 1 mm hole in the
pipeline, and measurements were recorded for an additional two minutes. Further data
collection was performed with the valve closed at a pressure of 18 bars for one minute.
Subsequently, a 0.5 mm leak was intentionally introduced, and data were collected for
two minutes with the valve open. This process was repeated for leak sizes of 0.7 mm and
1 mm at a reduced pressure of 7 bars. For each fluid pressure level, a total of 360 samples
were collected: 120 samples during normal operation (no leaks) and 240 samples under
leakage conditions, ensuring balanced representation across conditions. This procedure
generated 360 samples per pressure condition, capturing AE signal variations correspond-
ing to both normal and faulty states.
The AE signals recorded during normal operation and leakage conditions are illus-
trated in Figures 8 and 9, offering visual insights into signal differences between these
states. A detailed summary of the collected data, including variations across normal and
leak states under different pressure levels, is presented in Table 4. This dataset provides
a comprehensive foundation for fault detection and classification analysis in pipeline
monitoring systems.
Number of Samples
Data Set Pressure of Fluid (Bars) Leak Size (mm) Time (s)
Non-Leak (Normal) Leak
Water 13 1.0 360 120 240
Gas 18 1.0 360 120 240
Water 7 0.7 360 120 240
Gas 7 0.5 360 120 240
states. A detailed summary of the collected data, including variations across normal and
leak states under different pressure levels, is presented in Table 4. This dataset provides a
Appl. Sci. 2025, 15, 185 comprehensive foundation for fault detection and classification analysis in pipeline mon-
13 of 19
itoring systems.
Figure
Figure 8. 8. Non-leak
Non-leak AEAE signal
signal (a)(a)
1313
barbar
(b)(b)
1818 bar.
bar.
(a) (b)
Figure
Figure 9. Leak
9. Leak AEAE signal
signal (a)(a)
13 13
barbar
(b)(b)
18 18 bar.
bar.
4. Results
Table 4. Data set description.
Pressure of Fluid The arrangement of training and validation data plays a crucial
Number role in evaluating
of Samples
Data Set the Leak Size of
effectiveness (mm)the proposed Time (Sec)During the training phase, data corresponding
method.
(Bars) Non-Leak (Normal) Leak
Water 13 to a leak size1.0 of 1 mm under fluid pressures
360 of 13 and 18 bars 120 were utilized, 240while the
Gas 18 evaluation phase
1.0 employed data from
360 varying pressure levels
120and leak sizes to ensure a
240
Water 7 comprehensive 0.7 assessment. The dataset
360 comprised 1080 samples,
120 evenly divided between
240
Gas 7 non-leak samples0.5 and leak samples. To 360construct and validate the 120model, 80% of the 240dataset
was randomly allocated for training, while the remaining 20% was reserved for validation.
4. Class imbalance was addressed by adjusting the loss function to assign higher importance
Results
to the minority class and using stratified k-fold cross-validation to ensure balanced splits
The arrangement of training and validation data plays a crucial role in evaluating the
during training and testing phases.
effectiveness of the proposed method. During the training phase, data corresponding to a
To maintain consistency and reliability, the experiments were repeated 10 times. The
leak size of 1 mm under fluid pressures of 13 and 18 bars were utilized, while the evalua-
model’s convergence was examined by varying the number of training epochs (50, 100, and
tion phase employed data from varying pressure levels and leak sizes to ensure a com-
150 epochs), and it was observed that optimal accuracy was achieved between 70 and
prehensive assessment. The dataset comprised 1080 samples, evenly divided between
100 epochs. Early stopping was applied to prevent overfitting by halting training if the
non-leak samples and leak samples. To construct and validate the model, 80% of the da-
validation loss did not improve for 10 consecutive epochs. Additionally, a dropout rate
taset was randomly allocated for training, while the remaining 20% was reserved for val-
of 0.5 was introduced in the fully connected layers to prevent over-reliance on specific
idation. Class imbalance was addressed by adjusting the loss function to assign higher
features, and training was stopped once validation loss plateaued. Furthermore, a 5-fold
importance to the minority
cross-validation strategy class and using stratified
was implemented k-foldthe
to validate cross-validation to ensure
model’s robustness bal-dif-
across
anced splits during training and testing phases.
ferent data subsets. These combined strategies ensured a balanced, efficient, and reliable
To maintain
training process, consistency
resulting inand reliability,
a robust the experiments
and generalizable were
fault repeated
diagnosis 10 times.
model Thefor
suitable
model’s convergence
real-world applications. was examined by varying the number of training epochs (50, 100,
and 150Metrics
epochs), and
like it was observed
precision, accuracy,that optimal
recall, andaccuracy
F1 score was
wereachieved
employedbetween 70 andthe
to evaluate
100efficacy of the suggested method. These metrics give an accurate measure of the ifclassifi-
epochs. Early stopping was applied to prevent overfitting by halting training the
validation loss did not improve for 10 consecutive epochs. Additionally, a dropout rate of
0.5 was introduced in the fully connected layers to prevent over-reliance on specific fea-
tures, and training was stopped once validation loss plateaued. Furthermore, a 5-fold
cross-validation strategy was implemented to validate the model’s robustness across dif-
ferent data subsets. These combined strategies ensured a balanced, efficient, and reliable
Appl. Sci. 2025, 15, 185 14 of 19
cation algorithm’s efficiency and data classification accuracy. Equations (13)–(16) are the
specific formulas that were used to calculate these measurements.
T.Pα
(∑αA nα ) ∗
T.Pα + F.Pα
Precision = (13)
N
T.Pα
(∑αA nα ) ∗
T.Pα + F.Nα
Recall = (14)
N
A A
Recallα ∗ Prcisionα
1
F1 =
N ∑ nα ∗ 2 ∗ ∑ Recallα + Precisionα
(15)
α α
(∑αA T.Pα )
Accuracy = (16)
N
where ‘FPα ’, ‘FNα ’, and ‘TPα ’ represent false positive, false negative, and true positive
outcomes for class A, respectively. A false positive (FPα ) occurs when a sample is incorrectly
classified as belonging to class A when it does not. A true positive (TPα ) indicates the
correct identification of samples that genuinely belong to class A. On the other hand, a false
negative (FNα ) happens when samples that actually belong to class A are misclassified as
belonging to another class.
The total number of samples in class A is represented by the sum of TPα and FNα
denoted as nα . The total number of samples misclassified as belonging to class A is the sum
of FPα and the difference between the total number of data samples (N) and nα . Here, N
signifies the total number of data samples in the testing dataset.
To evaluate the effectiveness of the proposed approach, a comparison was conducted
with three other models designed for similar tasks. The first model (CWT-CNN), developed
by Li et al. [39], employs a CNN trained on CWT images extracted from AE signals under
a similar experimental setup. The second model (FFT-CNN), proposed by Masoumeh
Rahimi et al. [40], utilizes FFT images as input to a CNN for feature extraction and clas-
sification. The third model (STFT-CNN) integrates STFT images with a CNN, leveraging
time-frequency representations for fault detection. These models represent diverse TFD
approaches combined with CNN architectures, providing a benchmark to assess the perfor-
mance and robustness of the proposed method across multiple preprocessing techniques
and feature extraction strategies
5. Discussion
The proposed CNN-LSTM hybrid model, applied to AE data from industrial fluid
pipelines, demonstrated outstanding performance, achieving precision, accuracy, F1 score,
and recall values of 99.71%, 99.69%, 99.82%, and 99.75%, respectively, as presented in
Table 5. These results highlight the model’s superiority over reference models, including
CWT-CNN, FFT-CNN, and STFT-CNN, in terms of classification accuracy. The model’s
enhanced performance stems from its ability to integrate spatial and temporal features
effectively. The CNN component extracts spatial features from enhanced CWT scalograms,
capturing intricate energy variations in the AE signals. Meanwhile, the LSTM component
excels in modeling temporal dependencies, identifying meaningful sequential patterns
within the data. Additionally, the inclusion of a genetic algorithm (GA) refines the extracted
features, ensuring that only the most relevant and discriminative features are selected
for classification. This hybrid architecture enables a seamless combination of spatial and
temporal feature extraction, significantly enhancing the model’s capacity to differentiate
Appl. Sci. 2025, 15, 185 15 of 19
Table 5. Comparison metrics of the proposed model with the reference models.
Li et al. [39] collected acoustic signals from a gas pipeline system with small, synthetic
leaks to apply deep learning techniques for leak detection. Their approach involved intro-
ducing controlled artificial leaks, which exposed the system to diverse acoustic signatures
under predefined conditions. This deliberately created input was important for training
the model to recognize patterns associated with small leaks, simulating real-world condi-
tions effectively. The system utilized these inputs to iteratively optimize its performance,
refining its robustness and adaptability by addressing edge cases through expert feed-
back. By transforming the acoustic signals into the frequency domain and applying a 1D
CNN model, the methodology was able to develop discriminative features for small-leak
detection. However, noise in the acoustic signals introduced challenges that impacted
performance, resulting in an accuracy of 85.18%. Despite these limitations, the approach
demonstrated its effectiveness and was selected for comparison due to its compatibility
with our experimental setup. The performance metrics in Table 5 reflect the application of
this reference technique to our dataset.
Masoumeh Rahimi et al. [40] employed a DL approach for leak detection by collecting
data using a hydrophone from a leaking plastic tank. Their study systematically compared
multiple signal preprocessing techniques across the frequency domain, time domain, and
time-frequency domain, with each preprocessed signal subsequently analyzed using a
convolutional neural network (CNN) for feature extraction and classification. The study
revealed that the FFT-CNN approach outperformed other preprocessing methods in effec-
tively detecting leaks. To ensure a fair and consistent comparison, the same methodology
was applied to our pipeline dataset, where signals underwent similar preprocessing across
the time, frequency, and time-frequency domains before being processed by a CNN model.
The results obtained from our dataset were carefully recorded and analysed, allowing for a
direct comparison with ABC’s findings to evaluate the relative performance of each method
in the context of pipeline fault detection.
The proposed model was compared with a TFD method, specifically the STFT-CNN.
In this approach, AE signals from the TD are transformed into the TFD using the STFT. The
resulting representations are fed into a CNN, which is trained to extract features indicating
leaks. This method utilizes the CNN’s pattern recognition capabilities combined with STFT
for feature extraction. For a fair comparison, the same dataset was used, and the STFT-CNN
achieved an accuracy of 93.05%. The lower accuracy is primarily due to information loss
caused by the windowing effect in STFT, which reduces its ability to capture transient signal
variations accurately. This limitation affects the TFD resolution, resulting in decreased fault
classification performance compared to the proposed model.
In comparison to the methods previously stated, the results obtained using the pro-
posed method show a higher classification accuracy. Figures 10 and 11 show the confusion
Appl. Sci. 2025, 15, 185 16 of
Appl. Sci. 2025, 15, 185 16 of 19
19
Appl. Sci. 2025, 15, 185 matrices and t-SNE visualizations to demonstrate this superiority, which16 isof mainly
19 at-
tributable to the method’s improved consistency and precision in identifying leak statuses
as well as pipeline normal operating conditions.
(b)
(a)
(b)
(a)
(c) (d)
(c) (d)
Figure
Figure 10.
Figure10.
10. Confusion
Confusion
Confusion matrix
matrix of
of (a)
matrix (a) proposed
ofproposed model,
model,
(a) proposed (b) CWT-CNN,
CWT-CNN,
(b) CWT-CNN,
model, (b) (c)FFT-CNN,
(c) FFT-CNN,
(c) FFT-CNN, (d)STFT-CNN.
STFT-CNN.
(d) STFT-CNN.
(d)
(a) (b)
(a) (b)
(c) (d)
Figure 11. t-SNE plot of (a) proposed model, (b) CWT-CNN, (c) FFT-CNN,
(d) (d) STFT-CNN.
(c)
Figure
Figure 11. t-SNE
t-SNE plot of (a) proposed model, (b)
(b) CWT-CNN,
CWT-CNN,(c)
(c)FFT-CNN,
FFT-CNN,(d)
(d)STFT-CNN.
STFT-CNN.
Appl. Sci. 2025, 15, 185 17 of 19
6. Conclusions
This study introduced an innovative approach for pipeline leak detection using ad-
vanced deep learning (DL) techniques. AE signals were collected from a pipeline system
and transformed into CWT images to capture essential time-frequency features. A hybrid
DL framework, integrating CNN and LSTM models, was developed to extract both spatial
and temporal features effectively from these images. To further enhance feature relevance
and classification accuracy, a Genetic Algorithm (GA) was employed for feature selec-
tion, ensuring that only the most discriminative features were retained. These optimized
features were then fed into a fully connected layer for pipeline health classification. The
proposed method demonstrated outstanding performance, achieving an impressive accu-
racy of 99.69% in leak detection. This highlights its robustness, reliability, and superiority
over traditional approaches. The scientific significance of this research lies in its seamless
integration of AE signal processing, time-frequency analysis, and DL techniques, resulting
in a highly accurate and scalable solution for pipeline leak detection. Furthermore, the
approach holds significant practical value, particularly for industries relying on pipelines
as critical infrastructure, offering a reliable and efficient tool for real-time monitoring
and maintenance.
Future work will address precise leak localization by developing methods such as
accurately extracting leak-related AE events and implementing time difference of arrival
techniques. Building on this, the integration of hydraulic behavior analysis will be explored,
incorporating physical models like Bernoulli’s principle and pressure-loss equations. These
advancements will enable a comprehensive framework that not only detects leaks with
high accuracy but also localizes them precisely while considering the hydraulic dynamics
of pipeline systems. Together, these developments aim to enhance operational safety,
reduce environmental and economic impacts, and contribute to a broader understanding
of pipeline health monitoring.
Author Contributions: Conceptualization, F.S., Z.A. and J.-M.K.; methodology, F.S., Z.A. and J.-M.K.;
validation, F.S., Z.A. and J.-M.K.; formal analysis, F.S., Z.A. and J.-M.K.; resources, F.S., Z.A.
and J.-M.K.; writing—original draft preparation, F.S., Z.A. and J.-M.K.; writing—review and editing,
J.-M.K.; visualization, F.S., Z.A. and J.-M.K.; project administration, J.-M.K.; funding acquisition,
J.-M.K. All authors have read and agreed to the published version of the manuscript.
Funding: This work was supported by the Korea Institute of Energy Technology Evaluation and
Planning (KETEP) grant funded by the Korean government (MOTIE) (‘RS-2023-00232515′ , ‘Devel-
opment of life prediction safety technology and hydrogen embrittlement estimation of LNG pipe
mixed hydrogen’). This work was also supported by the Korea Institute of Energy Technology Evalu-
ation and Planning (KETEP) grant funded by the Korean government (MOTIE) (‘RS-2024-00449107’,
‘Development of Flexible Pipe and Connector for Hydrogen Gas’).
Data Availability Statement: The original contributions presented in this study are included in the
article. Further inquiries can be directed to the corresponding author.
Conflicts of Interest: Author Jong-Myon Kim was employed by the company PD Technology Co., Ltd.
The remaining authors declare that the research was conducted in the absence of any commercial or
financial relationships that could be construed as a potential conflict of interest.
Nomenclature
AE Acoustic emission
CWT continuous wavelet transform
CNN Convolutional neural network
LSTM Long short-term memory
ANN Artificial neural network
Appl. Sci. 2025, 15, 185 18 of 19
GA Genetic algorithm
TD Time domain
FD Frequency domain
TFD Time-frequency domain
STFT Short-time Fourier transform
FFT Fast Fourier transform
DL Deep learning
ReLU Rectified neural network
References
1. Latif, J.; Shakir, M.Z.; Edwards, N.; Jaszczykowski, M.; Ramzan, N.; Edwards, V. Review on condition monitoring techniques for
water pipelines. Measurement 2022, 193, 110895. [CrossRef]
2. Zhang, Z.; Zhang, L.; Fu, M.; Ozevin, D.; Yuan, H. Study on leak localization for buried gas pipelines based on an acoustic
method. Tunn. Undergr. Space Technol. 2022, 120, 104247. [CrossRef]
3. Rahman, I.U.; Mohammed, H.J.; Siddique, M.F.; Ullah, M.; Bamasag, A.; Alqahtani, T.; Algarni, S. Application of membrane
technology in the treatment of waste liquid containing radioactive materials. J. Radioanal. Nucl. Chem. 2023, 332, 4363–4376.
[CrossRef]
4. Che, T.-C.; Duan, H.-F.; Lee, P.J. Transient wave-based methods for anomaly detection in fluid pipes: A review. Mech. Syst. Signal
Process. 2021, 160, 107874. [CrossRef]
5. Rai, A.; Ahmad, Z.; Hasan, M.J.; Kim, J.-M. A Novel Pipeline Leak Detection Technique Based on Acoustic Emission Features and
Two-Sample Kolmogorov–Smirnov Test. Sensors 2021, 21, 8247. [CrossRef] [PubMed]
6. Xing, J.; Meng, H.; Meng, X. An urban pipeline accident model based on system engineering and game theory. J. Loss Prev. Process
Ind. 2020, 64, 104062. [CrossRef]
7. Miao, X.; Zhao, H.; Xiang, Z. Leakage detection in natural gas pipeline based on unsupervised learning and stress perception.
Process Saf. Environ. Prot. 2023, 170, 76–88. [CrossRef]
8. Xu, T.; Zeng, Z.; Huang, X.; Li, J.; Feng, H. Pipeline leak detection based on variational mode decomposition and support vector
machine using an interior spherical detector. Process Saf. Environ. Prot. 2021, 153, 167–177. [CrossRef]
9. Siddique, M.F.; Ahmad, Z.; Ullah, N.; Ullah, S.; Kim, J.-M. Pipeline Leak Detection: A Comprehensive Deep Learning Model
Using CWT Image Analysis and an Optimized DBN-GA-LSSVM Framework. Sensors 2024, 24, 4009. [CrossRef] [PubMed]
10. Xiao, R.; Hu, Q.; Li, J. A model-based health indicator for leak detection in gas pipeline systems. Measurement 2021, 171, 108843.
[CrossRef]
11. Li, S.; Song, Y.; Zhou, G. Leak detection of water distribution pipeline subject to failure of socket joint based on acoustic emission
and pattern recognition. Measurement 2018, 115, 39–44. [CrossRef]
12. Park, S.; Yeo, D.; Bae, J.H. Unsupervised Learning–Based Plant Pipeline Leak Detection Using Frequency Spectrum Feature
Extraction and Transfer Learning. IEEE Access 2024, 12, 88939–88949. [CrossRef]
13. Siddique, M.F.; Ahmad, Z.; Kim, J.-M. Pipeline leak diagnosis based on leak-augmented scalograms and deep learning. Eng. Appl.
Comput. Fluid Mech. 2023, 17, 2225577. [CrossRef]
14. Banjara, N.K.; Sasmal, S.; Voggu, S. Machine learning supported acoustic emission technique for leakage detection in pipelines.
Int. J. Press. Vessel. Pip. 2020, 188, 104243. [CrossRef]
15. Xu, C.; Du, S.; Gong, P.; Li, Z.; Chen, G.; Song, G. An Improved Method for Pipeline Leakage Localization with a Single Sensor
Based on Modal Acoustic Emission and Empirical Mode Decomposition with Hilbert Transform. IEEE Sens. J. 2020, 20, 5480–5491.
[CrossRef]
16. Ullah, N.; Siddique, M.F.; Ullah, S.; Ahmad, Z.; Kim, J.-M. Pipeline Leak Detection System for a Smart City: Leveraging Acoustic
Emission Sensing and Sequential Deep Learning. Smart Cities 2024, 7, 2318–2338. [CrossRef]
17. Rojek, I.; Studzinski, J. Detection and Localization of Water Leaks in Water Nets Supported by an ICT System with Artificial
Intelligence Methods as a Way Forward for Smart Cities. Sustainability 2019, 11, 518. [CrossRef]
18. Elforjani, M.; Mba, D. Detecting natural crack initiation and growth in slow speed shafts with the Acoustic Emission technology.
Eng. Fail. Anal. 2009, 16, 2121–2129. [CrossRef]
19. Kim, H.; Lee, J.; Kim, T.; Park, S.J.; Kim, H.; Jung, I.D. Advanced Thermal Fluid Leakage Detection System with Machine Learning
Algorithm for Pipe-in-Pipe Structure. Case Stud. Therm. Eng. 2023, 42, 102747. [CrossRef]
20. Ali, H.; Choi, J. A Review of Underground Pipeline Leakage and Sinkhole Monitoring Methods Based on Wireless Sensor
Networking. Sustainability 2019, 11, 4007. [CrossRef]
21. Wang, W.; Mao, X.; Liang, H.; Yang, D.; Zhang, J.; Liu, S. Experimental research on in-pipe leaks detection of acoustic signature in
gas pipelines based on the artificial neural network. Measurement 2021, 183, 109875. [CrossRef]
Appl. Sci. 2025, 15, 185 19 of 19
22. Lee, S.; Kim, B. Machine Learning Model for Leak Detection Using Water Pipeline Vibration Sensor. Sensors 2023, 23, 8935.
[CrossRef] [PubMed]
23. Wang, F.; Lin, W.; Liu, Z.; Wu, S.; Qiu, X. Pipeline Leak Detection by Using Time-Domain Statistical Features. IEEE Sens. J. 2017,
17, 6431–6442. [CrossRef]
24. Wang, W.; Sun, H.; Guo, J.; Lao, L.; Wu, S.; Zhang, J. Experimental study on water pipeline leak using In-Pipe acoustic signal
analysis and artificial neural network prediction. Measurement 2021, 186, 110094. [CrossRef]
25. Esu, O.E.; Wang, Y.; Chryssanthopoulos, M.K. A baseline-free method for damage identification in pipes from local vibration
mode pair frequencies. Struct. Health Monit. 2022, 21, 2152–2189. [CrossRef]
26. Shukla, H.; Piratla, K. Leakage detection in water pipelines using supervised classification of acceleration signals. Autom. Constr.
2020, 117, 103256. [CrossRef]
27. Huang, L.; Hong, X.; Yang, Z.; Liu, Y.; Zhang, B. CNN-LSTM network-based damage detection approach for copper pipeline
using laser ultrasonic scanning. Ultrasonics 2022, 121, 106685. [CrossRef]
28. Shang, L.; Zhang, Z.; Tang, F.; Cao, Q.; Pan, H.; Lin, Z. CNN-LSTM Hybrid Model to Promote Signal Processing of Ultrasonic
Guided Lamb Waves for Damage Detection in Metallic Pipelines. Sensors 2023, 23, 7059. [CrossRef] [PubMed]
29. Spandonidis, C.; Theodoropoulos, P.; Giannopoulos, F. A Combined Semi-Supervised Deep Learning Method for Oil Leak
Detection in Pipelines Using IIoT at the Edge. Sensors 2022, 22, 4105. [CrossRef] [PubMed]
30. Chen, C.-C.; Liu, Z.; Yang, G.; Wu, C.-C.; Ye, Q. An Improved Fault Diagnosis Using 1D-Convolutional Neural Network Model.
Electronics 2020, 10, 59. [CrossRef]
31. Hasan, M.J.; Rai, A.; Ahmad, Z.; Kim, J.-M. A Fault Diagnosis Framework for Centrifugal Pumps by Scalogram-Based Imaging
and Deep Learning. IEEE Access 2021, 9, 58052–58066. [CrossRef]
32. Dong, L.; Shu, H.; Tang, Z.; Yan, X. Microseismic event waveform classification using CNN-based transfer learning models. Int.
J. Min. Sci. Technol. 2023, 33, 1203–1216. [CrossRef]
33. Li, W.; Huang, R.; Li, J.; Liao, Y.; Chen, Z.; He, G.; Yan, R.; Gryllias, K. A perspective survey on deep transfer learning for fault
diagnosis in industrial scenarios: Theories, applications and challenges. Mech. Syst. Signal Process. 2022, 167, 108487. [CrossRef]
34. Fu, D.; Shi, H.; Gueymard, C.A.; Yang, D.; Zheng, Y.; Che, H.; Fan, X.; Han, X.; Gao, L.; Bian, J.; et al. A Deep-Learning and
Transfer-Learning Hybrid Aerosol Retrieval Algorithm for FY4-AGRI: Development and Verification over Asia. Engineering 2024,
38, 164–174. [CrossRef]
35. Guo, Y.; Cui, Y.; Chen, H.; Xie, J.; Zhang, C.; Liu, J. Self-potential inversion based on Attention U-Net deep learning network.
J. Cent. South Univ. 2024, 31, 3156–3167. [CrossRef]
36. Nitin; Gupta, S.B. A Hybrid Image Denoising Method Based on Discrete Wavelet Transformation with Pre-Gaussian Filtering.
Indian J. Sci. Technol. 2022, 15, 2317–2324. [CrossRef]
37. Büssow, R. An algorithm for the continuous Morlet wavelet transform. Mech. Syst. Signal Process. 2007, 21, 2970–2979. [CrossRef]
38. Deng, G.; Cahill, L.W. An adaptive Gaussian filter for noise reduction and edge detection. In Proceedings of the 1993 IEEE Con-
ference Record Nuclear Science Symposium and Medical Imaging Conference, San Francisco, CA, USA, 31 October–6 November
1993; pp. 1615–1619. [CrossRef]
39. Li, J.; Liu, Y.; Chai, Y.; He, H.; Gao, M. A Small Leakage Detection Approach for Gas Pipelines based on CNN. In Proceedings of
the 2019 CAA Symposium on Fault Detection, Supervision and Safety for Technical Processes (SAFEPROCESS), Xiamen, China,
5–7 July 2019; pp. 390–394. [CrossRef]
40. Rahimi, M.; Alghassi, A.; Ahsan, M.; Haider, J. Deep Learning Model for Industrial Leakage Detection Using Acoustic Emission
Signal. Informatics 2020, 7, 49. [CrossRef]
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual
author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to
people or property resulting from any ideas, methods, instructions or products referred to in the content.