Witraffic: Low-Cost and Non-Intrusive Traffic Monitoring System Using Wifi

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 9

WiTraffic: Low-cost and Non-intrusive Traffic

Monitoring System Using WiFi


Myounggyu Won1 , Shaohu Zhang1 , and Sang H. Son2
1 WENS
Lab, South Dakota State University, Brookings, SD, United States
2 CPS Global Center, Daegu Gyeongbuk Institute of Science and Technology, Daegu, South Korea

{myounggyu.won,shaohu.zhang}@sdstate.edu, son@dgist.ac.kr

WiFi NIC
Abstract—The traffic monitoring system is an imperative tool
for traffic analysis and transportation planning. In this paper,
we present WiTraffic: the first WiFi-based traffic monitoring
system. Compared with existing solutions, it is non-intrusive,
cost-effective, and easy-to-deploy. Unique WiFi Channel State
Information (CSI) patterns of passing vehicles are captured
and analyzed to effectively perform vehicle classification, lane
detection, and speed estimation. A machine learning technique
WiFi Transmitter
is adopted to train vehicle classification models and efficiently Receiver System
categorize vehicles. An Earth Mover’s Distance (EMD)-based
vehicle lane detection algorithm and vehicle speed estimation Fig. 1. Illustration of WiTraffic system.
mechanism are proposed to further utilize WiFi CSI to identify
the lane in which a vehicle is located and to estimate the vehicle
speed. We implemented WiTraffic with off-the-shelf WiFi devices ultrasonic sensors [6]) either above the roadway or alongside
and performed real-world experiments with over a week of field the roadway. These systems are usually costly and easily
data collection in both local roads and highways. The results show
that the mean classification accuracy, lane detection accuracy for
affected by weather conditions. Aerial-based approaches [7]
both local road and highway settings are around 96%, and 95%, utilize satellites or aircrafts to capture road images, and extract
respectively. The average root-mean-square error (RMSE) of the traffic information via image processing. These solutions,
proposed CSI-based speed estimation method on a highway was however, suffer from spatio-temporal limitations.
5mph in our experimental settings. WiFi Channel State Information (CSI) represents channel
Index Terms—WiFi CSI; Traffic monitoring systems
properties of wireless communication links that describe how
signals are transmitted from a transmitter to a receiver. Re-
I. I NTRODUCTION cently, various CSI-based applications have been developed,
e.g., human activity recognition [8][9][10][11], and localiza-
The traffic monitoring system refers to a set of technolo- tion [12][13] manifesting the versatility of WiFi CSI. In this
gies that are designed to collect traffic data on the roadway paper, we present the design, implementation, and evaluation
usage, e.g., the number and characteristics of vehicles. It of the first WiFi CSI-based traffic monitoring system called
plays a vital role in analyzing the transportation system and WiTraffic and demonstrate that the limitations of existing
establishing plans for future transportation needs [1]. It is an traffic monitoring systems are addressed utilizing the rich
imperative tool for many state Departments of Transportation context information contained in WiFi CSI.
(DOTs) to achieve various purposes, e.g., determination of More specifically, we illustrate that WiFi CSI can be used to
road improvement plans, evaluation of the efficiency of road create a multifaceted traffic monitoring system that is capable
network, assessment of economic benefits, assistance in new of performing vehicle counting, classification, lane detection,
development plans, and so on [2]. and speed estimation. Distinctive CSI patterns of passing
Numerous traffic monitoring systems have been developed. vehicles are captured and analyzed to fulfill various functions
These systems can be largely classified into three categories: of the traffic monitoring system. A machine learning technique
in-road-based, over-road-based, and aerial-sensor-based ap- is employed to train vehicle classification models based on the
proaches. In-road-based systems require to sawcut the pave- unique CSI values of different vehicle types. The classification
ment and embed sensors in the pavement of the roadway. models are utilized to perform effective vehicle categorization.
Those sensors include inductive loop detectors [3], and mag- Additionally, motivated by the observation that each lane has a
netometers [4]. However, installing sensors is very time and unique distribution of CSI data, a novel vehicle lane detection
labor-intensive, and the operation of those sensors is inter- algorithm is developed that characterizes the distribution of
vened by roadway surfacing or pavement deterioration. Over- the CSI data per lane, and performs lane detection based on
road-based approaches install sensors (e.g., video cameras [5], the comparison of the probability distributions of CSI using
the Earth Mover’s Distance.
Myounggyu Won and Shaohu Zhang equally contributed to this work. Compared with existing traffic monitoring systems, the

978-1-5090-2991-4/17/$31.00 ©2017 IEEE


proposed system is non-intrusive, easy-to-deploy, portable, frequency response of each subcarrier for all streams, i.e.,
and inexpensive. Especially, in comparison with RF-based there are 𝑚 × 𝑛 streams if there are 𝑚 receiver antennas,
vehicle detection systems [14][15] that utilize the received and 𝑛 transmitter antennas. Thus, the dimension of matrix 𝐻
signal strength indicator (RSSI) to detect vehicles, the rich is 𝑚 × 𝑛 × 𝑤, where 𝑤 denotes the number of subcarriers.
information of CSI allows for more fine-grained analysis of For example, matrix 𝐻 for a certain stream is represented as
signals at the levels of frequency-selective fading and indepen- a vector of subcarrier groups:
dent spatial paths enabling vehicle classification beyond simple
vehicle detection. In addition, while the RSSI could fluctuate 𝐻 = [𝐻1 , 𝐻2 , ..., 𝐻𝑤 ],
to a few db at the same location [16], CSI is more stable and
robust to the complex environments [17]. All it’s required to where 𝐻𝑖 denotes the 𝑖-th subcarrier group that represents both
deploy the proposed system is a off-the-shelf WiFi access point the amplitude and phase information as follows.
(Internet Connection not necessary) and a WiFi device (such
as a laptop) that receives WiFi signals from the access point 𝐻𝑖 = ∣ℎ∣𝑒𝑗𝑝 ,
(Figure 1). With this system, anyone can easily deploy a traffic
monitoring system anywhere and perform traffic monitoring where ∣ℎ∣, and 𝑝 represent the amplitude and phase, respec-
at a low cost, potentially addressing the cost issue for many tively. The key idea is that by exploiting the amplitude and
state DOTs to deploy a large number of traffic monitoring phase information of subcarrier groups, small changes in the
systems on rural highways. The contributions of this paper channel usually caused by multipath effects are effectively
are summarized as follows. captured.
∙ The first WiFi-based traffic monitoring system is devel-
oped.
∙ Various functionalities of a traffic monitoring system, i.e.,
vehicle detection, classification, lane identification, and
speed measurement are developed based on WiFi CSI.
∙ A machine learning technique is applied to achieve highly
accurate vehicle classification.
∙ A novel vehicle lane detection mechanism is developed
based on the unique CSI distributions of vehicles on Fig. 2. Illustration of multipath effects caused by a passing vehicle.
different lanes.
∙ More than a week of real traffic data were collected The multipath effect caused by passing vehicles, i.e., signals
from local roads and highways, and extensive real-world reflected from the ground and the vehicle body, is utilized
experiments were conducted to evaluate the performance to perform vehicle classification. For example, as shown in
of the proposed system. Figure 2, the line of sight (LoS) signal is degraded due to the
This paper is organized as follows. In Section II, pre- vehicle body; paths 𝑝1 and 𝑝2 are reflected from the ground,
liminaries are presented to review CSI and to define basic and path 𝑝3 is reflected from the vehicle body. Considering the
terms that are used in this paper. Section III describes an application-specific characteristics of an outdoor environment
overview of the proposed system followed by the details of the that has significantly lower signal reflections compared with
system components. In Section IV, the system implementation typical indoor environments with many obstacles, an weighted
details are explained. Section V evaluates the performance of average of 30 CSI groups in the frequency domain is utilized
the proposed system, and in Section VI, the related work is not only to compensate for the small-scale fading effect,
presented. We conclude in Section VII. but also to minimize the computational overhead [19]. This
effective CSI is formally defined as follows.
II. P RELIMINARIES
𝐾
The orthogonal frequency division multiplexing (OFDM) 1 ∑
modulation scheme has been adopted to implement the physi- 𝐶𝑆𝐼𝑒𝑓 𝑓 = 𝑤𝑘 ⋅ ∣𝐻𝑘 ∣,
𝐾
cal layer of the current WiFi standards. It divides the channel 𝑘=1
into subcarriers, and data is transmitted over these subcarriers. where 𝑤𝑘 is the weight of the 𝑘th subcarrier, and K is
Using this channel division mechanism, OFDM addresses the the number of subcarriers. Here 𝑤𝑘 =𝑓𝑘 /𝑓0 , where 𝑓𝑘 is the
frequency selective fading caused by the multipath effect. CSI frequency of the 𝑘-th subcarrier, and 𝑓0 is the center frequency.
characterizes signal strengths and phases of these OFDM sub- Normalized effective CSI is converted into the ‘radio-
carriers. More specifically, a received WiFi signal is modeled strength-dependent one’ to more accurately capture the unique
as the following [18]. CSI values of vehicles, especially to distinguish vehicles that
are on different lanes exhibiting different power levels of CSI
𝑦 = 𝐻 ⋅ 𝑥 + 𝑛, depending on the distance from the transmitter. Consequently,
where 𝑥, 𝑦, and 𝑛 are the transmitted signal, received signal, CSI power is defined based on effective CSI and AGC (Au-
and channel noise, respectively. A matrix 𝐻 represents the tomatic Gain Control - obtained from the NIC) as follows.
(a) (b) (c)

(d) (e) (f)

Fig. 3. Snapshots of a passing (a) motor bicycle; (b) passenger vehicle; (c) truck, and the corresponding CSI values for the (d) motor bicycle; (e) passenger
vehicle; (f) truck.

data analysis are incorporated into the models in the Model


𝐶𝑆𝐼𝑒𝑓 𝑓
𝑃𝑐𝑠𝑖 = √ 𝐴𝐺𝐶 . Database to improve the performance of WiTraffic.
10 10
B. Noise reduction
CSI power is used as the main feature for vehicle classifica-
tion and lane detection. It is experimentally observed that CSI CSI data generated by commodity WiFi NICs are inherently
power effectively represents the unique CSI patterns of passing noisy due to dynamics of transmit power levels, transmission
vehicles on different lanes. Figure 3 displays the waveforms rates, and internal CSI reference levels. For accurate vehicle
of CSI power for a passing motorbike, a passenger vehicle, classification, such noise needs to be effectively removed. The
and a truck. Butterworth low-pass filter is well known for its effectiveness
to reduce noise of CSI data [10]. We adopt the Butterworth
III. S YSTEM D ESIGN low-pass filter to remove the noise of collected raw CSI data.
In this section, an overview of the proposed system is We tested the filter with different cut-off frequencies to find
presented followed by the details of its components. the best configuration and observed that with a normalized cut-
off frequency of 0.05rad/s, the noise was effectively reduced.
A. Overview
Figures 5 and 6 plot measurements of original CSI data and
filtered one for a passenger vehicle and a truck, respectively.
It is illustrated that the noise is effectively removed after
applying the Butterworth low-pass filter. It should be noted
that if we adapt the cut-off frequency depending on the traffic
environment, it is expected that WiTraffic will perform better.
We leave the algorithm development for this dynamic selection
of the cut-off frequency as future work.
C. Vehicle Detection and Classification
Once noise of CSI data is successfully reduced, the vehicle
Fig. 4. System architecture of WiTraffic. detection component of the Data Collection module starts
to run to detect a passing vehicle based on the filtered CSI
The system architecture of WiTraffic is depicted in Figure 4. data. Since passing vehicles cause high variance in CSI data
WiTraffic has three main system modules: Data Collection, (Figures 5 and 6), a simple threshold-based detection method
CSI Analysis, and Model Database. The Data Collection is developed, rather than developing a machine learning algo-
module collects raw CSI data in a sliding window, removes rithm to minimize the system complexity. More specifically,
noise in the collected data, and detects a passing vehicle a CSI power sample 𝑐𝑖 measured at time 𝑡𝑖 is compared
based on the noise-removed data. The CSI Analysis module with threshold Δ𝑑. The optimal threshold is experimentally
implements the functions of a traffic monitoring system, i.e., determined in Section V-B. We selected the threshold such
vehicle classification, lane detection, and speed estimation, by that the false positive rate is minimized while the vehicle
performing analysis of the filtered CSI data. The results of detection accuracy is maximized. Given the selected threshold,
if the current CSI sample value drops below the threshold, CSI 40 60

values in the corresponding sliding window are input to the 50


30
CSI Analysis module to proceed with vehicle classification, 40

Counts

Counts
lane detection, and speed estimation. 20 30

20
10
0.2 0.25 10
CSI Power Measurment (dBm)

CSI Power Measurment (dBm)


orignal orignal
filtered filtered 0 0
0.2 0 5 10 15 20 0 5 10 15 20
0.15
CSI bins CSI bins
0.15
0.1
0.1
Fig. 7. Probability distribution of Fig. 8. Probability distribution of
CSI values for a passenger vehicle CSI values for a passenger vehicle
0.05
0.05 on Lane 1. on Lane 2.
0 0
0 500 1000 1500 0 500 1000 1500
Sample Index Sample Index

Fig. 5. Filtered CSI power for a Fig. 6. Filtered CSI power for a truck.
passenger vehicle. that each lane has a distinctive probability distribution of
CSI data because of varying distance from the transmitter
Note that vehicle detection and vehicle classification are two that determines the received signal strength. To capture the
different functions of the proposed system, i.e., once a vehicle distribution of CSI data (for a certain vehicle type), CSI values
is detected, vehicle classification is performed to determine the are divided into 20 equal-sized bins. Figures 7 and 8 display
vehicle type. Rich information extracted from CSI data is used the results for a passenger vehicle on different lanes that
to train vehicle classification models, and vehicle classification exhibit distinct probability distributions of CSI data. A lane
is performed in accordance with the models. More specificaly, model for each lane is constructed by incorporating a large
we employ the C-Support Vector Machine (C-SVM) [20] amount of ground-truth CSI data that are validated with video
to train our vehicle classification models. In this paper, we data. This lane model is individually defined for each vehicle
create two models, i.e., for passenger vehicles, and for freight type since different probability distributions are obtained for
trucks. It is easy to extend the models for more sophisticated different vehicle types.
vehicle classification (e.g., SUVs, pickup trucks, mini-vans,
etc.), which we leave as our future work. Features of filtered More specifically, assume that a vehicle of type 𝑣 is deter-
CSI data that represent passing vehicles are extracted and input mined. Let a vector 𝐶𝑣 = {𝑐1 , 𝑐2 , ..., 𝑐𝑛 } be the CSI power
to the support vector machine to generate the models. of the detected vehicle. Each CSI sample 𝑐𝑖 of vector 𝐶𝑣 is
then mapped to a bin 𝑏𝑙,𝑣 defined for each lane denoted by 𝑙,
TABLE I i.e., a value within the range [0, 20], is associated with the CSI
𝑐𝑖
F EATURE T EST R ESULTS sample, more formally, ⌊ 1/20 ⌋ → 𝑏. This operation is repeated
Local Road Highway for all ground truth data to create, calibrate, and consolidate
Passenger Vehicle Truck Passenger Vehicle Truck the lane model.
RMS 0.1250 0.043 0.058 0.031
MAD 0.036 0.01 0.015 0.008 Once lane models are created, the lane detection module
MEAN 0.11 0.039 0.042 0.027 detects in which lane a vehicle is located. More specifically,
1Q 0.061 0.026 0.004 0.015
3Q 0.156 0.05 0.065 0.035 when a vehicle passes through the line of sight path between
the receiver and the transmitter, the module compares the prob-
To train our classification models, we used separated sets ability distribution of CSI values of the passing vehicle with
of data for training and testing. For training, five features of the lane models defined for each lane (and for this particular
CSI data were used: (1) root mean square (RMS), (2) median vehicle type), and determines the lane model that is ‘closest’ to
absolute deviation (MAD), (3) mean, (4) first quartile, and the probability distribution of the passing vehicle. To perform
(5) third quartile, based on the observation that a passing this distribution dissimilarity test and detect the vehicle lane,
vehicle creates high variance in CSI data. As shown in Table we employ the Earth Mover’s Distance (EMD) [21]. The
I, the values of these features for passenger vehicles and EMD is a measure of dissimilarities between two probability
trucks in both local roads and highways are distinctively distributions. Conceptually, each bin corresponds to a pile of
different indicating usefulness of these features to achieve high “earth”. The cost 𝑓 (𝑎, 𝑏) is defined such that a unit cost is
accuracy in vehicle classification. In particular, to select the required to move one unit of earth from bin 𝑎 to bin 𝑏. The
best parameters, i.e., 𝐶 and 𝛾, the cross-validation technique EMD measures the minimum cost to convert a histogram to
was used [20]. a target histogram. Thus, lower EMD means that the two
distributions are more highly correlated, indicating that the
D. Vehicle Lane Detection vehicle is on this particular lane. The vehicle lane detection
Once vehicle classification is completed, WiTraffic identifies accuracy based on this EMD metric will be evaluated in
in which lane a vehicle is located. The key intuition is Section V-E.
to build the models for vehicle classification, lane detection,
and speed measurement, two USB cameras, ELP 2.0mp, were
connected to the laptop and collected video data. In addition,
CSI Power the Bushnell velocity speed gun was also installed to collect
the ground truth vehicle speed data. More than a week of
real-world field data were collected to prepare a data set for a
large number of passenger vehicles and trucks for the system
evaluation of Wi-Traffic.

Time Laptop Router

15 m 16 m
Fig. 9. Illustration of vehicle detection and speed estimation. Router Laptop

E. Vehicle Speed Estimation Fig. 10. Experimental setup: local road (left); highway (right).

CSI data are further utilized to estimate the vehicle speed,


Given created models, the proposed system was evaluated
basically implementing all essential traffic monitoring func-
in two different roadway environments. Figure 10 depicts the
tions based on WiFi CSI. The key idea is simple: the number
two test scenarios: the local road (left) and the highway (right).
of CSI samples collected while a vehicle passes through the
The local road was selected as our test site to understand the
line-of-sight path between transmitter and receiver is used
system accuracy under complex environments in which there
as an indicator for estimating the speed of the vehicle. We
are pedestrians, bicycles, trees, buildings, and so on. In fact,
observe that when the line-of-sight path is interrupted, the
as it will be shown in Section V, the accuracy for the highway
CSI power substantially decreases. Consequently, in order to
was higher compared with that for the local road primarily due
estimate the vehicle speed, the first step is to find the beginning
to this complexity.
𝑐𝑏 and end 𝑐𝑒 of the CSI time series that represent the time
period for which the vehicle is blocking the line-of-sight path V. E XPERIMENTAL R ESULTS
(Figure 9). To find 𝑐𝑏 , a similar threshold-based approach is This section evaluates the performance of WiTraffic. The
used. Suppose that the vehicle was detected at 𝑡𝑖 , i.e., 𝑐𝑖 was optimal window size and threshold are experimentally deter-
smaller than the threshold. We then estimate that 𝑡𝑖 is 𝑐𝑏 . Now, mined. Based on the determined window size and threshold,
to determine 𝑐𝑒 , a small time window Δ𝑡 is defined. Starting accuracy of vehicle detection, vehicle classification, vehicle
from 𝑡𝑖 , the degree of variations in the CSI time series in a lane detection, and vehicle speed estimation is evaluated.
time window between 𝑡𝑗 and 𝑡𝑘 is iteratively calculated using
the mean absolute deviation (MAD) denoted by 𝛿𝑗𝑘 . If 𝛿𝑗𝑘 is A. Selection of Window Size
smaller than a predefined threshold, 𝑡𝑗 is marked as the end of It was observed that CSI values of a vehicle change signif-
the vehicle passing activity. Consequently, the total number of icantly when a vehicle crosses through the line-of-sight path
samples between 𝑡𝑖 and 𝑡𝑗 are counted, which is denoted by between the transmitter and receiver. Thus, the window size
𝑁𝑠 . This total number of samples is used as the main feature needs to be determined based on the vehicle body length. The
for training our vehicle speed model, i.e., a speed model is body length of a general passenger vehicle is around 4.5m. Ac-
built using a set of pairs (𝑁𝑠 , ground truth speed) for each cording to the Federal Highway Administration (FHWA) [23],
vehicle type. the maximum body length of commercial motor vehicles,
trucks, is about 40m. Assuming that the vehicle speed is
IV. S YSTEM I MPLEMENTATION
typically between 15mph (6.7m/s) and 75mph (33.5m/s), the
We used off-the-shelf hardware to implement the proposed maximum time required for a vehicle to cross the line-of-sight
system. The Dell Precision M4400 integrated with Intel 5300 path is between 0.13s and 1.19s, according to the vehicle body
WiFi NIC was used as the receiver. This laptop had the 2.5GHz length statistics. Considering the maximum possible time, the
Intel Core Duo processer with 8GB of RAM and ran Ubuntu window sizes of 0.05s, 0.1s, 0.2s, and 0.3s were evaluated.
14.04.01 with kernel version of Ubuntu-3.13.0-32.57. We used The classification accuracy for passenger vehicles and trucks
the TP-Link TL-WR7500 WiFi router as the transmitter which in the local road with varying window sizes is depicted in
operated in the 802.11n AP mode with 2.4GHz frequency and Figures 11 and 12. The results for passenger vehicles show
20MHz bandwidth. The modified WiFi NIC driver developed that the accuracy increased slightly between the window sizes
by Halperin et al. [22] was adopted to collect raw CSI data at of 0.05s and 0.1s, and decreased thereafter. The reason for the
the sampling rate of 1,000 packets per second. decreased accuracy is that a larger window contains more CSI
The laptop and router were deployed on the roadside as values, and thus more irrelevant data are included that affect
shown in Figure 10. In order to collect the ground truth data the classification process. In case of trucks (Figure 12), the
1.0 1.0 1 1
TP TP FP
FP FP Accuracy
0.8 0.8 0.8 0.8
FP
Accuracy
Accuracy

Accuracy

Accuracy

Accuracy
0.6 0.6 0.6 0.6

0.4 0.4 0.4 0.4

0.2 0.2 0.2 0.2

0 0 0 0
0.05s 0.1s 0.2s 0.3s 0.05s 0.1s 0.2s 0.3s 0.125 0.12 0.115 0.11 0.105 0.1 0.09 0.055 0.05 0.045 0.04 0.035 0.030.02
Window size Window size Threshold Threshold

Fig. 11. Effect of the window size for Fig. 12. Effect of the window size for Fig. 15. Effect of threshold (local). Fig. 16. Effect of threshold (high-
passenger vehicles (local road). trucks (local road). way).

1.0 1.0
TP TP

0.8
FP
0.8
FP thresholds resulted in higher false positive rates. In other
words, CSI values dropped below the threshold even though
Accuracy

Accuracy

0.6 0.6
there was no passing vehicles since the threshold was set too
0.4 0.4
high. Thus, when the threshold was lowered, the accuracy
0.2 0.2 increased and the false positive decreased. Interestingly, the
0 0 accuracy, however, stopped increasing at certain threshold and
0.05s 0.1s 0.2s 0.3s 0.05s 0.1s 0.2s 0.3s
Window size Window size started to decrease. This result indicates that if the threshold
is too small, some vehicles that do not cause much variation
Fig. 13. Effect of the window size for Fig. 14. Effect of the window size for in CSI values are not detected. Consequently, we selected the
passenger vehicles (highway). trucks (highway).
thresholds for both the local road (0.1125) and the highway
(0.0425) that maximize the accuracy while minimizing the
accuracy increased for all window sizes. The reason can be false positive rates. In particular, the threshold for the highway
explained with the long body length of trucks, i.e., a small- was set a bit smaller than that for the local road because of
sized window did not completely capture the entire CSI values the faster vehicle speed on the highway.
for a truck.
Figures 13 and 14 display the classification accuracy for C. Vehicle Detection Accuracy
passenger vehicles and trucks in a highway environment with
varying window sizes. Compared with the local road case, it
1 1
was observed that the accuracy for passenger vehicles more
sharply decreased for window sizes greater than 0.1s. The 0.8 0.8

reason can be attributed to the fast vehicle speed on the


Accuracy

Accuracy
0.6 0.6
highway. Despite the rapid accuracy decrease for window sizes
of 0.2s and 0.3s, the overall accuracy for smaller windows 0.4 0.4

was slightly greater than the local road case. The reason can 0.2 0.2

be explained with the complex environment of the local road,


0 0
e.g., obstacles such as houses, trees, etc. A similar observation 0 100 200 300 400 0 100 200 300 400
Vehicle index Vehicle index
was made for trucks; an increase of about 3% in the accuracy
was obtained compared with the local road scenario. Fig. 17. Detection accuracy for local Fig. 18. Detection accuracy for high-
Given the classification accuracy data for the local road road. way.
with varying window sizes, window sizes of 0.1s and 0.3s
were selected for passenger vehicles and trucks, respectively Having determined the appropriate window size and the
for the rest of the experiments. Similarly, window sizes of threshold, this section evaluates the vehicle detection accu-
0.1s and 0.3s were selected for passenger vehicles and trucks, racy. More specifically, the accuracy was measured for 400
respectively for the highway environment. passing vehicles in both the local road and the highway
environments. Figures 17 and 18 depict the accumulative
B. Selection of Threshold average of the detection accuracy for the local road and
Another key system parameter is the threshold Δ𝑑 (Sec- the highway, respectively. It was observed that the average
tion III-C) that is used to detect a vehicle. Recall that when detection accuracy reached 93% and 95% for the local road
measured CSI value drops below Δ𝑑, a vehicle is detected. and the highway, respectively. Despite the faster vehicle speed
In this section, we perform experiments to understand the on the highway, the accuracy for the highway was greater
effect of the threshold and select appropriate thresholds for than the local road due mainly to obstacles around the local
both the local road and the highway. Figures 15 and 16 road. Another observation was that the accumulative average
depict the effect of the threshold for the local road and accuracy reached its peak value more rapidly in the highway
the highway, respectively. As shown in both figures, larger environment. The reason is similarly attributed to the noise
caused by obstacles like houses and trees around the local
road.

D. Vehicle Classification Accuracy

1 1

0.8 0.8

Accuracy
0.6
Accuracy

0.6

Fig. 23. Lane model for Lane 1 Fig. 24. Lane model for Lane 2
0.4 0.4
(highway). (highway).
0.2 0.2

0
0
0 100 200 300 400 0 100 200 300 400 (Lane 2) dropped more sharply compared with the other lane
Vehicle Index Vehicle Index
(Lane 1).
Fig. 19. Classification accuracy for Fig. 20. Classification accuracy for Figures 23 and 24 depict the two lane models for Lane 1
local road. highway. and Lane 2 of the highway. Similar to the results for the local
road, distinctive distributions were observed for the two lanes.
Once a vehicle is detected, classification is performed to It is worth to mention that we obtain different distributions for
categorize the vehicle type. Similar to the experiments for the different vehicle types because of unique vehicle body lengths
detection accuracy, the classification accuracy was measured and shapes, and it can be easily extended that lane models for
for 400 passing vehicles. The same window size and threshold other types of vehicles are established for higher lane detection
were used for this experiment. Figures 19 and 20 depict accuracy.
the accumulative average of the classification accuracy for
the local road and highway, respectively. WiTraffic quickly 100
converged to the peak classification accuracy of 92% and 80
Local
Highway

Accuracy (%)
96% for the local road and the highway, respectively. It
60
was observed that the complex environment around the local
road not only influenced the vehicle detection accuracy but 40

also the classification accuracy, resulting in the slightly lower 20


classification accuracy for the local road compared with the 0
highway. It was also observed that WiTraffic reached the 1 2
Vehicle Lane
peak classification accuracy more rapidly in the highway
environment. Fig. 25. Lane detection accuracy for local road and highway.

E. Vehicle Lane Detection Accuracy The generated models were used to evaluate the vehicle lane
detection accuracy. Figure 25 depicts the average lane detec-
tion accuracy for a passenger vehicle in both lanes. Regardless
0.5 0.5
of lanes, the average lane detection accuracy was about 90%
0.4 0.4 in both the local road and the highway. It was observed that
the average detection accuracy for Lane 2 (95.34%) was about
0.3
Percent

0.3
3.5% higher than that for Lane 1. The reason is because Lane
Percent

0.2 0.2 2 was close to the access point which interrupted the line-of-
0.1 0.1
sight signal more significantly, thereby having more distinctive
signal patterns. Another observation was that the lane detection
0
0 5 10 15 20
0
0 5 10 15 20 accuracy for the highway was slightly higher compared with
CSI bins CSI bins
the local road due to the environmental factors around the local
Fig. 21. Lane model for Lane 1 (local Fig. 22. Lane model for Lane 2 (local road, e.g., houses, pedestrians, and trees, etc.
road). road).
F. Speed Estimation Accuracy
In this section, the vehicle lane detection accuracy is eval- In this section, the vehicle speed estimation accuracy is
uated. For this experiment, we generated lane models for a evaluated. We adopted the Bushnell velocity gun (model
passenger vehicle. A lane model is individually defined for 101911) to obtain the ground truth speed data. To calibrate
each lane. Figures 21 and 22 depict the two lane models for this device, we compared the vehicle speed measured with
Lane 1 and Lane 2 of the local road, respectively. As shown, the velocity gun to the speed data obtained from the vehicle
the two lane models exhibit clearly different distributions of speedometer. The results indicate that the average error was
CSI values. More specifically, it was observed that CSI values around 1mph. We then trained speed models for passenger
of a vehicle on the lane that was closer to the access point vehicles for the highway.
80 B. Over-Road-Base Solutions

70
To address the drawbacks of intrusive approaches, over-
Speed (mph)
road-based solutions deploy sensors (e.g.,, video image proces-
60 sors, ultrasonic sensors, radar sensors, and acoustic sensors)
50 either above or alongside the roadway.
Ground Truth Video based: With the significant progress in computer
40 Estimated vision, the video camera has been a rich source for vehi-
30 cle detection and surveillance over the last 30 years. The
0 5 10 15 20
appearance-based methods were developed to detect traf-
Vehicle Index
fic [5][30][31][32]. Some proposed motion-based approaches
Fig. 26. Speed estimation accuracy. to detect moving vehicles [33][34][35]. Major challenges for
video-based surveillance systems are weather and lighting
conditions, and vehicle occlusion.
Given the speed models, the vehicle speed was estimated. Ultrasonic based: Oudat et al. [6] has developed a traffic
The estimated vehicle speed was compared with the ground monitoring system based on the combination of ultrasonic
truth data measured with the speed gun. Figure 26 depicts ragefinders and multiple infrared temperature sensors. These
the results for highway. The results show that the root-mean- sensors are low cost and easy to manage. However, it has low
square error (RMSE) for the vehicle speed estimation in the accuracy for multi-lane low-traffic flows primarily due to its
highway was about 5mph. It is worth to note that higher speed limited range [36].
estimation accuracy can be obtained with more sophisticated RADAR or LIDAR technology-based: Radar and camera
vehicle classification models defined for various kinds of data are typically fusioned to perform vehicle detection in
vehicle types. different fusion levels [37]. Radar is used to locate interest
areas of an image to expedite the image processing speed.
However, these systems are very expensive due to their ad-
VI. R ELATED W ORK
vanced processing circuitry.
The traffic monitoring systems can be largely classified Infrared Detectors: Active and passive infrared detectors
into three categories: in-road-based, and over-road-based, and capture the energy change measured from the road surface in
aerial-sensor-based approaches. the absence of a vehicle [2][38].The advantages of infrared
detectors are that they can be operated during both day and
night. Disadvantages are that infrared detectors are sensitive
A. In-Road-Based Solutions to inclement weather conditions and ambient light.
The in-road-based solutions embed sensors in the pavement Acoustic Sensor-based: A microphone array is used to
of a roadway. These sensors include inductive loop detectors, collect road-side acoustic signals, and acoustic features are
magnetometers, weigh-in-motion sensors, and tape switches. extracted to perform traffic monitoring [39]. However, these
approaches are easily affected by noise.
Loop Detectors: Loop detectors have been the most widely
used sensors for traffic monitoring due to their mature technol- C. Aerial-sensor-based
ogy and large experience base. This well understood technol- Recently satellite images and drones are used to capture
ogy can obtain traffic count, vehicle classification, and vehicle road images, and extract traffic information via image pro-
speed [24][25][3]. Although loop detectors usually provide cessing [7]. These approaches, however, suffer from spatio-
accurate results, they are typically very costly to install. temporal limitations. The operation time is limited due to
Magnetometers: To improve the vehicle classification ac- the limited coverage and limited battery power. In addition,
curacy of loop detector-based systems (e.g., for non-axle-based maneuverability and wireless network communication are two
vehicle classification), magnetometer-based systems were in- key challenges for UAV-based traffic monitoring systems.
troduced. For instance, Cheung et al. used magnetometers
that were glued to the center of a lane [26]. There are other VII. C ONCLUSION
solutions that install megnetometers on the roadside [4][27]. We have presented the WiFi-based traffic monitoring system
Accelerometers: Accelerometer-based approaches are that provides essential functionalities of a traffic monitor-
based on the measurement of vibrations of the pavement when ing system including vehicle detection, vehicle classification,
a vehicle’s wheels move across the accelerometer [28][29]. vehicle lane detection, and vehicle speed estimation. Real-
These solutions are dependent on the accuracy of vehicle world experimental results demonstrate that the proposed
speed measurement. For example, Ma et al. utilized the system achieves high vehicle classification and lane detection
magnetometer to measure the vehicle speed [28]. Although accuracy in both the local road and the highway settings. The
this is less costly solution compared with the loop detectors, results further show that the proposed speed estimation method
they are difficult to install and have the energy provision is promising and can be improved significantly with more
issue. sophisticated vehicle classification models.
WiTraffic is a suitable solution for roads with low traffic [17] Z. Yang, Z. Zhou, and Y. Liu, “From rssi to csi: Indoor localization
volumes such as rural highways for which the number of via channel response,” ACM Computing Surveys (CSUR), vol. 46, no. 2,
p. 25, 2013.
deployed traffic monitoring systems is limited due to the [18] Y. Zeng, P. H. Pathak, C. Xu, and P. Mohapatra, “Your ap knows how
cost issue. We hope that the extremely low cost of WiTraffic you move: fine-grained device motion recognition through wifi,” in Proc.
will address this cost issue enabling DOTs to deploy a large of HotWireless, 2014.
[19] K. Wu, J. Xiao, Y. Yi, M. Gao, and L. M. Ni, “Fila: Fine-grained indoor
number of traffic monitoring systems. Unfortunately, however, localization,” in Proc. of INFOCOM, 2012.
WiTraffic will perform poorly on crowded city highways due [20] C.-C. Chang and C.-J. Lin, “LIBSVM: A library for support
to a large portion of ‘overlapped vehicles’. Our future work is vector machines,” ACM Transactions on Intelligent Systems and
Technology, vol. 2, pp. 27:1–27:27, 2011, software available at
to extend WiTraffic to make it accurately identify and classify http://www.csie.ntu.edu.tw/∼cjlin/libsvm.
overlapped vehicles and to perform lane detection and speed [21] Y. Rubner, C. Tomasi, and L. J. Guibas, “The earth mover’s distance as
estimation for overlapped vehicles. Another future work is a metric for image retrieval,” International journal of computer vision,
vol. 40, no. 2, pp. 99–121, 2000.
to improve the performance of WiTraffic by developing new [22] D. Halperin, W. Hu, A. Sheth, and D. Wetherall, “Tool release: gathering
features based on the amplitude and phase information of WiFi 802.11 n traces with channel state information,” ACM SIGCOMM
CSI, and by generating models (i.e., lane/speed models) for Computer Communication Review, vol. 41, no. 1, pp. 53–53, 2011.
[23] O. of Freight Management and Operations, “Federal size regulations for
more vehicle classes such as minivans or pickup trucks. commercial motor vehicles,” U.S. Department of Transportation Federal
Highway Administration, Tech. Rep., 2004.
ACKNOWLEDGMENTS [24] B. Coifman, “Using dual loop speed traps to identify detector errors,”
Transportation Research Record: Journal of the Transportation Research
This research was supported in part by the DGIST R&D Board, no. 1683, pp. 47–58, 1999.
Program of MSIP of Korea (CPS Global Center) and the [25] C. Chen, J. Kwon, J. Rice, A. Skabardonis, and P. Varaiya, “Detecting
Global Research Laboratory Program through NRF funded by errors and imputing missing data for single-loop surveillance systems,”
Transportation Research Record: Journal of the Transportation Research
MSIP of Korea (2013K1A1A2A02078326). Board, no. 1855, pp. 160–167, 2003.
[26] S. Cheung, S. Coleri, B. Dundar, S. Ganesh, C.-W. Tan, and P. Varaiya,
R EFERENCES “Traffic measurement and vehicle classification with single magnetic
[1] L. E. Y. Mimbela and L. A. Klein, “Summary of vehicle detection sensor,” Transportation research record: journal of the transportation
and surveillance technologies used in intelligent transportation systems,” research board, no. 1917, pp. 173–181, 2005.
Federal Highway Administrations Intelligent Transportation Systems [27] R. Wang, L. Zhang, K. Xiao, R. Sun, and L. Cui, “Easisee: Real-time
Joint Program Office, Tech. Rep., 2007. vehicle classification and counting via low-cost collaborative sensing,”
[2] L. A. Klein, M. K. Mills, and D. R. Gibson, “Traffic detector handbook,” IEEE Transactions on Intelligent Transportation Systems, vol. 15, no. 1,
Federal Highway Administration, Tech. Rep., 2006. pp. 414–424, 2014.
[3] H. X. Liu and J. Sun, “Length-based vehicle classification using event- [28] W. Ma, D. Xing, A. McKee, R. Bajwa, C. Flores, B. Fuller, and
based loop detector data,” Transportation Research Part C: Emerging P. Varaiya, “A wireless accelerometer-based automatic vehicle classifica-
Technologies, vol. 38, pp. 156–166, 2014. tion prototype system,” IEEE Transactions on Intelligent Transportation
[4] B. Yang and Y. Lei, “Vehicle detection and classification for low- Systems, vol. 15, no. 1, pp. 104–111, 2014.
speed congested traffic with anisotropic magnetoresistive sensor,” IEEE [29] E. Levenberg, “Estimating vehicle speed with embedded inertial sen-
Sensors Journal, vol. 15, no. 2, pp. 1132–1138, 2015. sors,” Transportation Research Part C: Emerging Technologies, vol. 46,
[5] B. Tian, B. T. Morris, M. Tang, Y. Liu, Y. Yao, C. Gou, D. Shen, pp. 300–308, 2014.
and S. Tang, “Hierarchical and networked vehicle surveillance in its: [30] X. Ma and W. E. L. Grimson, “Edge-based rich representation for
a survey,” Intelligent Transportation Systems, IEEE Transactions on, vehicle classification,” in Proc. of ICCV, 2005.
vol. 16, no. 2, pp. 557–580, 2015. [31] L.-W. Tsai, J.-W. Hsieh, and K.-C. Fan, “Vehicle detection using
[6] E. Oudat, M. Mousa, and C. Claudel, “Vehicle detection and classifica- normalized color and edge map,” Image Processing, IEEE Transactions
tion using passive infrared sensing,” in Proc. of MASS, 2015. on, vol. 16, no. 3, pp. 850–864, 2007.
[7] K. Kanistras, G. Martins, M. J. Rutherford, and K. P. Valavanis, “Survey [32] R. S. Feris, B. Siddiquie, J. Petterson, Y. Zhai, A. Datta, L. M. Brown,
of unmanned aerial vehicles (uavs) for traffic monitoring,” in Handbook and S. Pankanti, “Large-scale vehicle detection, indexing, and search in
of Unmanned Aerial Vehicles. Springer, 2015, pp. 2643–2666. urban surveillance videos,” Multimedia, IEEE Transactions on, vol. 14,
[8] C. Han, K. Wu, Y. Wang, and L. M. Ni, “Wifall: Device-free fall no. 1, pp. 28–42, 2012.
detection by wireless networks,” in Proc. of INFOCOM, 2014. [33] R. Cucchiara, M. Piccardi, and P. Mello, “Image analysis and rule-based
[9] W. Xi, J. Zhao, X.-Y. Li, K. Zhao, S. Tang, X. Liu, and Z. Jiang, “Elec- reasoning for a traffic monitoring system,” Intelligent Transportation
tronic frog eye: Counting crowd using wifi,” in Proc. of INFOCOM, Systems, IEEE Transactions on, vol. 1, no. 2, pp. 119–130, 2000.
2014. [34] S. Gupte, O. Masoud, R. F. Martin, and N. P. Papanikolopoulos,
[10] K. Ali, A. X. Liu, W. Wang, and M. Shahzad, “Keystroke recognition “Detection and classification of vehicles,” Intelligent Transportation
using wifi signals,” in Proc. of Mobicom, 2015. Systems, IEEE Transactions on, vol. 3, no. 1, pp. 37–47, 2002.
[11] J. Zhang, B. Wei, W. Hu, and S. S. Kanhere, “Wifi-id: Human identifi- [35] S.-H. Yu, J.-W. Hsieh, Y.-S. Chen, and W.-F. Hu, “An automatic
cation using wifi signal,” in Proc. of DCOSS, 2016. traffic surveillance system for vehicle tracking and classification,” in
[12] J. Xiao, K. Wu, Y. Yi, L. Wang, and L. M. Ni, “Pilot: Passive device-free Scandinavian Conference on Image Analysis, 2003.
indoor localization using channel state information,” in Proc. of ICDCS, [36] Y. Jo and I. Jung, “Analysis of vehicle detection with wsn-based
2013. ultrasonic sensors,” Sensors, vol. 14, no. 8, pp. 14 050–14 069, 2014.
[13] Y. Wang, J. Liu, Y. Chen, M. Gruteser, J. Yang, and H. Liu, “E-eyes: [37] G. Alessandretti, A. Broggi, and P. Cerri, “Vehicle and guard rail
device-free location-oriented activity identification using fine-grained detection using radar and vision data fusion,” IEEE Transactions on
wifi signatures,” in Proc. of Mobicom, 2014. Intelligent Transportation Systems, vol. 8, no. 1, pp. 95–105, 2007.
[14] N. Kassem, A. E. Kosba, and M. Youssef, “Rf-based vehicle detection [38] T. M. Hussain, T. N. Saadawi, and S. A. Ahmed, “Overhead infrared
and speed estimation,” in Proc. of VTC, 2012. sensor for monitoring vehicular traffic,” IEEE transactions on vehicular
[15] A. Al-Husseiny and M. Youssef, “Rf-based traffic detection and identi- technology, vol. 42, no. 4, pp. 477–483, 1993.
fication,” in Proc. of VTC, 2012. [39] Y. Na, Y. Guo, Q. Fu, and Y. Yan, “An acoustic traffic monitoring system:
[16] Z.-P. Jiang, W. Xi, X. Li, S. Tang, J.-Z. Zhao, J.-S. Han, K. Zhao, Design and implementation,” in Proc. 12th IEEE Int. Conf. Ubiquitous
Z. Wang, and B. Xiao, “Communicating is crowdsourcing: Wi-fi indoor Intell. Comput, 2015.
localization with csi-based speed estimation,” Journal of Computer
Science and Technology, vol. 29, no. 4, pp. 589–604, 2014.

You might also like