In the area of computer vision,object detection has always been an essential and hot research direction.The purpose of object detection is to employ neural network to extract feature information from the input images,so as to identify the object that needs to be distinguished from the entire image,and point out the classification and location of the object.The object detection of vehicle in variable road scenes is still a key and difficult point d ue to numerous factors.For instance,the various directions and shapes of roads in different s cenes,and diverse angles and shapes of vehicles.In addition,directly using the current mainstream object detection algorithm is often not able to get a satisfactory result.Therefore,aiming at the problem of multi-scale vehicle detection in multi-road scenes,relevant research and optimization of object detection algorithms are carried out.an improved YOLOv5 algorithm model and an optimized attention mechanism are respectively proposed to optimize multi-scene and multi-scale vehicle object detection.The main work and related contributions of this paper are summarized as follows:(1)In view of the characteristics of multi-road scenes and multi-scale vehicle objects,an improved YOLOv5 model is designed based on the YOLOv5 network model,namely GFMYOLOv5(Ghost Fuse Muti-Scale YOLOv5).Based on the features of different scales of vehicle objects,the improved structure enhances the extraction of multi-scale feature information.When multi-scale feature information is fused,the AFF(Attentional Feature Fusion)multi-scale feature fusion module is combined to optimize the extraction of feature information at different scales.At the same time,the backbone network is replaced with the Ghost convolution module,thereby reducing a certain amount of parameters.Finally,a Multiscene Multi-scale Vehicle Datasets(MMVD)for object detection is constructed.And the optimized model has the effect of improving the vehicle object in this MMVD datasets.(2)The attention mechanism is introduced to the YOLOv5 model.Then,the advantages and disadvantages of common attention mechanisms on the MMVD datasets is compared thr ough experiments.According to the complex and changeable characteristics of the road scene in the vehicle object,based on the shuffle attention module,a Self-calibration Shuffle Attention(Sc SA)mechanism improved for vehicle target detection in different road scenes is proposed.It improves the attention feature extraction of the units in the shuffled attention module group,and uses Self-calibration Convolution when the grouping units are spliced to strengthen the connection and dependence between the channel and the spatial feature information,thereby merging richer feature information to improve the effect of object detection.The experimental results in the MMVD datasets show that applying this module has an improved effect on vehicle object detection.(3)Combined with the optimization method of multi-scene and multi-scale vehicle object detection algorithm proposed in this thesis,a multi-road scene road condition detection system that can detect real-time video is designed,which can realize real-time detection and alarm of different events in different road scenes at the same time. |