Intersection Safety Assessment Using Video-Based Trafﬁc Conﬂict Analysis: The Case Study of Thailand

: In the road transport network, intersections are among the most critical locations leading to a risk of death and serious injury. The traditional methods to assess the safety of intersections are based on statistical analyses that require crash data. However, such data may be under-reported and omit important crash-related factors. The conventional approaches, therefore, are not easily applied to making comparisons of intersection designs under different road classiﬁcations. This study developed a risk-based approach that incorporates video-based trafﬁc conﬂict analysis to investigate vehicle conﬂicts under mixed trafﬁc conditions including motorcycles and cars in Thailand. The study applied such conﬂict data to assess the risk of intersections in terms of time-to-collision and conﬂict speed. Five functional classes of intersections were investigated, including local-road/local-road, local-road/collector, collector/arterial, collector/collector, and arterial/arterial intersections. The results showed that intersection classes, characteristics, and control affect the behavior of motorists and the safety of intersections. The results found that the low-order intersections with stop/no control are high risks due to the short time-to-collision of motorcycle-related conﬂicts. They generate frequent conﬂicts with low chance of injury. The high-order intersections with signal control are high risks due to high conﬂicting speeds of motorcycle–car conﬂicts. They generate few conﬂicts but at a high chance of injury. The study presents the applicability of video-based trafﬁc conﬂict analysis for systematically estimating the crash risk of intersections. The risk-based approach can be deemed as a supplement indicator in addition to limited crash data to evaluate the safety of intersections. However, future research is needed to explore the potential of other road infrastructure under different circumstances.


Introduction
Intersections are among the most critical locations in the road transport network resulting in a risk of death and serious injury [1]. Intersection-related crashes account for approximately 20-45% of all reported crashes in both developed and developing countries, such as the United States, Norway, Japan, Singapore, and Thailand [2][3][4][5][6]. Most of them are attributable to inattention or illegal maneuvers through complicated traffic situations.
The factors contributing to intersection-related crashes are diverse and complex. Many factors, such as intersection types, control, and geometry, have different impacts on crash types and their frequency and severity [7]. For example, four-legged intersections have up to four times the number of crashes as T-intersections. Signalized intersections have higher percentages of rear-end collisions than stop-controlled intersections. On the other

Literature Review
The review of the literature is presented in three parts. Section 2.1 provides the concept of traffic conflict analysis at an intersection. Section 2.2 reviews the definition of time-tocollision, which is a surrogate safety measure of intersection conflict. Section 2.3 explores the applications of video analytics on traffic conflict analysis.

Traffic Conflict Analysis at Intersections
A roadway intersection is the area where two or more roads join or cross at-grade. It is where conflicting movements are concentrated and result in high-risk crashes. Various primary conflicting movements can be found at at-grade intersections, such as crosstraffic conflicts, opposing turning conflicts, same-direction conflicts, and lane-change conflicts [15].
An intersection conflict is any potential crash situation at an intersection. Such a conflict is typically known as an evasive action conflict. It is described as a traffic incident involving the interaction of two or more vehicles where drivers take evasive action to avoid a collision from the same or different intersection approaches [12,16]. Another category of intersection conflict is a traffic violation conflict. This occurs when a driver invades an intersection area illegally [17].
Safety research studies have suggested that crash rates are related to the number of conflicts at an intersection. To characterize the difference between conflicts and crashes, the concept of a 'safety pyramid' has been employed to represent the variation in severity hierarchy, as shown in Figure 1 [18,19]. The position of each layer of the safety pyramid corresponds to the riskiness and closeness to crash of an event. The top portion of the pyramid presents the crash occurrence for the most severe crashes, which are very rare, to the least severe crashes (property damage only), which are more likely. The lower portion presents the near-crash events, which are more frequent than crashes. It is divided into pyramid presents the crash occurrence for the most severe crashes, which are very rare, to the least severe crashes (property damage only), which are more likely. The lower portion presents the near-crash events, which are more frequent than crashes. It is divided into severe conflicts, slight conflicts, and possible conflicts. The more severe the conflicts are, the higher the crash risk is. Traffic conflict technique (TCT) has been developed and widely adopted to evaluate crash potential and operational deficiencies at intersections in many countries over the last few decades [20]. TCT represents an efficient approach to enable a proactive strategy. There are two approaches to monitor traffic conflicts: detailed descriptions of direct field observations and analysis from video recordings [21].
At an intersection, a traffic conflict is an observable event in which two or more road users are predicted to approach each other at the same time in the same intersection area such that there is a risk of collision [22]. The analysis of intersection traffic conflict is related to monitoring and measuring the frequency and severity of traffic conflicts to diagnose safety problems at an intersection [14]. The objective of traffic conflict analysis is to identify potential risks and safety problems of existing intersection design.
In many research studies, surrogate safety measures (SSMs), also called non-crash measures, have been of interest to analyze traffic conflicts [13,19,23]. The basic concept of surrogate safety is to examine vehicle movements and to identify all risky events involving a near-crash. SSMs serve as near-crash indicators to physically measure conflicts from the temporal or spatial proximity of road users. They can present the degree of severity and the frequency of events that are related to safety [18].
Surrogate safety measures can be useful to summarize the complicated dynamic interactions between road users in a simple measurable manner [24][25][26] by assuming that the closer vehicles are to each other, the nearer they are to a collision. In the literature, over 30 temporal or spatial proximal indicators have been proposed as surrogate safety measures, such as post-encroachment time (PET), time-to-collision (TTC), time-to-accident (TA), headway, proportion of stopping distance, deceleration rates, jerks, and lateral position [23]. Among the commonly used indicators, TTC is presented in this study.

Time-to-Collision
Time-to-collision (TTC) is the time until a collision between the vehicles would occur if they kept their present course at their present rates. TTC is more informative and frequently used in practice than other indicators. Several applications, such as advanced driver-assistance systems, have used TTC as an important warning criterion. The two most used TTC indicators are TTC minimum, which is the minimum TTC value calculated in an event, and time-to-accident (TA), which is the TTC value calculated at the moment an involved road user takes evasive action. Both indicators use a threshold value to differentiate between a severe and a non-severe event. Suitability for collision type of TTC include crossing, rear-end collision, turning/weaving, hit objects/parked vehicle, and hit pedestrian [23]. Traffic conflict technique (TCT) has been developed and widely adopted to evaluate crash potential and operational deficiencies at intersections in many countries over the last few decades [20]. TCT represents an efficient approach to enable a proactive strategy. There are two approaches to monitor traffic conflicts: detailed descriptions of direct field observations and analysis from video recordings [21].
At an intersection, a traffic conflict is an observable event in which two or more road users are predicted to approach each other at the same time in the same intersection area such that there is a risk of collision [22]. The analysis of intersection traffic conflict is related to monitoring and measuring the frequency and severity of traffic conflicts to diagnose safety problems at an intersection [14]. The objective of traffic conflict analysis is to identify potential risks and safety problems of existing intersection design.
In many research studies, surrogate safety measures (SSMs), also called non-crash measures, have been of interest to analyze traffic conflicts [13,19,23]. The basic concept of surrogate safety is to examine vehicle movements and to identify all risky events involving a near-crash. SSMs serve as near-crash indicators to physically measure conflicts from the temporal or spatial proximity of road users. They can present the degree of severity and the frequency of events that are related to safety [18].
Surrogate safety measures can be useful to summarize the complicated dynamic interactions between road users in a simple measurable manner [24][25][26] by assuming that the closer vehicles are to each other, the nearer they are to a collision. In the literature, over 30 temporal or spatial proximal indicators have been proposed as surrogate safety measures, such as post-encroachment time (PET), time-to-collision (TTC), time-to-accident (TA), headway, proportion of stopping distance, deceleration rates, jerks, and lateral position [23]. Among the commonly used indicators, TTC is presented in this study.

Time-to-Collision
Time-to-collision (TTC) is the time until a collision between the vehicles would occur if they kept their present course at their present rates. TTC is more informative and frequently used in practice than other indicators. Several applications, such as advanced driver-assistance systems, have used TTC as an important warning criterion. The two most used TTC indicators are TTC minimum, which is the minimum TTC value calculated in an event, and time-to-accident (TA), which is the TTC value calculated at the moment an involved road user takes evasive action. Both indicators use a threshold value to differentiate between a severe and a non-severe event. Suitability for collision type of TTC include crossing, rear-end collision, turning/weaving, hit objects/parked vehicle, and hit pedestrian [23]. TTC values correspond to conflict severities; lower TTC values correspond to higher conflict severities [21]. TTC can be calculated by Equation (1).
where S = the conflict distance, which is the relative distance from the position of vehicle taking the evasive action (evasive action point) to the potential conflict point, and CS = the conflict speed, which is the speed of the relevant vehicle while taking the evasive action. The concept of TTC for crossing and rear-end collision at an intersection is shown in Figure 2. TTC values correspond to conflict severities; lower TTC values correspond to higher conflict severities [21]. TTC can be calculated by Equation (1).

S TTC= CS
(1) where S = the conflict distance, which is the relative distance from the position of vehicle taking the evasive action (evasive action point) to the potential conflict point, and CS = the conflict speed, which is the speed of the relevant vehicle while taking the evasive action. The concept of TTC for crossing and rear-end collision at an intersection is shown in Fig

Video-Based Traffic Conflict Analytics
Video camera systems have been widely deployed to track vehicles frame by frame and monitor traffic flows at intersections [27,28]. Video analytics, which is a technology that uses artificial intelligence to automatically analyze video, has proven to be a tremendous help in smart and sustainable transport systems. It applies computer vision and deep learning to video streams to detect temporal and spatial events of traffic flows. Some applications of video analytics in real-time video streams include vehicle detection, vehicle classification, recognition, and tracking of license plates [13].
To analyze traffic data from video camera systems, computer vision techniques and object detection frameworks, such as Regional-based Convolutional Neural Networks (R-CNN) [29], You Only Look Once (YOLO) [30], and Single-Shot Multi-Box Detector (SSD) [31] are adapted for vehicle detection. Among object detection systems, YOLO is presented in this study. The YOLO algorithm is an extremely fast and accurate real-time object detection system. It detects objects by using a single neural network to predict multiple bounding boxes and associated class probabilities from an image. It then trains on multiple full images to improve detection accuracy. YOLO can finally learn generalizable representations of objects [32,33].
In recent years, video cameras have been applied to traffic conflict analysis in different stages of road safety management. Samara et al. (2020) [34] applied video analytics and connected cameras to identify risk locations with a high-concentration conflict rate on a road network. Chiu et al. [35] applied computer vision and image processing methods to diagnose safety issues by observing characteristics of traffic flow, including vehicle types, speed, acceleration, and trajectories, and calculating conflict severity based on TTC and invasion rate of safety space. Lynn et al. (2019) [13] used an automated video analytics tool to evaluate the surrogate safety measures of low-cost treatment at pedestrian crossings at intersections. The application of a video camera system is still evolving for traffic conflict monitoring and analysis. It requires close attention to technical knowledge, such as selection of cameras, video quality adjustment, and positioning of cameras [36,37].

Video-Based Traffic Conflict Analytics
Video camera systems have been widely deployed to track vehicles frame by frame and monitor traffic flows at intersections [27,28]. Video analytics, which is a technology that uses artificial intelligence to automatically analyze video, has proven to be a tremendous help in smart and sustainable transport systems. It applies computer vision and deep learning to video streams to detect temporal and spatial events of traffic flows. Some applications of video analytics in real-time video streams include vehicle detection, vehicle classification, recognition, and tracking of license plates [13].
To analyze traffic data from video camera systems, computer vision techniques and object detection frameworks, such as Regional-based Convolutional Neural Networks (R-CNN) [29], You Only Look Once (YOLO) [30], and Single-Shot Multi-Box Detector (SSD) [31] are adapted for vehicle detection. Among object detection systems, YOLO is presented in this study. The YOLO algorithm is an extremely fast and accurate real-time object detection system. It detects objects by using a single neural network to predict multiple bounding boxes and associated class probabilities from an image. It then trains on multiple full images to improve detection accuracy. YOLO can finally learn generalizable representations of objects [32,33].
In recent years, video cameras have been applied to traffic conflict analysis in different stages of road safety management. Samara et al. (2020) [34] applied video analytics and connected cameras to identify risk locations with a high-concentration conflict rate on a road network. Chiu et al. [35] applied computer vision and image processing methods to diagnose safety issues by observing characteristics of traffic flow, including vehicle types, speed, acceleration, and trajectories, and calculating conflict severity based on TTC and invasion rate of safety space. Lynn et al. (2019) [13] used an automated video analytics tool to evaluate the surrogate safety measures of low-cost treatment at pedestrian crossings at intersections. The application of a video camera system is still evolving for traffic conflict monitoring and analysis. It requires close attention to technical knowledge, such as selection of cameras, video quality adjustment, and positioning of cameras [36,37].

Methodology
The research methodology is presented in four stages, as shown in Figure 3: (1) selection of intersection sites; (2)

Methodology
The research methodology is presented in four stages, as shown in Figure 3: (1) selection of intersection sites; (2) video data collection; (3) video analytics development; and (4) safety analysis of intersections.

Site Selection
This study focused on assessing the safety of at-grade intersections under different road functional classifications using video-based traffic conflict analysis. The selection of intersections depends on varying road geometry, functional classes, type of control, crash history, and the feasibility of installing video cameras for proper field of view at intersections.
Typically, roadways can be classified by their functions into four classes: freeways, arterials, collectors, and local roads, according to the type of service [9]. In this study, five at-grade intersection classes according to roadway functional classification on a road network in Thailand were taken into consideration, as illustrated in

Site Selection
This study focused on assessing the safety of at-grade intersections under different road functional classifications using video-based traffic conflict analysis. The selection of intersections depends on varying road geometry, functional classes, type of control, crash history, and the feasibility of installing video cameras for proper field of view at intersections.
Typically, roadways can be classified by their functions into four classes: freeways, arterials, collectors, and local roads, according to the type of service [9]. In this study, five at-grade intersection classes according to roadway functional classification on a road network in Thailand were taken into consideration, as illustrated in Figure 4. The left figure shows a road hierarchy in a road network, while the right figure shows intersection classes in accordance with a road hierarchy. These intersection classes are as follows: 1.
Local-road/Local-road-The intersection of two two-lane local roads intersecting with stop control or without any control.

2.
Local-road/Collector-The intersection of a two-lane collector and a two-lane local road with through/stop and local road stopping.

3.
Collector/Arterial-The intersection of a collector (minor road) and an arterial (major road) with through/stop and collector stopping.

4.
Collector/Collector-The intersection of two collectors with signal control.

5.
Arterial/Arterial-The intersections of two arterials with signal control.

Methodology
The research methodology is presented in four stages, as shown in Figure 3: (1) selection of intersection sites; (2) video data collection; (3) video analytics development; and (4) safety analysis of intersections.

Site Selection
This study focused on assessing the safety of at-grade intersections under different road functional classifications using video-based traffic conflict analysis. The selection of intersections depends on varying road geometry, functional classes, type of control, crash history, and the feasibility of installing video cameras for proper field of view at intersections.
Typically, roadways can be classified by their functions into four classes: freeways, arterials, collectors, and local roads, according to the type of service [9]. In this study, five at-grade intersection classes according to roadway functional classification on a road network in Thailand were taken into consideration, as illustrated in    Figure 5 illustrates the layout of intersection sites with respect to these five intersection classes. Each intersection class differs in roadway geometry, traffic condition, and type of control. For each intersection class, three intersection sites with comparable geometries and configurations in Thailand were selected as case studies. A total of 15 intersection sites were examined. Table 1 summarizes the basic statistical data, including intersection type, crash data, traffic volume, proportion of vehicle types, and vehicle speed associated with all intersection sites.
Sustainability 2021, 13, x FOR PEER REVIEW 6 of 18 Figure 5 illustrates the layout of intersection sites with respect to these five intersection classes. Each intersection class differs in roadway geometry, traffic condition, and type of control. For each intersection class, three intersection sites with comparable geometries and configurations in Thailand were selected as case studies. A total of 15 intersection sites were examined. Table 1 summarizes the basic statistical data, including intersection type, crash data, traffic volume, proportion of vehicle types, and vehicle speed associated with all intersection sites.

Video Data Collection
Performing observations of traffic conflict in the field is a difficult task, which requires full attention throughout the study period. Thus, it is always recommended to complement field observations with video recording due to its flexibility and reliability.
To efficiently monitor traffic conflicts, it is recommended that the video cameras be positioned as high as possible to get a top view to address the occlusion problem. Nevertheless, for conflict detection at urban intersections, the video cameras are usually installed at the roadside poles and from all directions to cover the entire intersection without occluding serious vehicle situations due to the low vertical and lateral viewing angles [38][39][40].
In this study, video camera systems were deployed at the selected intersections to record vehicular traffic movement that generates crash risk exposure. Video cameras were installed at each of the intersection approaches, in addition to the closed-circuit television (CCTV) at the intersection area, as illustrated in Figure 6. All video cameras were positioned at a minimum of four meters height and were faced towards the intersection area five meters away from the intersection for measuring distance and detecting the speed of conflict. The study set up the video cameras and recorded the traffic at the intersection for at least 12 h from 7:00 a.m. to 7:00 p.m. from March to May 2021 for monitoring the number of expected vehicle conflicts by vehicle types and conflict types.

Video Analytics
After recording videos at intersection sites, video data were then processed using computer software. The study used the YOLO algorithm for vehicle detection. It is capable of processing more than 25 frames per second with a resolution of 960 × 480 pixels. It detects the vehicles by providing definition with a bounding box output and learning classification for detecting different types of vehicles (e.g., motorcycles, cars, trucks, etc.). The system is based on an Intel Core-i7 platform that operates at 2.2GHz and is equipped with 16GB SRAM and NVIDIA GTX1080 of GPU.
The YOLO algorithm processes data on a vehicle moving in a video with respect to its basic characteristics of shape and position and generates frame-by-frame detection and tracking of all vehicles in an intersection. Data from cameras were processed to detect and classify vehicles into three types (i.e., motorcycles, cars, and trucks). The deep learning algorithms were trained on over 1000 sample images. After 3000 iterations of training, the detection and classification accuracy were 94% and 97%, respectively.
In addition, the study determined and calculated the object's motion vector in intersection areas to solve the occlusion problem commonly discovered in the video stream. The software mapped the points in the video corresponding to coordinates in the intersection area. It tracked vehicles in the video to generate trajectories, position, and speed profiles of vehicles. For every possible traffic conflict, the software detected the evasive action point of vehicles and defined the potential conflict points to estimate conflicting speed and time-to-collision (TTC) of individual conflicts. Figure 7 presents the vehicle detection and vehicle tracking systems developed for this study.

Video Analytics
After recording videos at intersection sites, video data were then processed using computer software. The study used the YOLO algorithm for vehicle detection. It is capable of processing more than 25 frames per second with a resolution of 960 × 480 pixels. It detects the vehicles by providing definition with a bounding box output and learning classification for detecting different types of vehicles (e.g., motorcycles, cars, trucks, etc.). The system is based on an Intel Core-i7 platform that operates at 2.2 GHz and is equipped with 16GB SRAM and NVIDIA GTX1080 of GPU.
The YOLO algorithm processes data on a vehicle moving in a video with respect to its basic characteristics of shape and position and generates frame-by-frame detection and tracking of all vehicles in an intersection. Data from cameras were processed to detect and classify vehicles into three types (i.e., motorcycles, cars, and trucks). The deep learning algorithms were trained on over 1000 sample images. After 3000 iterations of training, the detection and classification accuracy were 94% and 97%, respectively.
In addition, the study determined and calculated the object's motion vector in intersection areas to solve the occlusion problem commonly discovered in the video stream. The software mapped the points in the video corresponding to coordinates in the intersection area. It tracked vehicles in the video to generate trajectories, position, and speed profiles of vehicles. For every possible traffic conflict, the software detected the evasive action point of vehicles and defined the potential conflict points to estimate conflicting speed and time-to-collision (TTC) of individual conflicts. Figure 7 presents the vehicle detection and vehicle tracking systems developed for this study.

Safety Analysis
There are many approaches to measure intersection safety, including crash data, behavioral observation, and conflicts. This study analyzed an intersection to determine its relative level of safety based on conflicts. The study performed a traffic conflict study to count the number of conflicts and applied a traffic conflict technique to assess the conflict risk. In this study, the risk of conflict was viewed by two measures.
The first dimension is the time-to-collision (TTC). TTC is related to the probability of a crash. Lower TTC value corresponds to higher chance of collision (crash likelihood). The study by Sayed and Zein [14] recommended the threshold of TTC values at 1.0, 1.5, and 2.0 s for the measure of safety with a high, moderate, and low risk, respectively. Vuong (2017) [41] applied the 85 th percentile of TTC as the cut-off between serious and non-serious conflicts.
Another dimension is the speed of the relevant vehicle. Vehicle speed is related to the risk of human injury and death when involving a crash. Higher speed corresponds to higher chance of injury (crash severity) [42][43][44]. According to the principles of sustainable safety, vision zero, and safe system approach, the safe speed is introduced for road design. The speed of the vehicle directly affects the probability of a fatality or serious injury involving a collision. The safe speed varies according to collision configurations, such as up to only 30 km/h in a vulnerable-road-user-related collision, up to 50 km/h in a side collision between vehicles at an intersection, and up to 70 km/h in a head-on collision [1, 45,46]. It is recommended that speeds at different probabilities of a fatality or serious injury are chosen to represent different levels of collision severity [13,47,48].
This study highlighted the need to distinguish the risk between vulnerable road users (e.g., motorcyclists) and other vehicles. Motorcyclists can tolerate a lower impact speed than drivers for any collision types. The study applied different thresholds of speed for motorcycles and cars to define conflict risk. The speeds of 15, 30, and 50 km/h for motorcycles and 25, 50, and 70 km/h for cars, which correspond to the probability of a fatality or serious injury at 0.05, 0.10, and 0.85, were defined as low-risk, moderate-risk, and highrisk conflict, respectively [46,49]. Table 2 shows the threshold of time-to-collision and vehicle speed used to classify the risk of conflict. Figure 8 illustrates risk-of-conflict (ROC) diagrams for motorcycle-related collision and car-related collision at intersections. Each diagram is divided into four regions as follows: high-risk conflict (in red), moderate-risk conflict (in orange), low-risk conflict (in yellow), and no-risk conflict (in green). It shows that the conflict risk is high when TTC is low and vehicle speed is high.

Safety Analysis
There are many approaches to measure intersection safety, including crash data, behavioral observation, and conflicts. This study analyzed an intersection to determine its relative level of safety based on conflicts. The study performed a traffic conflict study to count the number of conflicts and applied a traffic conflict technique to assess the conflict risk. In this study, the risk of conflict was viewed by two measures.
The first dimension is the time-to-collision (TTC). TTC is related to the probability of a crash. Lower TTC value corresponds to higher chance of collision (crash likelihood). The study by Sayed and Zein [14] recommended the threshold of TTC values at 1.0, 1.5, and 2.0 s for the measure of safety with a high, moderate, and low risk, respectively. Vuong (2017) [41] applied the 85th percentile of TTC as the cut-off between serious and non-serious conflicts.
Another dimension is the speed of the relevant vehicle. Vehicle speed is related to the risk of human injury and death when involving a crash. Higher speed corresponds to higher chance of injury (crash severity) [42][43][44]. According to the principles of sustainable safety, vision zero, and safe system approach, the safe speed is introduced for road design. The speed of the vehicle directly affects the probability of a fatality or serious injury involving a collision. The safe speed varies according to collision configurations, such as up to only 30 km/h in a vulnerable-road-user-related collision, up to 50 km/h in a side collision between vehicles at an intersection, and up to 70 km/h in a head-on collision [1, 45,46]. It is recommended that speeds at different probabilities of a fatality or serious injury are chosen to represent different levels of collision severity [13,47,48].
This study highlighted the need to distinguish the risk between vulnerable road users (e.g., motorcyclists) and other vehicles. Motorcyclists can tolerate a lower impact speed than drivers for any collision types. The study applied different thresholds of speed for motorcycles and cars to define conflict risk. The speeds of 15, 30, and 50 km/h for motorcycles and 25, 50, and 70 km/h for cars, which correspond to the probability of a fatality or serious injury at 0.05, 0.10, and 0.85, were defined as low-risk, moderate-risk, and high-risk conflict, respectively [46,49]. Table 2 shows the threshold of time-to-collision and vehicle speed used to classify the risk of conflict. Figure 8 illustrates risk-of-conflict (ROC) diagrams for motorcycle-related collision and car-related collision at intersections. Each diagram is divided into four regions as follows: high-risk conflict (in red), moderate-risk conflict (in orange), low-risk conflict (in yellow), and no-risk conflict (in green). It shows that the conflict risk is high when TTC is low and vehicle speed is high.   To assess the safety of intersections, the risk of conflict is introduced as the conflict rate between the number of conflicts at risk and number of all interactions (of two vehicles) during the same period (see Equation (2)). In other words, it is the risk for an interaction (of two vehicles) to develop into a conflict at risk.
where ROC = risk of conflict; NH, NM, and NL = number of conflicts at risk consisting of high-risk conflicts, moderate-risk conflicts, and low-risk conflicts, respectively; and N = number of all conflicts (both conflicts at risk and non-risk conflicts)

Results and Discussion
This study applied video-based traffic conflict analysis to investigate the conflict risk of vehicles at different intersection sites in Thailand. The results are presented in two respects: the analysis of traffic conflicts, and the analysis of the risk of intersections.

Analysis of Traffic Conflicts
Using video analytics for a traffic conflict study, thousands of vehicle conflict situations (or interactions) were detected at each intersection site. For each intersection site, the number of traffic conflicts were recorded from 7:00 a.m. to 7:00 p.m. (12 h). It is noted that video analytics were applied only in the daytime. Two main conflict types were observed: crossing conflicts between vehicles from two directions at the intersection area and rearend conflicts between vehicles at intersection approaches. Traffic conflicts were then classified by types of vehicles involved in the conflict. The three types of vehicle conflicts were: motorcycle-motorcycle (MC-MC) conflicts, motorcycle-car (MC-Car) conflicts, and car-car conflicts.
First, consider the vehicle types involved in a conflict. Figure 9 plots the frequency distribution of traffic conflicts associated with the five classes of intersection. The figures To assess the safety of intersections, the risk of conflict is introduced as the conflict rate between the number of conflicts at risk and number of all interactions (of two vehicles) during the same period (see Equation (2)). In other words, it is the risk for an interaction (of two vehicles) to develop into a conflict at risk.
where ROC = risk of conflict; N H , N M , and N L = number of conflicts at risk consisting of high-risk conflicts, moderate-risk conflicts, and low-risk conflicts, respectively; and N = number of all conflicts (both conflicts at risk and non-risk conflicts)

Results and Discussion
This study applied video-based traffic conflict analysis to investigate the conflict risk of vehicles at different intersection sites in Thailand. The results are presented in two respects: the analysis of traffic conflicts, and the analysis of the risk of intersections.

Analysis of Traffic Conflicts
Using video analytics for a traffic conflict study, thousands of vehicle conflict situations (or interactions) were detected at each intersection site. For each intersection site, the number of traffic conflicts were recorded from 7:00 a.m. to 7:00 p.m. (12 h). It is noted that video analytics were applied only in the daytime. Two main conflict types were observed: crossing conflicts between vehicles from two directions at the intersection area and rear-end conflicts between vehicles at intersection approaches. Traffic conflicts were then classified by types of vehicles involved in the conflict. The three types of vehicle conflicts were: motorcycle-motorcycle (MC-MC) conflicts, motorcycle-car (MC-Car) conflicts, and car-car conflicts.
First, consider the vehicle types involved in a conflict. Figure 9 plots the frequency distribution of traffic conflicts associated with the five classes of intersection. The figures present the number of conflicts classified by three vehicle conflicts (i.e., MC-MC, MC-Car, and Car-Car) from 7:00 a.m. to 7:00 p.m. (12 h) at one site of each intersection class. The results showed that motorcycle-related conflicts (both MC-MC and MC-Car) were high at intersections on local road networks, while car-related conflicts were high at intersections on collectors and arterials. This also showed that the conflict frequencies at signal-controlled intersections are much fewer than those at stop/no control intersections. Next, consider the two conflict types (crossing and rear-end conflicts) at intersections. Table 3 presents the basic statistics of traffic conflicts among the five intersection classes. Next, consider the two conflict types (crossing and rear-end conflicts) at intersections. Table 3 presents the basic statistics of traffic conflicts among the five intersection classes. The table shows the conflict frequencies and their 95% confidence interval of surrogate safety measures (time-to-collision and conflict speed) associated with crossing and rear-end conflicts. The results revealed that conflict frequencies and surrogate indicators were varied among intersection classes. Further observations are as follows: • Local-road/local-road intersections. Traffic conflicts were frequent. The range of TTC value was small, and speed was the lowest. This might be because the right-of-way at this class of intersections was ambiguous for road users and led to inconsistent yielding behavior. Most motorists first came to stop at an intersection, but quickly departed from the intersection. • Local/collector intersections. Traffic conflicts were also frequent, but TTC value was longer, and speed was higher than intersections with two local roads. This might be because this class of intersection was clearly visible but had a lack of appropriate regulatory control devices. Motorists on both roads passed through an intersection without stopping. They could not indicate the priority at the intersection since the cross-sections of both roads might look similar yet have different road functions.

•
Collector/arterial intersections. Traffic conflicts were especially frequent from collectors. The priority at this class of intersection was clear. However, motorists from minor roads easily misjudged the gaps in traffic on major roads. Collector/collector intersections. With signal-control, crossing conflicts were not applicable at this class of intersection and rear-end conflicts only were detected. • Arterial/arterial intersections. Traffic conflicts on this class of intersection were more severe than other signalized intersections due to high speed, and as a result, time-tocollision was critical.

Analysis of Conflict Risk
The descriptive statistics on traffic conflicts only might not fully describe the safety performance of intersections. This study introduced the risk assessment of intersections by viewing traffic conflict situations in two dimensions: the chance of collision (likelihood) and the chance of injury (severity). The study plotted the distribution of traffic conflicts with respect to time-to-collision and conflict speed and compared these among five intersection classes to visualize the risk levels, as shown in Figure 10.

•
Collector/collector intersections. Traffic conflicts were few. The conflicts were at moderate risk • Arterial/arterial intersections. Traffic conflicts were very few, but all of them were at high risk due to short time-to-collision and high speed. Consider the types of vehicles involved in a conflict. The conflict diagrams for each vehicle type were drawn. Figure 11 illustrates the example of conflict diagrams associated with the Collector/Arterial intersection. The conflict diagrams are classified by vehicle  Local-road/local-road intersections. Most conflicts had short time-to-collision, but low conflict speed. Road users might take high evasive action, but such conflicts might not result in high risk of injury.

•
Local/collector intersections. The distribution of traffic conflicts was more dispersed with longer time-to-collision and higher conflict speed than local intersections.

•
Collector/arterial intersections. Traffic conflicts had short time-to-collision and higher conflict speed, which led to higher risk.
• Collector/collector intersections. Traffic conflicts were few. The conflicts were at moderate risk • Arterial/arterial intersections. Traffic conflicts were very few, but all of them were at high risk due to short time-to-collision and high speed.
Consider the types of vehicles involved in a conflict. The conflict diagrams for each vehicle type were drawn. Figure 11 illustrates the example of conflict diagrams associated with the Collector/Arterial intersection. The conflict diagrams are classified by vehicle types: all conflicts, MC-MC conflicts, MC-Car conflicts, and Car-Car conflicts, respectively. It is noted that the threshold of speed for Car-Car conflicts is different from motorcyclerelated conflicts, as described in the previous section. This example showed that although Car-Car conflicts are the most frequent at this intersection, traffic conflicts between motorcycles and cars are the most serious. The chance of collision was high due to short TTC, and injury was possible since some conflicts involved high speed. types: all conflicts, MC-MC conflicts, MC-Car conflicts, and Car-Car conflicts, respectively. It is noted that the threshold of speed for Car-Car conflicts is different from motorcycle-related conflicts, as described in the previous section. This example showed that although Car-Car conflicts are the most frequent at this intersection, traffic conflicts between motorcycles and cars are the most serious. The chance of collision was high due to short TTC, and injury was possible since some conflicts involved high speed. Further, the conflict risk was determined for different conflict vehicles. Table 4 shows the risk of conflict categorized by conflict types and vehicle types among five classes of intersections. Figure 12 illustrates the percentage of conflicts in different risk levels associated with 15 intersection sites. The first figure is for motorcycle-related conflicts (i.e., MC-MC and MC-Car conflicts), and the second figure is for Car-Car conflicts.
The results indicated that for all conflict types and vehicle types, high-order intersections (e.g., arterial/arterial and collector/collector intersections) with signal control showed a higher risk of conflict than low-order intersections with stop/no control due to high conflict speed. The results clearly showed that motorcycles are exposed to higher risk than cars at all intersection sites, especially those with stop/no control. Further, the conflict risk was determined for different conflict vehicles. Table 4 shows the risk of conflict categorized by conflict types and vehicle types among five classes of intersections. Figure 12 illustrates the percentage of conflicts in different risk levels associated with 15 intersection sites. The first figure is for motorcycle-related conflicts (i.e., MC-MC and MC-Car conflicts), and the second figure is for Car-Car conflicts.    The results indicated that for all conflict types and vehicle types, high-order intersections (e.g., arterial/arterial and collector/collector intersections) with signal control showed a higher risk of conflict than low-order intersections with stop/no control due to high conflict speed. The results clearly showed that motorcycles are exposed to higher risk than cars at all intersection sites, especially those with stop/no control.

Conclusions and Recommendations
This exploratory study presented a new method in road safety data collection and analysis for sustainably assessing the safety of intersections under mixed traffic conditions with a high percentage of motorcycles in Thailand. The proposed method used videobased traffic conflict analysis, which applied traffic conflict studies together with automated video image-processing techniques. The objectives of this study were to develop the video analytics for observing and recording conflicting behavior of vehicles and their associated characteristics, and to apply such traffic conflict data to make relative comparisons of the risk at various intersections.
The study developed video analytic tools that could detect the type, speed, and trajectory of vehicles under mixed traffic conditions, including motorcycles and cars, and analyze surrogate safety measures in terms of the time-to-collision and speed of individual conflicts. The conflict risk of an intersection was estimated as the ratio of the number of conflicts at risk and the total number of conflicts observed. The study presented the conflict diagrams to visualize the conflict risk in terms of the frequency and severity of conflicts at intersections. In other words, it is the risk that two vehicles approaching an intersection will develop into a conflict at risk.
Based on traffic conflict data and analysis of intersections in the study area, the results showed that intersection classes (or orders of intersecting roads) and characteristics and types of intersection control affect the risk of an intersection. The high-order intersections with signal control show high risks due to high conflicting speed. They generate few conflicts yet are at the highest risk of injury. The low-order intersections with stop control or no control show high risks due to short time-to-collision. They generate frequent conflicts at the lowest risk of injury. The intersections of lower-and higher-order roads with clear right-of-way, such as collector/arterial, generate frequent conflicts, especially crossing conflicts by vehicles from a lower-order road. The intersections of lower-and higher-order roads with unclear right-of-way generate higher risk of conflict than those with clear right-of-way.
Traffic conflict analysis is of considerable importance in identifying hazardous locations in which traffic conflicts are concentrated or severe. It can further be applied to diagnosing the possible crash patterns and to recommend road safety countermeasures to specific problems. Video-based traffic conflict analysis can be a suitable tool for systematically and comprehensively assessing road safety. Lastly, the risk of conflict based on traffic conflict data can be deemed as a supplemental indicator in addition to limited crash data to evaluate the safety of roadway infrastructure projects and prioritize among them.
Although this risk-based approach can be deemed as a supplemental indicator in addition to limited crash data to evaluate the safety of intersections, this exploratory study has limitations and future research is still needed. The study employed surrogate safety measures to assess intersection safety. However, this investigation was applied to a limited number of intersections, certain conflict types, limited vehicle types, and a specified time of analysis. It is also noted that this study developed the approach to the study area under mixed traffic conditions, including a high number of motorcycles and cars. Careful attention must be paid when applying the approach to other study areas with different combinations of vehicle types. Future research is needed to explore more practical applications, such as the consideration of other collision types and vehicle types, the selection of surrogate indicators, the accuracy of the algorithm, the calibration of conflict risk levels for other crash patterns, and the potential for other road infrastructure under different contextual circumstances.
Author Contributions: Conceptualization, N.K. and C.S.; methodology, N.K. and C.S.; formal analysis, C.S.; writing-original draft preparation, C.S.; writing-review and editing, N.K.; supervision, T.S. and P.L.; funding acquisition, N.K. All authors have read and agreed to the published version of the manuscript.
Funding: This research received no external funding.
Institutional Review Board Statement: Not applicable.
Informed Consent Statement: Not applicable.