0% found this document useful (0 votes)
216 views

Analysis and Control of Traffic Using Artificial Intelligence

This document is a seminar report submitted by Pratik Goyal to partially fulfill seminar work requirements. The report analyzes and proposes using artificial intelligence techniques like neural networks for traffic control and management. It discusses literature on using AI for traffic, describes common AI techniques, proposes a system architecture using video cameras and sensors for data collection, and presents experimental results analyzing vehicle detection during day and night times. The report aims to investigate using AI like ANNs to eliminate or reduce traffic and improve safety.

Uploaded by

Ketaki
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
216 views

Analysis and Control of Traffic Using Artificial Intelligence

This document is a seminar report submitted by Pratik Goyal to partially fulfill seminar work requirements. The report analyzes and proposes using artificial intelligence techniques like neural networks for traffic control and management. It discusses literature on using AI for traffic, describes common AI techniques, proposes a system architecture using video cameras and sensors for data collection, and presents experimental results analyzing vehicle detection during day and night times. The report aims to investigate using AI like ANNs to eliminate or reduce traffic and improve safety.

Uploaded by

Ketaki
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 38

A

Seminar Report

On

“Analysis and Control of Traffic using


Artificial Intelligence”

submitted by:
Pratik Goyal
Roll Number:3146

T.E. Division A

Seminar Guide
Prof.J.R.Tambe

For the partial fulfilment of


Seminar Work in T.E. Computer Engineering

Department of Computer Engineering


Amrutvahini College of Engineering
Sangamner

2020-21
Department of Computer Engineering
Amrutvahini College of Engineering,
Sangamner

CERTIFICATE

This is to certify that Mr. Goyal Pratik Dharamveer student in Third Year
Division A, Computer Engineering has successfully completed her Seminar titled
“Analysis and Control of Traffic using Artificial Intelligence” at Amrutvahini College
of Engineering, Sangamner towards partial fulfillment of Seminar Workin Computer
Engineering.

Prof. J.R.Tambe Prof. A.N.Nawathe


Seminar Guide Seminar Coordinator

Prof. R.L.Paikrao Dr. M.A.Venkatesh


Head of Department Principal
Abstract
The increase in both rural and urban road traffic flow in recent years has led to several
disasters in the transportation sector which include trafficcongestion, accidents, and high
rateof pollution. Alternative traffic control measures are needed whenever there is failure
of conventional trafficcontrol or real time traffic issues at road intersection. This current
study seeks to investigate the stability and efficiency of Artificial Intelligence (AI)
techniques, the artificial neural network (ANN) for eliminating or reducing traffic volume
in the case of non- autonomous vehicles in a mixedSouth African traffic flow conditions.
Electronic traffic data ofone hundred and twenty six (126) vehicles were observed from
Mikros Traffic Monitoring (MTM) firm, a subsidiary of Syntell Group of Company, South
Africa. The traffic data was obtained via the traffic technologies employed at MTM which
are basically sensor embedded on road surfaces to monitor and control vehicles which
passes the traffic counter daily..

Keywords -Traffic safty;Traffic accident;Analogy analysis;Vehicle Detection;image


processing;Traffic signal coordination
Acknowledgements
Achievement is Finding out what you have been doing and what you have to do. The
higher is submit,the harder is climb. The goal was fixed and I began with the determined
resolved and put in a ceaseless sustained hard work. Greater the challenge, greater was
our determination and it guided us to overcome all difficulties. It has been rightly said
that we are built on the shoulders of others. For everything I have achieved, the credit
goes to who had really help us to complete this seminar and for the timely guidance and
infrastructure. Before we proceed any further, We would like to thank all those who have
helped me in all the way through. To start with I thankful to Honorable Principal Dr.
M. A. Venkatesh sir for his encouragement and support. I also thankful to our respected
Head of Department Prof. R.L.Paikrao . I would also like to take this opportunity to thank
to Seminar Coordinator Prof. A.N.Nawathe and my guide Prof. J.R.Tambe for her
guidance, care and support, which she offered whenever I needed it the most.

ii
Contents

Abstract i

Acknowledgements ii

Contents iii

List of Figures v

Abbreviations vii

1 Introduction 1

2 Literature Survey 3

3 What Is Artificial Intelligence? 5


3.1 How does Artificial Intelligence Work? ............................................................... 6
3.2 Characteristics of Artificial Intelligence: .............................................................. 6
3.3 Main reasons for successful growing of AI at present ....................................... 8
3.4 Main areas of AI using in transportation ....................................................... 8

4 Artificial Intelligence Techniques 10


4.1 Genetic Algorithm (GA) ................................................................................. 11
4.2 Fuzzy sets / logic............................................................................................ 11
4.3 Neural Network ................................................................................................. 12
4.4 Advantages of Artificial Intelligence .................................................................. 13
4.5 Applications ......................................................................................................... 13

5 System Architecture 15
5.1 AI Architecture for Traffic Control System ................................................... 15
5.1.1 Video capturing Method: ...................................................................... 16
5.1.2 Object Detection..................................................................................... 16
5.1.3 Object tracking ....................................................................................... 17
5.1.4 Data collection methods ........................................................................ 18

6 Proposed Solution For Traffic Control: 20


6.1 Proposed model ....................................................................................................... 20
6.1.1 Pre-processing method ................................................................................ 21
6.1.2 Vehicle Detection in Day Time .............................................................. 21

iii
Contents iv

6.1.3 Vehicle Detection in Night Time............................................................ 22

7 Experimental Results And Analysis: 24


7.0.1 Analysis of Vehicle Detection During The Night: .............................. 24
7.0.2 Analysis of Vehicle Detection During The Day: ................................ 25
7.1 Algorithm ............................................................................................................ 26

8 conclusion 28

References 29

iv
List of Figures

3.1 AI In Real World .............................................................................................. 5

4.1 Artificial Intelligence Techniques ........................................................................ 10

4.2 Fuzzy Logic Architecture .................................................................................... 12

4.3 Neural Network ...................................................................................................13

5.1 Architecture of Al for Traffic Control ................................................................ 15

5.2 Camera for traffic control ................................................................................... 16

5.3 Object-detection-algorithm ...................................................................................... 17

5.4 Object tracking Algorithm ..............................................................................18

5.5 Ultrasonic vehicle detector .................................................................................... 18

5.6 Traffic controller .................................................................................................. 19

6.1 Block diagram of proposed model ........................................................................ 20

6.2 Block diagram of pre- processing data ................................................................. 21

6.3 Vehicle Detection in Day Time........................................................................... 22

6.4 Vehicle Detection for day and night time .......................................................... 23

6.5 Vehicle Detection in night Time ......................................................................... 23

7.1 Night time vehicle detection chart ..................................................................... 24

7.2 Day time vehicle detection chart ........................................................................ 25

7.3 Vehicle detection graph .......................................................................................... 25

v
List of Figures vi

7.4 Formula ............................................................................................................... 26

7.5 Algorithm ............................................................................................................ 27


Abbreviations

AI Artificial Intelligence
RFID Radio frequency identification
HSV Hue,Saturation,Value
ITS Intelligent transport system
NN Neural network
FS Fuzzy system
GA Genetic Algorithm

vii
Chapter 1

Introduction

Intelligent technologies which are penetrating to different parts of human life don’t
ignore transportation. we can take intelligent transport systems and automated
transport systems which use information, transportation and communication tech-
nologies implemented to vehicles or to infrastructure. These systems aim to in-
crease people or goods mobility along with increasing road safety and transporta-
tion comfort, reduction of transport collisions and impacts on environment. Infor-
mation technologies usage became inherent component of “human“ development.
Ability to effectively process and use information and knowledge became one of the
most important parts of economic growth and prosperity. In transportation, the still
changing environment of many participants, special attention should be paid to
artificial intelligence – progressive information technology.
The standard traffic control systems used are very antiquated compared to the
fast pace of life that we live today. Manual controlling and automatic controlling are
the two most commonly used systems . Manual controlling involves presence of
traffic police where the traffic signals in controlled by his commands. On the other
hand, automatic controlling system uses constant timer technology where the
signal alters after a fixed interval of time. Image processing techniques canbe
implemented to manage traffic control system and avoid the above drawbacks
while providing a more efficient approach. a system where sensors and other re-
lated hardware like RFID active tag, RFID passive tag, and RF reader were used
to identify the presence of vehicle and change traffic light accordingly. A HSV based
approach use the hue and value of the image to determine the day time

1
Chapter 1. Introduction 2

and night time image . Only the value parameter of the images has been included
after analyzing in this research in order to differentiate between the day and night
images.Also contain process of determining the headlights of vehicles to count the
number of existing vehicles on a road at night using gray scale conversion, noise
filtering and background.
As the number of vehicles keeps on increasing and the scale of cities expands
rapidly, growing urban traffic congestion is a serious problem faced by cities around
the world. With the development of communication, computing and control tech-
nologies for intelligent transportation systems (ITS), adopting network-wide traffic
signal control strategies is an efficient way to mitigate traffic. In this framework, the
first and the important step is to establish an artificial traffic model to describethe
dynamics of traffic flows in urban networks which is possible due to influence of AI.
The section I of the study indicates Artificial intelligence definition,characteristics,Main
reasons for successful growing of AI at present, section II of the study express the
influence of AI in transportation. III AI Techniques section IV system architecture
,section V Data collection methods ,section VI Proposed solution for traffic control
and Analysis,Expected result etc.

Department of Computer Engineering


Chapter 2

Literature Survey

Harpal et al. implemented a system where sensors and other related hardware like RFID
active tag, RFID passive tag, and RF reader were used to identify the presence of vehicle
and change traffic light accordingly .

Albagul et al. also developed a system using infrared object detector . The above implemented
systems require a lot of hardware installations and that can often provide erroneous results
due to interference in signals. As a result, image processing is an effective approach
compared to these traditional methodologies.

Choudekar et al. applied edge detection in their research works for detecting vehicles
. However, the detection of the vehicles can be done without the implementation of edge
detection using the comparison of pixels of foreground and background images thus
increasing the efficiency of the system.

Taha et al. implemented a HSV based approach where they experiment the hue and value
of the image to determine the day time and night time image . Only the valueparameter of
the images has been included after analyzing in this research in order to differentiate between
the day and night images.

Perera et al. applied a process of determining the headlights of vehicles to count the
number of existing vehicles of a road at night using gray scale conversion, noise filtering
and background subtraction . Eliminating the mentioned processes, we converted the
RGB foreground image directly to black and white format with a threshold value to

3
Chapter 2. Literature Survey 4

preserve only the headlight pixels eliminating all the unnecessary ones, thus adding to
the overall efficiency of this system.

Department of Computer Engineering


Chapter 3

What Is Artificial Intelligence?

AI is branch of computer science that involves creation of intelligent machines that work
exactly like humans and possess all the capabilities as that of a human brain.

Artificial Intelligence:

FIGURE 3.1: AI In Real World

According to these definitions we can say that AI systems are characterized by:
They think like people .
They act like people.
They think reasonably (rational).

5
Chapter 3. What Is Artificial Intelligence 6

They can perform a numerous human function such as speech recognition , learning ,
planning and problem solving . AI is set of algorithm and intelligence to try to mimic
human intelligence .

3.1 How does Artificial Intelligence Work?

AI works by combining large amounts of data with fast, iterative processing and intelli-
gent algorithms, allowing the software to learn automatically from patterns or features in
the data.

Artificial Intelligence mainly works on three techniques. They are Symbolic AI, Data-
Driven and Future development. Symbolic artificial intelligent covers Expert systems,
Fuzzy logic and Early principle of AI. An expert system, the computer is given a prob-
lem and few practices were carried out to check its logical problem-solving skills. They
have given a set of rules and they will strictly follow the best in a constrained environ-
ment.In fuzzy logic, it is mostly true or false method and applied in control systems. In
Data-driven machine learning, Neural networks and deep learning algorithm are applied
process the pool of data by data mining and big data and is applied in NLP. It is im- portant
to distinguish between different methods and apply the right one to their level of
maturity.

Artificial Intelligence in education makes a worthy contribution to human beings. Here a


complex problem is solved by dividing the problem into subunits and finding the solution
to each subunit. The subunit may be a system or human trying to find a solution to
the problem. The proposed theory shows that cognitive science in education developed
a tutor by programming a computer and that tutor would watch the students problem-
solving skills. Now the tutor will guide the student and advises them in each step of his
solution by preventing them before they fell into a trap. This method makes the student
learn a lesson about the problem and be cognitive in the future.

3.2 Characteristics of Artificial Intelligence:

1. Eliminate dull tasks

Department of Computer Engineering


Chapter 3. What Is Artificial Intelligence 7

We all have days where we have to do busy work: dull, boring tasks that may be necessary but
are neither important nor valuable. Fortunately, AI are beginning to address someof
this through human-computer interaction technologies. Virtual assistants like Siri,
Cortana, and Google Assistant perform basic tasks, conversing with the user in natural
language.

2. Focus diffuse problems

Data informs every level of a modern company’s operation. Even small businesses have
a lot of material to interpret, so a major enterprise consumes amounts of information at
a scale equally awe-inspiring and terrifying.

3. Distribute data

Modern cybersecurity drives a need for comparing terabytes of inside data with a com-
parable amount of outside data. This has been a very difficult problem to solve, but AI
are perfect tools for the job.

4. Solve dynamic data

Every business book written in the past 50 years has sections devoted to developing
efficiency; it is a prized workplace characteristic. A major stumbling block in that pursuit
has always been addressing individual employee traits. Now, some forward- looking
companies are adopting AI to solve the dynamic problems of human behavior.

5. Prevent dangerous issues

Cutting-edge industrial systems combine AI-powered robots, 3D printing, and human


oversight. Not only can companies realize billions in savings with these systems, but they
will also save lives.

Industrial automation leader Rethink Robotics builds interactive robot systems driven
by AI. This process not only reduces cost and improves efficiency for the company, but
creates much safer environments for the human workers. The dangerous elements of
manufacturing jobs are supplanted by machines, while the brains behind them remain
safe and human.

Department of Computer Engineering


Chapter 3. What Is Artificial Intelligence 8

3.3 Main reasons for successful growing of AI at present

However AI theory is developing some decade years already its using had to wait for
progress in IT technologies area. Including AI in transport machines or systems requires:

The huge development of IT technologies. The development of computer components –


mainly speedy processors, high capacity memory devices etc.

Digitalization of sound and image – for inputs.

Computer networks creation and growth as wireless nets, logistic systems, Internet are.

Satellite and mobile nets.

Progress in transport devices area.

Thanks to this current technical progress Artificial Intelligence contains ways and means
to be used in transportation such as neural nets, AI planning, evolution algorithms,
knowing and expert systems, fuzzy logic, multi-agent systems, vector regression, data
mining, optimizing techniques, etc.

3.4 Main areas of AI using in transportation

AI at present provides instruments and allows solving problems in each kind of transport
and their interaction (air, road, railway and water transport) and is used in areas such
as:

Real time transport managing.

Design, operation, time schedule and administration of logistical systems and freight
transport.

Transport policy, planning, projecting and managing.

Questions related to environment, toll – roads, reliability and safety.

Travel demands analysis, predictions and transport organization.

City planning of sustainable mobility.

Department of Computer Engineering


Chapter 3. What Is Artificial Intelligence 9

Service oriented architecture of vehicles and vehicles in communication infrastructure.

Artificial transport systems and simulations.

AI techniques allow using applications for entire transport system managing – vehicle,
driver, infrastructure and the way in which these components dynamically offer transport
services.

Department of Computer Engineering


Chapter 4

Artificial Intelligence Techniques

AI methods have been introduced to develop innovative traffic control strategies and
fine tune signal timing plans and parameters. These AI applications can be summarized
into the following three categories and detailed in the remaining of this study: neural
networks (NN), fuzzy systems (FS), and Genetic Algorithm (GA). An introduction tothese
AI methods is given below Figure.

FIGURE 4.1: Artificial Intelligence Techniques

10
Chapter 4. Artificial Intelligence Techniques 11

4.1 Genetic Algorithm (GA)

Genetic Algorithm is an evolutionary algorithm. The model is based on three basic design
items: the use of genetic algorithms as an optimization technique, the use of cellular
automata simulators within the evaluation function, and the use of a clusteras a
parallel execution environment for this architecture. The number of traffic signals
contained in the traffic circle under study is supposed to be “N Stages”; the chromosome
encoding consists of the state of every traffic light, at every step of the fixed period. There
are allowed only two possible states: Red encoded as ’1’ – and Intermittent Yellow –
encoded as ’0’. This have been set like this in order to simulate two real world traffic
control commands: ’Stop’ (Red Light) and ’Pass with caution’ (Intermittent Yellow).The
initial population of the GA is created randomly. At random points – for a pair of parent
chromosomes – it selected two random points, cuts them at these positions into three
pieces and then interchanges the central chunk. When an individual is chosen to be
mutated – according to the mutation probability – the value stored at a randomly chosen
position of its. the number of vehicles that left the network during the traffic simulation
carried out.

4.2 Fuzzy sets / logic

Fuzzy logic is widely used in a machine control. fuzzy logic has the advantage that
the solution to the problem can be cast in terms that human operators can understand
.Fuzzy control systems include input values in terms of logical variables that take on
continuous values between 0 and 1 based on fuzzy logic. the design of a fuzzy traffic light
controller at the intersection of two streets that changes cycle time depending uponthe
densities of cars behind green and red lights and the current cycle time. A fuzzy model of
the system has been built and tested to predict the behavior of the model underdifferent
traffic conditions. Based fuzzy inference system was used to synchronize the time of
duration and phase angle of the traffic lights, and also maintain the maximum possible
velocity of the vehicles traveling on the road. The classifier event action block can
implement both crisp and fuzzy rules. This system uses one network of traffic light
controller agents at each intersection. Each traffic controller agent uses a fuzzy classifier
block to make decisions about traffic light timing in order to minimize local vehicle

Department of Computer Engineering


Chapter 4. Artificial Intelligence Techniques 12

wait time. The traffic data are acquired from the detectors in the intersections and lanes.
Mistakes were possible due to different car lengths, car speeds, and the length of the
intersection. Therefore, this approach consequently reduced car waiting times and start-
up delay times using fuzzy control of feedback data.

FIGURE 4.2: Fuzzy Logic Architecture

4.3 Neural Network

Traffic light can be controlled by collecting of information about the number of passing
vehicles, and processing this data. The neural network computes timing information for
the control unit of the traffic lights controller on the basis of the information coming from
the cameras or sensors. ENN is another traffic light control system developedto deal
with object recognition in outdoor environments . In outdoor environments, lighting
conditions cannot be controlled or predicted, objects can be partially occluded, and their
position and orientation is not known a priori. The chosen objects are traffic or road signs,
due to ease of sign maintenance and inventory in highways and cities, driver support
systems and intelligent autonomous vehicles. A neural network can achieve classification
and have presented an intelligent traffic light control method based on extension theory
for crossroads. First, the number of passing vehicles and maximum passing time of one
vehicle within the green light time period are measured in the main-line and sub-line of a
selected crossroad. Some experimental results were obtainedto verify the effectiveness
of the proposed intelligent traffic flow control method. The diagnostic results indicated
that the proposed estimated method can discriminate the traffic flow of a standard
crossroad rapidly and accurately.

Department of Computer Engineering


Chapter 4. Artificial Intelligence Techniques 13

FIGURE 4.3: Neural Network

4.4 Advantages of Artificial Intelligence

1.Minimal human intervention


2.Faster and accurate
3.Performance/Quality increases
4.Solving new problems
5.Better handling of information
6.Digital Assistance
7.Handling Repetitive Jobs
8.In Medical Applications
9.Hazardous Exploration
10.Reduction of Error

4.5 Applications

1. AI In Marketing

With the growing advancement in AI, in the near future, it may be possible for consumers
on the web to buy products by snapping a photo of it.

2. AI In Banking

Department of Computer Engineering


Chapter 4. Artificial Intelligence Techniques 14

AI in banking is growing faster than you thought! A lot of banks have already adopted
AI-based systems to provide customer support, detect anomalies and credit card frauds.
An example of this is HDFC Bank.

3. AI In Finance

Ventures have been relying on computers and data scientists to determine future patterns
in the market. Trading mainly depends on the ability to predict the future accurately.

Machines are great at this because they can crunch a huge amount of data in a short span.
Machines can also learn to observe patterns in past data and predict how these patterns
might repeat in the future.

4. AI In Agriculture

AI can help farmers get more from the land while using resources more sustainably.Issues
such as climate change, population growth, and food security concerns have pushed the
industry into seeking more innovative approaches to improve crop yield.

5. AI In HealthCare

When it comes to saving our lives, a lot of organizations and medical care centers are
relying on AI. There are many examples of how AI in healthcare has helped patients all
over the world.

6. AI In Gaming

Over the past few years, Artificial Intelligence has become an integral part of the gaming
industry. In fact, one of the biggest accomplishments of AI is in the gaming industry.

7. AI In Autonomous Vehicles

For the longest time, self-driving cars have been a buzzword in the AI industry. The
development of autonomous vehicles will definitely revolutionaries the transport system.

Department of Computer Engineering


Chapter 5

System Architecture

5.1 AI Architecture for Traffic Control System

FIGURE 5.1: Architecture of Al for Traffic Control

AI System for Traffic control contents :

There are Five types of processes

A.Video capturing

B. Object detection

C. Object tracking

D. Vehicle count

15
Chapter 5. System Architecture 16

E. Data storage/Data collection methods

5.1.1 Video capturing Method:

Closed-circuit television (CCTV) cameras are an important tool in the transportation


management toolbox. Transportation agencies rely on them for incident verification,
response preparation, traffic management awareness, special events, weather conditions,
and much more.

The operational benefits of real-time video are somewhat obvious so why would an
agency also be interested in recording or archiving any of this CCTV video footage.

FIGURE 5.2: Camera for traffic control

5.1.2 Object Detection

Object detection is a computer technology related to computer vision and image pro- cessing
that deals with detecting instances of semantic objects of a certain class in digital images and
videos. Well-researched domains of object detection include face detectionand pedestrian
detection.

A good framework for real time object detection is Viola Jones Object Detection Frame-
work. It is fast at run time but slow in training. Object detection aids in pose estimation,
vehicle detection, surveillance etc.

Object detection algorithm is use for object detection as follows:

Department of Computer Engineering


Chapter 5. System Architecture 17

FIGURE 5.3: Object-detection-algorithm

5.1.3 Object tracking

Object tracking in videos is a classical computer vision problem. It consists of not only
detecting the object in a scene but also recognizing the object in each and every frame,
so as to distinguish it from other objects, both static and dynamic.

Characterization of an object is an extremely important component for any type of ob-


ject tracking algorithms.many features have been used in tracking algorithms, including
color histogram, histograms of oriented gradients (HOG) and ORB . In addition, search
strategies are also critical for tracking algorithms, and examples of search strategies
include both definite and random methods.

Algorithm use to track the vehicle on the road is as follows:

Department of Computer Engineering


Chapter 5. System Architecture 18

FIGURE 5.4: Object tracking Algorithm

5.1.4 Data collection methods

Two methods for data collection are planned to be used as follows:

a) Observation: we can count the traffic flow during one day, in some places that suffer
from traffic congestion, in order to get an actual data about transportation flow, peak
hours, and bottleneck, so we can find out where is the most effected aria by traffic
congestion.

b) Ultrasonic, and Image processing Vehicle Detector: Ultrasonic Vehicle detector will be
are installed at 300 m intervals used to detect vehicles based on the difference in arrival
time o f the waves which are reflected from vehicles and roads surface by transmitting
ultrasonic wave towards roadways.

FIGURE 5.5: Ultrasonic vehicle detector

Department of Computer Engineering


Chapter 5. System Architecture 19

C)We also plan to use a monitoring camera installed over roads which outputs traffic flow
information such as queue length in multiple lanes, volume, classification, occupancy,
presence, and speed. The camera will be strategically placed in the cross-sections at the
most effected aria by traffic congestion Figure 5.6.3. The data will be received and
processed within the model to adjust traffic lights timing to optimize traffic flow in
coordinated traffic lights systems.

FIGURE 5.6: Traffic controller

Department of Computer Engineering


Chapter 6

Proposed Solution For Traffic


Control:

6.1 Proposed model

Fig 6.1 presents a block diagram of the proposed model. In pre-processing state, day and
night images are differentiated using the methods described in section A. The images of
day and night are processed differently implementing the methods described in section B
and C, respectively.

FIGURE 6.1: Block diagram of proposed model

20
Chapter 6. Proposed Solution For Traffic Control 21

6.1.1 Pre-processing method

A. (Pre-processing) Day and Night image detection

Fig. 6.2 illustrates a block diagram of pre-processing. Firstly, the top half of the foreground
image with the natural light of the sky and artificial light of road lights is cropped out.

FIGURE 6.2: Block diagram of pre- processing data

Secondly, this RGB image is converted to HSV and vhistogram is computed. According
to Taha et al. bright pixels have v-component value above 150 in a 0 to 255 scale . This
scale has been converted to the range of 0 to 1 scale and used to determine the bright
pixels having v-components value above 0.59.

6.1.2 Vehicle Detection in Day Time

B. Vehicle Detection in Day Time

Fig. 6.3 illustrates block diagram of vehicle detection in day time.

Firstly, the RGB images are converted to gray scale images and the road portion of the
background image and foreground image is extracted using mask created with specific co-
ordinates for a specific road. Secondly, the foreground image is subtracted from the
background image which results in Fig.6.4(a). After that, the background image is

Department of Computer Engineering


Chapter 6. Proposed Solution For Traffic Control 22

FIGURE 6.3: Vehicle Detection in Day Time

subtracted from the foreground image to give an output of Fig.6.4(b). The reason for
subtracting twice is that some subtractions result in negative values due to subtraction
from lower dark pixels to brighter higher pixels. Afterwards, the images are binarized
by a threshold value shown in Fig. 6.4(c) and Fig.6.4(d). Then the negative pixels are
discarded while merging the two subtraction results. Fig. 6.4(e) represents the merged
binarized image.

(e) Fig. 6.4. Image subtraction and binarization. (a) Subtraction of foreground from
background. (b) Subtraction of background from foreground. (c) - (d) Binarization of
subtracted result images. (e) Merging of binarized image.

6.1.3 Vehicle Detection in Night Time

C. Night Time Image Processing Fig. 5 presents a block diagram of night time vehicle
detection procedure.

Fig. 6.5. Block diagram of night time image processing To detect night time vehicles,
the road portion of the foreground image is extracted using mask created with specific
co-ordinates for a specific road. Then the cropped foreground image is binarized by a

Department of Computer Engineering


Chapter 6. Proposed Solution For Traffic Control 23

FIGURE 6.4: Vehicle Detection for day and night time

FIGURE 6.5: Vehicle Detection in night Time

threshold value to filter only the pixels with high intensity thus extracting the headlights
which is shown in Fig. 6.4(a).

Department of Computer Engineering


Chapter 7

Experimental Results And


Analysis:

7.0.1 Analysis of Vehicle Detection During The Night:

Two sets of images were used in this system where the calculated accuracy varies from
80 to 100 percent and the average accuracy results out to be 94.10 percent . Compared
to the accuracy of 90.5 percent of vehicle detection at night in the research of Perera et
al. this system achieves a slightly higher accuracy of 94.1 percent .

FIGURE 7.1: Night time vehicle detection chart

24
Chapter 7. Experimental Results And Analysis 25

7.0.2 Analysis of Vehicle Detection During The Day:

This system achieves an accuracy of 95.08 percent to detect the number of vehicles during
the day compared to the edge detection methodology of Chandrasekhar et al. where the
accuracy was limited to 93.47 percent. Moreover, Hasan et al. approached the detection
of vehicles using the counting of white pixels of foreground image to detecttraffic density
directly . Whereas, this system detects the number of connected white pixels to create
vehicle objects and count their numbers to give a more precise count on the existing
vehicles rather than an overall traffic density.

FIGURE 7.2: Day time vehicle detection chart

FIGURE 7.3: Vehicle detection graph

Department of Computer Engineering


Chapter 7. Experimental Results And Analysis 26

Logical view – The results reveal that our proposed approach outperforms the other two
MPC control strategies in managing the traffic demands among subnetworks, especially
in the oversaturated traffic conditions. The reason for the lower subnetwork flow is that
the function of MFD is obtained from the curve fitting method, which are not able to
describe the scatter errors in the saturated and oversaturated part of MFD, leading to
inefficient usage of the network maximum flow. It may be solved by adding some
stochastic terms into the MFD function in future work. The similar result is clearly seen
in the MFDs for the three subnetworks. In order to further illustrate that the integrated
MPC approach is superior in distributing the number of vehicles efficiently over each
subnetwork, we utilize the standard deviation (SD) of link densities to analyze the
homogeneous degree within each subnetwork, which is defined as follows

FIGURE 7.4: Formula

7.1 Algorithm

Department of Computer Engineering


Chapter 7. Experimental Results And Analysis 27

FIGURE 7.5: Algorithm

Department of Computer Engineering


Chapter 8

conclusion

conclusion

As conclusion, we studied the optimization of traffic light controllers in a city using


Artificial Intelligence. Artificial Intelligence has increased understanding of the nature of
intelligence and provide an impressive array of application in wide range of areas as it has
broad utilization in every area of transport.it has sharpened understanding of human
reasoning, and of the nature of intelligence in general.

we can reduce the possibilities of traffic jams and Accident due to use of AI. Also the
number of passing vehicle on the road decides the density range of traffic and on basis
of vehicle count it decides the traffic light delays.

28
References

[1] Application of Artificial Intelligence in Traffic Control System of Non-autonomous Vehicles at


Signalized Road intersection (2020).

[2] The People’s Republic of China Road Traffic Accident Annual Statistical Report(2017).

[3] Article on ’Smart Traffic Control System Using Image Processing ’ Publishedin(2016).

[4] ’Traffic Analysis and Control Using Image Processing ’ an Article Published in(2017).

[5] The Impact of Autonomous Vehicles on Cities(2018).

29

You might also like