Number Plate Detection of car

Ashika Madhav
3 min readAug 19, 2021

In this model we will be detecting a car in a live stream or video and recognize characters on the number plate of the car then furthermore we will use the characters and fetch the owner's information using RTO API’s .
For the display, we will create a Web portal where all this information will be displayed (using HTML, CSS and JavaScript)

So let’s begin our Model implementation

We create a model which can detect the car in the live stream video or photo. For this, we have to create the large data-set of cars from which we train the model using Convolutional Neural Network

Automatic License/Number Plate Recognition (ANPR/ALPR) is a process involving the following steps:

Step #1: Detect and localize a license plate in an input image/video

Step #2: Extract the characters from the license plate

Step #3: Apply some form of Optical Character Recognition (OCR) to recognize the extracted characters

1. Train our Model

We have trained the model on the dataset to detect the characters in an image. this is needed since we are not detecting characters from strings but rather from images as number plates have slight variations too.

2. Passing The Video

When we pass the video as an argument to the model, the cv2 module goes through the video frame by frame and tries to find the characters in the image that are on the number plate until all the frames are completed, the for loop keeps on running so that model can keep detecting new and new number-plates.

3. Exceptions that may occur

There are chances that our model is unable to detect all the characters of the number-plate in one frame so I have put a constraint that if the characters are at least more than 6 then only we need to get the output. This is vital since it reduces the useless detection where we are not able to get the data of the complete number plate.

The model can perform only when it gets the video in the desired size and dimension so for each frame, we need to fix its size and shape so that it can be given as an input to the model

So finally we have our detection model ready. Now let's test in on any random video. To check out the complete code of Web portal where all this information will be displayed you may check out my GitHub profile link is:

THANK YOU !!!

--

--