Next Article in Journal
The Curvature Parameter of the Symmetry Energy and a Modified Polytropic Equation of State
Previous Article in Journal
Experimental and Numerical Validation of a Fully Composite Permanent Coupling for Segmented Wind Turbine Blades
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Real-Time Detection of Small Liquid Drip in Pipeline in Complex Industrial Scenes Based on Machine Vision

College of Computer Science and Cyber Security, Chengdu University of Technology, Chengdu 610059, China
*
Author to whom correspondence should be addressed.
Appl. Sci. 2026, 16(6), 2823; https://doi.org/10.3390/app16062823
Submission received: 13 February 2026 / Revised: 12 March 2026 / Accepted: 13 March 2026 / Published: 15 March 2026
(This article belongs to the Section Applied Industrial Technologies)

Abstract

Pipeline leakage can lead to catastrophic consequences, and traditional sensor-based detection methods often struggle to identify changes caused by slow or minor leaks. This paper proposes a real-time machine vision-based method for detecting liquid leakage in pipelines, suitable for complex industrial scenarios. By extracting droplet foreground regions and constructing a detection model based on the contour and motion features of droplets, the proposed method effectively filters out interference from lighting variations, equipment vibrations, and personnel movement in industrial environments, while accurately identifying the vertical motion characteristics of dripping liquids. An experimental platform was established to validate the effectiveness of the proposed approach. The results demonstrate that the proposed method achieves a detection rate of 98.04%, a false alarm rate of 5.26%, and a processing speed of 90.71 fps. Comparative experiments show that this method significantly outperforms traditional approaches, such as the dense optical flow method, which yields a higher false alarm rate and a processing speed of only 2.2 fps under the same test conditions. These findings confirm that our approach offers a more accurate and efficient solution for real-time pipeline liquid leakage detection.

1. Introduction

Industrial pipelines are extensively utilized in critical sectors such as petroleum, chemical engineering, and energy, serving functions analogous to the blood vessels of the human body. During their production, manufacturing, and operational phases, pipelines are susceptible to leakage due to welding defects or prolonged exposure to harsh conditions including high temperature, high pressure, humidity, and corrosion. Once a leak occurs, it can result in catastrophic consequences [1,2]. In response to this challenge, various detection technologies have been developed and applied for pipeline leakage monitoring.
Sensor-based methods have been widely adopted for this purpose, including pressure sensors [3,4,5], piezoelectric sensors [6,7,8], and optical sensors [9,10,11]. When a pipeline leak occurs, a pressure differential is generated, which can be detected by pressure sensors. However, this method typically requires the pressure change to reach a significant magnitude, rendering it prone to missed detections in cases of very small leaks. Piezoelectric sensors detect leakage by converting vibration signals into voltage, but they are highly susceptible to external interference, often resulting in false alarms. Similarly, optical sensors are vulnerable to environmental disturbances, leading to false positives [2]. Acoustic detectors installed on pipelines capture vibration and noise generated by leaks [12,13,14]; nevertheless, they are easily affected by background noise and varying environmental conditions, also contributing to false alarms. The negative pressure wave method [15,16] represents another commonly employed technique, yet it struggles to detect the subtle changes associated with slow or minor leaks.
The pressure and acoustic variations induced by slow leakage are often too subtle to be reliably detected by traditional sensor-based methods. To compensate for this limitation, manual inspection has been employed as a supplementary solution. However, it suffers from poor real-time performance and low efficiency. In recent years, with the increasing deployment of cameras in industrial environments, machine vision technology has attracted considerable attention from both academia and industry for leakage detection.
Several studies [17,18,19,20] have applied deep learning-based object detection to leakage identification. These approaches typically involve collecting and manually labeling leakage image data, training a deep learning model, and deploying it for field detection. However, collecting sufficient on-site leakage data is challenging, and the wide variety of leakage scenarios often leads to poor generalization and low detection rates. Moreover, object detection methods are generally effective only when a large liquid area has accumulated on the ground, which requires a considerable amount of time—making them unsuitable for early-stage leak detection.
In parallel, large language models and multimodal large language models have achieved remarkable success in fields such as natural language processing, knowledge-based question answering, and data processing [21]. They have also been applied to industrial visual anomaly detection [22,23,24,25,26]. However, their performance deteriorates significantly when applied to slow pipeline liquid leakage detection in complex industrial scenes. Experimental results in this study show a detection rate of 0%, indicating that multimodal large language models lack sufficient sensitivity to subtle visual changes.
Digital twin technology has also been explored for pipeline leak identification. In [27], a digital twin model based on the Arithmetic Optimization Algorithm-Support Vector Machine (AOA-SVM) was constructed, achieving a classification accuracy of 90.5% in a simulated MATLAB environment. Convolutional neural networks (CNNs) have also been employed for leak detection. Elvio et al. proposed an improved CNN for water supply network leak detection, achieving a detection rate of 92.8% [28]. Cherifi et al. applied image processing and deep learning methods to oil leakage detection by first extracting image features and then applying segmentation techniques [29]; however, this method is more suitable for large-scale oil spills. Li et al. used machine vision to detect underwater oil pipeline leaks, achieving a recognition success rate of 90% [30]. Wang et al. [31] employed a convolutional neural network (CNN) to detect gas leakage based on infrared images and categorized the images according to different leakage rates.
Despite these advances, existing methods still face limitations in detecting slow, small-scale liquid leaks in real time under complex industrial conditions. To address this gap, this paper proposes a machine vision-based method for real-time pipeline liquid leakage detection. The main contributions are as follows:
(1)
The proposed method achieves a processing speed of 90.71 fps at 1920 × 1080 resolution, enabling real-time detection and analysis.
(2)
It effectively handles environmental disturbances such as lighting variations, equipment vibration, and personnel movement, ensuring robustness in complex industrial scenarios.
(3)
By integrating both contour and motion features of droplets, the method effectively filters out interference and ensures accurate identification of pipeline liquid leakage. Experimental results demonstrate a detection rate of 98.04% and a false alarm rate of 5.26%, validating the effectiveness of the proposed approach and offering a novel solution for pipeline liquid leakage detection.

2. Methodology

2.1. Overview of the Model

The overall framework of the proposed model is illustrated in Figure 1. It consists of four main components: image foreground extraction, image foreground validity check, accumulation and attenuation of image foreground, and liquid drip detection.
(1)
Image foreground extraction: To detect liquid dripping behavior, it is necessary to first extract foreground targets from video streams. In this study, the frame difference method is employed to extract foreground regions from the image sequences.
(2)
Image foreground validity check: In real-world industrial scenarios, various interference signals are present, such as lighting variations, equipment vibration, and personnel movement, all of which can generate irrelevant foreground targets. To isolate valid droplet regions, a morphological feature model of falling droplets is constructed to eliminate interference and retain only candidate regions that exhibit droplet-like characteristics.
(3)
Accumulation and attenuation of image foreground: Interference signals are typically incidental and non-persistent, whereas liquid dripping behavior in pipelines exhibits repetitive patterns. However, slow dripping is difficult to detect from a single frame and may lead to false alarms if evaluated in isolation. To address this, a dynamic foreground accumulation and attenuation model is developed to capture the repetitive nature of droplet activity. This model records the accumulated behavioral features of dripping over a period of time, enhancing the reliability of detection.
(4)
Liquid drip detection: Unlike the repetitive falling motion characteristic of pipeline liquid dripping, interference signals are generally sporadic and lack persistence. By constructing a liquid dripping behavior detection model, the proposed method distinguishes repetitive foreground motion from occasional disturbances. This enables accurate detection of pipeline liquid dripping while effectively filtering out non-repetitive interference.

2.2. Video Foreground Motion Target Extracting

Pipeline leaks generate motion patterns that can be captured through video motion detection techniques. The frame difference method is a commonly used approach for detecting moving targets in video sequences. As shown in Equation (1), the differential image D n ( x , y ) is obtained by calculating the pixel-wise differences between the current frame F n ( x , y ) and the previous frame F n 1 ( x , y ) . After applying noise reduction and morphological opening and closing operations, the final differential image E n ( x , y ) is obtained, where x , y denotes the pixel coordinates. Prior to frame difference processing, each frame is converted to grayscale. The resulting differential image E n ( x , y ) is then binarized using a threshold θ . If the pixel difference exceeds θ , the pixel is classified as part of a motion region and set to 1; otherwise, it is set to 0, as described in Equation (2).
D n ( x , y ) = F n ( x , y ) F n 1 ( x , y )
M n ( x , y ) = 1 E n ( x , y ) θ 0 E n ( x , y ) < θ

2.3. Video Foreground Moving Object Filtering

By adjusting the binarization threshold θ , it is possible to extract subtle changes in the foreground motion region. However, in complex industrial environments, various factors—such as lighting variations, equipment vibration, and falling leaves—can also induce foreground changes and generate moving targets. For the specific task of detecting slow liquid dripping in pipelines, it is necessary to eliminate interference from irrelevant objects. This is achieved primarily by analyzing the proportion of foreground area relative to the image size and by leveraging the morphological characteristics of liquid droplets.
Events such as equipment vibration, sudden illumination changes, or intrusion of large objects can lead to a sharp increase in the number of foreground pixels. The total number of foreground pixels can be obtained by calculating the number of non-zero pixels in the foreground image M n ( x , y ) , as shown in Equation (3), where f r a m e w i d t h is the image frame width and f r a m e h e i g h t is the image frame height. An area ratio threshold θ a r e a ( 0 < θ a r e a < 1 ) is set. If the condition in Equation (4) is satisfied, the foreground image M n ( x , y ) is considered to contain abnormal large-area interference and is excluded from further processing.
M c o u n t = i = 0 f r a m e w i d t h j = 0 f r a m e h e i g h t x i , j
M c o u n t f r a m e w i d t h × f r a m e h e i g h t θ a r e a
Equation (4) effectively eliminates large-area interference. However, slow dripping behavior generates foreground regions that are typically small and localized. These regions should fall within a reasonable area range, as specified in Equation (5). Foreground contours are extracted from M n ( x , y ) , and the area of each contour is calculated. Contours that do not satisfy Equation (5) are removed, resulting in a set of candidate contours C n ( x , y ) . The contour area is computed using Equation (6).
θ m i n C o n A r e a c o n t o u r a r e a θ m a x C o n A r e a
c o n t o u r a r e a = 1 2 × i = 1 n 1 ( x i × y i + 1 x i + 1 × y i )
Figure 2 illustrates the foreground regions after the above filtering steps. The right side of Figure 2 shows the extracted contour of a pipeline liquid droplet. To further reduce false positives, the extracted contours are subjected to additional filtering based on morphological features. Due to the influence of gravity, most droplets exhibit characteristics such as an elongated vertical orientation, high contour solidity, and a shape between circular and oval. By calculating these features, foreground targets caused by non-drip events can be effectively filtered out.
Equation (7) computes the contour perimeter, and Equation (8) calculates the aspect ratio of the contour. The aspect ratio of a typical droplet contour is generally greater than 1 (indicating vertical elongation) and typically falls within the range of 1.0 to 5.0, as specified in Equation (9). Equation (10) defines contour compactness, where c o n t o u r a r e a , c o n t o u r w i d t h and c o n t o u r h e i g h t are the area, width and height of the contour, respectively. The compactness of a normal droplet contour should lie between 0.35 and 0.95, as shown in Equation (11). Equation (12) defines contour roundness, which measures the similarity between the contour and a perfect circle. Here, c o n t o u r a r e a and c o n t o u r p e r i m e t e r are the area and perimeter of the contour. The roundness of a normal droplet contour should exceed a given threshold R min , as specified in Equation (13). Equation (14) defines contour solidity, where c o n t o u r a r e a is the contour area and c o n t o u r a r e a F u l l is the area of the convex hull of the contour. A solidity value of 1 indicates a perfectly convex contour with no indentations, while values close to 0 indicate highly irregular or concave shapes. Normal droplet contours are expected to be regular with few indentations, satisfying Equation (15). Equation (16) computes contour eccentricity, where a and b are the semi-major and semi-minor axes of the ellipse fitted to the contour. The eccentricity of a normal droplet contour should satisfy Equation (17).
c o n t o u r p e r i m e t e r = i = 1 n 1 ( x i + 1 x i ) 2 + ( y i + 1 y i ) 2
A R = c o n t o u r h e i g h t c o n t o u r w i d t h
A R min A R A R max
C = c o n t o u r a r e a c o n t o u r w i d t h × c o n t o u r h e i g h t
C min C C max
R = 4 π × c o n t o u r a r e a c o n t o u r p e r i m e t e r
R R min
S = c o n t o u r a r e a c o n t o u r A r e a F u l l
S S min
E = 1 b 2 a 2
E E min

2.4. Foreground Moving Target Accumulation and Attenuation

After the filtering steps described in Section 2.3, the extracted contours may still contain residual interference signals. Pipeline liquid dripping exhibits typical repetitive and periodic characteristics. By leveraging these properties, further filtering of interference can be achieved through a mechanism that records the repeatability and periodicity of contour occurrences.
Let the contour set C be defined as follows:
C = < c x , c y , c w , c h , c t > c x , c y , c w , c h N , c t R
where c x , c y is the centroid coordinate of the contour, c w , c h is the width and height of the contour bounding rectangle, and c t is the time to read the frame for contour extraction.
To record the number of repeated occurrences of each contour, the Intersection over Union (IoU) is computed for any two elements c i , c j in the set C . If the IoU exceeds 0, the contour is considered to have recurred, and a repetition counter is incremented accordingly. Using this approach, the contour set can be clustered into groups of repeated occurrences, as expressed in Equation (19), where the counter value for the source point set C i is denoted as C o u n t C i .
C = C 1 C 2 C n
As video frames are continuously processed for foreground extraction and contour filtering, a time threshold θ T is introduced to manage the temporal validity of contours. Contours that exceed this threshold are removed, while newly extracted contours are added to the set. This dynamic update mechanism is described in Equation (20), where C n e w ( t ) represents a newly added contour and C d e l e t e ( t 1 ) denotes a contour to be removed.
C ( t ) = C ( t 1 ) C n e w ( t ) C d e l e t e ( t 1 )
This accumulation and attenuation strategy enables the model to capture the repetitive nature of dripping behavior while gradually discarding transient interference, thereby enhancing the robustness of the detection system.

2.5. Detection and Location of Liquid Leakage in Pipeline

Unlike interference signals such as the horizontal movement of walking personnel, the dripping process of pipeline liquid exhibits distinct vertical motion characteristics. Based on the repetitive and periodic foreground moving targets screened in Section 2.4, vertical motion detection rules are further applied to identify qualified foreground targets and locate the drip source.
Equation (21) defines the foreground moving target boxes that satisfy the repetition condition, where θ c o u n t is the repetition count threshold. Foreground moving targets meeting this requirement are grouped into a candidate set S D i for suspected vertical motion, as described in Equation (22). The condition that two foreground targets must satisfy to be considered part of the same vertical motion trajectory is given in Equation (23), where λ ( λ N ) is a constant threshold.
S D = ( s d i ) s d i C i C o u n t C i θ c o u n t
S D = S D 1 S D 2 S D n
x i x j θ m i n C o n A r e a × λ
In order to further determine whether the drip point in the set S D i is a vertical falling motion, the fitting straight line of the set S D i to be calculated is fitted by the least square method. The slope k calculation method is shown in Equation (24), and the intercept b calculation method is shown in Equation (25). The calculation method of fitting error is shown in Equation (26), and the fitting error and slope k must meet formula (27), where f r a m e h e i g h t is the frame height and α ( α ( 0 , 1 ) ) is a constant. By calculating each one, multiple pipeline liquid leaks can be found, and the leakage source is the minimum value of the middle y coordinate in the set S D i , i.e., min ( s d i . y , s d i S D i ) . This approach enables both the detection of liquid leakage events and the precise localization of the leak source based on vertical motion characteristics.
k = S D i · j = 1 S D i ( s d i . x j × s d i . y j ) j = 1 S D i s d i . x j × j = 1 S D i s d i . y j S D i · j = 1 S D i s d i . y j 2 j = 1 S D i s d i . y j 2
b = j = 1 S D i s d i . x j k × j = 1 S D i s d i . y j S D i
E r r o r f i t = j = 1 S D i s d i . x j ( k × s d i . y j + b ) S D i
E r r o r f i t f r a m e h e i g h t × α k δ

3. Experiment

3.1. Experimental Environment and Data

Due to the lack of publicly available datasets for pipeline liquid leakage, an experimental platform was designed to collect liquid leakage videos for validating the effectiveness of the proposed method. Representative experimental scenarios are shown in Figure 3. The experiments were conducted using actual pipeline equipment, with water injected to simulate drip leakage. A total of 69 video sequences were collected on-site, including 51 videos with pipeline dripping and 18 videos without dripping.

3.2. Evaluation Metrics

To effectively evaluate the detection performance of the proposed method, the detection rate (DR) and false alarm rate (FAR) are defined as follows:
D R = T P T P + F N
F A = F P F P + T N
where TP, FN, FP, and TN denote the numbers of true positives, false negatives, false positives, and true negatives, respectively.

3.3. Experimental Results

The experiments were conducted on a system equipped with an Intel i7-12700H processor and 32 GB of memory. The main parameter configurations are as follows: the kernel size for morphological closing and opening operations is (5, 5); the threshold of image θ foreground binarization is 5; the threshold θ a r e a of area proportion is 0.0001; the minimum threshold θ m i n C o n A r e a of contour area is 3; the maximum threshold θ m a x C o n A r e a of contour area is 50; the minimum threshold A R min of the height width ratio of the contour external rectangle is 1; the maximum threshold A R max of the height width ratio of the contour external rectangle is 5; the minimum threshold C min of the compactness of the liquid drip contour is 0.35; the maximum threshold C max of the compactness of the liquid drip contour is 0.95; the roundness threshold R min of the liquid drip contour is 0.3; the convexity S min of the liquid drip contour is 0.6; the eccentricity E min of liquid drip profile is 0.95; the time threshold θ T is 10 s; the liquid drip repeat threshold θ c o u n t is 3; the vertical operation classification parameter λ is 3; the slope threshold δ is 1; and the fitting error E r r o r f i t is 0.03.
The experimental results are summarized in Table 1. As shown in the table, the proposed method achieves a detection rate of 98.04%, a false alarm rate of 5.26%, and an average processing speed of 90.71 fps.

3.4. Comparison with Other Methods

Several existing methods have been proposed for pipeline leak detection. In [28], a Convolutional Neural Network (CNN)-based method was developed for leak detection in water supply networks. By capturing anomalies in pressure stabilization signals caused by leaks, this approach achieved a detection accuracy of 92.8%. However, sensor-based methods generally struggle to detect slow leaks due to the extremely weak signal variations, making reliable detection challenging.
Machine vision offers a promising alternative for pipeline liquid leakage detection. In recent years, deep learning-based object detection has made significant progress in video image analysis. Nevertheless, its application to liquid leak detection faces two major limitations. First, the difficulty of constructing large-scale, high-quality datasets restricts the generalization ability of deep learning models. Second, liquid leak targets are often extremely small, leading to a high false negative rate when using conventional object detection techniques. The optical flow method is a commonly used technique in computer vision, primarily applied in motion detection and motion behavior analysis. It includes both dense optical flow and sparse optical flow methods [32]. The sparse optical flow method requires the initial extraction of feature points from an image, followed by tracking and analysis of these points. In contrast, the dense optical flow method analyzes the positional changes in every pixel in the image.
In the context of detecting slow liquid drips in pipelines addressed in this paper, the droplet features are not prominent, making feature extraction difficult. Therefore, we adopt the dense optical flow method to detect liquid drips. In this approach, a region where the majority of pixels exhibit downward motion is identified as an abnormal drip region. The parameters of the dense optical flow method are configured as follows: under the same experimental conditions as those used in the previous experiments of this study, the area of the moving region is constrained to the range of [3, 50] pixels. The angular range of downward motion is limited to a specific interval [ 60 ° , 120 ° ] . To effectively detect slow drip behavior, the motion amplitude threshold φ is set to a relatively low value of 0.5, as shown in formula (30), where the horizontal and vertical displacements are considered.
Experimental results show that, for samples with pipeline liquid leakage, the dense optical flow method successfully detects liquid drips. However, it also incorrectly identifies regions without leakage as leakage, leading to false positives. For samples without pipeline liquid leakage, the method produces a considerable number of false alarms, resulting in substantial false detections. Figure 4 presents the motion regions extracted by the dense optical flow method for sample “5.mp4,” which contains pipeline liquid leakage. A total of 17 motion regions were detected. Figure 5 shows the drip regions detected by the dense optical flow method for the same sample. The red rectangular boxes indicate the detected leakage regions—five in total. Among them, one correctly detected region is marked by a red arrow, while the other four are false positives. Figure 6 displays the motion regions extracted by the dense optical flow method for sample “52.mp4,” which does not contain pipeline liquid leakage. A total of 8 motion regions were detected. Figure 7 illustrates the drip regions detected by the dense optical flow method for sample “52.mp4.” The red rectangular boxes indicate two detected leakage regions, both of which are false positives, caused by pipeline jitter being misidentified as leakage. In terms of detection speed, the dense optical flow method, when compared with the detection method proposed in this paper, achieves an average processing frame rate of only 2.2 fps across 69 test samples.
d x 2 + d y 2 φ
Machine learning methods have also been explored for pipeline leak detection. In [27], an improved Support Vector Machine (SVM) approach—termed AOA-SVM (Arithmetic Optimization Algorithm-Support Vector Machine)—was proposed. By establishing a 3D Reduced Order Model (3D ROM) of the pipeline and importing pipeline data, signal classification was performed in the MATLAB environment, achieving a classification accuracy of 90.5%.
Multimodal large language models have shown promising potential in industrial anomaly detection [22,23,24,25]. To evaluate their capability in pipeline liquid leakage detection, we tested the Qwen2-VL [26] model (8B parameters) on our dataset. The system prompt was set as follows: “You are a production safety inspector. Please check whether there is pipeline leakage. If not, answer ‘no’. If yes, return the coordinates of the rectangular box around the leakage source. The size of the rectangular box should correspond to the observed leakage area.” Experimental results showed that the model failed to detect any leakage in all 51 test videos containing pipeline dripping, resulting in a detection rate of 0%.
In contrast, the proposed machine vision-based method demonstrates strong versatility, achieving a detection rate of 98.04%, a false alarm rate of 5.26%, and real-time performance of 90.71 fps. These results meet the requirements for industrial applications and provide an effective solution for pipeline liquid leakage detection.

4. Discussion

The proposed method for pipeline liquid leakage detection consists of four main components: video foreground moving target extraction, video foreground moving target filtering, video foreground moving target accumulation and attenuation, and pipeline liquid leakage detection and localization. Experimental results demonstrate the effectiveness of this approach. However, in certain challenging industrial scenarios—such as partial occlusion of the leakage area, or the simultaneous occurrence of interfering events and actual leakage—missed detections may still occur.
Given the complexity of industrial environments, the robustness of the method can be further enhanced by incorporating an electronic fence mechanism. Specifically, detection can be restricted to predefined regions where pipeline leakage is most likely to occur, while foreground targets outside these regions are directly discarded. This would reduce false alarms and improve computational efficiency.
Future research directions include addressing the limitations identified in this study. In particular, methods to improve detection performance under partial occlusion and in scenes where interference and leakage co-occur should be explored. Developing more advanced feature representations or integrating contextual information may help mitigate these challenges and further increase the detection rate.

5. Conclusions

Pipeline leakage can lead to catastrophic consequences, making early detection of critical importance. Slow leakage often occurs in the early stages of pipeline degradation, yet traditional sensor-based methods struggle to detect the subtle changes associated with such leaks. To address this gap, this paper proposes a real-time pipeline liquid leakage detection method based on machine vision, which is suitable for complex industrial scenarios.
To extract accurate visual leakage signals from cluttered industrial environments, a comprehensive detection model is constructed. This model integrates droplet foreground contour analysis with motion feature extraction, enabling effective filtering of interference from lighting variations, equipment vibration, and personnel movement. An experimental platform was established to validate the proposed method. The results demonstrate a detection rate of 98.04%, a false alarm rate of 5.26%, and a processing speed of 90.71 fps. Comparative experiments with the dense optical flow method further highlight the advantages of our approach. Under identical test conditions, the dense optical flow method produced a significantly higher false alarm rate and achieved a processing speed of only 2.2 fps, confirming the superior accuracy and real-time performance of the proposed method.
The proposed approach provides a practical and efficient solution for early pipeline liquid leakage detection, offering a valuable complement to existing sensor-based techniques.

Author Contributions

Conceptualization, J.Z. and B.C.; methodology, J.Z.; software, J.Z.; validation, J.Z.; formal analysis, J.Z. and B.C.; investigation, J.Z.; resources, J.Z.; data curation, J.Z.; writing—original draft preparation, J.Z.; writing—review and editing, J.Z.; visualization, J.Z.; supervision, B.C.; project administration, J.Z.; funding acquisition, B.C. All authors have read and agreed to the published version of the manuscript.

Funding

The authors declare that they are self-funded for the submitted work and they did not receive external funds, grants or support from any organization.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

Data will be available upon request.

Acknowledgments

The authors would like to thank the anonymous reviewers for their helpful comments and valuable suggestions.

Conflicts of Interest

The authors declare that there are no financial interests, commercial affiliations, or other potential conflicts of interest that could have influenced the objectivity of this research or the writing of this paper.

References

  1. Rajtar, J.M.; Muthiah, R. Pipeline Leak Detection System for Oil and Gas Flowlines. J. Manuf. Sci. Eng. 1997, 119, 105–109. [Google Scholar] [CrossRef]
  2. Wang, X.F.; Cui, K.Y. Overview of Pipeline Leakage Detection Sensors and Applications. J. Jilin Univ. (Inf. Sci. Ed.) 2025, 43, 265–275. (In Chinese) [Google Scholar]
  3. Yao, Z.; Li, Y.; Ding, Y.; Wang, C.; Yao, L.; Song, J. Improved Shock Tube Method for Dynamic Calibration of the Sensitivity Characteristic of Pizoresistive Pressure Sensors. Measurement 2022, 196, 111271. [Google Scholar] [CrossRef]
  4. Li, J.; Zheng, Q.; Qian, Z.; Yang, X. A Novel Location Algorithm for Pipeline Leakage Based on the Attenuation of Negative Pressure Wave. Process Saf. Environ. Prot. 2019, 123, 309–316. [Google Scholar] [CrossRef]
  5. Song, P.; Ma, Z.; Ma, J.; Yang, L.; Wei, J.; Zhao, Y.; Zhang, M.; Yang, F.; Wang, X. Recent Progress of Miniature MEMS Pressure Sensors. Micromachines 2020, 11, 56. [Google Scholar] [CrossRef]
  6. Rathod, V.T. A Review of Electric Impedance Matching Techniques for Piezoelectric Sensors, Actuators and Transducers. Electronics 2019, 8, 169. [Google Scholar] [CrossRef]
  7. Lee, M.-K.; Han, S.-H.; Park, K.-H.; Park, J.-J.; Kim, W.-W.; Hwang, W.-J.; Lee, G.-J. Design Optimization of Bulk Piezoelectric Acceleration Sensor for Enhanced Performance. Sensors 2019, 19, 3360. [Google Scholar] [CrossRef] [PubMed]
  8. Kang, J.; Park, Y.J.; Lee, J.; Wang, S.H.; Eom, D.S. Novel Leakage Detection by Ensemble CNN-SVM and Graph-Based Localization in Water Distribution Systems. IEEE Trans. Ind. Electron. 2017, 65, 4279–4289. [Google Scholar] [CrossRef]
  9. Zuo, J.; Zhang, Y.; Xu, H.; Zhu, X.; Zhao, Z.; Wei, X.; Wang, X. Pipeline Leak Detection Technology Based on Distributed Optical Fiber Acoustic Sensing System. IEEE Access 2020, 8, 30789–30796. [Google Scholar] [CrossRef]
  10. He, Z.Y.; Liu, Q.W. Principles and Applications of Optical Fiber Distributed Acoustic Sensors. Laser Optoelectron. Prog. 2021, 58, 11–25. [Google Scholar]
  11. Stajanca, P.; Chruscicki, S.; Homann, T.; Seifert, S.; Schmidt, D.; Habib, A. Detection of Leak-Induced Pipeline Vibrations Using Fiber: Optic Distributed Acoustic Sensing. Sensors 2018, 18, 2841. [Google Scholar] [CrossRef]
  12. Klein, W.R. Acoustic Leak Detection. In Proceedings of the 16th Annual Energy-Sources Technology Conference and Exhibition, Houston, TX, USA, 31 January–4 February 1993. [Google Scholar]
  13. Datta, S.; Sarkar, S. A Review on Different Pipeline Fault Detection Methods. J. Loss Prev. Process Ind. 2016, 41, 97–106. [Google Scholar] [CrossRef]
  14. Zhang, J. Designing a Cost-Effective and Reliable Pipeline Leak-Detection System. Pipes Pipelines Int. 1997, 42, 20–26. [Google Scholar]
  15. Chen, C.G.; Wang, Y.; Yang, Z.K. Overview of Long Oil and Gas Pipeline Leak Detection Technology. Chem. Engneering Oil Gas 2002, 31, 52–54. [Google Scholar]
  16. Sun, L.; Chang, N. Integrated-Signal-Based Leak Location Method for Liquid Pipelines. J. Loss Prev. Process Ind. 2014, 32, 311–318. [Google Scholar] [CrossRef]
  17. Wang, B.; Chen, M.; Guan, C.; Xia, Z.; Gao, Y.; Dong, L. Oil Leak Detection Method Based on Improved YOLOv7. In Proceedings of the IEEE 2nd International Conference on Energy and Electrical Engineering, Nanchang, China, 20–21 June 2025. [Google Scholar] [CrossRef]
  18. Zhang, J.; Lan, X.; Wang, S.; Liu, W. EPA-YOLO: A Lightweight Pipeline Leak Detection Algorithm Based on Improved YOLOv7. In Proceedings of the 5th International Conference on Computers and Artificial Intelligence Technology, Hangzhou, China, 20–22 December 2024. [Google Scholar] [CrossRef]
  19. Li, Z.; Kong, S.; Tang, P.; Hu, J.; Chen, J.; Wang, Q. A Leak Detection Method for Heat Network pipes Based on YOLOv5 and Automatic Region Growing. In Proceedings of the 8th International Conference on Image, Vision and Computing, Dalian, China, 27–29 July 2023. [Google Scholar] [CrossRef]
  20. Rong, S.; Hamdan, E.; Khaleghi, H.; Karatas, A.; Cetin, A.E. Air Leak Detection Using Sobel-Enhanced YOLO Algorithm from Infrared Images. In Proceedings of the IEEE International Symposium on Circuits and Systems (ISCAS), London, UK, 25–28 May 2025. [Google Scholar] [CrossRef]
  21. Achiam, J.; Adler, S.; Agarwal, S.; Ahmad, L.; Akkaya, I.; Aleman, F.L.; Almeida, D.; Altenschmidt, J.; Altman, S.; Anadkat, S.; et al. Gpt-4 technical report. arXiv 2023. [Google Scholar] [CrossRef]
  22. Jiang, X.; Li, J.; Deng, H.; Liu, Y.; Gao, B.-B.; Zhou, Y.; Li, J.; Wang, C.; Zheng, F. MMAD: A Comprehensive Benchmark for Multimodal Large Language Models in Industrial Anomaly Detection. arXiv 2024. [Google Scholar] [CrossRef]
  23. Wei, S.; Jiang, J.; Xu, X. UniNet: A Contrastive Learning-guided Unified Framework with Feature Selection for Anomaly Detection. In Proceedings of the Computer Vision and Pattern Recognition Conference (CVPR), Nashville, TN, USA, 11–15 June 2025; Available online: https://ieeexplore.ieee.org/document/11094947 (accessed on 20 January 2026).
  24. Shao, Y.; He, H.; Li, S.; Chen, S.; Long, X.; Zeng, F.; Fan, Y.; Zhang, M.; Yan, Z.; Ma, A.; et al. Eventvad: Training-free event-aware video anomaly detection. In Proceedings of the ACM International Conference on Multimedia, Dublin, Ireland, 27–31 October 2025. [Google Scholar] [CrossRef]
  25. Zhou, Q.; Pang, G.; Tian, Y.; He, S.; Chen, J. Anomalyclip: Object-agnostic prompt learning for zero-shot anomaly detection. arXiv 2023. [Google Scholar] [CrossRef]
  26. QwenTeam. Qwen3-VL Technical Report. arXiv 2025. [Google Scholar] [CrossRef]
  27. Dongmeia, W.; Nannan, S.; Dan, Z.; Peng, W.; Jingyi, L. Leakage Identification Model of Digital Twin Pipeline Based on AOA-SVM. J. Jilin Univ. (Inf. Sci. Ed.) 2025, 43, 934–943. [Google Scholar] [CrossRef]
  28. Elvio, D.; Giancarlo, B. An Efficient Data-Driven Leak Detection Strategy by Enhancing a Convolutional Neural Network Approach Using a Gaussian Process Regressor. Water Resour. Manag. 2026, 40, 32. [Google Scholar] [CrossRef]
  29. Cherifi, D.; Mekroud, S.; Boudaoud, A. Deep Learning-Based Segmentation for Oil Pipeline Leak Detection Using Quadcopter Drones. In Proceedings of International Conference on Artificial Intelligence in Renewable Energetic Systems; Lecture Notes in Networks and Systems; Springer: Cham, Switzerland, 2025; Volume 1238. [Google Scholar] [CrossRef]
  30. Li, Y.; Liu, Y.; Wan, Q.; Bi, L.; Yin, X. Implementation of Underwater Vehicle Pipeline Inspection Based on Machine Vision. In Intelligent Networked Things; Communications in Computer and Information Science; Springer: Singapore, 2022; Volume 1714. [Google Scholar] [CrossRef]
  31. Wang, J.; Tchapmi, L.P.; Ravikumara, A.P.; McGuire, M.; Bell, C.S.; Zimmerle, D.; Savarese, S.; Brandt, A.R. Machine vision for natural gas methane emissions detection using an infra-red camera. Appl. Energy 2020, 257, 113998. [Google Scholar] [CrossRef]
  32. Mingguang, S.; Mengmeng, D.; Xuefen, X.; Luyi, L.; Lei, L.; Bin, L.; Zhi, Z. Research Progress on Optical-Flow-Based Video Vibration Measurement Technology. Chin. J. Lasers 2026, 53, 0504003. [Google Scholar]
Figure 1. Framework of the proposed model.
Figure 1. Framework of the proposed model.
Applsci 16 02823 g001
Figure 2. Pipeline droplet contour extraction (the arrow on the left indicates the dripping position; the right image shows the foreground moving target after filtering, noise reduction, and morphological opening and closing operations).
Figure 2. Pipeline droplet contour extraction (the arrow on the left indicates the dripping position; the right image shows the foreground moving target after filtering, noise reduction, and morphological opening and closing operations).
Applsci 16 02823 g002
Figure 3. Experimental scenarios.
Figure 3. Experimental scenarios.
Applsci 16 02823 g003
Figure 4. Motion regions extracted by the dense optical flow method for sample “5.mp4” with pipeline liquid leakage (yellow rectangular boxes indicate motion regions).
Figure 4. Motion regions extracted by the dense optical flow method for sample “5.mp4” with pipeline liquid leakage (yellow rectangular boxes indicate motion regions).
Applsci 16 02823 g004
Figure 5. Drip regions detected by the dense optical flow method for sample “5.mp4” with pipeline liquid leakage (red rectangular boxes indicate detected drip regions; the region marked by the red arrow is correctly identified, while the others are false positives).
Figure 5. Drip regions detected by the dense optical flow method for sample “5.mp4” with pipeline liquid leakage (red rectangular boxes indicate detected drip regions; the region marked by the red arrow is correctly identified, while the others are false positives).
Applsci 16 02823 g005
Figure 6. Motion regions extracted by the dense optical flow method for sample “52.mp4” without pipeline liquid leakage (yellow rectangular boxes indicate motion regions).
Figure 6. Motion regions extracted by the dense optical flow method for sample “52.mp4” without pipeline liquid leakage (yellow rectangular boxes indicate motion regions).
Applsci 16 02823 g006
Figure 7. Drip regions detected by the dense optical flow method for sample “52.mp4” without pipeline liquid leakage (red rectangular boxes indicate detected drip regions, all of which are false positives).
Figure 7. Drip regions detected by the dense optical flow method for sample “52.mp4” without pipeline liquid leakage (red rectangular boxes indicate detected drip regions, all of which are false positives).
Applsci 16 02823 g007
Table 1. Detection performance analysis.
Table 1. Detection performance analysis.
FileTPFPTNFNAverage Time (ms)FPSNumber of Frames
1.mp4100011.8084.78604
2.mp401019.88101.20638
3.mp4100011.6885.59455
4.mp4100013.7272.88576
5.mp4100010.1099.02415
6.mp4100013.8472.23603
7.mp4100013.7372.83654
8.mp4100013.3574.93639
9.mp410009.49105.39429
10.mp410009.77102.35612
11.mp410009.69103.17608
12.mp4100010.2497.62605
13.mp4100010.6493.96613
14.mp4100010.2497.66677
15.mp4100010.1298.79636
16.mp4100010.8692.05606
17.mp4100012.6379.16626
18.mp4100010.1398.70725
19.mp4100010.4295.99601
20.mp4100010.5794.60605
21.mp4100010.1198.88613
22.mp4100010.3496.75608
23.mp4100010.2997.22610
24.mp4100010.2397.74602
25.mp410009.89101.15643
26.mp4100010.8991.81755
27.mp4100010.9391.50755
28.mp4100011.0790.35796
29.mp4100011.0690.39599
30.mp4100010.9791.17624
31.mp4100010.9791.19739
32.mp4100011.1789.53902
33.mp4100011.2888.65935
34.mp4100011.3688.00914
35.mp4100011.0090.90906
36.mp4100011.0290.71904
37.mp4100011.1989.39897
38.mp4100010.9891.09913
39.mp4100011.0290.75905
40.mp4100011.1889.471101
41.mp4100011.2888.631122
42.mp4100011.2788.71913
43.mp4100011.1090.07898
44.mp4100010.9990.95971
45.mp4100010.9491.40918
46.mp4100011.1090.061059
47.mp4100011.3188.41926
48.mp4100011.4587.35760
49.mp4100011.3488.22748
50.mp4100011.3588.091062
51.mp4100011.5786.40736
52.mp4001011.3088.52541
53.mp4001012.0583.02455
54.mp4001011.3787.94443
55.mp4001010.1099.05577
56.mp4001010.5894.55899
57.mp4001010.9591.36452
58.mp4001010.5195.15447
59.mp4001010.5794.58606
60.mp4001011.1589.70523
61.mp4001011.2289.14445
62.mp4001010.6194.23893
63.mp4001010.7792.88690
64.mp4001011.1189.98537
65.mp4001010.4295.93453
66.mp4001010.3796.43453
67.mp4001010.5594.81458
68.mp4001010.7792.86448
69.mp4001011.0490.57407
subtotal50118111.0290.7147488
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.

Share and Cite

MDPI and ACS Style

Zeng, J.; Cai, B. Real-Time Detection of Small Liquid Drip in Pipeline in Complex Industrial Scenes Based on Machine Vision. Appl. Sci. 2026, 16, 2823. https://doi.org/10.3390/app16062823

AMA Style

Zeng J, Cai B. Real-Time Detection of Small Liquid Drip in Pipeline in Complex Industrial Scenes Based on Machine Vision. Applied Sciences. 2026; 16(6):2823. https://doi.org/10.3390/app16062823

Chicago/Turabian Style

Zeng, Jingcan, and Biao Cai. 2026. "Real-Time Detection of Small Liquid Drip in Pipeline in Complex Industrial Scenes Based on Machine Vision" Applied Sciences 16, no. 6: 2823. https://doi.org/10.3390/app16062823

APA Style

Zeng, J., & Cai, B. (2026). Real-Time Detection of Small Liquid Drip in Pipeline in Complex Industrial Scenes Based on Machine Vision. Applied Sciences, 16(6), 2823. https://doi.org/10.3390/app16062823

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop