Surface defects in industrial environments severely the impact product aesthetics, quality, and operational efficiency. Although deep learning approaches show promise, current architectures often demonstrate inadequate feature extraction in industrial settings. We introduce EFEN-YOLOv8, a novel defect detection framework that prioritizes efficient feature extraction to enhance detection accuracy. Our approach incorporates a -FEIoU loss function that concurrently tackles defect-background discrimination and positive-negative sample imbalance. The Shallow Attention Convolution (SAConv) module strengthens feature localization in early network layers, while Large Separable Kernel Attention (LSKA) expands receptive fields and augments processing efficiency. Additionally, our Weighted Atrous Spatial Pyramid Pooling (WASPP) feature fusion module facilitates multi-scale integration, enabling richer abstract information capture and improved model representation. Comprehensive experimental validation, including statistical significance testing across diverse data splits, confirms superior performance over existing methods. Our framework achieves 7.4% mAP improvement on NEU-DET and 3.3% enhancement on GC10-DET compared to baseline models, maintaining consistent performance across both 8:2 and 9:1 train-test configurations. These findings validate the method’s robust generalization capacity and establish its effectiveness for industrial surface defect detection applications. Code and datasets are available at: https://github.com/01WineCool/YOLO .
24 July 2025 in Journal of Real-Time Image Processing
Seal defect detection in food packaging integrity inspection presents substantial challenges, primarily owing to minimal textural disparities between defective and intact regions under industrial illumination. These challenges intensify in production environments where moderate class imbalance intersects with pronounced inter-class similarity. This study introduces an enhanced MobileNetV4 architecture incorporating adaptive feature learning mechanisms to overcome these limitations. A novel LocalAttention module, employing dynamically weighted rectangular sliding windows, augments the model's texture discrimination capabilities by effectively isolating elongated structural anomalies characteristic of seal defects. To address suboptimal illumination conditions, we integrate Pinwheel-shaped Convolution (PConv), which leverages Gaussian-inspired distribution patterns to amplify weak signal detection in poorly lit environments. Additionally, an Adaptive Similarity-Modulated Loss function concurrently mitigates class imbalance while refining feature space organization for morphologically close categories. Evaluated on a grain packaging dataset from Zhangzhou, Fujian, the proposed framework achieves 99.54% accuracy and 99.75% F1-score with only 3.7M parameters and 25.27 FPS on Raspberry Pi 4B. To validate industrial reliability, robustness experiments under simulated LED degradation and sensor noise confirm consistent performance advantages over baseline architectures, and an 8-hour continuous stress test demonstrates stable edge deployment without thermal throttling. Cross-domain validation on NEU-CLS further achieves 99.72% accuracy with superior parameter efficiency, suggesting transferability to related industrial defect classification tasks.
The circular knitting machine plays a vital role in the textile industry, with the surface quality of its triangular line grooves directly affecting fabric performance. Existing detection methods struggle with accuracy due to the grooves’ small size and complex backgrounds. To address this, we propose CGSE-DETR, a lightweight detection algorithm based on RT-DETR. It introduces a CGSE block to replace the BasicBlock in the backbone, reducing parameters, and applies multi-scale feature enhancement for improved small-object detection. Wavelet convolution (WTConv) is incorporated into the RepC3 block to better capture texture defects. Additionally, a lightweight adaptive extraction (LAE) block optimizes computational efficiency. Experiments on a self-built dataset and the NEU public dataset show that CGSE-DETR reduces parameters by 40.8% and computation by 38.4%, while improving mAP@0.5 by 3.4% and 2%, respectively. The proposed model achieves enhanced detection accuracy with fewer resources, meeting real-time defect detection needs in knitting machine grooves.