In order to reduce and eliminate the harm of tobacco smoke and protect public health,China has issued regulations on smoking control in many places,which stipulates that indoor public places are completely prohibited from smoking,and clarifies the scope of outdoor public places where smoking is completely prohibited.Expanding the scope of smoking ban is the general trend.Compared with the manual supervision method and the traditional sensor smoke alarm,the intelligent monitoring smoking behavior detection system has the advantages of a wide range of monitoring,high utilization of monitoring resources,automatic positioning of smokers and alarm.This paper combines the characteristics of public places and cigarettes to study the video smoking behavior detection algorithm in public places based on facial analysis and implement the deployment of the system on the embedded platform Xavier.The main tasks as follows:(1)An improved MTCNN face detection algorithm for smokers in public places is proposed.The face detection algorithm is compared and analyzed from the two aspects of traditional machine learning and deep learning.The limitations of the face detection algorithm based on Haar-Adaboost are described.For the face characteristics of smokers in public places,the MTCNN algorithm with anchors is proposed,which can detect small or very small faces,and use sparse pyramids to process larger-scale faces,reducing the amount of network forward calculation.The proposed algorithm significantly improves the face detection speed and average accuracy of the WIDER_FACE test set,ensuring the real-time and effectiveness of the algorithm.(2)A smoking behavior detection algorithm based on face analysis is proposed.On the basis of the improved MTCNN algorithm output face box coordinates,determine the positioning rules of the mouth area,then compare the classification effect of the HOG-SVM algorithm and the MobileNet-V1 migration learning algorithm for the smoking behavior of the mouth area,to build a smoking behavior detection algorithm model that combines the improved MTCNN face detection model and the MobileNet-V1 smoking behavior classification model.The test results show that the smoking behavior detection algorithm based on face analysis proposed in this paper has an average accuracy of 91.06% for smoking behavior detection in different scenarios,and the average processing time for each video frame is 38 ms,a good balance can be achieved in real-time and accuracy.(3)Transplant and deploy the trained smoking behavior detection algorithm model,and construct a smoking behavior detection system based on face analysis on the Jetson AGX Xavier,to achieve smoking behavior detection in public places,at the same time,make a hardware alarm and return the smoker image.The results show that the system can run well on the Jetson AGX Xavier development platform. |