Traffic Violation Detection Camera
Traffic Violation Detection Camera
ISSN No:-2456-2165
Snehal Mane
Assistant Professor of Electronics and
Telecommunication Department,
Bharati Vidyapeeth
(Deemed to be University)
College of Engineering Pune, India
Abstract:- Poor road safety is a crucial developmental road accidents. Road accident is one of the most unwanted
issue, a public health concern and a ruling cause of things to happen to a road user, though they happen quite
injury and demise in India. As per the Report of often. The most unfortunate thing is that we do not
Ministry of Road Transport and Highways on road understand that the reason for these road accidents is
accidents in India 2019 [1], there were 1,51,113 accident- because of our carelessness. Most of the road users are
related deaths in India in 2019. It is a matter of great aware of the general traffic rules and safety
concern that despite the fact that there are so many road measures/precautions for their as well as fellow road user’s
laws introduced by our government for the safety of the safety but it is only the indifference on part of road users,
passengers and drivers, the number of accidents are still which cause accidents and crashes. Main cause of accidents
increasing alarmingly. The main reason behind these and crashes are due to human errors like over speeding,
accidents is that people do not follow the basic traffic triple riding, avoiding safety gears like seat belts and
rules like wearing a seat belt or helmet, over speeding helmets etc.
and triple riding. This paper proposed a method to
monitor these violations and store the information of India’s traffic laws are stricter than those of other
violators to report it to the concerned authorities. Our countries, but these laws are not enforced. India’s
proposed system does not need any human interception enforcement of laws on speeding are rated 3 and 4 out of 10,
which makes it free from human error and bribery. respectively, compared to 8 and 9 in China and 9 in Sri
Lanka, by the Global Road Safety Report 2018, that
Keywords:- AI; Deep Learning; Road accidents; Python; analyzed traffic laws of 175 countries. When it comes to
Raspberry Pi; Machine Learning; Character Recognition. enforcement, we know human behavior is affected by
enforcement and in India, enforcement is largely driven by
I. INTRODUCTION human beings and is prone to corruption.
According to the 2017 WHO Global Health Estimates Our project aims to catch these violators and maintain
one of the most common causes of deaths in India is road a database of their vehicle information so that this database
accidents, it is also the 9th most common cause of premature can be sent to the concerned authority for penalty
deaths and the 10th most common reason for disability. generation. Since our project is fully automated it is free of
corruption and human error. We have used raspberry pi 3
India is one of the busiest countries in the world in module along with its camera module to monitor the traffic
terms of road traffic. The automotive industry across the [2]. In the first phase of our project, our system detects and
south Asian country became the fourth largest in the world divides the traffic into two categories that are- 2-wheeler and
in 2017. There were almost 3 million new car 4-wheeler vehicles. In the second phase if the detected
registrations in the country in 2019. The Indian road vehicle is a 2-wheeler vehicle the system checks for the
network, which is spanning over 5 million kilometers, speed of the vehicle determines whether the driver is
carries approximately 90 percent of the country’s passenger wearing a helmet and checks for tripling riding if any of the
traffic and around 65 percent of the goods. With the rapid mentioned aspects are violated a snap of the video is taken
increase in the number of cars bought by people and the and sent to the third phase of the system. In the third phase
mercilessly congested Indian roads, road safety has turned of the system the license plate of the vehicle is detected and
into a factor of utmost importance for the country’s citizens. the vehicle details along with the violation is stored in a data
India loses almost 1.5 lakh lives every year on account of base.
A. Two-wheeler-dataset
The Two-wheeler-dataset on GitHub is a public bike
and two-wheeler image data collection. The collection
collected 2462 two-wheeler images from different part of
country, including 1248 images of bikes, 978 of
scooties/scooters and 236 of bicycles.
B. Four-wheeler-dataset
Four-wheeler dataset has 2312 images (JPEG) and 2
categories (cars/heavy vehicle). The four-wheeler images in
this dataset is collected from The Ministry of Road
Transport and Highways, India. All vehicle images collected
by the ministry are used as part of routine traffic detection.
III. MTEHODOLOGY
Figure 1.1. FLOW CHART OF TYPE OF VEHICLE
Collecting dataset images
The datasets contain images of different vehicles. The B. Over Speeding
dataset has 4650 vehicle images including 2462 two-wheeler Here to detect the speed of an over speeding vehicle
and 2312 four-wheeler images 64 x 64-pixel(size), RGB we used Doppler radar (HB 100). In this set-up, a continuous
(color model) images were used, images were resized to wave doppler radar is used which provides a velocity output
make all the test images of unform size and shape. The and the Arduino micro is used to calculate the speed of the
dataset was divided into 3 sub datasets, first was used for vehicle. To drive the microcontroller as the sensor output is
training the model, the second one is used for validation of in micro volts and to amplify the voltage level, an amplifier
the system and the third one is used for testing hence the is used. The speed levels can be seen through an LCD
problem of overfitting is avoided. After the refining of the screen. A Doppler radar regulate the frequency shift that
dataset, it was then used in all the three phases of our system occurs in EM waves due to the motion of scatters toward or
mentioned below. away from the observer through measurement of the phase
change that occurs in electromagnetic waves during a series
A. Type of Vehicle of pulses. If the Doppler frequency is negative then the
This is the first phase of our system; we used the objects is receding from the radar. If its Doppler frequency
concept of real time object detection using deep learning and is positive then the object is approaching the radar.[5]
open cv [3] to determine the type of a moving vehicle in a
video. We used our video streaming with a Raspberry Pi Flow of over speeding detection:
camera [4] along with two separate databases of 2 wheelers
and 4 wheelers which we got from internet. The system
divides and iterates through the video frame by frame and
converts these frames to gray images. 2 wheelers and 4
wheelers are detected from these frames and a loop is run to
put a box around the detected vehicle. These frames are then
sent for phase two of our system where the vehicles are
scanned to detect the violators.
1. Phase 1
Phase 1 consist of detection of the type of vehicle
(two-wheeler or four-wheeler) and marks the box and label
them accordingly.
Figure 1.5 FLOW CHART OF TRIPLE RIDING
A. Two-wheeler.
After a two-wheeler being detected in 1st phase then in
phase ii it is checked if there are any traffic rules being
violated by that two-wheeler. If any violation is detected,
then the snap of that vehicle is captured and send to 3 rd
phase.
1. Helmet Detection.
In this subpart it is checked whether a rider is wearing
a helmet or not and if not then mark the head portion if the
rider and capture a snapshot.
3. Phase III
In this phase the license number plate is detected,
extracted and stored for further process of imposing penalty
to the driver through online method.
V. CONCLUSION
REFERENCES
[1]. https://morth.nic.in/road-accident-in-india
[2]. https://randomnerdtutorials.com/video-streaming-with-
raspberry-pi-camera/
[3]. https://www.pyimagesearch.com/2017/09/18/real-
time-object-detection-with-deep-learning-and-opencv/
[4]. https://randomnerdtutorials.com/video-streaming-with-
raspberry-pi-camera/
[5]. https://www.ijtsrd.com/papers/ijtsrd26653.pdf
[6]. https://www.hindawi.com/journals/ace/2020/9703560/
[7]. https://dl.acm.org/doi/10.1016/j.neucom.2016.06.098
[8]. https://www.pyimagesearch.com/2020/09/21/opencv-
automatic-license-number-plate-recognition-anpr-with-
python/