A Statistical Framework for Real-Time Traffic Accident Recognition

Over the past decade, automatic traffic accident recognition has become a prominent objective in the area of machine vision and pattern recognition because of its immense application potential in developing autonomous Intelligent Transportation Systems (ITS). In this paper, we present a new framework toward a real-time automated recognition of traffic accident based on the Histogram of Flow Gradient (HFG) and statistical logistic regression analysis. First, optical flow is estimated and the HFG is constructed from video shots. Then vehicle patterns are clustered based on the HFG-features. By using logistic regression analysis to fit data to logistic curves, the classifier model is generated. Finally, the trajectory of the vehicle by which the accident was occasioned, is determined and recorded. The experimental results on real video sequences demonstrate the efficiency and the applicability of the framework and show it is of higher robustness and can comfortably provide latency guarantees to real-time surveillance and traffic monitoring applications.


Introduction
Read traffic plays an extremely remarkable role in today's life and many crucial services and human activities are becoming more dependent either directly or indirectly on it.Therefore the efficient management for traffic of road vehicles has become an imperative need today for any country.In recent traffic management system, traffic surveillance by means of monitoring cameras has already been applied [1,2].However, existing methods predominantly rely on human observation of captured video sequences of images.This needs a great deal of human effort and time and does not support a real-time response to abnormal events.In the other hand, current intelligent traffic surveillance systems based on computer vision and image processing algorithms, can track, localize, and recognize vehicles in video sequences captured by road cameras with little or no human intervention [3].Furthermore these systems have the ability of analyzing the vehicle activities and giving full and precise descriptions based on the results of motion detection and tracking processes.This helps, in turn, in facilitating daily traffic management and allowing an instant response when ab-normal events occur, and then an advanced viable surveillance system can be developed.
The purpose of this paper is to investigate the problem of automatic traffic accident recognition and try to develop a real-time framework for it.The proposed framework performs the following major functions: first, it detects the accident as it develops.Then, it traces the accident vehicle and records its trajectory during accident period.These captured information, recorded by the system, are valuable that can provide guidance for investigators in determining accident causes and follow-up action.Furthermore, via the abnormal traffic behavior of vehicle, the system has the ability to predict beforehand the probability of accident occurrence and give a warning signal that may assist to avoid the accident.
The rest of the paper is structured as follows.Section 2 presents related literature.In Section 3, the proposed framework of automatic traffic accident recognition is described in detail.In Section 4 the experimental results are reported and the performance of the approach is compared with that of recently reported techniques.At last, in Section 5, conclusions are drawn and the future directions are discussed.

Related Work
Over the course of the last few years, researchers in computer vision and image processing fields have looked with more interest on traffic accident detection [4,5].As a result, several approaches (with varying degrees of sophistication and success) have been developed to address this problem [6][7][8][9][10].In [11], the authors propose a system for automatic incident detection.The system aims to distinguish between different types of incidents.While in [12] Hu et al. propose a probabilistic model for detecting traffic accident using fuzzy self-organizing neural network.Additionally, Kimachi et al. [13] focus their attention on studying the abnormal vehicle behavior causing an incident.Their work is based on the concepts of fuzzy theory.The decision if an accident occurs or not relies on the behavioral abnormality of some continual image shots.Zeng et al. [14] develope a technique for automatic incident detection using D-S evidence theory data fusion based on probabilistic output of multi-class SVM.However, the results of most of these methods mentioned above are still unsatisfactory and further efforts are needed to develop them.

Proposed Approach
In this section, the proposed traffic accident recognition framework is presented.Our main goal is to develop a simple fast technique for traffic accident recognition, which can efficiently operate under real-time constraints.To achieve real-time speed, various steps are taken.The real 24-bit color video images are converted to monochromatic video images.The 640 × 480 digitized image is averaged and sub-sampled to a resolution of 320 × 240.The directions of flow gradient are measured using a simple 8-bin histogram.With these steps, the total processing time is 45 ms per frame.Furthermore, we want the detection process to be relatively tolerant to changes in lighting conditions.The approach is designed to be powerful and robust enough, and to yield the best accuracy-speed trade-off.An outline of the proposed traffic accident recognition system is shown in Figure 1.

Optical Flow Estimation
The measurement of optical flow is a crucial in the processing of video sequences and is used in performing a wide variety of tasks.However accurate estimation of optical flow is a challenging task, which often requires addressing difficult energy optimization problems.In this work, optical flow is estimated based on the following hypotheses (see [15]).
1) Brightness constancy.The brightness of a pixel does not change as it is tracked from frame to frame.
2) Temporal persistence or "small movements".The temporal increments are fast enough compared to the scale of motion in the image.This means the object does not move much from frame to frame.
3) Spatial coherence.Adjacent points belonging to the same surface in a scene have similar motion, and project to nearby points on the image plane.Now considering the above-mentioned hypotheses, we have the following differential equation on the intensity function ( ) , , I x y t as follows ( ) Equation ( 1) can be expanded into the following partial differential equation as follows = 0 Replacing differential terms with , , , , .3) can be formed into a matrix equation as follows where = x y Equation ( 4) has two unknowns and cannot be solved as such.To find the optical flow, another set of equations is needed, which can be obtained by an additional constraint.The solution as given by [15] is a non-iterative method which assumes a locally constant flow.As an improvement over the original Lucas-Kanade method, the algorithm is iteratively carried out in a coarse-to-fine manner, in such a way that the spatial derivatives are first computed at a coarse scale, and then iterative updates are successively computed at finer scales.

Feature Extraction
HOG (Histogram of Oriented Gradient), first proposed by Dalal and Triggs in 2005 [16], is a feature descriptor originally used for the purpose of pedestrian detection in static imagery.This technique counts occurrences of gradient orientation in localized portions of an image.In this work, the original HOG algorithm is utilized, but with some adaption to be appropriate to deal with the flow field.Such a modified version of HOG is called HFG (Histogram of flow Gradient).HFG algorithm is very similar to that of HOG, but differs in that HFG locally runs on optical flow field in motion scenes (see Figure 2  (a)).Furthermore, the implementation of HFG is computationally faster than that of HOG counterpart.The magnitude and the angle of the optical flow required to construct HFG are determined by: ( ) ( ) where m and ϕ are the magnitude and the angle of

Classification
In this section the automatic classification stage of the proposed system is described, as well as some adaptations are made to allow the system to be robust against gradual and sudden changes in the scene.By using the features extracted on the previous step, the location of the center of gravity for each pattern is given by ( ) where ( ) and i h are the flow vectors belonging to the pattern i and the histogram of that pattern re- spectively.Then the Euclidean distance metrics (EDMs) between each two patterns are calculated The distances are then normalized to get a quantitative parameter upon which classification is determined since the normalized distance is a characteristic quantity not easily influenced by sudden changes.Given the normalized distances, ˆij λ between each two patterns i and j , it is possible to define the probability ij p that de- termines the relationships between different patterns using a sigmoidal mapping as follows

(
) where δ is the observed distance value.The parameter α is determined using the well-known logistic regres- sion technique.Statistically speaking, logistic regression (sometimes termed logistic model or logit model) is used for prediction of the probability of occurrence of an event by fitting data to a logistic curve.It is a generalized linear model used for binomial regression.Logistic model, like many from of regression analysis, makes use of several predictor variables that may be either numerical or categorical (for more details see [17]).The orientation mean is considered and combined with the probabilities obtained from the above mapping.We enforce some restrictions on the classification process by adjusting the pairwise probabilities.For example, the pattern pair probability is set to zero if the pattern density is too small (in the evaluations, ratio 0.2 was utilized as the limit).The pairwise probabilities obtained is finally compared with a threshold to determine the state of each vehicle and then decide whether the accident has occurred, is likely to occur or not.

Experimental Results
In this section, the experiments undertaken to evaluate the proposed framework illustrated above are described and the results that confirm the feasibility of the proposed system are shown.All the algorithms of the proposed system have been implemented using Visual Studio 2008 and OpenCV and the software has been executed on a Pentium 4 (2.83 GHz) computer running under Windows Vista platform.Due to the difficulty (and danger) of capturing or simulating traffic accidents in real scenes, it was only possible to carry out the experiments in a relatively limited number of a real traffic accident scenes.The proposed framework has been tested on a set of 45 video streams depicting a total of over 250 real scenes of traffic accidents or abnormal vehicle events captured by traffic surveillance cameras.All these data were collected from Internet sites and supplied free of charge.Data comprise of a wide variety of different road types such as a straight roads, curves, ramps, crossings, and bridges, and also many vehicle events including turning left, turning right, entering, and leaving were involved in.In order to quantitatively evaluate the performance of the proposed framework in recognizing traffic accident, we have used a receiver operating characteristic (ROC) curve that defines the relationship between the detection rate (DR) and the false-alarm rate (FAR), which are given by Total ofnon -accidents × The symbol # used above means "the number of". Figure 3 shows the interpolated ROC curve of the proposed recognition system.According to Figure 3, the performance of the proposed system is very promising.The recognition rate of the system reaches up to 99.6% with false alarm rate at 5.2%.What is more, this performance meets or exceeds those of recently reported methods [14,9] in terms of recognition rate and false alarm rate.The example shown in Figure 4 illustrates how the proposed system could successfully recognize the occurrence of a highway traffic accident and then track out and record the trajectory of the vehicle by which the accident was occasioned.Finally, the proposed accident recognizer can run comfortably at 25 fps on average (using a 2.8 GHz Intel dual core machine with 4 GB RAM running Microsoft Windows Vista).This timing performance enables our method to provide delay guarantees to real-time surveillance and traffic monitoring applications.

Conclusions and Future Work
In this paper, a new framework for real-time automated traffic accident recognition has been introduced.The framework is based on flow gradient histogram and statistical logistic regression.The results of the experiments conducted have validated the effectiveness and efficiency of this framework and it matches or outperforms the best reported results on automatic traffic accident recognition.Future work will be along two main axes.The first will be the further improvement of the classification stage by using advanced machine learning algorithms that help in improving the overall recognition efficiency of the proposed approach.The second will look at the possibility of applying the approach to other applications that consider spatio-temporal features, such as human event recognition, crowd behavior analysis, tracking of an individual in crowded scenes, etc.

Figure 1 .
Figure 1.An outline of the proposed traffic accident recognition framework.
velocity flow respectively .The orientation of flow is represented by an 8-bin histogram of gradient orientations in the range of ( )

Figure 3 .
Figure 3. ROC curve for the proposed automatic traffic accident recognition framework.

Figure 4 .
Figure 4.An example of a highway traffic accident recognition.The first row depicts three camera shots of the accident vehicle, (a) before the accident, (b) beginning the accident, and (c) end of the accident.The second row shows the clustering results.