CMRN-DETR: a context-guided and feature-aware model for detecting small-scale defects in insulators
Abstract
To address the challenges of insulator inspection during UAV patrols, such as high background noise, varying target scales, and small-scale defects, this paper develops the insulator defect detection model CMRN-detection transformer (DETR) based on real-time-DETR, which enables rapid detection of visible defects on insulator surfaces using visible-light images. First, a backbone network named CG-MCANet is designed. Through the local and context branches of the Context Guided Block, it jointly models local details and the surrounding environment to enhance background noise suppression. Furthermore, the Monte Carlo attention module is embedded to generate channel attention via multi-scale random pooling, thereby improving feature perception for small-scale defects. Second, Rep-Net with CSP and efficient layer aggregation network (ELAN) is introduced to replace the original RepC3, achieving efficient scale-dependent feature fusion through ELAN-based multi-branch aggregation and reparameterized convolutions. Finally, we adopt Normalized Wasserstein Distance to optimize the regression loss function, using the Wasserstein distance to measure bounding box similarity and address the location-sensitivity issue in the regression process for small-scale defects. Validation on the dataset shows that compared with baseline models, the proposed algorithm achieves average performance improvements of 1.7% and 1.9% in mAP@0.5 and mAP@0.5:0.95, respectively, while reducing the number of parameters by 18.5% and computational cost by 9.1%. Furthermore, in representative qualitative examples under complex backgrounds and simulated weather interference, the proposed method shows relatively better visual detection results, indicating that this method offers improved detection performance under these conditions.