SlideShare a Scribd company logo
International Journal of Software Engineering & Applications (IJSEA), Vol.3, No.3, May 2012
DOI : 10.5121/ijsea.2012.3302 17
Neural Network based Vehicle Classification for
Intelligent Traffic Control
Saeid Fazli 1
, Shahram Mohammadi 2
, Morteza Rahmani 3
1,2,3
Electrical Engineering Department, Zanjan University, Zanjan, IRAN
Fazli@znu.ac.ir , Shahram@znu.ac.ir , Rahmanim@znu.ac.ir
ABSTRACT
Nowadays, number of vehicles has been increased and traditional systems of traffic controlling couldn’t be
able to meet the needs that cause to emergence of Intelligent Traffic Controlling Systems. They improve
controlling and urban management and increase confidence index in roads and highways. The goal of this
article is vehicles classification base on neural networks. In this research, it has been used a immovable
camera which is located in nearly close height of the road surface to detect and classify the vehicles. The
algorithm that used is included two general phases; at first, we are obtaining mobile vehicles in the traffic
situations by using some techniques included image processing and remove background of the images and
performing edge detection and morphology operations. In the second phase, vehicles near the camera are
selected and the specific features are processed and extracted. These features apply to the neural networks
as a vector so the outputs determine type of vehicle. This presented model is able to classify the vehicles in
three classes; heavy vehicles, light vehicles and motorcycles. Results demonstrate accuracy of the
algorithm and its highly functional level.
KEYWORDS
traffic controlling, vehicle classification, camera, neural network, image processing.
1. INTRODUCTION
By developing of digital cameras and increasing of power in processing computer, application of
this tools increased. So that in the most systems, it is used of these technologies. The systems of
controlling traffic intelligently was one of the applications which tools account of most countries.
By increasingly growth of vehicles and crossing them in the roads and highways and
unresponsible of available fundamental of vehicle. The need to a automatic system is presented
much more. The increase of demand for travelling in highways has reached to a explosive growth
in recent years. Building road and spreading fundamentals of vehicle is not only way and should
apply some new technologies for controlling traffic.
A way of controlling by video has been pay attention in parts of view computer. Nowadays In
most of the societies, It,s used of this intelligent system for controlling traffic and obtaining those
parameters of transportation. The using of systems of based on computer vision has been
accounted. It,s because of facility installation and high level of efficiency in controlling traffic
[1,2,3]. One of the most effective area in machine vision is processing into one mobile image. So
that it can obtain a lot of features of mobile objects.
One of the most important and basic in auto controlling traffic are detection and classification.
These process cause to extract a lot of parameters of traffic [2,4]. One of the hardest matter in
International Journal of Software Engineering & Applications (IJSEA), Vol.3, No.3, May 2012
18
computer vision is vehicle classification which need to a complicated algorithm and high
accuracy. So far diverse works have considered for this classification. These process mostly are
finding about separation and classify of vehicle from passengers. One of these ways is which
Gupte et al [5]. is suggester. In this suggestive way it has been used of dimensions of vehicles for
separation of cars and walked passengers. But It,s needed to more complicated for getting better
answer. Ma et al. have presented a new way of classification that is used of modifiers SIFT [6].
But responsive of this system is still unknown. The method of detection and classification of
vehicles with 3D was a way which Alex et al. suggester but It has own problems [7,8]. One of the
greatest problem is modelling of all vehicles as a 3D that almost is not possible. Our suggestive
method is a kind of neural network MLP that is used for vehicle classification.
2. THE SUGGESTED ALGORITHM
In this section we are analysing the algorithm which is used in this project. The algorithm
includes two general phases that each has different parts. The first phase in algorithm includes
background extraction and second includes finding passing vehicles and extracting the special
features. These features have been applying to a neural network multilayer perceptron (MLP) and
the classification of the vehicles has been being created as an output of neural network eventually.
This process has been described as Figure (1) following:
Movies that used in this project have been provided from several highways in province Zanjan-
Iran.
Figure 1. System overview
2.1. Background Extraction
To obtaining a background image, we are implementing following steps:
At first, we divide the input film obtained from the traffic scene into its forming frames and each
frame is converting to gray level image. By using threshold of all columns and line of frame, if
difference of pixels between 50 frames was smaller than a specific threshold, its value will be
considered as intensity of light in the background. In Figure (2) X, Y axis shows size of the input
image and position of each pixel has axis of X , Y and also height shows amount of brightness
intensity.
Background
Subtraction
Thresholding
and Feature
Extraction
MLP Neural
Network
Vehicle
Classificatio
International Journal of Software Engineering & Applications (IJSEA), Vol.3, No.3, May 2012
19
Figure 2. 3D drawing of background image
Now, It,
s gained some matrix that is input matrix as a background.
2.2. Extracting vehicles from an image
Extracting of vehicle is the most common way to obtain changes between two frames. For
recognition the changes between two frames of an image, the f(x, y, ti) and f(x, y, tj) frames take
in ti and tj times respectively, and comparison have be done for every pixels. For doing this, we
are considering the background that extracted of previous step as a resource image which includes
some constant items. Comparing of this image and the second one from the same traffic scene
include vehicles, we can subtract invariant elements in these images that have no differences and
maintain non-zero inputs that are equal to variant items of the images. Figure (3) shows images of
the subtraction of two images taken in ti and tj. subtracted as following: [1]
.1
Witch T is threshold.
A B
Figure 3. A) Original image B) Difference image from the original image
Now, It is used of method of approximation derive of image for recognizing of edge and then
when ever of image that has gradient in pixels is that edge. Since It might charge the object into


 >
−
=
.
0
)
,
,
(
)
,
,
(
1
)
,
(
otherwise
T
t
y
x
f
t
y
x
f
y
x
d j
i
ij
International Journal of Software Engineering & Applications (IJSEA), Vol.3, No.3, May 2012
20
several piece after finding edge or by using of operator of dilation morphology of these pieces are
linked together so it will be obtained a same object. As a result finding image will be labeled.
2.3. Recognizing of vehicles
This system is a form whence the vehicle is reached to the nearest distance of camera it can detect
it, in this case it dosent need to any other previous vehicle in frame. So, we find those frames
which put vehicles in the nearest distance to camera. Therefore, the process of detection begins
and we are processing the image of the nearest vehicle.
Now, we are obtaining the features of the some special object in the image. There are six feature
that including: length and width of the labelled objects, the area of object, in this case the
obtaining object will have some small cavities and holes after the subtracting process of
background. In this section, at first we are considering those cavities and holes and then obtaining
the total area of object which is like a crick. An other feature of them refers to the real numbers of
pixels in object. We need to use of two others features for better extracting vehicles. If we put a
circle into the object so that it can cover it, we use of diameter of this circle for another feature.
The last step is obtaining the ratio of distance between the centre of object and its length,
s main
axis, we use it for extracting features variable. After extracting features, we,
ll make the vector for
these features.
2.4. Obtaining the output from the neural network
After, that processing in the image and extracting of those features as a feature,
s vector to the
neural network, so process of recognizing is done. The order of operation is this, at first we are
saving the vector in the file excel which including six columns and each of them is presentation of
a feature of object. We are specifying every kind of this feature,
s vector for our classification
including three types: heavy vehicle, light vehicle and motorcycle. We are producing these data
for neural network and then are defined the target vector for teaching neural network. The special
neural network that is considered in this project is multilayer perceptron (MLP) with two hidden
layers.
The output of neural network can recognize the type crossing vehicle which has shown in Figure
(4). In this project we have classified the vehicles into 3 types as a heavy and light vehicles and
motorcycle. At last the performance of the system was satisfied.
Figure 4. Result of the algorithm when crossing heavy vehicle
International Journal of Software Engineering & Applications (IJSEA), Vol.3, No.3, May 2012
21
3. EXPERIMENTAL RESULTS
In today society, the techniques of vehicle detection and classification based on visuality of
camera for controlling traffic is the one the main programs and effective in the system of vehicle.
Intelligent systems made the people to have ensured more than before. So, This system is
conducting in the most countries. The designed system in this study is in the height almost higher
than roods which has used for film taking of trafficking scene with a instant camera. It is able to
detect and classify of crossing vehicle with minimum information. It,
s one of the most important
factor in automatic controlling of traffic and finding a lot of details of traffic. It also helps to
decrease of accidents. In addition to ability of vehicle detection and classification, it will be able
to obtain the numbers of crossing cars in every time. The algorithm is done successfully. Figure
(5) illustrates a part of results.
Figure 5. Results of the algorithm on some image frame
The outcome results verified the accuracy and high level of the performance of this method. So
that it can detect and classify the special system with higher than %90 of crossing vehicle in the
scenes of traffic. The finding results have been show in the following tables.
Table 1. Classification Results
Heavy
vehicles
Light
Vehicles
Motorcycle Total
vehicles
Number Of
Vehicle
21 128 33 182
Number Of
Detection
17 119 28 164
Classification
Rate
81% 93% 85% 90%
International Journal of Software Engineering & Applications (IJSEA), Vol.3, No.3, May 2012
22
4. CONCLUSION
In this project, a traffic controlling system base on neural networks has been presented that it can
recognize vehicles in a traffic scene and categorize it. Finding transportation parameters
especially number and type of vehicles are one of the most important and applicable factors that
cause to increase confidence index and reduce road crashes in roadways and highways. The
camera that used in this project located in a place above the road surface. As an advantage of used
method in design of algorithm is the camera don’ts need to calibration. After recognition of
vehicles, they have been categorized in three classes. The results of testing of this method in
several highways in Zanjan city were satisfying. In the future we can integrate whole of the
system and make a network, then it is possible to categorize transportation vehicles base on real
time.
REFERENCES
[1] Naixue Xiong, Jing He, Jong Hyuk Park, Donald Cooley, Yingshu Li. A Neural Network Based
Vehicle Classification System for Pervasive Smart Road Security. Journal of Universal Computer
Science, vol. 15, no. 5 (2009), 1119-1142
[2] N. K. Kanhere and S. T. Birchfield. Real-Time Incremental Segmentation and Tracking of Vehicles at
Low Camera Angles Using Stable Features.
. IEEE Transactions on Intelligen Transportation Systems,
9(1):148-160, March 2008.
[3] N. K. Kanhere, S. T. Birchfield, W. A. Sarasua, and S. Khoeini. Traffic Monitoring of Motorcycles
During Special Events Using Video Detection. Transportation Research Record: Journal of the
Transportation Research Board, 2010.
[4] Jin-Cyuan Lai, and Shih-Shinh Huang, and Chien-Cheng Tseng.
. I
Im
ma
ag
ge
e-
-b
ba
as
se
ed
d v
ve
eh
hi
ic
cl
le
e t
tr
ra
ac
ck
ki
in
ng
g a
an
nd
d
c
cl
la
as
ss
si
if
fi
ic
ca
at
ti
io
on
n o
on
n t
th
he
e h
hi
ig
gh
hw
wa
ay
y.
. Green Circuits and Systems (ICGCS), 2010 International Conference
on,
, N
NO
O.
. 2
21
1,
, June 2010.
.
[5] S. Gupte, O. Masoud, R. F. K. Martin, and N. P. Papanikolopoulos. Detection and Classification of
Vehicles. IEEE Transactions on Intelligent Transportation Systems, 3(1), 2002, 37-47.
[6] X. Ma, W. E. L. Grimson. Edge-based rich representation for vehicle classification. Proc. of the
International Conference on Computer Vision, 2006, 1185-1192.
[7] A
Am
mo
ol
l A
Am
mb
ba
ar
rd
de
ek
ka
ar
r,
, M
Mi
ir
rc
ce
ea
a N
Ni
ic
co
ol
le
es
sc
cu
u,
, a
an
nd
d G
Ge
eo
or
rg
ge
e B
Be
eb
bi
is
s.
. E
Ef
ff
fi
ic
ci
ie
en
nt
t V
Ve
eh
hi
ic
cl
le
e T
Tr
ra
ac
ck
ki
in
ng
g a
an
nd
d
C
Cl
la
as
ss
si
if
fi
ic
ca
at
ti
io
on
n for a
an
n A
Au
ut
to
om
ma
at
te
ed
d T
Tr
ra
af
ff
fi
ic
c S
Su
ur
rv
ve
ei
il
ll
la
an
nc
ce
e S
Sy
ys
st
te
em
m.
. D
De
ep
pa
ar
rt
tm
me
en
nt
t o
of
f C
Co
om
mp
pu
ut
te
er
r S
Sc
ci
ie
en
nc
ce
e a
an
nd
d
E
En
ng
gi
in
ne
ee
er
ri
in
ng
g U
Un
ni
iv
ve
er
rs
si
it
ty
y o
of
f N
Ne
ev
va
ad
da
a,
, R
Re
en
no
o U
U.
.S
S.
.A
A.
.,
, Aug 2008.
[8] Limin Xia. Vehicle Recognition Using Boosting Neural Network Classifiers. Proceedings of the 6th
World Congress on Intelligent Control and Automation, June 21 - 23, 2006, Dalian, China.

More Related Content

PDF
IJCER (www.ijceronline.com) International Journal of computational Engineerin...
PDF
Classification and Detection of Vehicles using Deep Learning
PDF
VEHICLE CLASSIFICATION USING THE CONVOLUTION NEURAL NETWORK APPROACH
PDF
A Traffic Sign Classifier Model using Sage Maker
PDF
CANNY EDGE DETECTION BASED REAL-TIME INTELLIGENT PARKING MANAGEMENT SYSTEM
PDF
Research on object detection and recognition using machine learning algorithm...
PDF
IMAGE RECOGNITION USING MATLAB SIMULINK BLOCKSET
PDF
Real Time Object Identification for Intelligent Video Surveillance Applications
IJCER (www.ijceronline.com) International Journal of computational Engineerin...
Classification and Detection of Vehicles using Deep Learning
VEHICLE CLASSIFICATION USING THE CONVOLUTION NEURAL NETWORK APPROACH
A Traffic Sign Classifier Model using Sage Maker
CANNY EDGE DETECTION BASED REAL-TIME INTELLIGENT PARKING MANAGEMENT SYSTEM
Research on object detection and recognition using machine learning algorithm...
IMAGE RECOGNITION USING MATLAB SIMULINK BLOCKSET
Real Time Object Identification for Intelligent Video Surveillance Applications

What's hot (20)

PDF
OpenCVand Matlab based Car Parking System Module for Smart City using Circle ...
PDF
Identification and classification of moving vehicles on road
PDF
IRJET- Automatic Traffic Sign Detection and Recognition using CNN
PDF
Design and development of DrawBot using image processing
PDF
IRJET- Identification of Scene Images using Convolutional Neural Networks - A...
PDF
Intelligent Parking Space Detection System Based on Image Segmentation
PDF
Identification and Control of Three-Links Electrically Driven Robot Arm Using...
PDF
Smart element aware gate controller for intelligent wheeled robot navigation
PDF
MULTIPLE HUMAN TRACKING USING RETINANET FEATURES, SIAMESE NEURAL NETWORK, AND...
PDF
Industrial Microcontroller Based Neural Network Controlled Autonomous Vehicle
PDF
Improving face recognition by artificial neural network using principal compo...
PDF
Robot Machine Vision
PDF
Traffic Light Detection and Recognition for Self Driving Cars using Deep Lear...
PDF
Objects detection and tracking using fast principle component purist and kalm...
PDF
IRJET - Steering Wheel Angle Prediction for Self-Driving Cars
PDF
Vehicle detection and tracking techniques a concise review
PDF
IRJET- Implementation of Gender Detection with Notice Board using Raspberry Pi
PDF
journal nakk
PDF
Number Plate Recognition of Still Images in Vehicular Parking System
PDF
Leader follower formation control of ground vehicles using camshift based gui...
OpenCVand Matlab based Car Parking System Module for Smart City using Circle ...
Identification and classification of moving vehicles on road
IRJET- Automatic Traffic Sign Detection and Recognition using CNN
Design and development of DrawBot using image processing
IRJET- Identification of Scene Images using Convolutional Neural Networks - A...
Intelligent Parking Space Detection System Based on Image Segmentation
Identification and Control of Three-Links Electrically Driven Robot Arm Using...
Smart element aware gate controller for intelligent wheeled robot navigation
MULTIPLE HUMAN TRACKING USING RETINANET FEATURES, SIAMESE NEURAL NETWORK, AND...
Industrial Microcontroller Based Neural Network Controlled Autonomous Vehicle
Improving face recognition by artificial neural network using principal compo...
Robot Machine Vision
Traffic Light Detection and Recognition for Self Driving Cars using Deep Lear...
Objects detection and tracking using fast principle component purist and kalm...
IRJET - Steering Wheel Angle Prediction for Self-Driving Cars
Vehicle detection and tracking techniques a concise review
IRJET- Implementation of Gender Detection with Notice Board using Raspberry Pi
journal nakk
Number Plate Recognition of Still Images in Vehicular Parking System
Leader follower formation control of ground vehicles using camshift based gui...
Ad

Similar to Neural Network based Vehicle Classification for Intelligent Traffic Control (20)

PDF
A real-time system for vehicle detection with shadow removal and vehicle clas...
PDF
IRJET - Vehicle Classification with Time-Frequency Domain Features using ...
PDF
An Analysis of Various Deep Learning Algorithms for Image Processing
PDF
Real time vehicle counting in complex scene for traffic flow estimation using...
PDF
IRJET- A Survey of Approaches for Vehicle Traffic Analysis
PDF
IRJET- A Survey of Approaches for Vehicle Traffic Analysis
PDF
STEP TOWARDS INTELLIGENT TRANSPORTATION SYSTEM WITH VEHICLE CLASSIFICATION AN...
PDF
Deep Learning Approach Model for Vehicle Classification using Artificial Neur...
PDF
Obstacle Detection and Collision Avoidance System
PDF
IRJET- Front View Identification of Vehicles by using Machine Learning Te...
PDF
Automated License Plate Recognition for Toll Booth Application
PDF
Real Time Road Blocker Detection and Distance Calculation for Autonomous Vehi...
PDF
Real time vehicle counting in complex scene for traffic flow estimation using...
PDF
IRJET- Reckoning the Vehicle using MATLAB
PDF
Automatic Vehicle Detection Using Pixelwise Classification Approach
PDF
Kq3518291832
PDF
IRJET - Traffic Density Estimation by Counting Vehicles using Aggregate Chann...
PDF
Intelligent Transportation System Based On Machine Learning For Vehicle Perce...
PDF
Accident vehicle types classification: a comparative study between different...
PDF
A Video Processing based System for Counting Vehicles
A real-time system for vehicle detection with shadow removal and vehicle clas...
IRJET - Vehicle Classification with Time-Frequency Domain Features using ...
An Analysis of Various Deep Learning Algorithms for Image Processing
Real time vehicle counting in complex scene for traffic flow estimation using...
IRJET- A Survey of Approaches for Vehicle Traffic Analysis
IRJET- A Survey of Approaches for Vehicle Traffic Analysis
STEP TOWARDS INTELLIGENT TRANSPORTATION SYSTEM WITH VEHICLE CLASSIFICATION AN...
Deep Learning Approach Model for Vehicle Classification using Artificial Neur...
Obstacle Detection and Collision Avoidance System
IRJET- Front View Identification of Vehicles by using Machine Learning Te...
Automated License Plate Recognition for Toll Booth Application
Real Time Road Blocker Detection and Distance Calculation for Autonomous Vehi...
Real time vehicle counting in complex scene for traffic flow estimation using...
IRJET- Reckoning the Vehicle using MATLAB
Automatic Vehicle Detection Using Pixelwise Classification Approach
Kq3518291832
IRJET - Traffic Density Estimation by Counting Vehicles using Aggregate Chann...
Intelligent Transportation System Based On Machine Learning For Vehicle Perce...
Accident vehicle types classification: a comparative study between different...
A Video Processing based System for Counting Vehicles
Ad

Recently uploaded (20)

PPTX
IOT PPTs Week 10 Lecture Material.pptx of NPTEL Smart Cities contd
PPT
CRASH COURSE IN ALTERNATIVE PLUMBING CLASS
PDF
Embodied AI: Ushering in the Next Era of Intelligent Systems
PPTX
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
PDF
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
PDF
Enhancing Cyber Defense Against Zero-Day Attacks using Ensemble Neural Networks
PPTX
Lecture Notes Electrical Wiring System Components
PPT
Mechanical Engineering MATERIALS Selection
PDF
Model Code of Practice - Construction Work - 21102022 .pdf
PPTX
web development for engineering and engineering
PPTX
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
PPTX
UNIT-1 - COAL BASED THERMAL POWER PLANTS
DOCX
573137875-Attendance-Management-System-original
PPTX
Geodesy 1.pptx...............................................
PDF
BMEC211 - INTRODUCTION TO MECHATRONICS-1.pdf
PPT
Project quality management in manufacturing
PPTX
Internet of Things (IOT) - A guide to understanding
PPTX
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
PDF
TFEC-4-2020-Design-Guide-for-Timber-Roof-Trusses.pdf
PPTX
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
IOT PPTs Week 10 Lecture Material.pptx of NPTEL Smart Cities contd
CRASH COURSE IN ALTERNATIVE PLUMBING CLASS
Embodied AI: Ushering in the Next Era of Intelligent Systems
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
Enhancing Cyber Defense Against Zero-Day Attacks using Ensemble Neural Networks
Lecture Notes Electrical Wiring System Components
Mechanical Engineering MATERIALS Selection
Model Code of Practice - Construction Work - 21102022 .pdf
web development for engineering and engineering
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
UNIT-1 - COAL BASED THERMAL POWER PLANTS
573137875-Attendance-Management-System-original
Geodesy 1.pptx...............................................
BMEC211 - INTRODUCTION TO MECHATRONICS-1.pdf
Project quality management in manufacturing
Internet of Things (IOT) - A guide to understanding
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
TFEC-4-2020-Design-Guide-for-Timber-Roof-Trusses.pdf
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx

Neural Network based Vehicle Classification for Intelligent Traffic Control

  • 1. International Journal of Software Engineering & Applications (IJSEA), Vol.3, No.3, May 2012 DOI : 10.5121/ijsea.2012.3302 17 Neural Network based Vehicle Classification for Intelligent Traffic Control Saeid Fazli 1 , Shahram Mohammadi 2 , Morteza Rahmani 3 1,2,3 Electrical Engineering Department, Zanjan University, Zanjan, IRAN Fazli@znu.ac.ir , Shahram@znu.ac.ir , Rahmanim@znu.ac.ir ABSTRACT Nowadays, number of vehicles has been increased and traditional systems of traffic controlling couldn’t be able to meet the needs that cause to emergence of Intelligent Traffic Controlling Systems. They improve controlling and urban management and increase confidence index in roads and highways. The goal of this article is vehicles classification base on neural networks. In this research, it has been used a immovable camera which is located in nearly close height of the road surface to detect and classify the vehicles. The algorithm that used is included two general phases; at first, we are obtaining mobile vehicles in the traffic situations by using some techniques included image processing and remove background of the images and performing edge detection and morphology operations. In the second phase, vehicles near the camera are selected and the specific features are processed and extracted. These features apply to the neural networks as a vector so the outputs determine type of vehicle. This presented model is able to classify the vehicles in three classes; heavy vehicles, light vehicles and motorcycles. Results demonstrate accuracy of the algorithm and its highly functional level. KEYWORDS traffic controlling, vehicle classification, camera, neural network, image processing. 1. INTRODUCTION By developing of digital cameras and increasing of power in processing computer, application of this tools increased. So that in the most systems, it is used of these technologies. The systems of controlling traffic intelligently was one of the applications which tools account of most countries. By increasingly growth of vehicles and crossing them in the roads and highways and unresponsible of available fundamental of vehicle. The need to a automatic system is presented much more. The increase of demand for travelling in highways has reached to a explosive growth in recent years. Building road and spreading fundamentals of vehicle is not only way and should apply some new technologies for controlling traffic. A way of controlling by video has been pay attention in parts of view computer. Nowadays In most of the societies, It,s used of this intelligent system for controlling traffic and obtaining those parameters of transportation. The using of systems of based on computer vision has been accounted. It,s because of facility installation and high level of efficiency in controlling traffic [1,2,3]. One of the most effective area in machine vision is processing into one mobile image. So that it can obtain a lot of features of mobile objects. One of the most important and basic in auto controlling traffic are detection and classification. These process cause to extract a lot of parameters of traffic [2,4]. One of the hardest matter in
  • 2. International Journal of Software Engineering & Applications (IJSEA), Vol.3, No.3, May 2012 18 computer vision is vehicle classification which need to a complicated algorithm and high accuracy. So far diverse works have considered for this classification. These process mostly are finding about separation and classify of vehicle from passengers. One of these ways is which Gupte et al [5]. is suggester. In this suggestive way it has been used of dimensions of vehicles for separation of cars and walked passengers. But It,s needed to more complicated for getting better answer. Ma et al. have presented a new way of classification that is used of modifiers SIFT [6]. But responsive of this system is still unknown. The method of detection and classification of vehicles with 3D was a way which Alex et al. suggester but It has own problems [7,8]. One of the greatest problem is modelling of all vehicles as a 3D that almost is not possible. Our suggestive method is a kind of neural network MLP that is used for vehicle classification. 2. THE SUGGESTED ALGORITHM In this section we are analysing the algorithm which is used in this project. The algorithm includes two general phases that each has different parts. The first phase in algorithm includes background extraction and second includes finding passing vehicles and extracting the special features. These features have been applying to a neural network multilayer perceptron (MLP) and the classification of the vehicles has been being created as an output of neural network eventually. This process has been described as Figure (1) following: Movies that used in this project have been provided from several highways in province Zanjan- Iran. Figure 1. System overview 2.1. Background Extraction To obtaining a background image, we are implementing following steps: At first, we divide the input film obtained from the traffic scene into its forming frames and each frame is converting to gray level image. By using threshold of all columns and line of frame, if difference of pixels between 50 frames was smaller than a specific threshold, its value will be considered as intensity of light in the background. In Figure (2) X, Y axis shows size of the input image and position of each pixel has axis of X , Y and also height shows amount of brightness intensity. Background Subtraction Thresholding and Feature Extraction MLP Neural Network Vehicle Classificatio
  • 3. International Journal of Software Engineering & Applications (IJSEA), Vol.3, No.3, May 2012 19 Figure 2. 3D drawing of background image Now, It, s gained some matrix that is input matrix as a background. 2.2. Extracting vehicles from an image Extracting of vehicle is the most common way to obtain changes between two frames. For recognition the changes between two frames of an image, the f(x, y, ti) and f(x, y, tj) frames take in ti and tj times respectively, and comparison have be done for every pixels. For doing this, we are considering the background that extracted of previous step as a resource image which includes some constant items. Comparing of this image and the second one from the same traffic scene include vehicles, we can subtract invariant elements in these images that have no differences and maintain non-zero inputs that are equal to variant items of the images. Figure (3) shows images of the subtraction of two images taken in ti and tj. subtracted as following: [1] .1 Witch T is threshold. A B Figure 3. A) Original image B) Difference image from the original image Now, It is used of method of approximation derive of image for recognizing of edge and then when ever of image that has gradient in pixels is that edge. Since It might charge the object into    > − = . 0 ) , , ( ) , , ( 1 ) , ( otherwise T t y x f t y x f y x d j i ij
  • 4. International Journal of Software Engineering & Applications (IJSEA), Vol.3, No.3, May 2012 20 several piece after finding edge or by using of operator of dilation morphology of these pieces are linked together so it will be obtained a same object. As a result finding image will be labeled. 2.3. Recognizing of vehicles This system is a form whence the vehicle is reached to the nearest distance of camera it can detect it, in this case it dosent need to any other previous vehicle in frame. So, we find those frames which put vehicles in the nearest distance to camera. Therefore, the process of detection begins and we are processing the image of the nearest vehicle. Now, we are obtaining the features of the some special object in the image. There are six feature that including: length and width of the labelled objects, the area of object, in this case the obtaining object will have some small cavities and holes after the subtracting process of background. In this section, at first we are considering those cavities and holes and then obtaining the total area of object which is like a crick. An other feature of them refers to the real numbers of pixels in object. We need to use of two others features for better extracting vehicles. If we put a circle into the object so that it can cover it, we use of diameter of this circle for another feature. The last step is obtaining the ratio of distance between the centre of object and its length, s main axis, we use it for extracting features variable. After extracting features, we, ll make the vector for these features. 2.4. Obtaining the output from the neural network After, that processing in the image and extracting of those features as a feature, s vector to the neural network, so process of recognizing is done. The order of operation is this, at first we are saving the vector in the file excel which including six columns and each of them is presentation of a feature of object. We are specifying every kind of this feature, s vector for our classification including three types: heavy vehicle, light vehicle and motorcycle. We are producing these data for neural network and then are defined the target vector for teaching neural network. The special neural network that is considered in this project is multilayer perceptron (MLP) with two hidden layers. The output of neural network can recognize the type crossing vehicle which has shown in Figure (4). In this project we have classified the vehicles into 3 types as a heavy and light vehicles and motorcycle. At last the performance of the system was satisfied. Figure 4. Result of the algorithm when crossing heavy vehicle
  • 5. International Journal of Software Engineering & Applications (IJSEA), Vol.3, No.3, May 2012 21 3. EXPERIMENTAL RESULTS In today society, the techniques of vehicle detection and classification based on visuality of camera for controlling traffic is the one the main programs and effective in the system of vehicle. Intelligent systems made the people to have ensured more than before. So, This system is conducting in the most countries. The designed system in this study is in the height almost higher than roods which has used for film taking of trafficking scene with a instant camera. It is able to detect and classify of crossing vehicle with minimum information. It, s one of the most important factor in automatic controlling of traffic and finding a lot of details of traffic. It also helps to decrease of accidents. In addition to ability of vehicle detection and classification, it will be able to obtain the numbers of crossing cars in every time. The algorithm is done successfully. Figure (5) illustrates a part of results. Figure 5. Results of the algorithm on some image frame The outcome results verified the accuracy and high level of the performance of this method. So that it can detect and classify the special system with higher than %90 of crossing vehicle in the scenes of traffic. The finding results have been show in the following tables. Table 1. Classification Results Heavy vehicles Light Vehicles Motorcycle Total vehicles Number Of Vehicle 21 128 33 182 Number Of Detection 17 119 28 164 Classification Rate 81% 93% 85% 90%
  • 6. International Journal of Software Engineering & Applications (IJSEA), Vol.3, No.3, May 2012 22 4. CONCLUSION In this project, a traffic controlling system base on neural networks has been presented that it can recognize vehicles in a traffic scene and categorize it. Finding transportation parameters especially number and type of vehicles are one of the most important and applicable factors that cause to increase confidence index and reduce road crashes in roadways and highways. The camera that used in this project located in a place above the road surface. As an advantage of used method in design of algorithm is the camera don’ts need to calibration. After recognition of vehicles, they have been categorized in three classes. The results of testing of this method in several highways in Zanjan city were satisfying. In the future we can integrate whole of the system and make a network, then it is possible to categorize transportation vehicles base on real time. REFERENCES [1] Naixue Xiong, Jing He, Jong Hyuk Park, Donald Cooley, Yingshu Li. A Neural Network Based Vehicle Classification System for Pervasive Smart Road Security. Journal of Universal Computer Science, vol. 15, no. 5 (2009), 1119-1142 [2] N. K. Kanhere and S. T. Birchfield. Real-Time Incremental Segmentation and Tracking of Vehicles at Low Camera Angles Using Stable Features. . IEEE Transactions on Intelligen Transportation Systems, 9(1):148-160, March 2008. [3] N. K. Kanhere, S. T. Birchfield, W. A. Sarasua, and S. Khoeini. Traffic Monitoring of Motorcycles During Special Events Using Video Detection. Transportation Research Record: Journal of the Transportation Research Board, 2010. [4] Jin-Cyuan Lai, and Shih-Shinh Huang, and Chien-Cheng Tseng. . I Im ma ag ge e- -b ba as se ed d v ve eh hi ic cl le e t tr ra ac ck ki in ng g a an nd d c cl la as ss si if fi ic ca at ti io on n o on n t th he e h hi ig gh hw wa ay y. . Green Circuits and Systems (ICGCS), 2010 International Conference on, , N NO O. . 2 21 1, , June 2010. . [5] S. Gupte, O. Masoud, R. F. K. Martin, and N. P. Papanikolopoulos. Detection and Classification of Vehicles. IEEE Transactions on Intelligent Transportation Systems, 3(1), 2002, 37-47. [6] X. Ma, W. E. L. Grimson. Edge-based rich representation for vehicle classification. Proc. of the International Conference on Computer Vision, 2006, 1185-1192. [7] A Am mo ol l A Am mb ba ar rd de ek ka ar r, , M Mi ir rc ce ea a N Ni ic co ol le es sc cu u, , a an nd d G Ge eo or rg ge e B Be eb bi is s. . E Ef ff fi ic ci ie en nt t V Ve eh hi ic cl le e T Tr ra ac ck ki in ng g a an nd d C Cl la as ss si if fi ic ca at ti io on n for a an n A Au ut to om ma at te ed d T Tr ra af ff fi ic c S Su ur rv ve ei il ll la an nc ce e S Sy ys st te em m. . D De ep pa ar rt tm me en nt t o of f C Co om mp pu ut te er r S Sc ci ie en nc ce e a an nd d E En ng gi in ne ee er ri in ng g U Un ni iv ve er rs si it ty y o of f N Ne ev va ad da a, , R Re en no o U U. .S S. .A A. ., , Aug 2008. [8] Limin Xia. Vehicle Recognition Using Boosting Neural Network Classifiers. Proceedings of the 6th World Congress on Intelligent Control and Automation, June 21 - 23, 2006, Dalian, China.