An Improved YOLOv8 Method for Detection of Urban Appearance Violations
摘要
The detection of multiple types of urban appearance violations still faces several challenges, which make it difficult for algorithms to effectively extract the corresponding features. To address the above problems, a custom dataset was created including four categories of objects to solve the problem of lacking dataset. The CBAM attention mechanism was applied for improving the model’s capacity to extract features. A tiny target detection head was added to capture the characteristics of small targets and context information more effectively, improving the performance of model. The application of the loss function WIoUv3 was made, which can adaptively modify the weight coefficient and enhance the bounding box’s regression performance and detection resilience. Experimental results show that compared with the YOLOv8n model, the Precision, Recall, mAP0.5 and mAP0.5–0.95 of the proposed method increase by 3.8, 2.1, 3.3 and 4.8%, respectively. Although the FPS decreases from 135.1 to 107.5, it still maintains a relatively high running speed. Comparative experiments validate the effectiveness of the proposed method in object detection within practical scenarios of UAV images.