SlideShare a Scribd company logo
1 of 12
Download to read offline
1
Online/Offline Lane Change Events Detection
Algorithms
Eid Arrache, Feras Tanan and Ousama Esbel
Abstract—in this paper, We are presenting two algo-
rithms for lane change detection. The first one is used
for online detection (real-time detection) with accuracy of
85% and the other one is used for offline detection with
accuracy of 95%. The main purpose of the offline detection
algorithm is to find at which GPS locations the number
of happened left/right lane changes.
For the purpose of these algorithms we used the
”crowd-sensing” approach which means that the sensors of
different mobile devices that were fixed in different cars
are the sources of input data for the above mentioned
algorithms. Specifically speaking, we used Accelerometer
and Gyroscope sensors. We also presented an algorithm
for blinker pattern extraction using the microphone sensor.
Keywords: Pattern Extraction, Lane Change detection,
Accelerometer, Gyroscope and Crowd Sensing
I. MOTIVATION AND INTRODUCTION
One of the most important things for driver-less
vehicles (autonomous cars for example) is to have
background knowledge about the streets, highways,
and roads they drive on. This background knowl-
edge is contained in high accurate street maps. So
autonomous cars will need these maps in order
to know how to navigate through roads. The data
which is used to get the background knowledge
should be collected in an efficient way which is
not energy-consuming, then the collected data has
to be processed offline in order to make it useful
data which in turn should be used to enhance the
high accurate street maps to be used by driver-less
vehicles to understand what’s happening on their
ways and to understand the nature of these ways.
The useful data that will be visualized on the
maps is called driver’s behaviors. Driver’s Behaviors
mean the reaction the driver does in responding to
the current road conditions lying ahead of him. For
example, if the driver faces a construction site, then
he must change the current lane which he is driving
through, for example, the driver makes a right lane
change or a left lane change in order to avoid the
construction site. This left and right lane change is
some kind of driver behavior driver behavior.
The high accurate street maps are highly dynam-
ically. It must be dynamic maps. Otherwise, these
maps will be outdated quickly. That is why we will
use sensors of smart phones of which are fixed in
different cars to extract drivers behavior to generate
background knowledge about the current driving
conditions on this road segment to keep the maps
updated. This approach is called crowd-sensing. So
we can use large amount of the smart phones of
the cars driving through certain road. Using this
approach, even older cars or motor cycles could
participate in the crowd sensing not only automated
cars which are equipped with fancy sensor equip-
ment. Then, the generated data would be processed
offline to update the streets maps.
Among the many technologies which make au-
tonomous vehicles possible is a combination of
sensors and actuators, sophisticated algorithms, and
powerful processors to execute software. The sen-
sors and actuators in an autonomous vehicle fall into
three broad categories: 1) navigation and guidance;
2) driving and safety and 3) performance (man-
aging the car’s basic internal systems).There are
dozens of subsystems and hundreds of specialized
sensor channels for these three categories [1]. The
approach of adding specialized hardware to the
vehicle is too expensive because then lots of sensing
hardware must be added in order to detect the paths
that should be used to drive through. However, in
case of using the background knowledge in the
streets maps, it is not expensive and it may be more
accurate because these maps are generated by a
crowd-sensing approach which means that different
cars contribute to describing the nature of the street.
In this paper we are limiting the scope of achiev-
ing the autonomous driving to the specific driving
behavior introduced through a lane change. We are
going to present an efficient approach which can tell
the driver less cars where they should do a left or
2
right lane change based on predefined map.
Lane-level positioning systems for cars represent
the next generation for outdoor navigation, where
systems will not only predict the car location on
the road but also its exact driving lane. This fine
granularity is required for a wide range of emerging
applications including advanced driver assistance
Systems (ADASs) [2].
There were some Computer visions based ap-
proaches [3] which tried to detect if a car is doing
lane change using the mobile devices’ cameras. If
the car is crossing the lane markers then this con-
sidered as a lane change. But some [12] argued that
this is not a complete solution because the markers
may be unclear at some parts of the road due to
some bad weather conditions or any other reason.
Furthermore, it is an extensive energy consuming
approach which requires much effort to process all
of the images captured.
Due to the high spread of smart phones among
people, these smart phones could be used for further
than their basic purposes. Smart phones contain sen-
sors like accelerometer, gyroscope, compass, mag-
netometer... etc. which provide lots of data about the
device itself as well as the surrounding environment,
for example, accelerometer provides data about the
speed of movement of the smart phone regarding
the three axis x, y and z. So when we fix the
smart phone in a certain situation in a moving
car, the data which is read by the smart phones’
sensors can be considered as data describing the car
behavior because the smart phone is moving and
acting the same way the car does it really. So in
this way we can replace some specialized expensive
hardware and sensors by available cheap already-
existing sensors in order to gather the data about
the moving car.
In this paper we are presenting an online ap-
proach which can detect the lane change in real
time through an android application that uses ac-
celerometer, gyroscope and microphone to detect
the lane change. We are also presenting an efficient
offline approach to make driverless vehicles able to
know where they should make a left or right lane
change. As mentioned we are using smartphones
sensors to collect data that contain knowledge about
the drivers behaviors. In order to come up with
a correct driver behavior, we are collecting huge
amounts of data using about twenty smartphone
devices . After collecting these amounts of sensors
data of the smartphones which are fixed in the
cars, the collected data can be processed offline
to extract the knowledge and interpret the drivers
behaviors contained in the collected data in order to
visualize the behaviors on the maps again to provide
driverless vehicles with previous knowledge (drivers
behaviors) about the streets they are driving on.
The rest of the paper is structured as follows:
In section ii) we are presenting related work and
discussing what has already be done in the same
context and in section iii) System approach we will
discuss our approach in terms of design, implemen-
tation and evaluation. After that in section iv) Con-
clusion we will sum up what we have contributed
to this context. Then in section v)Future Work, we
will present how our work can be extended.
II. RELATED WORK
In this section, we are presenting what has already
be done in the context of lane-detection systems.
Moreover we will discuss these previous research
in terms of some factors like: energy consumption
and accuracy.
The first work is ”LaneQuest”: An Accurate and
Energy-Efficient Lane Detection System which is
a system that leverages the ubiquitous and low-
energy inertial sensors available in commodity
smart-phones to provide an accurate estimate of the
cars current lane [4]. So the main purpose of this
system is to know at which lane the car is driving
now. The intersection between what we are doing
at our research project and LaneQuest is precisely
that LaneQuest identifies at a certain phase the lane
changes either to right or to left in order to get an
idea at which lane the car is driving now.
Basically, LaneQuest system is composed of four
main components: 1) Preprocessing Module: at this
Module, the system collect data from the energy-
efficient inertial sensors in the smartphone (ac-
celerometer, gyroscope and magnetometer), then it
processes this collected data to reduce noise effect
by applying Low-pass Filter), 2) Event Detection
Module: what meant by event is exactly what we
mean by drivers behavior in our case. At this Mod-
ule LaneQuest tries to identify some events which
may be used to estimate the current lane of the car.
So here LaneQuest tries to identify lane change. 3)
Probabilistic Lane Estimation Module: LaneQuest
uses Markov localization to maintain probability
3
distribution over all possible lanes. 4) Organic Lane
Anchors Updates Module: This module is responsi-
ble for estimating the location.
The lane change detection module of LaneQuest
is to use the data collected by the accelerometer sen-
sor of the smartphone which is fixed at the moving
car to extract the pattern of the lane change whether
it is a right lane change or a left lane change.
When the car changes the lane it drives on some
very clear changes appear in the readings of the
accelerometer sensor. LaneQuest uses the approach
provided by Marvel: multiple antenna based relative
vehicle localizer [5].
Regarding this approach, tests showed that it is
acceptable and can detect the most of the real lane
changes the driver does, however it depends on
some experimental values like Threshold, highest
peak, lowest peak of the data coming from the
accerlerometer. Moreover the accelerometer sensor
is very noisy in general which means that there is
some obvious noise in its readings which makes it
somehow inaccurate to depend on it alone in lane
change detections. To sum up, it is inevitable to use
accelerometer sensor but we need to support it by
using other techniques.
The Second related work we would like to present
and discuss here is Using Mobile Phone Sensors
to Detect Driving Behavior [6]. In this research
the authors implemented an android application that
is able to adjust the driver behavior by giving
indicators about the driving behavior of the driver.
They used the approach of fixing a smartphone
device in the car in order to use the sensors of
this device to collect the data to be processed
in order to extract pre-defined patterns of some
driving behaviors. They used GPS, accelerometer
and microphone as a combination in order to collect
data.
[6] built an application in two phases; the first one
is collecting data about the different driving behav-
iors specifically: speed breaker, indicator (blinker),
left/right turn, left/right lane change, reverse and
horn. Those collected data represent patterns of
the mentioned driving behaviors. So in the online
detection algorithm which is used in this research
they would use those patterns as a ground truth to
compare the coming data with. We can say that
lane detection in this research is more accurate than
the first research we presented because [6] uses
accelerometer as well as microphone in order to
detect lane change pattern from accelerometer data
and blinker pattern from microphone data. On the
other hand [4] uses only the data coming from the
accelerometer.
Regarding this approach [6], we can still argue
that running the microphone all the way is highly
energy-consuming. So there should be a way to
still benefit from the presence of microphone but
not to keep it recording all the way. Moreover its
not clear in this research how the recorded data
is filtered especially the microphones data. This
approach could also be furthermore supported in
decision taking.
The approach [7] for lane detection is used as
a driver assistant to increase the safety especially
in traffic conditions. It is a vision-based approach
which uses a video camera mounted on the moving
car. The camera is used to capture images of the
lanes on the way. After that, the recorded video
of the camera is transferred to a high powered
computer in order to manipulate the frames of the
video so that everything in the frame is turned to
black pixels but the lanes markings. So after that the
frame would contain only the lanes of the road. But
before that, a noise-filtering algorithm is performed
in order to get rid of all the noise in the image. The
output of this system is warnings to the driver if he
exceed the lanes.
The approach [7] implements a very complex
algorithm which can perform in different situations
such as: rainy weather or darkness which means that
the lane change is detected at a very good accuracy.
But this approach is a very high energy-consuming
approach because it needs to run the camera all
over the time when the car is driving. Moreover
it requires real-time processing for videos.
The approach [8] is concerned with detection
the intention of drivers to do a lane-change. [8]
presents a novel methodology for inferring driver
intentions using model tracing. Model tracing means
to observe the actual driver behavior and compare
it to intentions. At the same time, the system gath-
ers observable data from the driver and compares
each models simulated behavior with the drivers
actual observed behavior. In doing so, model trac-
ing determines the best matching model and thus
infers the drivers most likely current intention. We
are concerned with the part of observing actual
driver behavior (observing actual lane change). At
this approach, the data is collected using different
4
instruments. Thats why [8] considers the car as
an instrumented car. So First of all the types of
data collected are: steering wheel angle; accelerator
depression; lateral position; longitudinal distance
and time headway to a lead vehicle; longitudinal
distance, front and back, to vehicles in adjacent
lanes; and the presence or absence of a lane to the
left and right of the current travel lane.
Then the next step is passing these data to a
system which construct the behavioral models and
runs them simultaneously. We can say that this
approach is accurate however it is not cheap because
specialized instruments are required to gather the
data about the driver behavior and the surrounding
environment.
In Approach [9], the authors are doing drive
analysis using vehicle dynamics and vision-based
lane semantics basing on the concept of Naturalistic
Driving Studies (NDS). NDS means capture large
volumes of drive data from multiple sensor modal-
ities, which are analyzed for critical information
about driver behavior and driving characteristics.
The main purpose of [9] is to gather large amounts
of information about the driving in highways to
process these information offline to know some
characteristics of the driving way that lead to ac-
cidents. In approach [9], the authors focus on the
lane change event detection. For that, they used in-
vehicle Control Area Network (CAN bus), inertial
motion unit (IMU), global positioning system (GPS)
and Camera. In order to detect lane changes hap-
pened during the drive, the scan bands in the near
view of the vehicle are processed. This is because a
lane change is characterized by the position of the
vehicle with respect to the lane positions in the near-
view of the vehicle. They consider the lane feature
positions so the position of the left lane marking
appears to move towards the right as the vehicle
makes the left lane change. Similarly, during a right
lane change, the right lane marker moves to the left
with respect to the vehicle. These observations are
used to detect the lane change events.
Concerning approach [9], we can indicate that it
is a robust approach. But using the camera sensor is
energy-consuming which means that the efficiency
of this approach still is a point to discuss.
To sum up, we have discussed different research
work in the literature of lane change detection
domain in terms of accuracy, energy-consumption,
and robustness. What we achieved in our research
work is a lane change detection approach which
is accurate, efficient and robust. Moreover, we im-
plemented this approach to work online (real-time
lane change detection) using android platform and
also offline in order to get indicators of where the
drivers have done lane changes in order to enhance
the street maps to be used by driver-less cars.
III. SYSTEM APPROACH
In this section, we are going to present our
approach to solve the problem of lane change event
detection. The approach we developed is efficient,
accurate, and robust as we will see in the evaluation
section. This section is divided into the following
sections:
• Overview.
• Data collection.
• Online lane change events detection approach.
• Offline lane change events detection approach.
• Evaluation.
A. Overview
We developed our lane change event detection ap-
proach basing on the three factors we have discussed
earlier in the related work section which are:
• Efficiency.
• Accuracy.
• Robustness.
Our approach is efficient because it doesn’t require
special dedicated hardware equipment like (instru-
mented cars for example) rather it only depends
on sensors of smart phones which are expected
to be existing at many cars already. Using the
already existing sensors means making a new use
of them rather than their basic obvious purposes.
Our approach is also accurate since it detects real
lane changes with very high accuracy as we will
see in the evaluation. Moreover, our approach is
robust since it detects smooth or harsh lane changes.
Since our main purpose of this project is providing
data about some locations where lots of cars made a
right or left lane change to enhance the street maps
with data, we developed an offline procedure to deal
with large amounts of the data to interpret data into
meaningful data to know where the lane changes
where made. We also developed an online real time
procedure which can detect lane changes in real time
using android platforms.
5
B. Data Collection
The whole project is about processing data and
providing data. The input of this project is a large
amount of raw sensor data. The data set itself
consists out of the readings of the sensors of the
mobile devices which are fixed in the car in a way so
that the 3 axes of each mobile device are considered
as the axes of the moving car itself. Moreover, we
used different orientation of the devices we The
sensors which we used to gather data are:
• Accelerometer.
• Gyroscope.
• Microphone.
Regarding the accelerometer and Gyroscope, we
have three fields in the data file for each of them
because for each sensor we have readings from three
different axes (x, y and z). Regarding the GPS we
have two fields which are longitude and latitude.
These two fields represent the location of the car
and will be used to tell the location where the lane
change happened. Finally, the microphone data will
be used to detect the blinker sound in order to
support the decision that a lane change is happening
because usually the driver turns the blinker on when
he makes left or right lane change.
One important thing about data collection is fil-
tering. Because the sensors of the smart phones
are so sensitive hardware, then their readings may
contain some noise. That is why a filtering process
is required. The filtering approach which is used
in data collection here has the following logic:
gather 20 readings of each sensor, then calculate the
average of these readings and record this average
value as a representative of all the 20 values. In this
way we are smoothing the values to be realistic and
readable.
The Data Collection phase took about three
months on daily basis approximately so we have
now very large amounts of data divided into separate
files that can be used in the offline process which
we will discuss later.
C. Online lane change approach
The online lane change detection algorithm
means that the same android device itself which
gathers the data of its sensors is able to tell if a
left or right lane change happened in real time. In
the online lane change approach we are using three
main components to take the decision:
Fig. 1. A car doing a lane change will have to make a small rotation
around the z-axis, leading to a change in its x-axis acceleration.
source is [4]
Fig. 2. A left lane change causes a specific pattern on the x
acceleration. The pattern is reversed for right lane change. source
is [4]
• Accelerometer.
• Gyroscope.
• Microphone.
1) Accelerometer: A number of techniques in lit-
erature proposed using the phone inertial sensors to
detect the car lane change event [5], [10]. The idea
is that for the car to change its lane, it experiences
a change in its direction (Figure 1), which causes
a rotation around the z-axis of the accelerometer
(for the oriented phone) and affects mainly the x-
acceleration [11].
In the case of fixing the mobile device in a way
so that the z-axis of the mobile device has the same
direction of the Gravity axis and the y axis of the
mobile device has the same direction of the speed
axis of the car then:
We have two types of lane change:
• Left lane change.
• Right lane change.
Left lane change:
If the car is making a left lane change then x-
acc readings will witness a sudden decrease to a
very low value which can be obviously noticed
comparing to previous stable values of this field.
Then and after a very short period of time, the value
6
of this x-acc will increase to a higher value than
the average value of this field, after that when the
car has already moved to the left lane, the value
of this field will decrease to approximately equal
the average value of it as long as the car is moving
straightforward, Figure 2(a) shows the readings of
the x-accelerometer when the car is doing a left lane
change. To capture this pattern, we use a slightly
modified version of the approach proposed by [5],
where we detect the maximum and minimum peaks
within a window. If the difference between the two
peaks exceeds a certain threshold which is in our
case is 1 and they are close to each other which
means the difference between the times of the two
peaks is less than 2.7s (this value is defined basing
on experiments), we detect a left lane change event
on the accelerometer.
Right lane change:
If the car is making a right lane change then x-
acc readings will witness a sudden increase to a
very high value which can be obviously noticed
comparing to previous stable values of this field.
Then and after a very short period of time, the value
of this x-acc will decrease to a lower value than the
average value of this field among all of its readings,
after that when the car has already moved to the
right lane, the value of this field will increase to
approximately equal the average value of it as long
as the car is moving straightforward.
Figure 2(b) shows the readings of the x-
accelerometer when the car is doing a right lane
change. The approach which can be used to detect
a right lane change is the same as the one used for
detecting the left lane change. We can figure out if
the detected lane change is left or right depending
on the following strategy:
• If the first peak of the lane change is the high
one, then it is a right lane change.
• If the first peak of the lane change is the low
one, then it is a left lane change.
2) Gyroscope: In our online approach for lane
change events detection, we also processed the
readings coming from the Gyroscope sensor in order
to engage the Gyroscope sensor in the process of
decision taking in terms of the lane change event
detection. Which makes this process more robust
and more accurate because now we have two sensors
responsible for telling whether a certain reading case
is a lane change or not.
Actually, when the car moves from a lane to an-
other one, some changes also appear on the readings
of the Gyroscope sensor. These changes can be used
in order to detect the lane change happening.
In the case of fixing the mobile device in a way
so that the z-axis of the mobile device has the same
direction of the Gravity axis and the y axis of the
mobile device has the same direction of the speed
axis of the car then:
Left lane change:
Fig. 3. A left lane change causes a specific pattern on the z
Gyroscope. The pattern is reversed for right lane change. this figure
is generated basing on our real life data
When the car is doing a left lane change, then
the readings of the Gyroscope in the z axis changes
noticeably. For a left lane change, the first peak of
the lane change will be noticed to be the higher
one and the other peak of the lane change will be
noticed to be the lower one. Figure 3 shows a left
lane change affects the Gyro z-axis.
Right lane change: When the car is doing a right
lane change, then the readings of the Gyroscope in
the z axis changes noticeably. same as left the first
peak of the lane change will be noticed to be the
lower one and the other peak of the lane change will
be noticed to be the higher one. Figure 4 shows a
right lane change affects the Gyro z-axis. ,
Note: Figure 3 and Figure 4 are drown from our
real life data sets which means The graphs therefore
are influenced by the noise of the sensor readings.
3) Online lane change detection algorithm: With
this sensor setup we were now able to write the
algorithm which combines both the Gyroscope and
the Accelerometer processing.
7
Fig. 4. A right lane change causes a specific pattern on the z
Gyroscope. this figure is generated basing on our real life data
Fig. 5. ”s2” situation of mobile device orientation
we will present the algorithm then we will discuss
it.
Algorithm 1 is pretty simple and efficient.
first of all we give the driver the flexibility
to fix the mobile device in the car in three dif-
ferent situations. the procedure CheckMobileDe-
vice(GYROFlag,ACCFlag) is checking these three
possibilities:
• s1= If z axis of the mobile device has the same
direction as the gravity AND y axis has the
same direction as the speed direction of the
car, then we should read data from x axis of
accelerometer and z axis of Gyroscope.
• s2= If x axis of the mobile device has the same
direction as the gravity AND z axis has the
same direction as the speed direction of the
Fig. 6. ”s3” situation of mobile device orientation
car, then we should read data from y axis of
accelerometer and x axis of Gyroscope.
• s3= If y axis of the mobile device has the same
direction as the gravity AND z axis has the
same direction as the speed direction of the
car, then we should read data from x axis of
accelerometer and y axis of Gyroscope.
Now after detecting the source of the data we
read data and fill it in small windows for both the
Accelerometer and the Gyroscope, Then we check
in each of the small windows whether a window
has a lane change or not. Small windows are used
to detect harsh lane changes and big windows are
used to gather small windows which don’t have lane
changes in order to detect smooth lane changes. If it
has a lane change then we store information about
this lane change (time and location, we store the info
for lane changes for accelerometer and gyroscope in
GYROLanes and ACCLanes respectively.
AHASLAneChange is a procedure for checking
if a window which has data coming from the
accelerometer sensor has a lane change or not
according to the following formulas:
AltitudeV ariance = highestPeak −
lowestPeak
TimeV ariance =
Max(t(highestPeak), t(lowestPeak) −
Min(t(highestPeak), t(lowestPeak)
if
(AltitudeV ariance > 1)
and
(TimeV ariance < 2.7)
Then it is a lane change.
8
GHASLAneChange has the same logic but dif-
ferent thresholds:
if
(AltitudeV ariance > 0.0075)
and
(TimeV ariance < 2.7)
Then it is a lane change.
and in case this small windows don’t have any
lane change then we store the small window in a
larger window to read another small window. When
we read another small window and this one again
does not have any lane change then we add it also
to the large window to check it with the previous
small window.
when the big window is filled and no lane change
has been detected we empty it to make space for
the new coming small windows. Any time we find
a lane change we record its info in the appropriate
vector.
after we extract the lane changes, we make a
voting process between the accelerometer and the
gyroscope. So we scan both vectors AccLanes and
GYROLanes; for each element in AccLanes, if we
find an element in GYROLanes which is close in
time to the element of AccLanes then we consider
it a lane change because both the GYRO and the
ACC have voted for it. Otherwise we don’t consider
it as a lane change because only one sensor voted
for it.
To Know if the detected lane change is a right or
a left lane change, we have the following options
according to the mobile device situation:
• s1 and s3:
Left: For ACC: lowest peak first then highest
peak comes. For Gyro: highest peak first then
lowest peak comes.
Right: For ACC: highest peak first then lowest
peak comes. For Gyro: lowest peak first then
highest peak comes.
• s2:
Left: For ACC: highest peak first then lowest
peak comes. For Gyro: lowest peak first then
highest peak comes.
Right: For ACC: lowest peak first then lowest
peak comes. For Gyro: highest peak first then
highest peak comes.
4) Microphone: The driving law in most of the
countries requires that the driver has to turn on the
blinker of the car when he wants to change the
lane he is driving on. That is why, we have another
important source to make the online lane change
detection algorithm more robust. Because when we
can detect that the blinker is turned on, that means
that the driver is very likely to do a lane change. So
integrating this source of data alongside with both
accelerometer and gyroscope will lead to a more
robust and accurate detection.
When turning the blinker on, it makes period-
ically sounds. So we can use the same mobile
device which is fixed in the car in order to record
this periodic sound signal which in turn gives an
indicator to the fact that a lane change is happening.
One very important note: capturing this periodic
sound signal alone doesn’t mean that a lane change
is happening; the driver may want to do a left or
right turn or the blinker may be turned on without
any purpose. That is why, detecting the periodic
sound signal of the blinker using the microphone
sensor of the mobile device can only support the
lane change detection algorithm when it is inte-
grated with both gyroscope and accelerometer. But
it cannot take the decision alone.
Now we are going to present algorithm 2 which
can extract the blinks out of a sound signal recorded
by the mobile device.
Algorithm 2 shows the flow of extracting sound
blinks out of the signal.
After we find out where each blink is located
(at which frame) then we try to find at least three
consecutive blinks so that we can say that we have
a blinker running.
Consecutive blinks means there are 40 frames
between each two consecutive blinks.
Explaining algorithm 2:.
First of all, The algorithm listens to the coming
sound until the user turn it off by clicking a button.
The first step is to fill a buffer of data with size of
34 readings and we process it. First of all we do a
Fourier Transformation in order to get the frequency
domain representation of the original signal. Now
we have the Buffer of the sound signal in the
frequency domain. Then we pass the data again
through a high-pass filter so that only the points
of data which have the frequencies above 8 KHz
can pass. That is important to get rid of some noise
coming from the car’s engine for example. After
that, we only process the intensity of the signal
which means the number of data points that can
be found in one frame. Now since we have the
9
data points with their frequencies, we can extract
the blinks.
recursivelyFindBlinks(Buffer, threshold):
this function finds the blinks in the buffer. the
initial value of threshold is 150.
This function assumes the middle data point of
the buffer as a Blink. Then it calculates the standard
Deviation between all the points in the right half of
the buffer. It also calculates the standard deviation
between all the points in the left half of the buffer.
After that, it calculates the deviation between stan-
dard deviation of the right half of the buffer and the
middle point mentioned above and in case of the
difference between these two values is more than the
passed threshold, then the middle point of the buffer
is a blink so we store it in a vector and the new
threshold value is set to be the difference between
the standard deviation of the values in the right
side and the middle point and we call the function
recursively to do the same processing for the right
half of the Buffer. The same processing happens for
the points of data in the left side.
note:
Using the microphone sensor may be energy
consuming. That is why, we thought to use it in a
way so that the microphone should not be activated
for the whole time. It should be activated only when
the other sensors (gyro and acc) detect a lane change
themselves. The idea is to trigger the microphone
sensor only when both gyroscope and accelerometer
finds a very low or a very high peak, so we activate
the microphone sensor in order to extract the blinker
at its latest phases. When the gyroscope or the
accelerometer finds a very low or a very high peak
on its readings, that means that it may be a lane
change is going to happen. We didn’t integrate the
microphone sensor with the online detection yet. We
leave this for future work.
D. Offline lane change events detection approach:
The offline lane change detection approach has
the same basic concepts as the online lane change
detection approach. However, the offline lane detec-
tion algorithm processes larger amounts of data than
the online lane change algorithm. Moreover, the
offline approach is processing data coming not only
from one smart phone but from many different smart
phones. In another words, the offline approach for
lane change detection processes data coming from
different moving cars in order to get some valuable
information about certain locations. For example,
the offline approach will be able to tell something
like: [in location X of the highway y, lots of the
moving cars are making right lane change].
concerning the offline algorithm, it is divided
into separate phases which can be explained easily
since lots of the used concepts have been already
explained in the online detection approach:
phase 1 - Getting Data:
the data are already gathered and structured in
files because every smart phone records the data
coming from its sensors into structured spreadsheets
after doing some filtering. moreover the driver has
the option to annotate that a certain record is a
right lane change or a left lane change. So we
have fields for gyroscope, accerlerometer, GPS,
time, Date,mobile device, and some other fields like
annotation.
For every mobile device type, the offline algo-
rithm gathers its data into two vectors; one for data
coming from accelerometer and the other vector for
data coming from gyroscope.
phase 2 - Windowing:
For each data vector in each mobile device, the
offline detection algorithm divide this vector into
windows where each window has 7 readings, it also
extract the hugest peak, the lowest peak, the time of
the highest peak and the time of the lowest peak.
phase 3- Detection:
Now the algorithm scans all the accelerometer
vectors and all the gyroscope vectors which have
been already divided into windows in order to
extract wether a lane change happened in any of the
windows. The detection decision is done based on
the same way like in the online detection approach.
We calculate the altitude variance (the difference
between the highest peak and the lowest peak)
and the time variance ( the duration between the
highest peak and the lowest peak) in each window
. The altitude variance should be more than 2.1 in
accelerometer and more than 0.09 in the gyroscope
and the time variance should be less than 2 in the
accelerometer, and less than 2.7 in the gyroscope
in order to detect a lane change. When we detect a
lane change we store the lane change information
in a separate vector associated with its information.
phase 4- Merging:
in this phase, for each mobile device, the al-
gorithm loops over the results of the detection
10
phase for gyroscope and for each element of the
results vector of the gyroscope, the algorithm checks
whether the accelerometer has also detected this
lane change depending on the GPS component.
so if both sensors have already detected the same
lane change, then we add this lane change to the
final result vector of this mobile device with high
weight. Otherwise, we add the lane change to the
final results vector of the mobile device with lower
weight because only one sensor has detected it.
phase 5- Voting:
Now each mobile device has a vector of the
results which have been extracted from both the
accelerometer and gyroscope of that device. But
the voting process should be generalized for all of
the mobile devices. Because in our case we have
putted about 20 mobile devices in the same car
and recorded the data coming from all of these
devices, so when more than 50 % of the devices
have detected this of these devices vote (yes) for
certain lane change then we consider it as a lane
change.
Voting is done through looping over the final
results’ vectors of the mobile devices to check
weather more than the half have this lane change in
their vectors. We say that two mobile devices have
voted (yes) for certain lane change, if the second
mobile device has a lane change in the same or
a very near potion as the first mobile device. Very
near position means the difference between the GPS
components of the two lane changes in the two
mobile devices is less than 15m.
E. Evaluation
Before we start stating the evaluation, we want
to present two basic concepts for evaluation:
false positive (fp): number of detected lane
changes which did not happen.
false negative (fn): number of lane changes which
were not detected.
true positive (tp): number of detected lane
changes out of the actual ones.
true negative (tn): the system didn’t detect a lane
change and this lane change didn’t happen.
Recall: Recall indicates the true positive rate
Recall = tp
tp+fn
Precision: Precision indicates the positive predic-
tive value
Precision = tp
tp+fp
F-Measure: F-Measure indicates Large number of
negatives versus positives.
F − Measure = 2 ∗ Recall∗Precision
Recall+Precision
1) The Online detection algorithm: We had
tested the online lane change detection algorithm on
the highway between Darmstadt and Ruesselsheim
for 5 rounds and we found the following:
Number of the windows of the read data is
approximately 1750.
Number of the observed lane changes is 33.
TP=28, FP=5, FN=5 and TN= 1712. So: recall =
85% precission = 85%
F − Measure = 85%
2) The offline detection algorithm: we have runt
the algorithm over a data set with the following
information:
Number of the windows of the read data is
approximately 4761.
Number of the annotated lane changes is 107.
TP=97, FP=5, FN=10 and TN= 4649. F −
Measure = 95%
Generally Speaking:
The basic logic of the both online and offline al-
gorithms is completely correct but this lack of accu-
racy is caused because of choosing some thresholds
which should be more flexible rather than a fixed
value.
Foe example, the threshold which is used in the
online detection for altitude variance is related to
two different factors:
• Speed of the car: if the speed of the car
changes, the threshold should change also be-
cause the altitude variance will obviously in-
crease however, the time variance will obvi-
ously decrease.
• The suspension System of the car itself which
is hardware related issue but it affects the
thresholds used.
IV. CONCLUSION
In this paper, we have developed and imple-
mented two lane change detection algorithms and
we also presented blinker detection algorithm.
The first one is used for online lane change
events detection so that we fixed a smart phone
in the moving car. This smart phone provides the
algorithm with input using its sensors (gyroscope,
accelerometer, and GPS). The algorithm detects in
real time when a left or right lane change happens.
11
We also showed that the online algorithm’s accuracy
is 99.4% and the offline algorithm’s accuracy is
99.1%.
The next algorithm is used for offline lane change
detection. It takes as an input data coming from
more than 20 smart phones. After that, It process all
of this amount of data in order to extract patterns
of left or right lane change according to a voting
process handled by all the contributed devices.
The accuracy of the offline lane change detection
algorithm is 91%.
We also presented blinker detection algorithm
which can detect blinker pattern coming from the
microphone sensor of the mobile device.
V. FUTURE WORK
Well, What is next?
• integrating the blinker detection algorithm in
the online detection algorithm so that we can
make the algorithm more robust.
• in order to enhance the accuracy of both men-
tioned algorithms, the system should be able
to calculate the thresholds used rather than
defining them as constants because the values
of the pattern of the lane change (highest
peak for example) will change according to the
speed of the car or the suspension system of the
car which differs from car to another. So the
online application should have a button for the
right lane change and another button for the
left lane change. At the first phase of running
the application, it would be in the learning
mode, so when the driver wants to make a
right lane change, he should press the right lane
change button in order to trigger the algorithm
to store the values of the right lane change
pattern (altitude variance, time variance, and
annotation strings) for this car at the current
speed, so after some short time the algorithm
will have a training data set which can be
used as input for a machine learning model
(clustering for example) in order to get the
optimal thresholds values for different speeds
of this car.
• Detecting another driver behavior other than
lane change.
ACKNOWLEDGMENT
We would like to thank Florian Jomrich,M.Sc.
who has supervised this project for his accurate
advice and guidelines.
REFERENCES
[1] M. Electronics, ”The autonomous car: A diverse array of sen-
sors drives navigation, driving, and performance,” 2016. [On-
line]. Available: http://eu.mouser.com/applications/autonomous-
car-sensors-drive-performance/. Accessed: Jun. 14, 2016.
[2] S. Hofmann and C. Brenner, Quality assessment of automatically
generated feature maps for future driver assistance systems, in
SIGSPATIAL GIS. ACM, 2009
[3] F. Ren, J. Huang, M. Terauchi, R. Jiang, and R. Klette, Lane
Detection on the iPhone. Springer, 2010.
[4] Heba Aly, Anas Basalamah and Moustafa Youssef. ”LaneQuest:
An Accurate and Energy-Efficient Lane Detection System” In
IEEE PerCom 2015
[5] D. Li, T. Bansal, Z. Lu, and P. Sinha, Marvel: multiple antenna
based relative vehicle localizer, in Mobicom. ACM, 2012.
[6] Pushpendra Singh , Nikita Juneja , Shruti Kapoor, Using mobile
phone sensors to detect driving behavior, Proceedings of the 3rd
ACM Symposium on Computing for Development, January 11-
12, 2013, Bangalore, India [doi¿10.1145/2442882.2442941]
[7] G. Somasundaram, Kavitha, and K. I. Ramachandran, ”LANE
CHANGE DETECTION AND TRACKING FOR A SAFE-
LANE APPROACH IN REAL TIME VISION BASED NAV-
IGATION SYSTEMS,” 2011.
[8] J. Schlechtriemen, A. Wedel, J. Hillenbrand, G. Breuel, and
K.-D. Kuhnert, ”A Lane Change Detection Approach using
Feature Ranking with Maximized Predictive Power,” in 2014
IEEE Intelligent Vehicles Symposium (IV), Dearborn, Michigan,
USA, 2014.
[9] Satzoda, R.K. (2014) Drive Analysis using Vehicle Dynamics
and Vision-based Lane Semantics, USA: IEEE Transactions on
Intelligent Transportation Systems.
[10] M. Fazeen, B. Gozick, R. Dantu, M. Bhukhiya, and M. C.
Gonzalez, Safe driving using mobile phones, IEEE Transactions
on ITS, 2012.
[11] R. Serway and J. Jewett, Physics for scientists and engineers.
Cengage Learning, 2013.
[12] J. Paefgen, F. Kehr, Y. Zhai, and F. Michahelles, ”Driving
Behavior Analysis with Smartphones: Insights from a Controlled
Field Study,”.
12
Data: readings coming online (real time) from
both Gyroscope and Accelerometer
sensors.
Result: detecting at which location a lane
change happened and stores that in the
data file.
checkMobileDevice(GY ROFlag, ACCFlag)
ACCBigWindow = empty;
GY ROBigWindow = empty;
while true do
GyroSmallWindow =
fillGyro(GY ROFlag);
ACCSmallWindow =
fillAcc(ACCFlag);
end
if AHASLaneChange(ACCSmallWindow)
then
AccLanes[i] =
recordLanechangeTimeandlocation
else
ACCaddTOBigWindow(ACCSmallWindow)
end
if GHasLaneChange(GyroSmallWindow)
then
GY ROLanes[i] =
recordLanechangeTimeandlocation
else
GY ROaddTOBigWindow(GY ROSmallWindow)
end
if AHASLaneChange(ACCBigWindow)
then
AccLanes[i] =
recordLanechangeTimeandlocation
else
if Full(ACCBigWindow) then
ACCBigWindow=empty;
end
end
if GHASLaneChange(GY ROBigWindow)
then
GY ROLanes[i] =
recordLanechangeTimeandlocation
else
if Full(GYROBigWindow) then
GYROBigWindow=empty;
end
end
voting(GY ROLanes, ACCLanes);
Algorithm 1: Online lane change detection al-
gorithm which processes data coming from both
Gyroscope sensor and Accelerometer sensor.
Data: readings coming online (real time) from
Microphone sensor.
Result: extracting blinker pattern.
while soundsignalstillcoming do
FillBuffer(Buffer, soundSignal)
FourierTransform(Buffer)
HighPassFilter(Buffer)
IntensityComponent(Buffer)
recursivelyFindBlinks(Buffer, threshold);
end
Algorithm 2: Online lane change detection algo-
rithm which processes sound signal coming from
the microphone sensor.
1: procedure RECURSIVELYFIND-
BLINKS(Buffer, threshold);
if width(Buffer) > CONSTANT then
middle = Buffer[MiddleIndex];
sdr = calculateSD(rightHalf);
sdl = calculateSD(leftHalf);
dr = calculateD(sdr, middle);
dl = calculateD(sdl, middle);
if sdr − dr > threshold then
middle is a blink;
store(middle);
threschold = sdr − dr;
recursivelyFindBlinks(rightHalf, threshol
end
if sdl − dl > threshold then
middle is a blink;
store(middle);
threschold = sdl − dl;
recursivelyFindBlinks(leftHalf, threshold
end
end
2: end procedure
Algorithm 3: recursivelyFindBlinks

More Related Content

What's hot

An Approach to Improve the Railway Crack Detection in the Tracks by Automated...
An Approach to Improve the Railway Crack Detection in the Tracks by Automated...An Approach to Improve the Railway Crack Detection in the Tracks by Automated...
An Approach to Improve the Railway Crack Detection in the Tracks by Automated...IOSR Journals
 
Autonomous vehicles
Autonomous vehiclesAutonomous vehicles
Autonomous vehiclesKomal Wadhwa
 
Intelligent transportation system using wireless sensor network
Intelligent transportation system using wireless sensor networkIntelligent transportation system using wireless sensor network
Intelligent transportation system using wireless sensor networkBrundha Sholaganga
 
(Paper) A Method for Pedestrian Position Estimation using Inter-Vehicle Comm...
 (Paper) A Method for Pedestrian Position Estimation using Inter-Vehicle Comm... (Paper) A Method for Pedestrian Position Estimation using Inter-Vehicle Comm...
(Paper) A Method for Pedestrian Position Estimation using Inter-Vehicle Comm...Naoki Shibata
 
Vehicle Speed Estimation using Haar Classifier Algorithm
Vehicle Speed Estimation using Haar Classifier AlgorithmVehicle Speed Estimation using Haar Classifier Algorithm
Vehicle Speed Estimation using Haar Classifier Algorithmijtsrd
 
Low Cost Rail Crack Inspection System
Low Cost Rail Crack Inspection SystemLow Cost Rail Crack Inspection System
Low Cost Rail Crack Inspection SystemEditor IJMTER
 
Density based-traffic-signal-system
Density based-traffic-signal-systemDensity based-traffic-signal-system
Density based-traffic-signal-systemPAVAN KUMAR ILLA
 
Traffic Congestion Prediction using Deep Reinforcement Learning in Vehicular ...
Traffic Congestion Prediction using Deep Reinforcement Learning in Vehicular ...Traffic Congestion Prediction using Deep Reinforcement Learning in Vehicular ...
Traffic Congestion Prediction using Deep Reinforcement Learning in Vehicular ...IJCNCJournal
 
Emergency vehicles detection and special road system ppt
Emergency vehicles detection and special road system pptEmergency vehicles detection and special road system ppt
Emergency vehicles detection and special road system pptRejetiPrathyusha
 
Intelligent Collision avoidance and monitoring system for railway using wirel...
Intelligent Collision avoidance and monitoring system for railway using wirel...Intelligent Collision avoidance and monitoring system for railway using wirel...
Intelligent Collision avoidance and monitoring system for railway using wirel...Editor IJMTER
 
IRJET-utomatic Intelligent Traffic Control System
IRJET-utomatic Intelligent Traffic Control SystemIRJET-utomatic Intelligent Traffic Control System
IRJET-utomatic Intelligent Traffic Control SystemIRJET Journal
 
Jatin sharma (42162)
Jatin sharma (42162)Jatin sharma (42162)
Jatin sharma (42162)Jatin Sharma
 
SENSPEED: Sensing Driving Conditions to Estimate Vehicle Speed in Urban Envir...
SENSPEED: Sensing Driving Conditions to Estimate Vehicle Speed in Urban Envir...SENSPEED: Sensing Driving Conditions to Estimate Vehicle Speed in Urban Envir...
SENSPEED: Sensing Driving Conditions to Estimate Vehicle Speed in Urban Envir...IRJET Journal
 
Design and Construction of Navigation Based Auto Self Driving Vehicle using G...
Design and Construction of Navigation Based Auto Self Driving Vehicle using G...Design and Construction of Navigation Based Auto Self Driving Vehicle using G...
Design and Construction of Navigation Based Auto Self Driving Vehicle using G...ijtsrd
 
IRJET- Lane Detection using Neural Networks
IRJET- Lane Detection using Neural NetworksIRJET- Lane Detection using Neural Networks
IRJET- Lane Detection using Neural NetworksIRJET Journal
 
How long to wait predicting bus arrival time with mobile phone based particip...
How long to wait predicting bus arrival time with mobile phone based particip...How long to wait predicting bus arrival time with mobile phone based particip...
How long to wait predicting bus arrival time with mobile phone based particip...Papitha Velumani
 
Traffic control system
Traffic control systemTraffic control system
Traffic control systemzahid6
 

What's hot (20)

An Approach to Improve the Railway Crack Detection in the Tracks by Automated...
An Approach to Improve the Railway Crack Detection in the Tracks by Automated...An Approach to Improve the Railway Crack Detection in the Tracks by Automated...
An Approach to Improve the Railway Crack Detection in the Tracks by Automated...
 
Autonomous vehicles
Autonomous vehiclesAutonomous vehicles
Autonomous vehicles
 
50120140504010
5012014050401050120140504010
50120140504010
 
Intelligent transportation system using wireless sensor network
Intelligent transportation system using wireless sensor networkIntelligent transportation system using wireless sensor network
Intelligent transportation system using wireless sensor network
 
(Paper) A Method for Pedestrian Position Estimation using Inter-Vehicle Comm...
 (Paper) A Method for Pedestrian Position Estimation using Inter-Vehicle Comm... (Paper) A Method for Pedestrian Position Estimation using Inter-Vehicle Comm...
(Paper) A Method for Pedestrian Position Estimation using Inter-Vehicle Comm...
 
AUTONOMOUS VEHICLES
AUTONOMOUS VEHICLESAUTONOMOUS VEHICLES
AUTONOMOUS VEHICLES
 
Vehicle Speed Estimation using Haar Classifier Algorithm
Vehicle Speed Estimation using Haar Classifier AlgorithmVehicle Speed Estimation using Haar Classifier Algorithm
Vehicle Speed Estimation using Haar Classifier Algorithm
 
Low Cost Rail Crack Inspection System
Low Cost Rail Crack Inspection SystemLow Cost Rail Crack Inspection System
Low Cost Rail Crack Inspection System
 
Density based-traffic-signal-system
Density based-traffic-signal-systemDensity based-traffic-signal-system
Density based-traffic-signal-system
 
Traffic Congestion Prediction using Deep Reinforcement Learning in Vehicular ...
Traffic Congestion Prediction using Deep Reinforcement Learning in Vehicular ...Traffic Congestion Prediction using Deep Reinforcement Learning in Vehicular ...
Traffic Congestion Prediction using Deep Reinforcement Learning in Vehicular ...
 
Emergency vehicles detection and special road system ppt
Emergency vehicles detection and special road system pptEmergency vehicles detection and special road system ppt
Emergency vehicles detection and special road system ppt
 
Intelligent Collision avoidance and monitoring system for railway using wirel...
Intelligent Collision avoidance and monitoring system for railway using wirel...Intelligent Collision avoidance and monitoring system for railway using wirel...
Intelligent Collision avoidance and monitoring system for railway using wirel...
 
IRJET-utomatic Intelligent Traffic Control System
IRJET-utomatic Intelligent Traffic Control SystemIRJET-utomatic Intelligent Traffic Control System
IRJET-utomatic Intelligent Traffic Control System
 
Jatin sharma (42162)
Jatin sharma (42162)Jatin sharma (42162)
Jatin sharma (42162)
 
SENSPEED: Sensing Driving Conditions to Estimate Vehicle Speed in Urban Envir...
SENSPEED: Sensing Driving Conditions to Estimate Vehicle Speed in Urban Envir...SENSPEED: Sensing Driving Conditions to Estimate Vehicle Speed in Urban Envir...
SENSPEED: Sensing Driving Conditions to Estimate Vehicle Speed in Urban Envir...
 
Design and Construction of Navigation Based Auto Self Driving Vehicle using G...
Design and Construction of Navigation Based Auto Self Driving Vehicle using G...Design and Construction of Navigation Based Auto Self Driving Vehicle using G...
Design and Construction of Navigation Based Auto Self Driving Vehicle using G...
 
IRJET- Lane Detection using Neural Networks
IRJET- Lane Detection using Neural NetworksIRJET- Lane Detection using Neural Networks
IRJET- Lane Detection using Neural Networks
 
Traffic management
Traffic managementTraffic management
Traffic management
 
How long to wait predicting bus arrival time with mobile phone based particip...
How long to wait predicting bus arrival time with mobile phone based particip...How long to wait predicting bus arrival time with mobile phone based particip...
How long to wait predicting bus arrival time with mobile phone based particip...
 
Traffic control system
Traffic control systemTraffic control system
Traffic control system
 

Similar to Online/Offline Lane Change Events Detection Algorithms

LANE CHANGE DETECTION AND TRACKING FOR A SAFE-LANE APPROACH IN REAL TIME VISI...
LANE CHANGE DETECTION AND TRACKING FOR A SAFE-LANE APPROACH IN REAL TIME VISI...LANE CHANGE DETECTION AND TRACKING FOR A SAFE-LANE APPROACH IN REAL TIME VISI...
LANE CHANGE DETECTION AND TRACKING FOR A SAFE-LANE APPROACH IN REAL TIME VISI...cscpconf
 
A survey on real time bus monitoring system
A survey on real time bus monitoring systemA survey on real time bus monitoring system
A survey on real time bus monitoring systemIRJET Journal
 
Real Time Road Blocker Detection and Distance Calculation for Autonomous Vehi...
Real Time Road Blocker Detection and Distance Calculation for Autonomous Vehi...Real Time Road Blocker Detection and Distance Calculation for Autonomous Vehi...
Real Time Road Blocker Detection and Distance Calculation for Autonomous Vehi...Associate Professor in VSB Coimbatore
 
Design of Smart Traffic Light Controller Using Embedded System
Design of Smart Traffic Light Controller Using Embedded SystemDesign of Smart Traffic Light Controller Using Embedded System
Design of Smart Traffic Light Controller Using Embedded SystemIOSR Journals
 
Smart and efficient system for the detection of wrong cars parking
Smart and efficient system for the detection of wrong cars parkingSmart and efficient system for the detection of wrong cars parking
Smart and efficient system for the detection of wrong cars parkingjournalBEEI
 
Smart cars (1)
Smart cars (1)Smart cars (1)
Smart cars (1)Itcs399
 
Study of Estimation of Road Roughness Condition and Ghat Complexity Analysis ...
Study of Estimation of Road Roughness Condition and Ghat Complexity Analysis ...Study of Estimation of Road Roughness Condition and Ghat Complexity Analysis ...
Study of Estimation of Road Roughness Condition and Ghat Complexity Analysis ...IRJET Journal
 
Iaetsd literature review on traffic signal control system based on
Iaetsd literature review on traffic signal control system based onIaetsd literature review on traffic signal control system based on
Iaetsd literature review on traffic signal control system based onIaetsd Iaetsd
 
traffic jam detection using image processing
traffic jam detection using image processingtraffic jam detection using image processing
traffic jam detection using image processingMalika Alix
 
Identification and classification of moving vehicles on road
Identification and classification of moving vehicles on roadIdentification and classification of moving vehicles on road
Identification and classification of moving vehicles on roadAlexander Decker
 
Presentation on INTELLIGENT TRANSPORT SYSTEM by jaswinder singh
Presentation on INTELLIGENT TRANSPORT SYSTEM by jaswinder singhPresentation on INTELLIGENT TRANSPORT SYSTEM by jaswinder singh
Presentation on INTELLIGENT TRANSPORT SYSTEM by jaswinder singhJaswinder Singh
 
Control of Traffic Signals by AI based Image Processing
Control of Traffic Signals by AI based Image ProcessingControl of Traffic Signals by AI based Image Processing
Control of Traffic Signals by AI based Image ProcessingIRJET Journal
 
Discernment Pothole with Autonomous Metropolitan Vehicle
	 Discernment Pothole with Autonomous Metropolitan  Vehicle	 Discernment Pothole with Autonomous Metropolitan  Vehicle
Discernment Pothole with Autonomous Metropolitan VehicleIRJET Journal
 
Automatic Park and retrieve assissted systems for automobiles using smartphone
Automatic Park and retrieve assissted systems for automobiles using smartphoneAutomatic Park and retrieve assissted systems for automobiles using smartphone
Automatic Park and retrieve assissted systems for automobiles using smartphonetheijes
 
Automatic Park and retrieve assissted systems for automobiles using smartphone
Automatic Park and retrieve assissted systems for automobiles using smartphoneAutomatic Park and retrieve assissted systems for automobiles using smartphone
Automatic Park and retrieve assissted systems for automobiles using smartphonetheijes
 
A Method for Predicting Vehicles Motion Based on Road Scene Reconstruction an...
A Method for Predicting Vehicles Motion Based on Road Scene Reconstruction an...A Method for Predicting Vehicles Motion Based on Road Scene Reconstruction an...
A Method for Predicting Vehicles Motion Based on Road Scene Reconstruction an...ITIIIndustries
 

Similar to Online/Offline Lane Change Events Detection Algorithms (20)

LANE CHANGE DETECTION AND TRACKING FOR A SAFE-LANE APPROACH IN REAL TIME VISI...
LANE CHANGE DETECTION AND TRACKING FOR A SAFE-LANE APPROACH IN REAL TIME VISI...LANE CHANGE DETECTION AND TRACKING FOR A SAFE-LANE APPROACH IN REAL TIME VISI...
LANE CHANGE DETECTION AND TRACKING FOR A SAFE-LANE APPROACH IN REAL TIME VISI...
 
A survey on real time bus monitoring system
A survey on real time bus monitoring systemA survey on real time bus monitoring system
A survey on real time bus monitoring system
 
Real Time Road Blocker Detection and Distance Calculation for Autonomous Vehi...
Real Time Road Blocker Detection and Distance Calculation for Autonomous Vehi...Real Time Road Blocker Detection and Distance Calculation for Autonomous Vehi...
Real Time Road Blocker Detection and Distance Calculation for Autonomous Vehi...
 
A017430110
A017430110A017430110
A017430110
 
Db35575578
Db35575578Db35575578
Db35575578
 
Design of Smart Traffic Light Controller Using Embedded System
Design of Smart Traffic Light Controller Using Embedded SystemDesign of Smart Traffic Light Controller Using Embedded System
Design of Smart Traffic Light Controller Using Embedded System
 
Smart and efficient system for the detection of wrong cars parking
Smart and efficient system for the detection of wrong cars parkingSmart and efficient system for the detection of wrong cars parking
Smart and efficient system for the detection of wrong cars parking
 
Smart cars (1)
Smart cars (1)Smart cars (1)
Smart cars (1)
 
Study of Estimation of Road Roughness Condition and Ghat Complexity Analysis ...
Study of Estimation of Road Roughness Condition and Ghat Complexity Analysis ...Study of Estimation of Road Roughness Condition and Ghat Complexity Analysis ...
Study of Estimation of Road Roughness Condition and Ghat Complexity Analysis ...
 
Iaetsd literature review on traffic signal control system based on
Iaetsd literature review on traffic signal control system based onIaetsd literature review on traffic signal control system based on
Iaetsd literature review on traffic signal control system based on
 
A real-time system for vehicle detection with shadow removal and vehicle clas...
A real-time system for vehicle detection with shadow removal and vehicle clas...A real-time system for vehicle detection with shadow removal and vehicle clas...
A real-time system for vehicle detection with shadow removal and vehicle clas...
 
traffic jam detection using image processing
traffic jam detection using image processingtraffic jam detection using image processing
traffic jam detection using image processing
 
Identification and classification of moving vehicles on road
Identification and classification of moving vehicles on roadIdentification and classification of moving vehicles on road
Identification and classification of moving vehicles on road
 
Presentation on INTELLIGENT TRANSPORT SYSTEM by jaswinder singh
Presentation on INTELLIGENT TRANSPORT SYSTEM by jaswinder singhPresentation on INTELLIGENT TRANSPORT SYSTEM by jaswinder singh
Presentation on INTELLIGENT TRANSPORT SYSTEM by jaswinder singh
 
Control of Traffic Signals by AI based Image Processing
Control of Traffic Signals by AI based Image ProcessingControl of Traffic Signals by AI based Image Processing
Control of Traffic Signals by AI based Image Processing
 
Discernment Pothole with Autonomous Metropolitan Vehicle
	 Discernment Pothole with Autonomous Metropolitan  Vehicle	 Discernment Pothole with Autonomous Metropolitan  Vehicle
Discernment Pothole with Autonomous Metropolitan Vehicle
 
Icquest1518
Icquest1518Icquest1518
Icquest1518
 
Automatic Park and retrieve assissted systems for automobiles using smartphone
Automatic Park and retrieve assissted systems for automobiles using smartphoneAutomatic Park and retrieve assissted systems for automobiles using smartphone
Automatic Park and retrieve assissted systems for automobiles using smartphone
 
Automatic Park and retrieve assissted systems for automobiles using smartphone
Automatic Park and retrieve assissted systems for automobiles using smartphoneAutomatic Park and retrieve assissted systems for automobiles using smartphone
Automatic Park and retrieve assissted systems for automobiles using smartphone
 
A Method for Predicting Vehicles Motion Based on Road Scene Reconstruction an...
A Method for Predicting Vehicles Motion Based on Road Scene Reconstruction an...A Method for Predicting Vehicles Motion Based on Road Scene Reconstruction an...
A Method for Predicting Vehicles Motion Based on Road Scene Reconstruction an...
 

Recently uploaded

Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
Direct Style Effect Systems -The Print[A] Example- A Comprehension AidDirect Style Effect Systems -The Print[A] Example- A Comprehension Aid
Direct Style Effect Systems - The Print[A] Example - A Comprehension AidPhilip Schwarz
 
Sector 18, Noida Call girls :8448380779 Model Escorts | 100% verified
Sector 18, Noida Call girls :8448380779 Model Escorts | 100% verifiedSector 18, Noida Call girls :8448380779 Model Escorts | 100% verified
Sector 18, Noida Call girls :8448380779 Model Escorts | 100% verifiedDelhi Call girls
 
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...SelfMade bd
 
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...kalichargn70th171
 
The Top App Development Trends Shaping the Industry in 2024-25 .pdf
The Top App Development Trends Shaping the Industry in 2024-25 .pdfThe Top App Development Trends Shaping the Industry in 2024-25 .pdf
The Top App Development Trends Shaping the Industry in 2024-25 .pdfayushiqss
 
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...panagenda
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsAlberto González Trastoy
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsJhone kinadey
 
ManageIQ - Sprint 236 Review - Slide Deck
ManageIQ - Sprint 236 Review - Slide DeckManageIQ - Sprint 236 Review - Slide Deck
ManageIQ - Sprint 236 Review - Slide DeckManageIQ
 
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...Shane Coughlan
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providermohitmore19
 
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrainmasabamasaba
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Modelsaagamshah0812
 
10 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 202410 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 2024Mind IT Systems
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfkalichargn70th171
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfkalichargn70th171
 
LEVEL 5 - SESSION 1 2023 (1).pptx - PDF 123456
LEVEL 5   - SESSION 1 2023 (1).pptx - PDF 123456LEVEL 5   - SESSION 1 2023 (1).pptx - PDF 123456
LEVEL 5 - SESSION 1 2023 (1).pptx - PDF 123456KiaraTiradoMicha
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdfPearlKirahMaeRagusta1
 
8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech studentsHimanshiGarg82
 
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park %in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park masabamasaba
 

Recently uploaded (20)

Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
Direct Style Effect Systems -The Print[A] Example- A Comprehension AidDirect Style Effect Systems -The Print[A] Example- A Comprehension Aid
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
 
Sector 18, Noida Call girls :8448380779 Model Escorts | 100% verified
Sector 18, Noida Call girls :8448380779 Model Escorts | 100% verifiedSector 18, Noida Call girls :8448380779 Model Escorts | 100% verified
Sector 18, Noida Call girls :8448380779 Model Escorts | 100% verified
 
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
 
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
 
The Top App Development Trends Shaping the Industry in 2024-25 .pdf
The Top App Development Trends Shaping the Industry in 2024-25 .pdfThe Top App Development Trends Shaping the Industry in 2024-25 .pdf
The Top App Development Trends Shaping the Industry in 2024-25 .pdf
 
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial Goals
 
ManageIQ - Sprint 236 Review - Slide Deck
ManageIQ - Sprint 236 Review - Slide DeckManageIQ - Sprint 236 Review - Slide Deck
ManageIQ - Sprint 236 Review - Slide Deck
 
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
 
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
 
10 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 202410 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 2024
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
 
LEVEL 5 - SESSION 1 2023 (1).pptx - PDF 123456
LEVEL 5   - SESSION 1 2023 (1).pptx - PDF 123456LEVEL 5   - SESSION 1 2023 (1).pptx - PDF 123456
LEVEL 5 - SESSION 1 2023 (1).pptx - PDF 123456
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdf
 
8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students
 
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park %in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
 

Online/Offline Lane Change Events Detection Algorithms

  • 1. 1 Online/Offline Lane Change Events Detection Algorithms Eid Arrache, Feras Tanan and Ousama Esbel Abstract—in this paper, We are presenting two algo- rithms for lane change detection. The first one is used for online detection (real-time detection) with accuracy of 85% and the other one is used for offline detection with accuracy of 95%. The main purpose of the offline detection algorithm is to find at which GPS locations the number of happened left/right lane changes. For the purpose of these algorithms we used the ”crowd-sensing” approach which means that the sensors of different mobile devices that were fixed in different cars are the sources of input data for the above mentioned algorithms. Specifically speaking, we used Accelerometer and Gyroscope sensors. We also presented an algorithm for blinker pattern extraction using the microphone sensor. Keywords: Pattern Extraction, Lane Change detection, Accelerometer, Gyroscope and Crowd Sensing I. MOTIVATION AND INTRODUCTION One of the most important things for driver-less vehicles (autonomous cars for example) is to have background knowledge about the streets, highways, and roads they drive on. This background knowl- edge is contained in high accurate street maps. So autonomous cars will need these maps in order to know how to navigate through roads. The data which is used to get the background knowledge should be collected in an efficient way which is not energy-consuming, then the collected data has to be processed offline in order to make it useful data which in turn should be used to enhance the high accurate street maps to be used by driver-less vehicles to understand what’s happening on their ways and to understand the nature of these ways. The useful data that will be visualized on the maps is called driver’s behaviors. Driver’s Behaviors mean the reaction the driver does in responding to the current road conditions lying ahead of him. For example, if the driver faces a construction site, then he must change the current lane which he is driving through, for example, the driver makes a right lane change or a left lane change in order to avoid the construction site. This left and right lane change is some kind of driver behavior driver behavior. The high accurate street maps are highly dynam- ically. It must be dynamic maps. Otherwise, these maps will be outdated quickly. That is why we will use sensors of smart phones of which are fixed in different cars to extract drivers behavior to generate background knowledge about the current driving conditions on this road segment to keep the maps updated. This approach is called crowd-sensing. So we can use large amount of the smart phones of the cars driving through certain road. Using this approach, even older cars or motor cycles could participate in the crowd sensing not only automated cars which are equipped with fancy sensor equip- ment. Then, the generated data would be processed offline to update the streets maps. Among the many technologies which make au- tonomous vehicles possible is a combination of sensors and actuators, sophisticated algorithms, and powerful processors to execute software. The sen- sors and actuators in an autonomous vehicle fall into three broad categories: 1) navigation and guidance; 2) driving and safety and 3) performance (man- aging the car’s basic internal systems).There are dozens of subsystems and hundreds of specialized sensor channels for these three categories [1]. The approach of adding specialized hardware to the vehicle is too expensive because then lots of sensing hardware must be added in order to detect the paths that should be used to drive through. However, in case of using the background knowledge in the streets maps, it is not expensive and it may be more accurate because these maps are generated by a crowd-sensing approach which means that different cars contribute to describing the nature of the street. In this paper we are limiting the scope of achiev- ing the autonomous driving to the specific driving behavior introduced through a lane change. We are going to present an efficient approach which can tell the driver less cars where they should do a left or
  • 2. 2 right lane change based on predefined map. Lane-level positioning systems for cars represent the next generation for outdoor navigation, where systems will not only predict the car location on the road but also its exact driving lane. This fine granularity is required for a wide range of emerging applications including advanced driver assistance Systems (ADASs) [2]. There were some Computer visions based ap- proaches [3] which tried to detect if a car is doing lane change using the mobile devices’ cameras. If the car is crossing the lane markers then this con- sidered as a lane change. But some [12] argued that this is not a complete solution because the markers may be unclear at some parts of the road due to some bad weather conditions or any other reason. Furthermore, it is an extensive energy consuming approach which requires much effort to process all of the images captured. Due to the high spread of smart phones among people, these smart phones could be used for further than their basic purposes. Smart phones contain sen- sors like accelerometer, gyroscope, compass, mag- netometer... etc. which provide lots of data about the device itself as well as the surrounding environment, for example, accelerometer provides data about the speed of movement of the smart phone regarding the three axis x, y and z. So when we fix the smart phone in a certain situation in a moving car, the data which is read by the smart phones’ sensors can be considered as data describing the car behavior because the smart phone is moving and acting the same way the car does it really. So in this way we can replace some specialized expensive hardware and sensors by available cheap already- existing sensors in order to gather the data about the moving car. In this paper we are presenting an online ap- proach which can detect the lane change in real time through an android application that uses ac- celerometer, gyroscope and microphone to detect the lane change. We are also presenting an efficient offline approach to make driverless vehicles able to know where they should make a left or right lane change. As mentioned we are using smartphones sensors to collect data that contain knowledge about the drivers behaviors. In order to come up with a correct driver behavior, we are collecting huge amounts of data using about twenty smartphone devices . After collecting these amounts of sensors data of the smartphones which are fixed in the cars, the collected data can be processed offline to extract the knowledge and interpret the drivers behaviors contained in the collected data in order to visualize the behaviors on the maps again to provide driverless vehicles with previous knowledge (drivers behaviors) about the streets they are driving on. The rest of the paper is structured as follows: In section ii) we are presenting related work and discussing what has already be done in the same context and in section iii) System approach we will discuss our approach in terms of design, implemen- tation and evaluation. After that in section iv) Con- clusion we will sum up what we have contributed to this context. Then in section v)Future Work, we will present how our work can be extended. II. RELATED WORK In this section, we are presenting what has already be done in the context of lane-detection systems. Moreover we will discuss these previous research in terms of some factors like: energy consumption and accuracy. The first work is ”LaneQuest”: An Accurate and Energy-Efficient Lane Detection System which is a system that leverages the ubiquitous and low- energy inertial sensors available in commodity smart-phones to provide an accurate estimate of the cars current lane [4]. So the main purpose of this system is to know at which lane the car is driving now. The intersection between what we are doing at our research project and LaneQuest is precisely that LaneQuest identifies at a certain phase the lane changes either to right or to left in order to get an idea at which lane the car is driving now. Basically, LaneQuest system is composed of four main components: 1) Preprocessing Module: at this Module, the system collect data from the energy- efficient inertial sensors in the smartphone (ac- celerometer, gyroscope and magnetometer), then it processes this collected data to reduce noise effect by applying Low-pass Filter), 2) Event Detection Module: what meant by event is exactly what we mean by drivers behavior in our case. At this Mod- ule LaneQuest tries to identify some events which may be used to estimate the current lane of the car. So here LaneQuest tries to identify lane change. 3) Probabilistic Lane Estimation Module: LaneQuest uses Markov localization to maintain probability
  • 3. 3 distribution over all possible lanes. 4) Organic Lane Anchors Updates Module: This module is responsi- ble for estimating the location. The lane change detection module of LaneQuest is to use the data collected by the accelerometer sen- sor of the smartphone which is fixed at the moving car to extract the pattern of the lane change whether it is a right lane change or a left lane change. When the car changes the lane it drives on some very clear changes appear in the readings of the accelerometer sensor. LaneQuest uses the approach provided by Marvel: multiple antenna based relative vehicle localizer [5]. Regarding this approach, tests showed that it is acceptable and can detect the most of the real lane changes the driver does, however it depends on some experimental values like Threshold, highest peak, lowest peak of the data coming from the accerlerometer. Moreover the accelerometer sensor is very noisy in general which means that there is some obvious noise in its readings which makes it somehow inaccurate to depend on it alone in lane change detections. To sum up, it is inevitable to use accelerometer sensor but we need to support it by using other techniques. The Second related work we would like to present and discuss here is Using Mobile Phone Sensors to Detect Driving Behavior [6]. In this research the authors implemented an android application that is able to adjust the driver behavior by giving indicators about the driving behavior of the driver. They used the approach of fixing a smartphone device in the car in order to use the sensors of this device to collect the data to be processed in order to extract pre-defined patterns of some driving behaviors. They used GPS, accelerometer and microphone as a combination in order to collect data. [6] built an application in two phases; the first one is collecting data about the different driving behav- iors specifically: speed breaker, indicator (blinker), left/right turn, left/right lane change, reverse and horn. Those collected data represent patterns of the mentioned driving behaviors. So in the online detection algorithm which is used in this research they would use those patterns as a ground truth to compare the coming data with. We can say that lane detection in this research is more accurate than the first research we presented because [6] uses accelerometer as well as microphone in order to detect lane change pattern from accelerometer data and blinker pattern from microphone data. On the other hand [4] uses only the data coming from the accelerometer. Regarding this approach [6], we can still argue that running the microphone all the way is highly energy-consuming. So there should be a way to still benefit from the presence of microphone but not to keep it recording all the way. Moreover its not clear in this research how the recorded data is filtered especially the microphones data. This approach could also be furthermore supported in decision taking. The approach [7] for lane detection is used as a driver assistant to increase the safety especially in traffic conditions. It is a vision-based approach which uses a video camera mounted on the moving car. The camera is used to capture images of the lanes on the way. After that, the recorded video of the camera is transferred to a high powered computer in order to manipulate the frames of the video so that everything in the frame is turned to black pixels but the lanes markings. So after that the frame would contain only the lanes of the road. But before that, a noise-filtering algorithm is performed in order to get rid of all the noise in the image. The output of this system is warnings to the driver if he exceed the lanes. The approach [7] implements a very complex algorithm which can perform in different situations such as: rainy weather or darkness which means that the lane change is detected at a very good accuracy. But this approach is a very high energy-consuming approach because it needs to run the camera all over the time when the car is driving. Moreover it requires real-time processing for videos. The approach [8] is concerned with detection the intention of drivers to do a lane-change. [8] presents a novel methodology for inferring driver intentions using model tracing. Model tracing means to observe the actual driver behavior and compare it to intentions. At the same time, the system gath- ers observable data from the driver and compares each models simulated behavior with the drivers actual observed behavior. In doing so, model trac- ing determines the best matching model and thus infers the drivers most likely current intention. We are concerned with the part of observing actual driver behavior (observing actual lane change). At this approach, the data is collected using different
  • 4. 4 instruments. Thats why [8] considers the car as an instrumented car. So First of all the types of data collected are: steering wheel angle; accelerator depression; lateral position; longitudinal distance and time headway to a lead vehicle; longitudinal distance, front and back, to vehicles in adjacent lanes; and the presence or absence of a lane to the left and right of the current travel lane. Then the next step is passing these data to a system which construct the behavioral models and runs them simultaneously. We can say that this approach is accurate however it is not cheap because specialized instruments are required to gather the data about the driver behavior and the surrounding environment. In Approach [9], the authors are doing drive analysis using vehicle dynamics and vision-based lane semantics basing on the concept of Naturalistic Driving Studies (NDS). NDS means capture large volumes of drive data from multiple sensor modal- ities, which are analyzed for critical information about driver behavior and driving characteristics. The main purpose of [9] is to gather large amounts of information about the driving in highways to process these information offline to know some characteristics of the driving way that lead to ac- cidents. In approach [9], the authors focus on the lane change event detection. For that, they used in- vehicle Control Area Network (CAN bus), inertial motion unit (IMU), global positioning system (GPS) and Camera. In order to detect lane changes hap- pened during the drive, the scan bands in the near view of the vehicle are processed. This is because a lane change is characterized by the position of the vehicle with respect to the lane positions in the near- view of the vehicle. They consider the lane feature positions so the position of the left lane marking appears to move towards the right as the vehicle makes the left lane change. Similarly, during a right lane change, the right lane marker moves to the left with respect to the vehicle. These observations are used to detect the lane change events. Concerning approach [9], we can indicate that it is a robust approach. But using the camera sensor is energy-consuming which means that the efficiency of this approach still is a point to discuss. To sum up, we have discussed different research work in the literature of lane change detection domain in terms of accuracy, energy-consumption, and robustness. What we achieved in our research work is a lane change detection approach which is accurate, efficient and robust. Moreover, we im- plemented this approach to work online (real-time lane change detection) using android platform and also offline in order to get indicators of where the drivers have done lane changes in order to enhance the street maps to be used by driver-less cars. III. SYSTEM APPROACH In this section, we are going to present our approach to solve the problem of lane change event detection. The approach we developed is efficient, accurate, and robust as we will see in the evaluation section. This section is divided into the following sections: • Overview. • Data collection. • Online lane change events detection approach. • Offline lane change events detection approach. • Evaluation. A. Overview We developed our lane change event detection ap- proach basing on the three factors we have discussed earlier in the related work section which are: • Efficiency. • Accuracy. • Robustness. Our approach is efficient because it doesn’t require special dedicated hardware equipment like (instru- mented cars for example) rather it only depends on sensors of smart phones which are expected to be existing at many cars already. Using the already existing sensors means making a new use of them rather than their basic obvious purposes. Our approach is also accurate since it detects real lane changes with very high accuracy as we will see in the evaluation. Moreover, our approach is robust since it detects smooth or harsh lane changes. Since our main purpose of this project is providing data about some locations where lots of cars made a right or left lane change to enhance the street maps with data, we developed an offline procedure to deal with large amounts of the data to interpret data into meaningful data to know where the lane changes where made. We also developed an online real time procedure which can detect lane changes in real time using android platforms.
  • 5. 5 B. Data Collection The whole project is about processing data and providing data. The input of this project is a large amount of raw sensor data. The data set itself consists out of the readings of the sensors of the mobile devices which are fixed in the car in a way so that the 3 axes of each mobile device are considered as the axes of the moving car itself. Moreover, we used different orientation of the devices we The sensors which we used to gather data are: • Accelerometer. • Gyroscope. • Microphone. Regarding the accelerometer and Gyroscope, we have three fields in the data file for each of them because for each sensor we have readings from three different axes (x, y and z). Regarding the GPS we have two fields which are longitude and latitude. These two fields represent the location of the car and will be used to tell the location where the lane change happened. Finally, the microphone data will be used to detect the blinker sound in order to support the decision that a lane change is happening because usually the driver turns the blinker on when he makes left or right lane change. One important thing about data collection is fil- tering. Because the sensors of the smart phones are so sensitive hardware, then their readings may contain some noise. That is why a filtering process is required. The filtering approach which is used in data collection here has the following logic: gather 20 readings of each sensor, then calculate the average of these readings and record this average value as a representative of all the 20 values. In this way we are smoothing the values to be realistic and readable. The Data Collection phase took about three months on daily basis approximately so we have now very large amounts of data divided into separate files that can be used in the offline process which we will discuss later. C. Online lane change approach The online lane change detection algorithm means that the same android device itself which gathers the data of its sensors is able to tell if a left or right lane change happened in real time. In the online lane change approach we are using three main components to take the decision: Fig. 1. A car doing a lane change will have to make a small rotation around the z-axis, leading to a change in its x-axis acceleration. source is [4] Fig. 2. A left lane change causes a specific pattern on the x acceleration. The pattern is reversed for right lane change. source is [4] • Accelerometer. • Gyroscope. • Microphone. 1) Accelerometer: A number of techniques in lit- erature proposed using the phone inertial sensors to detect the car lane change event [5], [10]. The idea is that for the car to change its lane, it experiences a change in its direction (Figure 1), which causes a rotation around the z-axis of the accelerometer (for the oriented phone) and affects mainly the x- acceleration [11]. In the case of fixing the mobile device in a way so that the z-axis of the mobile device has the same direction of the Gravity axis and the y axis of the mobile device has the same direction of the speed axis of the car then: We have two types of lane change: • Left lane change. • Right lane change. Left lane change: If the car is making a left lane change then x- acc readings will witness a sudden decrease to a very low value which can be obviously noticed comparing to previous stable values of this field. Then and after a very short period of time, the value
  • 6. 6 of this x-acc will increase to a higher value than the average value of this field, after that when the car has already moved to the left lane, the value of this field will decrease to approximately equal the average value of it as long as the car is moving straightforward, Figure 2(a) shows the readings of the x-accelerometer when the car is doing a left lane change. To capture this pattern, we use a slightly modified version of the approach proposed by [5], where we detect the maximum and minimum peaks within a window. If the difference between the two peaks exceeds a certain threshold which is in our case is 1 and they are close to each other which means the difference between the times of the two peaks is less than 2.7s (this value is defined basing on experiments), we detect a left lane change event on the accelerometer. Right lane change: If the car is making a right lane change then x- acc readings will witness a sudden increase to a very high value which can be obviously noticed comparing to previous stable values of this field. Then and after a very short period of time, the value of this x-acc will decrease to a lower value than the average value of this field among all of its readings, after that when the car has already moved to the right lane, the value of this field will increase to approximately equal the average value of it as long as the car is moving straightforward. Figure 2(b) shows the readings of the x- accelerometer when the car is doing a right lane change. The approach which can be used to detect a right lane change is the same as the one used for detecting the left lane change. We can figure out if the detected lane change is left or right depending on the following strategy: • If the first peak of the lane change is the high one, then it is a right lane change. • If the first peak of the lane change is the low one, then it is a left lane change. 2) Gyroscope: In our online approach for lane change events detection, we also processed the readings coming from the Gyroscope sensor in order to engage the Gyroscope sensor in the process of decision taking in terms of the lane change event detection. Which makes this process more robust and more accurate because now we have two sensors responsible for telling whether a certain reading case is a lane change or not. Actually, when the car moves from a lane to an- other one, some changes also appear on the readings of the Gyroscope sensor. These changes can be used in order to detect the lane change happening. In the case of fixing the mobile device in a way so that the z-axis of the mobile device has the same direction of the Gravity axis and the y axis of the mobile device has the same direction of the speed axis of the car then: Left lane change: Fig. 3. A left lane change causes a specific pattern on the z Gyroscope. The pattern is reversed for right lane change. this figure is generated basing on our real life data When the car is doing a left lane change, then the readings of the Gyroscope in the z axis changes noticeably. For a left lane change, the first peak of the lane change will be noticed to be the higher one and the other peak of the lane change will be noticed to be the lower one. Figure 3 shows a left lane change affects the Gyro z-axis. Right lane change: When the car is doing a right lane change, then the readings of the Gyroscope in the z axis changes noticeably. same as left the first peak of the lane change will be noticed to be the lower one and the other peak of the lane change will be noticed to be the higher one. Figure 4 shows a right lane change affects the Gyro z-axis. , Note: Figure 3 and Figure 4 are drown from our real life data sets which means The graphs therefore are influenced by the noise of the sensor readings. 3) Online lane change detection algorithm: With this sensor setup we were now able to write the algorithm which combines both the Gyroscope and the Accelerometer processing.
  • 7. 7 Fig. 4. A right lane change causes a specific pattern on the z Gyroscope. this figure is generated basing on our real life data Fig. 5. ”s2” situation of mobile device orientation we will present the algorithm then we will discuss it. Algorithm 1 is pretty simple and efficient. first of all we give the driver the flexibility to fix the mobile device in the car in three dif- ferent situations. the procedure CheckMobileDe- vice(GYROFlag,ACCFlag) is checking these three possibilities: • s1= If z axis of the mobile device has the same direction as the gravity AND y axis has the same direction as the speed direction of the car, then we should read data from x axis of accelerometer and z axis of Gyroscope. • s2= If x axis of the mobile device has the same direction as the gravity AND z axis has the same direction as the speed direction of the Fig. 6. ”s3” situation of mobile device orientation car, then we should read data from y axis of accelerometer and x axis of Gyroscope. • s3= If y axis of the mobile device has the same direction as the gravity AND z axis has the same direction as the speed direction of the car, then we should read data from x axis of accelerometer and y axis of Gyroscope. Now after detecting the source of the data we read data and fill it in small windows for both the Accelerometer and the Gyroscope, Then we check in each of the small windows whether a window has a lane change or not. Small windows are used to detect harsh lane changes and big windows are used to gather small windows which don’t have lane changes in order to detect smooth lane changes. If it has a lane change then we store information about this lane change (time and location, we store the info for lane changes for accelerometer and gyroscope in GYROLanes and ACCLanes respectively. AHASLAneChange is a procedure for checking if a window which has data coming from the accelerometer sensor has a lane change or not according to the following formulas: AltitudeV ariance = highestPeak − lowestPeak TimeV ariance = Max(t(highestPeak), t(lowestPeak) − Min(t(highestPeak), t(lowestPeak) if (AltitudeV ariance > 1) and (TimeV ariance < 2.7) Then it is a lane change.
  • 8. 8 GHASLAneChange has the same logic but dif- ferent thresholds: if (AltitudeV ariance > 0.0075) and (TimeV ariance < 2.7) Then it is a lane change. and in case this small windows don’t have any lane change then we store the small window in a larger window to read another small window. When we read another small window and this one again does not have any lane change then we add it also to the large window to check it with the previous small window. when the big window is filled and no lane change has been detected we empty it to make space for the new coming small windows. Any time we find a lane change we record its info in the appropriate vector. after we extract the lane changes, we make a voting process between the accelerometer and the gyroscope. So we scan both vectors AccLanes and GYROLanes; for each element in AccLanes, if we find an element in GYROLanes which is close in time to the element of AccLanes then we consider it a lane change because both the GYRO and the ACC have voted for it. Otherwise we don’t consider it as a lane change because only one sensor voted for it. To Know if the detected lane change is a right or a left lane change, we have the following options according to the mobile device situation: • s1 and s3: Left: For ACC: lowest peak first then highest peak comes. For Gyro: highest peak first then lowest peak comes. Right: For ACC: highest peak first then lowest peak comes. For Gyro: lowest peak first then highest peak comes. • s2: Left: For ACC: highest peak first then lowest peak comes. For Gyro: lowest peak first then highest peak comes. Right: For ACC: lowest peak first then lowest peak comes. For Gyro: highest peak first then highest peak comes. 4) Microphone: The driving law in most of the countries requires that the driver has to turn on the blinker of the car when he wants to change the lane he is driving on. That is why, we have another important source to make the online lane change detection algorithm more robust. Because when we can detect that the blinker is turned on, that means that the driver is very likely to do a lane change. So integrating this source of data alongside with both accelerometer and gyroscope will lead to a more robust and accurate detection. When turning the blinker on, it makes period- ically sounds. So we can use the same mobile device which is fixed in the car in order to record this periodic sound signal which in turn gives an indicator to the fact that a lane change is happening. One very important note: capturing this periodic sound signal alone doesn’t mean that a lane change is happening; the driver may want to do a left or right turn or the blinker may be turned on without any purpose. That is why, detecting the periodic sound signal of the blinker using the microphone sensor of the mobile device can only support the lane change detection algorithm when it is inte- grated with both gyroscope and accelerometer. But it cannot take the decision alone. Now we are going to present algorithm 2 which can extract the blinks out of a sound signal recorded by the mobile device. Algorithm 2 shows the flow of extracting sound blinks out of the signal. After we find out where each blink is located (at which frame) then we try to find at least three consecutive blinks so that we can say that we have a blinker running. Consecutive blinks means there are 40 frames between each two consecutive blinks. Explaining algorithm 2:. First of all, The algorithm listens to the coming sound until the user turn it off by clicking a button. The first step is to fill a buffer of data with size of 34 readings and we process it. First of all we do a Fourier Transformation in order to get the frequency domain representation of the original signal. Now we have the Buffer of the sound signal in the frequency domain. Then we pass the data again through a high-pass filter so that only the points of data which have the frequencies above 8 KHz can pass. That is important to get rid of some noise coming from the car’s engine for example. After that, we only process the intensity of the signal which means the number of data points that can be found in one frame. Now since we have the
  • 9. 9 data points with their frequencies, we can extract the blinks. recursivelyFindBlinks(Buffer, threshold): this function finds the blinks in the buffer. the initial value of threshold is 150. This function assumes the middle data point of the buffer as a Blink. Then it calculates the standard Deviation between all the points in the right half of the buffer. It also calculates the standard deviation between all the points in the left half of the buffer. After that, it calculates the deviation between stan- dard deviation of the right half of the buffer and the middle point mentioned above and in case of the difference between these two values is more than the passed threshold, then the middle point of the buffer is a blink so we store it in a vector and the new threshold value is set to be the difference between the standard deviation of the values in the right side and the middle point and we call the function recursively to do the same processing for the right half of the Buffer. The same processing happens for the points of data in the left side. note: Using the microphone sensor may be energy consuming. That is why, we thought to use it in a way so that the microphone should not be activated for the whole time. It should be activated only when the other sensors (gyro and acc) detect a lane change themselves. The idea is to trigger the microphone sensor only when both gyroscope and accelerometer finds a very low or a very high peak, so we activate the microphone sensor in order to extract the blinker at its latest phases. When the gyroscope or the accelerometer finds a very low or a very high peak on its readings, that means that it may be a lane change is going to happen. We didn’t integrate the microphone sensor with the online detection yet. We leave this for future work. D. Offline lane change events detection approach: The offline lane change detection approach has the same basic concepts as the online lane change detection approach. However, the offline lane detec- tion algorithm processes larger amounts of data than the online lane change algorithm. Moreover, the offline approach is processing data coming not only from one smart phone but from many different smart phones. In another words, the offline approach for lane change detection processes data coming from different moving cars in order to get some valuable information about certain locations. For example, the offline approach will be able to tell something like: [in location X of the highway y, lots of the moving cars are making right lane change]. concerning the offline algorithm, it is divided into separate phases which can be explained easily since lots of the used concepts have been already explained in the online detection approach: phase 1 - Getting Data: the data are already gathered and structured in files because every smart phone records the data coming from its sensors into structured spreadsheets after doing some filtering. moreover the driver has the option to annotate that a certain record is a right lane change or a left lane change. So we have fields for gyroscope, accerlerometer, GPS, time, Date,mobile device, and some other fields like annotation. For every mobile device type, the offline algo- rithm gathers its data into two vectors; one for data coming from accelerometer and the other vector for data coming from gyroscope. phase 2 - Windowing: For each data vector in each mobile device, the offline detection algorithm divide this vector into windows where each window has 7 readings, it also extract the hugest peak, the lowest peak, the time of the highest peak and the time of the lowest peak. phase 3- Detection: Now the algorithm scans all the accelerometer vectors and all the gyroscope vectors which have been already divided into windows in order to extract wether a lane change happened in any of the windows. The detection decision is done based on the same way like in the online detection approach. We calculate the altitude variance (the difference between the highest peak and the lowest peak) and the time variance ( the duration between the highest peak and the lowest peak) in each window . The altitude variance should be more than 2.1 in accelerometer and more than 0.09 in the gyroscope and the time variance should be less than 2 in the accelerometer, and less than 2.7 in the gyroscope in order to detect a lane change. When we detect a lane change we store the lane change information in a separate vector associated with its information. phase 4- Merging: in this phase, for each mobile device, the al- gorithm loops over the results of the detection
  • 10. 10 phase for gyroscope and for each element of the results vector of the gyroscope, the algorithm checks whether the accelerometer has also detected this lane change depending on the GPS component. so if both sensors have already detected the same lane change, then we add this lane change to the final result vector of this mobile device with high weight. Otherwise, we add the lane change to the final results vector of the mobile device with lower weight because only one sensor has detected it. phase 5- Voting: Now each mobile device has a vector of the results which have been extracted from both the accelerometer and gyroscope of that device. But the voting process should be generalized for all of the mobile devices. Because in our case we have putted about 20 mobile devices in the same car and recorded the data coming from all of these devices, so when more than 50 % of the devices have detected this of these devices vote (yes) for certain lane change then we consider it as a lane change. Voting is done through looping over the final results’ vectors of the mobile devices to check weather more than the half have this lane change in their vectors. We say that two mobile devices have voted (yes) for certain lane change, if the second mobile device has a lane change in the same or a very near potion as the first mobile device. Very near position means the difference between the GPS components of the two lane changes in the two mobile devices is less than 15m. E. Evaluation Before we start stating the evaluation, we want to present two basic concepts for evaluation: false positive (fp): number of detected lane changes which did not happen. false negative (fn): number of lane changes which were not detected. true positive (tp): number of detected lane changes out of the actual ones. true negative (tn): the system didn’t detect a lane change and this lane change didn’t happen. Recall: Recall indicates the true positive rate Recall = tp tp+fn Precision: Precision indicates the positive predic- tive value Precision = tp tp+fp F-Measure: F-Measure indicates Large number of negatives versus positives. F − Measure = 2 ∗ Recall∗Precision Recall+Precision 1) The Online detection algorithm: We had tested the online lane change detection algorithm on the highway between Darmstadt and Ruesselsheim for 5 rounds and we found the following: Number of the windows of the read data is approximately 1750. Number of the observed lane changes is 33. TP=28, FP=5, FN=5 and TN= 1712. So: recall = 85% precission = 85% F − Measure = 85% 2) The offline detection algorithm: we have runt the algorithm over a data set with the following information: Number of the windows of the read data is approximately 4761. Number of the annotated lane changes is 107. TP=97, FP=5, FN=10 and TN= 4649. F − Measure = 95% Generally Speaking: The basic logic of the both online and offline al- gorithms is completely correct but this lack of accu- racy is caused because of choosing some thresholds which should be more flexible rather than a fixed value. Foe example, the threshold which is used in the online detection for altitude variance is related to two different factors: • Speed of the car: if the speed of the car changes, the threshold should change also be- cause the altitude variance will obviously in- crease however, the time variance will obvi- ously decrease. • The suspension System of the car itself which is hardware related issue but it affects the thresholds used. IV. CONCLUSION In this paper, we have developed and imple- mented two lane change detection algorithms and we also presented blinker detection algorithm. The first one is used for online lane change events detection so that we fixed a smart phone in the moving car. This smart phone provides the algorithm with input using its sensors (gyroscope, accelerometer, and GPS). The algorithm detects in real time when a left or right lane change happens.
  • 11. 11 We also showed that the online algorithm’s accuracy is 99.4% and the offline algorithm’s accuracy is 99.1%. The next algorithm is used for offline lane change detection. It takes as an input data coming from more than 20 smart phones. After that, It process all of this amount of data in order to extract patterns of left or right lane change according to a voting process handled by all the contributed devices. The accuracy of the offline lane change detection algorithm is 91%. We also presented blinker detection algorithm which can detect blinker pattern coming from the microphone sensor of the mobile device. V. FUTURE WORK Well, What is next? • integrating the blinker detection algorithm in the online detection algorithm so that we can make the algorithm more robust. • in order to enhance the accuracy of both men- tioned algorithms, the system should be able to calculate the thresholds used rather than defining them as constants because the values of the pattern of the lane change (highest peak for example) will change according to the speed of the car or the suspension system of the car which differs from car to another. So the online application should have a button for the right lane change and another button for the left lane change. At the first phase of running the application, it would be in the learning mode, so when the driver wants to make a right lane change, he should press the right lane change button in order to trigger the algorithm to store the values of the right lane change pattern (altitude variance, time variance, and annotation strings) for this car at the current speed, so after some short time the algorithm will have a training data set which can be used as input for a machine learning model (clustering for example) in order to get the optimal thresholds values for different speeds of this car. • Detecting another driver behavior other than lane change. ACKNOWLEDGMENT We would like to thank Florian Jomrich,M.Sc. who has supervised this project for his accurate advice and guidelines. REFERENCES [1] M. Electronics, ”The autonomous car: A diverse array of sen- sors drives navigation, driving, and performance,” 2016. [On- line]. Available: http://eu.mouser.com/applications/autonomous- car-sensors-drive-performance/. Accessed: Jun. 14, 2016. [2] S. Hofmann and C. Brenner, Quality assessment of automatically generated feature maps for future driver assistance systems, in SIGSPATIAL GIS. ACM, 2009 [3] F. Ren, J. Huang, M. Terauchi, R. Jiang, and R. Klette, Lane Detection on the iPhone. Springer, 2010. [4] Heba Aly, Anas Basalamah and Moustafa Youssef. ”LaneQuest: An Accurate and Energy-Efficient Lane Detection System” In IEEE PerCom 2015 [5] D. Li, T. Bansal, Z. Lu, and P. Sinha, Marvel: multiple antenna based relative vehicle localizer, in Mobicom. ACM, 2012. [6] Pushpendra Singh , Nikita Juneja , Shruti Kapoor, Using mobile phone sensors to detect driving behavior, Proceedings of the 3rd ACM Symposium on Computing for Development, January 11- 12, 2013, Bangalore, India [doi¿10.1145/2442882.2442941] [7] G. Somasundaram, Kavitha, and K. I. Ramachandran, ”LANE CHANGE DETECTION AND TRACKING FOR A SAFE- LANE APPROACH IN REAL TIME VISION BASED NAV- IGATION SYSTEMS,” 2011. [8] J. Schlechtriemen, A. Wedel, J. Hillenbrand, G. Breuel, and K.-D. Kuhnert, ”A Lane Change Detection Approach using Feature Ranking with Maximized Predictive Power,” in 2014 IEEE Intelligent Vehicles Symposium (IV), Dearborn, Michigan, USA, 2014. [9] Satzoda, R.K. (2014) Drive Analysis using Vehicle Dynamics and Vision-based Lane Semantics, USA: IEEE Transactions on Intelligent Transportation Systems. [10] M. Fazeen, B. Gozick, R. Dantu, M. Bhukhiya, and M. C. Gonzalez, Safe driving using mobile phones, IEEE Transactions on ITS, 2012. [11] R. Serway and J. Jewett, Physics for scientists and engineers. Cengage Learning, 2013. [12] J. Paefgen, F. Kehr, Y. Zhai, and F. Michahelles, ”Driving Behavior Analysis with Smartphones: Insights from a Controlled Field Study,”.
  • 12. 12 Data: readings coming online (real time) from both Gyroscope and Accelerometer sensors. Result: detecting at which location a lane change happened and stores that in the data file. checkMobileDevice(GY ROFlag, ACCFlag) ACCBigWindow = empty; GY ROBigWindow = empty; while true do GyroSmallWindow = fillGyro(GY ROFlag); ACCSmallWindow = fillAcc(ACCFlag); end if AHASLaneChange(ACCSmallWindow) then AccLanes[i] = recordLanechangeTimeandlocation else ACCaddTOBigWindow(ACCSmallWindow) end if GHasLaneChange(GyroSmallWindow) then GY ROLanes[i] = recordLanechangeTimeandlocation else GY ROaddTOBigWindow(GY ROSmallWindow) end if AHASLaneChange(ACCBigWindow) then AccLanes[i] = recordLanechangeTimeandlocation else if Full(ACCBigWindow) then ACCBigWindow=empty; end end if GHASLaneChange(GY ROBigWindow) then GY ROLanes[i] = recordLanechangeTimeandlocation else if Full(GYROBigWindow) then GYROBigWindow=empty; end end voting(GY ROLanes, ACCLanes); Algorithm 1: Online lane change detection al- gorithm which processes data coming from both Gyroscope sensor and Accelerometer sensor. Data: readings coming online (real time) from Microphone sensor. Result: extracting blinker pattern. while soundsignalstillcoming do FillBuffer(Buffer, soundSignal) FourierTransform(Buffer) HighPassFilter(Buffer) IntensityComponent(Buffer) recursivelyFindBlinks(Buffer, threshold); end Algorithm 2: Online lane change detection algo- rithm which processes sound signal coming from the microphone sensor. 1: procedure RECURSIVELYFIND- BLINKS(Buffer, threshold); if width(Buffer) > CONSTANT then middle = Buffer[MiddleIndex]; sdr = calculateSD(rightHalf); sdl = calculateSD(leftHalf); dr = calculateD(sdr, middle); dl = calculateD(sdl, middle); if sdr − dr > threshold then middle is a blink; store(middle); threschold = sdr − dr; recursivelyFindBlinks(rightHalf, threshol end if sdl − dl > threshold then middle is a blink; store(middle); threschold = sdl − dl; recursivelyFindBlinks(leftHalf, threshold end end 2: end procedure Algorithm 3: recursivelyFindBlinks