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

e-ISSN: 2582-5208

International Research Journal of Modernization in Engineering Technology and Science


( Peer-Reviewed, Open Access, Fully Refereed International Journal )
Volume:04/Issue:12/December-2022 Impact Factor- 6.752 www.irjmets.com

HELMET DETECTION AND LICENSE PLATE RECOGNITION FOR


TRAFFIC SURVEILLANCE
Dr. V.P. Balpande*1, Kartik Parashar*2, Yogita Sakharkar*3, Kaustubh Shingade*4,
Abdulkadir Pankhaniya*5
*1Associate Professor, Department Of Computer Science And Engineering, Priyadarshini JL
College Of Engineering, Nagpur, Maharashtra, India.
*2,3,4,5UG Students, Department Of Computer Science And Engineering, Priyadarshini JL College Of
Engineering, Nagpur, Maharashtra, India.
DOI : https://www.doi.org/10.56726/IRJMETS32490
ABSTRACT
Nowadays, riding motorcycles without wearing a helmet is a traffic violation that leads to an increase in the
number of accidents and deaths in India. For public safety reasons, the government made it a law that every
motorcyclist wears a helmet while riding a motorcycle. But most of the people still contradict this by riding
their vehicles without helmets. To address this issue, in this paper, we propose an approach for automatic
detection of helmetless motorcyclists and recognition of license number plates using surveillance videos in
real-time. For detection the system will use the YOLO deep learning framework. For classification SVM
algorithm will be used to recognize the number plates of motorcyclists using images or videos taken by a
camera, which involves different steps like vehicle classification, pre-processing, recognition of number plate.
To avoid accidents and for public safety, there is need for a system that automatically detects the people who
are not wearing a helmet and extracts the vehicle number which would help find the motorcyclist to be
penalized. This will help the traffic police department in catching the violators and using this, data fines can be
imposed on the riders who repeatedly commits the mistake of not wearing the helmet.
Keyword: YOLO, Convolutional Neural Network, SVM, OCR.
I. INTRODUCTION
In practically every country, two-wheelers are a popular mode of transportation. However, there is a
substantial danger associated due to the lack of protection. It is highly recommended that bike riders use
helmets to lessen the risk associated. Two-Wheelers account for the topmost number of road accidents. Though
reckless and reckless driving is the primary cause of these incidents, brain injuries are the leading cause of
mortality in road accidents. Study shows that further than one- third who failed in road accidents could have
survived if they would have worn a helmet, the operation of helmet can save accident deaths by 30 to 40. The
number of traffic accidents caused by motorcycle riders who do not wear helmets has been alarming. According
to Police Department annual report (published in 2017), 35-40% of fatal accidents in the city in 2016 were
caused by motorcyclists “not wearing helmets” or “low quality helmets.” Section 129 of the Motor Vehicles Act
of 1988 requires two-wheeler users to wear safety helmets. The law also states that a helmet should have a
thickness of 20-25mm and be made of high-quality foam. It should also include the ISI mark and follow to the
Bureau of Indian Standards.
But unfortunately, no one seems to follow these rules, at least not for pillion riders. These days videotape
Surveillance grounded systems have turned into significant gear to remain a track on any veritably crook or foe
to law movement in current moral advancement. There are being styles which use technical detectors in the
ergonomics of the motorbike to check the presence of a helmet. But it's insolvable to move every stoner to
install detectors on the formerly being bikes. Also, the delicacy and integrity of these detectors is questionable.
Apart from this, systems that use videotape processing have veritably high computational costs. The
technologies that were used to make the system were veritably precious hence making it an economically
nonviable choice.
In light of this, there is an increasing demand for the development of a solid and simple adept technique for
detecting helmet use of motorcycle riders that does not accept an individual's viewpoint. AI is a potential

www.irjmets.com @International Research Journal of Modernization in Engineering, Technology and Science


[1364]
e-ISSN: 2582-5208
International Research Journal of Modernization in Engineering Technology and Science
( Peer-Reviewed, Open Access, Fully Refereed International Journal )
Volume:04/Issue:12/December-2022 Impact Factor- 6.752 www.irjmets.com
method for automating the recognition of motorcycle helmet wear. AI has been used in a variety of street
healthrelated discovery projects and has achieved great precision for general recognition. Several researchers
have attempted to address the problem of detecting motorcyclists without helmets using various methods, but
have been unable to accurately identify motorcyclists without helmets under difficult conditions such as
occlusion, illumination, poor video quality, varying weather conditions, and so on. One key cause for previous
systems' low performance is the use of less discriminative representation for object classification, as well as the
inclusion of irrelevant items against the goal of detecting motorcyclists without helmets. Furthermore, present
techniques only make advantage of handmade features. Deep networks have acquired popularity for producing
cuttingedge results in complex tasks like as picture classification, object identification, motion detection, and
segmentation due to its capacity to learn features straight from raw data without the need for operator tuning.
In modern society, video surveillance-based systems have become a vital piece of technology for keeping track
of any type of illegal or anti-law activity. Over the last few decades, various artificial intelligence techniques,
such as computer vision and machine learning, have been widely used in intelligent monitoring at power
substations. It can not only save time by avoiding labour-intensive operations, but it can also detect power
equipment faults and worker unlawful operation in real time, protecting against accidents.
However, contemporary video surveillance-based solutions are passive and require extensive human
intervention. In general, such systems are impractical owing to the participation of people, whose efficiency
degrades with time. Automation of this procedure is very desirable for accurate and rigorous monitoring of
these infractions, as well as for drastically reducing the quantity of human resources required. In addition,
numerous nations are implementing systems using surveillance cameras in public spaces. As a result, the
option for identifying violators utilizing current infrastructure is also cost-effective.
II. RELATED WORK
The first step in the helmet detection of motorcyclists is normally motorcycle detection. From the existing
literature, it can be seen that utmost of the current styles are traditional styles, and there are relatively many
styles grounded on deep learning. The object detection domain has been more frequent due to the evolving
object detection algorithms that give improved accuracy in the newer performances. It's important to
understand how these algorithms work and the advantages and disadvantages of choosing the one that suits
this operation. This review of the former literature will concentrate on the aspects of each algorithm, and the
reason for choosing a specific algorithm for this design will be justified.
2.1 Detection of helmets using traditional methods
Traditional methods generally employ similar concepts, as illustrated. It is proposed in paper by B. Yogameena
et.al [1] in first step is to detect moving objects. First, moving objects are extracted from surveillance videos
using the motion segmentation method. Optical flow, frame difference, and background subtraction are
examples of common motion segmentation methods used by Lucas BD et.al [3]. Finally, binary classifiers (such
as support vector machine (SVM) and K-nearest neighbour (KNN)) are used to categories motorcycles. The
methodology followed by Messelodi S. et.al [5] used the YOLOv3 algorithm to detect whether a motorcyclist is
wearing a helmet, although motorbike detection is not reported. Devadiga et al [6] described and tested a
system for automatic classification of motorcycles with and without helmets. It has used (SVM) Support Vector
Machine which is derived from the head region of the static images and individual image frame from video data.
By this method the accuracy rate was high but the number of testing images taken were very less.
The algorithm (YOLO) is used to extract the foreground objects in the video which is then extracted as frames.
The location where the helmet can be found is found by the bounding boxes. This area is extracted and the
helmet is detected using a machine learning classifier. Tuytelaars T. et al [8]. used a background removal
technique to identify moving cars and principal component analysis to analyse the resulting features.
Waranusast et al. [9] Employ the background removal approach and the SMO (Sequential Minimal
Optimization) classifier to recognize motorcycles in footage. The moving item on the video frame is obtained
via adaptive background subtraction in paper proposed by Wen C-Y et.al. [10]

www.irjmets.com @International Research Journal of Modernization in Engineering, Technology and Science


[1365]
e-ISSN: 2582-5208
International Research Journal of Modernization in Engineering Technology and Science
( Peer-Reviewed, Open Access, Fully Refereed International Journal )
Volume:04/Issue:12/December-2022 Impact Factor- 6.752 www.irjmets.com
2.2 Deep learning-based helmet detection
Deep learning-based solutions have been proposed by scholars in recent years. W. Hu et.al [11] utilized the
YOLOv3 method to recognize the motorbike and person in the image and then estimated the overlapping area
of the bounding box between the motorcycle and the person to determine who was riding the motorcycle. Some
authors like K. Dahiya et.al [16] used YOLOv3 technique to detect the motorbike, then extract the upper part of
the image and use the classification algorithm to distinguish the helmet and non-helmet. Similarly, when there
is more than one person on the motorcycle, the classification algorithm is rendered ineffective. Finally, the
YOLOv3 algorithm was utilized to determine whether the motorcyclist was wearing a helmet. However, in
terms of traffic surveillance, motorcyclists and motorcycles are heavily overlapping, thus detecting
motorcyclists individually is superfluous. Then, hand-crafted features and CNN are employed to differentiate
between helmet and non-helmet. Finally, it is demonstrated that CNN outperforms manual features in terms of
accuracy. CNN is then utilized to classify motorcycle riders in moving objects. Finally, they continue to employ
CNN to classify the top quarter area of motorcycles in order to confirm that riders are not wearing helmets.
Algorithm then use a faster region-based CNN (faster R-CNN) to detect motorcycles in the indicated foreground
items, ensuring that motorcyclists exist. Later, the quicker R-CNN was utilized to detect motorcyclists wearing
or not wearing helmets. Although the helmet detection approach is employed in paper by R.V. Silva et.al [18]
standard background subtraction is still used to retrieve the foreground target in the motorbike identification
step, which will be very poor in a busy setting. In the paper proposed by Redmon J et.al [20] background
subtraction and object segmentation are used to recognize bike riders in surveillance video first. Then, using
binary classifier, it identifies whether or not the bike rider is wearing a helmet. Adam et al [21] divided the
problem of detecting motorcycle helmet use into two steps. The first step is to segment and categories the
vehicle images. This stage attempts to detect all moving objects in the scene. The second phase is helmet
detection, a support vector machine classifier to classify an image as helmet or non-helmet.
Some authors used certain vehicle detection algorithms in which they cropped the upper part of the image and
use classification algorithms to distinguish helmet and non-helmet riders which consumed more time and
decreased the efficiency of the project. Some authors suggested circle arc detection algorithm to detect the
presence of a helmet but they found that the drawback of this algorithm is that it uses only geometric features
of the helmet. Geometric features are not enough to detect the helmet because many times the head can be
mistaken with the helmet. To increase accuracy some authors used algorithms such as histogram of oriented
gradient but the time interval required for image processing and object detection is high i.e., rate of 11.58 ms
per frame. In order to improve the system's accuracy and overcome these issues, we will use the YOLO
algorithm and the SVM as a classifier in our project.
III. METHODOLOGY
The methodology is given in the following steps: -

Data Set
Pre-Processing
Gathering

Object Object
Detection Classification
Figure 1: General Control Flow of System

www.irjmets.com @International Research Journal of Modernization in Engineering, Technology and Science


[1366]
e-ISSN: 2582-5208
International Research Journal of Modernization in Engineering Technology and Science
( Peer-Reviewed, Open Access, Fully Refereed International Journal )
Volume:04/Issue:12/December-2022 Impact Factor- 6.752 www.irjmets.com
3.1 Dataset Gathering and pre-processing.
The live feed captured from the Traffic Cameras will be provided as the dataset. Now inside the model first we
need to pre-process the video frames by techniques such as.
•Noise reduction: - Image noise is random variation of brightness or colour information in images, and is
usually an aspect of electronic noise.
•Gradient calculation: - Gradient magnitude represents the strength of the change in the intensity level of the
image.
•Image Sharpening: - Image sharpening is an effect applied to digital images to give them a sharper
appearance.
3.2 Object detection

Figure 2: Working Of YOLO


The first step is to detect the objects by using Localization. Object localization is a fundamental practical task in
Computer Vision, which aims to locate the target within the image or video. It has been used in many
applications, including human face recognition, retail checkout recognition, automated driving, and automatic
monitoring systems.
Then the algorithm we are using to detect objects is YOLO. YOLO algorithm employs convolutional neural
networks (CNN) to detect objects in real-time. As the name suggests, the algorithm requires only a single
forward propagation through a neural network to detect objects.
First, as shown in fig.2 the image is divided into grid cells. Each grid has a dimension of S X S. Each grid cell
forecasts B bounding boxes and provides their confidence scores. By use of these algorithms, we will detect a
rider, helmet and number plate. All the predictions are made simultaneously using a convolutional neural
network. Intersection over union ensures that the predicted bounding boxes are equal to the real boxes of the
objects. This phenomenon eliminates unnecessary bounding boxes that do not meet the characteristics of the
objects (like height and width).
The final detection will consist of unique bounding boxes that fit the objects perfectly. Hence the two-wheelers,
helmets and number plates will be detected and passed to the next step.
3.3 Object Classification
After helmet and motorbike detection, in this stage we will apply the classification methods to distinguish
between the two-wheeler and the other moving objects and also classify the biker is wearing the helmet or not.
The Number plate is then accessed only if the rider is not wearing the helmet.
www.irjmets.com @International Research Journal of Modernization in Engineering, Technology and Science
[1367]
e-ISSN: 2582-5208
International Research Journal of Modernization in Engineering Technology and Science
( Peer-Reviewed, Open Access, Fully Refereed International Journal )
Volume:04/Issue:12/December-2022 Impact Factor- 6.752 www.irjmets.com
For classification purpose we will use support vector machine algorithm. SVM (support vector machine)
chooses the extreme points/vectors that help in creating the hyperplane and finds the closest point of the lines
from both the classes and then make categorization. After this if the helmetless rider is detected then the
number plate is extracted of that bike. Finally, as shown in fig. 3 the motorcycle and helmet are detected.

Figure 3: Detection of frame with helmet and bike


IV. DISCUSSION
We are proposing a system for the automatic detection of motorcycle riders without helmets from CCTV video
and the automatic retrieval of vehicle license number plates for such motorcyclists. The existing system needs
human assistance, which is a difficult task. This system will mainly use object detection principles with the
YOLO architecture for helmet and license plate detection from the input given in the form of a video or an
image, and the system recognizes motorcyclists who drive without wearing a helmet. Using optical character
recognition (OCR), the license plate details will be read and stored in the database. The method will ensure that
it will reduce both complexity and time and will save the lives of many by forcing riders to wear helmets while
travelling on two wheelers and this system will help the traffic police in catching the helmetless riders without
being physically present on the field.
V. CONCLUSION
This model focuses on catching motorcyclists without helmets. The existing video surveillance system is
effective, but it requires significant human assistance, whose efficiency decreases with time, so we want to
make it automated. First, the system classifies moving objects as either motorcycling or non-motorcycling.
Furthermore, if the system detects a motorcyclist without a helmet, it will finally extract the license plate of the
vehicle. This will help the Transport Office to identify every offender accurately and arrest the suspect's vehicle,
thereby imposing violation fines. Thus, our model increases the speed of operations in real time with the use of
the YOLO and OCR methods.
ACKNOWLEDGEMENT
First and foremost, we would like to express our heartfelt sincere gratitude to Dr.V.P. Balpande of Priyadarshini
JL College of Engineering for their excellent guidance and valuable suggestions that helped us throughout this
project. The team members would like to thank the Department of Computer Science and Engineering of
Priyadarshini JL College of Engineering for providing the necessary support and resources.

www.irjmets.com @International Research Journal of Modernization in Engineering, Technology and Science


[1368]
e-ISSN: 2582-5208
International Research Journal of Modernization in Engineering Technology and Science
( Peer-Reviewed, Open Access, Fully Refereed International Journal )
Volume:04/Issue:12/December-2022 Impact Factor- 6.752 www.irjmets.com
VI. REFERENCES
[1] B. Yogameena, K. Menaka and S. Saravana Perumaal, "Deep learning-based helmet wear analysis of a
motorcycle rider for intelligent surveillance system," in IET Intelligent Transport Systems, vol. 13, no.
7, 2019, pp.1190-1198
[2] J. Chiverton, “Helmet presence classification with motorcycle detection and tracking,” Intelligent
Transport Systems (IET), vol. 6, no. 3, September 2012, pp.259–269.
[3] Lucas BD, Kanade T (1981), “An iterative image registration technique with an application to stereo
vision”, Morgan Kaufmann Publishers Inc, San Francisco, pp 674–679.
[4] J. Mistry, A. K. Mishra, M. Agarwal, A. Vyas, V. M. Chudasama and K. P. Upla, "An automatic detection of
helmeted and non-helmeted motorcyclists with license plate extraction using convolutional neural
network",2017 Seventh International Conference on Image Processing Theory, Tools and Applications
(IPTA), Montreal, QC, 2017, pp.1-6.
[5] Messelodi S, Modena C, Zanin M (2005), “A computer vision system for the detection and classification
of vehicles at urban road intersections”, Pattern Anal Palp 8:17–31.
[6] Kavyashree Devadiga, Yash Gujarathi, Pratik Khanapurkar, Shreya Joshi and Shubhankar
Deshpande,"Real Time Automatic Helmet Detection of Bike Riders", International Journal for
Innovative Research in Science & Technology Volume 4 Issue 11, 2018, pp.146-148.
[7] Sonoda S, Tan JK, Kim H, Ishikawa S, Morie T (2011), “Moving objects detection at an intersection by
sequential background extraction”, International conference on control automation and systems
(ICCAS), pp 1752 –1755.
[8] Tuytelaars T, Gool LV, Bay H, Less A (2008), “Speeded-up robust features (surf)”, Computer vision
image understand, pp 346–359.
[9] Waranusast R, Bundon N, Timtong V, Tangnoi C, Pattanathaburt P (2013), “Machine vision techniques
for motorcycle safety helmet detection”, 28th International conference of image and vision computing
New Zealand (IVCNZ), pp. 35–40.
[10] Wen C-Y, Chiu S-H, Liaw J-J, Chuan-Pin L (2003), “The safety helmet detection for ATM’s surveillance
system via the modified though transform”, IEEE 37th Annual international Carnahan conference on
security technology, pp.364–369.
[11] W. Hu, T. Tan, L. Wang, and S. Maybank, “A survey on visual surveillance of object motion and
behaviors”, IEEE Transactions on Systems, Man, and Cybernetics, Part C: Applications and Reviews, vol.
34, no. 3, 2004, pp.33
[12] Manoharan, S. (2019),"An Improved Safety Algorithm for Artificial Intelligence Enabled Processors in
Self Driving Cars”, Journal of Artificial Intelligence, 1(02), pp.95-104.
[13] Pattasu Doughmala, Katanyoo Klubsuwan, "Half and Full Helmet Detection in Thailand using Haar Like
Feature and Circle Hough Transform on Image Processing" in Proceeding of IEEE International
Conference on Computer and Information Technology, Thailand, Bangkok, 2016, pp.611-614.
[14] N. Boonsiri Sumpun, W. Puarungroj and P. Wairocana Phuttha, "Automatic Detector for Bikers with no
Helmet using Deep Learning", 22nd International Computer Science and Engineering Conference
(ICSEC), Chiang Mai, Thailand, 2018, pp.1-4.
[15] M. Dasgupta, O. Bandyopadhyay and S. Chatterji, "Automated Helmet Detection for Multiple Motorcycle
Riders using CNN", IEEE Conference on Information and Communication Technology, Allahabad, India,
2019, pp.1-4.
[16] K. Dahiya, D. Singh and C.K.Mohan, "Automatic detection of bike riders without helmets using
surveillance videos in real-time", in Proceeding of International Joint Conference Neural Networks
(IJCNN), Vancouver, Canada, 24-2, 2016, pp.3046-3051.
[17] B. Yogameena, K. Menaka and S. Saravana Perumaal, "Deep learning-based helmet wear analysis of a
motorcycle rider for intelligent surveillance system", IET Intelligent Transport Systems, vol. 13, no. 7,
2019, pp.1190-1198.
www.irjmets.com @International Research Journal of Modernization in Engineering, Technology and Science
[1369]
e-ISSN: 2582-5208
International Research Journal of Modernization in Engineering Technology and Science
( Peer-Reviewed, Open Access, Fully Refereed International Journal )
Volume:04/Issue:12/December-2022 Impact Factor- 6.752 www.irjmets.com
[18] R. V. Silva, T. Aires, and V. Rodrigo, " Helmet Detection on Motorcyclists using image descriptors and
classifiers", in Proceeding of Graphics, Patterns and Images (SIBGRAPI), Rio de Janeiro, Brazil, 27-30
August 2014, pp.141-148R.
[19] Redmon, Joseph, and Ali Farhadi. ’YOLO9000: better, faster, stronger.’ IEEE conference on computer
vision and pattern recognition, 2017, pp.7263- 7271.
[20] Redmon J, Divvala S, Girshick R, et al. You only look once: unified, real time object detection Computer
Vision and Pattern Recognition, 2016, pp.779-786.
[21] A.Adam, E. Rivlin, I. Shimshoni, and D. Reinitz, “Robust real-time unusual event detection using multiple
fixed location monitors,” IEEE Transactions on Pattern Analysis and Machine Intelligence, vol. 30, no. 3,
march 2008, pp.555–560.

www.irjmets.com @International Research Journal of Modernization in Engineering, Technology and Science


[1370]

You might also like