| With the progress of science and technology and social development,the number of cars has increased sharply,and the problem of road safety has been paid more and more attention,among which road safety is a very important part.At present,the research on the detection and tracking of highway vehicles has some limitations,including low detection accuracy and integrity,and weak anti-interference ability in rainy and snowy weather,which makes it impossible to track highway vehicles accurately.Aiming at the above problems,this paper studies the highway vehicle detection algorithm,rain removal algorithm,snow removal algorithm and tracking algorithm.The specific research is as follows:(1)Road moving vehicle detectionThe improved vibe algorithm is used to detect road moving vehicles,and the "ghost" problem and background model updating problem of the original vibe algorithm are improved accordingly.Firstly,the background image of video sequence is obtained by mean method,which is used to initialize the background model of vibe algorithm and solve the "ghost" problem.The dynamic threshold of pixel classification is adjusted by counting method to improve the detection accuracy.The idea of frame difference method is combined with foreground segmentation to make the foreground image of highway moving vehicles more complete.The stability of background updating is improved by introducing threshold,and the problem of updating road vehicles into background model when they are stationary is solved.Compared with other detection algorithms,it is proved that the improved vibe algorithm has better performance and detection effect.(2)Research on rain removal algorithmThe principle of RSRV rain removal algorithm is studied,and the background model initialization parameters obtained by the mean method are used to reduce the calculation and iteration time.The mask matrix and background model obtained from the calculation process are used to directly obtain the rain removal video image,optimize the algorithm flow and greatly reduce the calculation time of the algorithm.Compared with the original RSRV algorithm and other algorithms,the improved RSRV algorithm reduces the calculation time of the algorithm while ensuring the rain removal effect.(3)Research on snowflake removal algorithmAccording to the object characteristics of snowflakes,the pixel value of snowflake pixels is larger than that of non snowflake pixels,and there is a difference between snowflake pixels and the background brightness covered due to the strong reflection of snowflakes.According to these two characteristics,a snowflake detection algorithm is designed,which can accurately detect snowflakes in the image and avoid detecting large white objects.The background model is used to fill the pixel position of the removed snowflake,so as to ensure that the snow removal effect will not affect the details of non snowflake objects.Finally,the snow removal effect and performance of the proposed algorithm are proved by experiments.(4)Research on road vehicle tracking algorithmThe CAMSHIFT filter and Kalman filter tracking algorithm are combined to track road moving vehicles to solve the problem of vehicle target occlusion and multi vehicle tracking.After the test of normal data set and rain and snow weather data set,it is proved that the algorithm can track road vehicles under different conditions. |