| As an important place for oil and gas supply in a city,a gas station will often bring incalculable losses and harm to the city and enterprises in the event of a safety accident.Therefore,in order to minimize the occurrence rate of dangerous accidents,it is necessary to strengthen the supervision of oil unloading work.At present,the provision of protective equipment for unloading oil at gas stations often relies on specialized staff to conduct inspections.However,this method of supervision is inefficient and prone to mistakes.As artificial intelligence technology advances at an astonishing pace,the target detection technology based on deep learning has gradually been applied to the field of security protection detection.Using the currently popular YOLOv5 n target detection algorithm to check the protective equipment in the scene of unloading oil at the gas station can not only ensure the safety of unloading work but also save manpower.The YOLOv5 n algorithm is one of the YOLOv5 series algorithms,and it has the fastest detection speed and the smallest model,which is convenient for rapid detection and deployment on the mobile terminal.However,when it is applied to the detection scene of unloading protective equipment at gas stations,the YOLOv5 n algorithm has poor detection accuracy,and there are problems of missed detection of small targets.Therefore,the focus of this thesis is on how to improve the recognition accuracy of targets,reduce the missing detection of small targets,and obtain a detection algorithm for gas station unloading oil protection equipment that has high detection accuracy and fast speed.The main work of this thesis is as follows:(1)In order to solve the low detection accuracy and the missing detection of small targets of the YOLOv5 n algorithm,this thesis proposes a YOLOv5 n detection algorithm based on feature fusion improvement and attention mechanism.Firstly,by referring to the feature fusion structure of the weighted bidirectional feature pyramid network,a new horizontal and cross-scale connection path is added,so that the model can fully integrate the fine-grained features in the shallow feature map and the advanced semantic information in the deep feature map;Secondly,a convolution block attention module is added between the backbone and neck of the YOLOv5 n network,so that the network can fully extract features and further enhance the learning ability for small target objects.The experimental results show that the YOLOv5 n detection algorithm based on the improved feature fusion and attention mechanism has improved the detection accuracy,and the detection effect and recognition accuracy have been significantly improved.(2)In order to make the detection model of oil unloading protection equipment more lightweight and improve the detection speed of the network,this thesis proposes a lightweight YOLOv5n-BC detection algorithm for oil unloading protection equipment.Firstly,the Ghost Conv module and the improved C3-Ghost module in the lightweight network Ghost Net are introduced into the YOLOv5n-BC algorithm,which greatly compresses the parameters of the model and improves the calculation speed;Secondly,it is proposed to use Focal and Efficient Intersection Over Union function instead of Complete Intersection Over Union.It enables the model to increase the attention to difficult-to-recognize samples,effectively reduces the loss value between the real box and the predicted box during the training process,and accelerates the speed of network convergence.The experimental results show that the lightweight YOLOv5n-BC detection model has relatively balanced performance,and it still maintains high detection accuracy when the model is relatively small.(3)This thesis designs a detection system for oil unloading protection equipment based on lightweight YOLOv5n-BC,and successfully applies the system to the actual oil unloading detection scene.Through the detection of video stream images,the system can timely discover the situation that operators are equipped with protective equipment,so as to realize effective supervision of oil unloading work and provide a strong guarantee for the safe and stable operation of gas stations. |