Wearing helmets correctly is an important part of protecting the lives and property safety of operators in industrial production.By applying computer vision to industrial production,detecting the wearing of helmets by operators,strengthening the supervision of operators in the industry,In order to reduce the damage caused by other accidents.By using the image method based on convolutional neural network,the YOLOV3 algorithm is improved.First,CSPDarknet53 is used as the network model,and then the KMeans++algorithm is used to improve the a priori frame detection,and finally the detection accuracy and speed are improved.After experimental verification,the algorithm can effectively identify 5 types of targets,including 4 color helmets and operators.It has high accuracy and recognition efficiency,and is ready for effective supervision of production operators to wear helmets correctly..The specific work is as follows:(1)Obtain the helmet image data by means of web crawlers,and use the labelimg tool to make the helmet data set.According to the research needs of this article,5 types of image targets are collected,totaling 2054 images.Through the imgaug library function,the collected data set is expanded by methods such as spatial change,sample enhancement,and normalization.Finally,after screening,4672 pictures of five types of targets were selected as samples of this data set.(2)Configure the training environment and select the appropriate algorithm for helmet recognition to conduct experiments.By comparing the algorithms of different principles and the experimental results of predecessors,this paper chooses Faster R-CNN and YOLOV3 target recognition network as the basic network model,and trains on the helmet data set made in the previous article.After experiments,YOLO V3 model detection accuracy and detection speed are suitable for this detection task.(3)In order to improve the recognition accuracy,this paper proposes the CSPDarknet53+YOLO+KMeans++ algorithm to solve the deficiencies of YOLOV3.The improved algorithm uses CSPDarknet53 instead of Darknet53 as the feature extraction network,which not only reduces the amount of calculation and enhances the performance of the gradient,and extracts image features;the K-Means++ clustering algorithm is used to calculate the length and width of the anchor boxes.The improved YOLOV3 algorithm improves the accuracy of target detection during recognition.(4)Train on the improved YOLOV3 algorithm to obtain an algorithm network model suitable for helmet recognition.After comparison,the improved YOLOV3 algorithm is more practical.After the research of this article,the detection accuracy of CSPDarknet53+YOLO+K-Means++algorithm for 5 types of targets,including 4 color helmets and operators is 92.03%.After comparing experiments with other networks,the CSPDarknet53+YOLO+K-Means++algorithm is significantly better than other algorithms,and it has increased by 6 percentage points on the basis of the original YOLOV3 network. |