Support Vector Machine Applied to Road Traffic Event Classification

The aim of this paper is to present results of road traffic event signal recognition. First, several types of systems for road traffic monitoring, including Intelligent Transport System (ITS) are shortly described. Then, assumptions of creating a database of vehicle signals recorded in different weather and road conditions are outlined. Registered signals were edited as single vehicle pass by. Using the Matlab-based application a feature vector containing 48 parameters was extracted and analyzed in the context of parameter separability and classification effectiveness employing SVM (Support Vector Machine) algorithm. In conclusion, the classifier developed and its effectiveness were discussed.


Introduction
An important element of the environment management is checking and controlling pollution of various types, including noise. Noise mapping is no longer an emerging technology of urban noise management, which was developed first and widely applied in the European Union countries in accordance with EU directive 2002/49/EC. Acoustic noise maps show the noise level imposed on existing geophysical maps of cities, areas around railway junctions, etc. Such a presentation of data allows for determining the area in which the sound level of passing vehicles can be a problem for the environment. For appropriate management of the noise data and checking results obtained, it is possible to introduce changes to the road traffic structure, as well as, for example, the construction of noise barriers to minimize the impact of pollution by undesirable sound in the area considered. Traffic monitoring is based not only on the determination and interpretation of noise maps, but also on the analysis of its structure. This issue is much more complicated due to the required processing of the signal recorded at the road and the extraction of its parameters, which are variable over time and dependent on many additional factors, among them: atmospheric and road conditions. The paper is organized as follows: first the background of traffic monitoring systems is shortly reviewed along with the presentation of various types of intelligent transport systems (ITS). The next Section presents measurement methods used in determining the level of transport noise and road traffic structure. Sound signal analysis in the context of selecting parameters for the classification process based on machine learning is also discussed. Then, the methodology and scenarios of measurements as well as the locations where the test recordings are performed are presented. The measurements take into account various weather conditions. The next stages of analysis contain preparation of registered samples, extraction of parameters from the signal in both time-and frequency domain, discussion of the derived parameters. Moreover, quality of parameters in terms of parameter separability is checked by employing Bron-Kerbosch algorithm and Behrens-Fisher statistic. Classification of recorded audio signals is based on the Support Vector Machine (SVM) method. In the final part of the paper, a summary of results and conclusions derived from the conducted research as well as directions of further research development are included.

Aim
As already mentioned the analysis of noise maps is often obscured by a large variety of vehicles traveling on the roads and their simultaneous occurrence on road lanes. In this context, it is important to operate in real time, hence there is a need to make gathering of the collection of traffic data as well as their classifying automatic. The aim of this paper is an analysis of the road traffic recordings in the context of automatically identifying events in the audio signal by employing Support Vector Machine (SVM).

Intelligent Transport Systems (ITS)
An interesting glossary of terms was presented in the paper by Shaheen and Fionson [1] in which terms such as e.g.: bus rapid transit, eco-driving, eco-routing, electronic toll collection, incident management, intelligent transportation systems (ITS), shared-used mobility, traffic management and surveillance, traveler information, smart parking, vehicle control technologies, etc. were defined. All these notions are introduced in relation to intelligent transportation systems (ITS) and energy consumption, thus we can see that ITS technologies are related not only to state-of-the-art wireless, electronic and automated technologies to improve transportation safety, efficiency, convenience, optimizing trips but also refer to time and fuel consumption, the latter issue having in addition an impact on air quality. It should also be remembered that the concept of ITS appeared in 1991 when the first legislation action was introduced in the U.S.A., thus the history of ITS was built through the last three decades with several dramatic changes of technology. Also, the authors of this paper pointed out that both modeling and implementation of ITS occur in discrete applications, rather as fully integrated systems [1]. This last remark is still very true as we can see ITS technologies deployed often as local solutions, rarely as nation-wise or implemented at the international level. Moreover, some concerns are raised about benefits and profitability of the ITS solutions, especially regarding their reliability and precision [2].
To give examples of the ITS approaches, a few ITS systems available in Poland are to be recalled further on. There are various systems in Poland that monitor traffic. Examples include the annual General Traffic Measurement as well as the map of road cameras refreshed every 5-15 minutes. In addition, there is the viaTOLL system working, which is assumed to be an electronic toll collection system, but it gives the opportunity to analyze vehicle traffic volume and structure.
In larger cities and agglomerations of Poland one can find systems that deal with monitoring as well as automatic traffic control by changing the cycles of traffic lights, adjusting to the current traffic volume. One of the examples of such systems is the Tristar (Tri-City Intelligent Agglomeration Transport System) introduced in Tricity in 2015. It includes, among others, motion detectors based on induction loops, cameras for identifying number plates ANPR (Automatic Number Plate Recognition) and meteorological stations [3]. Public transport vehicles are equipped with GPS signal receivers, which, by processing their position this information is passed to the traffic management center. It gives an additional opportunity to analyze and provide information to travelers about the current travel time on a given route. The main goal of the system is to shorten trip time in the agglomeration by approx. 20% [3].
Typical traffic control systems mainly use optical, electromagnetic and vision sensors. Individual options are presented in Table 1. The "+" sign informs about the detector supporting the given functionality, and/or the lack of indication about its absence. It can be seen that in the comparison of different types of sensors, the most comprehensive in operation seem: radar and video image processor (VIP). However, each of these systems has limitations: using radar cannot accurately identify the vehicle or determine the registration number, however, is much more resistant to weather conditions and changes in lighting that affect the operation of the matrix in the video recorder. Induction loop due to the influence of electromagnetic waves across the lanes allows for distinguishing vehicles moving in different lanes only in specific situations. It depends, among other things, on the permitted speed on the route, the size of the loop and the method of assembly. In the case of such a device, it is not, however, possible to distinguish between vehicles moving across multiple lanes and to classify a vehicle. The matrix of acoustic detectors, despite the detection of vehicles in various lanes, does not allow the classification of a vehicle type [4].

Method
The first part of work was registering passing vehicles. Along with audio signal recording, a video image was additionally registered. The measurement system consisted of a camera set up perpendicularly to the road and an audio recorder with a shotgun microphone or with microphones in the XY configuration depending on the scenario. For each measurement, the distance between the measuring equipment and the edge of the roadway was noted. During the measurements, temperature and humidity values were also recorded at two measuring points -corresponding to the asphalt surface and the height of the microphone suspension (1.2 m). The camera was set in such a way that the frame contains two adjacent horizontal signs separating road lanes, which supports the determination of the frame width [5]. In Fig. 1 a scheme showing a way of vehicle pass by recordings is presented. Recording was performed in six different locations in different weather conditions and road surface condition, and speed limit. Table 2 contains description of the road traffic conditions at selected locations in Pomeranian. Road surface quality refers to the roughness of the wearing surface. "Cold" means the air temperature on the road surface at 15 degrees Celsius and "warm" conditionsabove this temperature. "Wet" refers to that water on the road surface and "dry" when the surface was dry. Vehicle density was determined based on a point measurement by determining the relationship between the number of vehicles and the time of measurement. All data gathered are presented in Table 3. It can be noticed that the greatest disproportions occur in the case of a vehicle type, where cars occupy 71.07% of all samples within the class. In the case of temperature and humidity, the ratio is 57.53% and 42.47%, respectively. The MIRtoolbox (Music Information Retrieval Toolbox) was used for the analysis. It is a library executed in the MATLAB environment, which provides a simple way to parameterize any audio signal. Parameters that can be obtained directly from the functions implemented in this open source toolbox are extracted based on both temporal and spectral analysis. Among the parameters calculated are mel-cepstral coefficients, the number of zero crossings or envelope determination, widely-known from the Music Information retrieval domain. In addition to the signal analysis, the application allows extraction of perceptual parameters such as brightness and sound roughness. A detailed description of features and methods of their calculation is included in the MIRToolbox package documentation and literature [6,7]. For further analysis, a feature vector consisting of 48 parameters was determined for each of the prepared samples.
Then, the next step involved statistical analyses performed on the feature vector to optimize it, resulting in low-correlated parameters. For this purpose Bron-Kerbosch algorithm as well as Behrens-Fisher statistic were utilized. The purpose of the feature vector analysis is to find the maximum clique for a graph based on the correlation matrix of all vector elements. By definition, it is a kind of graph, for which a new, neighboring top of the graph cannot be added. To obtain such a result, we used the Bron-Kebrosch recombination algorithm of, which finds the maximum clique of the graph [8].
The next step of the analysis was to find the parameters with the best separation between object classes. To achieve this, Behrens-Fisher statistic was used, for which the critical value adopted in the study was 2.086. The combination of both algorithms enables to find parameters that may allow for effective classification of the tested vehicle types [8] as it guarantees an appropriate level of separation between classes. Optimized feature vector was used for training and testing SVMs.

Classification Results
A SVM algorithm was used to carry out the classification tests. Independent tests were performed for each class pair, taking into account various functions of the kernel. Linear, polynomial and Gaussian functions were used for this purpose. During each test, both test and training sets were selected randomly. The choice of parameters depended on the values of the calculated Behrens-Fisher statistic. They were inserted into a common vector and then sorted against the decreasing value. Finally, duplicate values were removed. With the division into a vehicle type, the cross-validation method was used to obtain the average result from several tests. In Tables Table 9 includes a summary of classification results. The best efficiency was obtained in the case of wet -dry road surface class recognition: 95% and temperature (96%) -in both cases SVM was employed with the linear kernel. High efficiency was also obtained for the class pair: delivery vans and trucks (90%, using the polynomial kernel function). In turn, the biggest problem was the distinction between the pair of passenger cars and delivery vans (71%), but this may be the result of a large similarity of vehicles within these classes.

Conclusion
Based on the results of the classification tests employing samples recorded under actual conditions, it can be concluded that the mean effectiveness of the applied method has been achieved at the level of 81.5%. Registration process of vehicle samples included scenarios containing various types of microphones, locations and measurement conditions. The preparation of vehicle pass by samples for further analysis included first assigning them to the appropriate classes in the created repository of samples. For each of them, a feature vector consisting of 48 parameters was determined and then, based on analyses employing Bron-Kerbosch algorithm and Behrens-Fisher statistic, the number of parameters was reduced, depending on the class, up to 5 descriptors. Such a pre-conditioning of the classification process allowed for speeding up the calculation time while simultaneously maintaining high quality classification. The results showed that the time of teaching and testing the classifier is independent of the number of parameters. The shortening of the processing time is a result of reducing the number of parameters in a feature vector.