Wood surface defect detection based on improved YOLOv8
摘要
The detection of wood surface defects is crucial for ensuring the quality of wood products in industries such as furniture manufacturing and construction. This study proposes DMD-YOLO, an advanced object detection model based on YOLOv8, specifically designed for wood surface defect detection. The model incorporates three key enhancements: Depth Attention Convolution (DAConv), Multi-Scale Attention Feature Fusion (MAFF), and a Decoupled Weighted Head (DWHead). DAConv integrates depthwise separable convolution with channel and spatial attention mechanisms to improve feature extraction efficiency and defect localization accuracy. MAFF enhances the fusion of multi-scale features by leveraging channel and spatial attention, enabling the model to capture global and local defect details. DWHead decouples classification and localization tasks, optimizing the detection of diverse and complex defects. Experimental results demonstrate that DMD-YOLO achieves state-of-the-art performance, with a mean Average Precision (mAP50) of 93.8%, a Recall of 90.4%, and an F1 score of 94.7%, significantly outperforming existing models such as YOLOv5s, Faster R-CNN and RT-DETR. The model shows excellent robustness in detecting small and complex defects while reducing false positives and missed detections, making it suitable for industrial applications and meeting the need for accuracy and robustness in quality inspection tasks.