Multi-scene pipeline leakage video detection based on C3D-RF with TRCE loss joint supervision method

Chengang Lyu, Lijuan Wang, Mengqi Zhang, Xiaojiao LinResearch Square 2024 · DOI

Abstract

In the field of industrial visual monitoring, PTZ cameras need to monitor the leakage of different easy leakage points. The backgrounds of the monitoring images change greatly and the characteristics of leakage targets are small, which will lead to large intra-class differences and small inter-class differences in the dataset samples. These problems affect the ability of the detection network to learn different class features of the leakage images and restrict the leakage detection performance. To solve the above problems, this paper proposes a pipeline leakage video detection method based on loss joint supervision in multiple scenes. Firstly, C3D network is used to simultaneously extract the spatial and temporal characteristics of the pipeline leakage video. In addition, the random forest classifier is used to avoid the tedious gradient calculation operation in the training process. Finally, by adding triple loss and center loss to jointly supervise model training, we measure the similarity within classes and the difference between classes to improve the decision-making ability of the leakage detection classifier. The experiment result shows that our method has a detection accuracy of 96.72% for pipeline leakage video in industrial environment and the training time is shortened by 18.75%.

Introduction

Detecting leaks in industrial pipelines—whether involving oil, water, or steam—is critical for safety and operational efficiency. While computer vision offers a non-invasive solution, real-world "multi-scene" environments present significant challenges. Leaks are often translucent and lack distinct spatial textures. Furthermore, in large facilities, a leak in one scene may resemble the background of another, leading to high intra-class dispersion and low inter-class discrimination. Traditional 2D image-based methods often fail as they ignore the temporal dynamics of the leak.

Methodology

The proposed C3D-RF architecture utilizes a joint supervision method termed TRCE loss to enhance detection robustness across diverse industrial backgrounds.

C3D Feature Extraction

The model employs a 3D Convolutional Neural Network (C3D) to extract spatio-temporal features. Unlike static 2D frames, C3D captures the motion of leaking fluids, which provides a more distinctive signature than appearance alone. This is particularly effective for translucent substances like steam.

Random Forest (RF) Classifier

To streamline the training process and reduce computational overhead, the standard Softmax output layer is replaced with a Random Forest classifier. This hybrid approach avoids complex gradient calculations during the final classification stage, facilitating deployment in resource-constrained environments.

The C3D-RF architecture integrates 3D feature extraction with a Random Forest classifier and TRCE joint loss supervision.

TRCE Joint Loss Supervision

The TRCE loss function combines three components to optimize the feature space:

  1. Cross-Entropy ($L_{CrossEntropy}$): Maintains baseline classification accuracy.
  2. Triplet Loss ($L_{Tr}$): Minimizes the distance between an anchor and a positive sample (same class) while maximizing the distance to a negative sample (different class).
  3. Center Loss ($L_{Ce}$): Minimizes the distance between samples and their respective class centers to create more compact clusters.
The Triplet Loss mechanism pulls positive samples closer to the anchor while pushing negative samples away in the embedding space.

Experimental Setup and Results

The system was evaluated using a custom dataset from the Tianjin Binhai heating station, comprising 5,110 video clips across 11 monitoring targets (valves, joints, etc.).

The C3D-RF model with TRCE loss achieved a detection accuracy of 96.72%, outperforming the baseline Cross-Entropy approach (95.23%). Notably, the training time was reduced by 18.75% compared to standard Softmax-based models. Real-time performance was maintained with a detection time of approximately 34ms per sample. Qualitative T-SNE analysis confirmed that the TRCE loss successfully produced tighter, more separable clusters for "leakage" and "no-leakage" categories across diverse scenes.

Conclusion

This research demonstrates that combining deep spatio-temporal feature extraction with classical ensemble learning and metric-based loss functions significantly improves pipeline leakage detection. Future work will focus on expanding dataset diversity and further optimizing the framework for edge device deployment.

Summary updated

Abstract

<title>Abstract</title> In the field of industrial visual monitoring, PTZ cameras need to monitor the leakage of different easy leakage points. The backgrounds of the monitoring images change greatly and the characteristics of leakage targets are small, which will lead to large intra-class differences and small inter-class differences in the dataset samples. These problems affect the ability of the detection network to learn different class features of the leakage images and restrict the leakage detection performance. To solve the above problems, this paper proposes a pipeline leakage video detection method based on loss joint supervision in multiple scenes. Firstly, C3D network is used to simultaneously extract the spatial and temporal characteristics of the pipeline leakage video. In addition, the random forest classifier is used to avoid the tedious gradient calculation operation in the training process. Finally, by adding triple loss and center loss to jointly supervise model training, we measure the similarity within classes and the difference between classes to improve the decision-making ability of the leakage detection classifier. The experiment result shows that our method has a detection accuracy of 96.72% for pipeline leakage video in industrial environment and the training time is shortened by 18.75%.
BibTeX
@inproceedings{lyu2024multi,
  author = {Chengang Lyu and Lijuan Wang and Mengqi Zhang and Xiaojiao Lin},
  title = {{Multi-scene pipeline leakage video detection based on C3D-RF with TRCE loss joint supervision method}},
  booktitle = {Research Square},
  year = {2024},
  doi = {10.21203/rs.3.rs-4225679/v1},
}
Figure