This video tutorial we will learn how we can do automatic number plate recognition using YOLO v ten
and paddle OCR.
We will also explore how we can save the license plate detection data to a SQL database.
So let's get started with it.
So I've divided this complete tutorial into these five steps which I have mentioned over here.
So first of all we will see how we can detect license plates using YOLO YOLO is basically the latest
state of the art object detection model, and we will be using this YOLO model in this project.
So in the step number one we will detect license plates using yolo v ten.
And in the step number two we will recognize text on the license plate.
Like we will read the text on the license plate like one, two, three or whatever it is.
So we will read the text on the license plate using paddle OCR.
Then in the step number three we will accumulate the unique license plates.
Like we will accumulate the unique license plate means like we will only we will create a list.
We will, uh, add only the unique license plates like there would be no duplications over there.
So then after accumulating the unique license plate, then we'll save the accumulated unique license
plate to a JSON file after every 20s.
So first of all, we will accumulate the unique license plate.
Then we'll save the accumulated unique license plate to a JSON file after every 20s.
So before uh, in the step number two, we will do two things.
So we will after every 20s interval, we will generate a JSON file, uh, in our JSON directory, which
will contain the start time.
The end time, like the 20 interval start time and 22nd interval end time.
And we will have the the directory license plates data which the license plates which are detected during
that 20s interval.
So after every 22nd inverter well we will generate a JSON file which will have the three things.
One is the start time and one is the end time, and the next will be the license plates which will are
detected during this 20s interval.
So there can be five lessons played.
There can be ten lessons played, or there can be only one license plate that is detected during the
22nd interval, or might be the license plate is directly during that 20s interval.
So this is the one thing which we will do.
And the second thing will be that we will create a cumulative JSON file like, um, one thing I told
you in the first step, like, uh, previously like we will be generating a new JSON file after every
20s interval.
Plus we will also generate a one single cumulative JSON file which will contain all the detected license
plate data for that the 20s.
Like this is the.
These are the license plate detected in the first 22nd interval.
These are the license plate detected during the next 22nd interval.
These are the license plate detected during the third 22nd interval.
So in the cumulative JSON file one JSON file will have all the license plate detected uh, during all
the 20s interval.
Okay.
Then in the step number five, what we'll do, we will save the license plate detection data to a SQL
database.
So we will be using SQLite which is a lightweight disk based database and which is easy to set up and
use.
So uh, before we go ahead, let me show you how our simulated JSON file will look like.
So you have no doubts about it.
So now over here you can see that these are all the JSON files that are generated after every 22nd interval.
Like you can see over here.
All these are the JSON files that are generated after every 22nd interval.
And here you can see at the top this is our cumulative JSON file which is given over here by the name
license plates.
So let me open it over here and let me navigate.
So now you can see over here this is the cumulative JSON file.
So now you can see that 2413 2433.
So these are the 22nd table.
And these is the list of the license plate that are detected during that 22nd interval.
So now as the first 22nd interval and over here.
So the next 22nd interval will be starting from here as well.
Like you can see.
And it will end at 2454.
And these are the lists of the license plates that are detected during that 22nd interval.
Now the here we can see that the last 22nd interval ends and the next 22nd interval will start from
here and it will end from here.
And these are the license plate that are detected during that 22nd interval.
So now here you can see this is the cumulative JSON file which contains all the list of the license
plates that are detected during that 20s interval.
Okay.
And over here you can see that output like these are the JSON file that are generated after every 22nd
interval.
So let me show you one of these as well.
So now over here you can see that this is our start time.
This is the end time.
And you can see this is a list of split data directory during that 22nd interval.
So this is our uh this one file look like that is generated after every 20s.
Terrible.
Okay.
Uh, let me open another one over here.
So now you can see over here, uh, this is another JSON file that is being generated after every 22nd
interval.
And we can see the start time and end time.
So this is how it looks like.
Uh, so this is an overview of how we are going to implement this project.
In the step number one, uh, we will see how we can fine tune the Yolov2 model on the license plate
data set.
In the previous video tutorial hike, I have already explained you how you can fine tune the Yolov2
model on any custom data set.
So now I will not go any details over here, I will just give you a general overview.
How you how you can fine tune the YOLO model on the license plate data set.
So over here this is the data set which I will be using.
So if you haven't created account on Roboflow you can simply create an account on Roboflow and download
this data set over here.
And if you just click on this data set over here uh download zip to computer and you can currently use
the Yolo V8 format because we can format is currently not available over here.
Uh, so basically Yolo Britain is built upon the Yolo V8.
So you can use the Yolo V8 format over here.
And you can simply write show download code over here.
And if you just copy this code and add into your Google Colab notebook, you will be able to export
this data set from Roboflow into your Google Colab notebook.
Okay, and this is our how our data set looks like.
We have around 300 images in our data set, and we have only one class which is license plate.
Okay.
And if I just go to the health check over here, like we have 300 images and we have a total of 333
annotations in these 300 images.
And we have only one class, uh, which is license.
And everything looks fine.
Like for one class, 300 images are good enough.
And you can see, uh, this is how our data set look like.
Like you can see we have a bounding box around, uh, license plate, and we have the name written over
here.
License.
Okay.
So we will be using this data set, and we will be fine tuning the model on this license plate data
set.
So first of all, um, I will not run this script again because we need to write down the complete code,
uh, in the next part.
So this is quite a lengthy task.
Okay.
So first of all, you will clone the YOLO and GitHub repo over here.
Then we will you will install all the required packages okay.
Over here.
And then um you will download the pre-trained model weights over here.
And then I've showed you how you can download a data set from Roboflow into your Google Code Colab notebook
over here.
Then we'll fine tune the Yolov2 model on this lesson's Great data set, which will download it from
Roboflow into this Google Colab notebook.
And you can see over here, uh, we have fine tuned the model for 120 epochs.
And let's see what our final mean average precision scores we get okay.
So we have got a mean average precision score with IOU 0.5 as 0.867 and mean average precision score
when IOU varies from 0.5 to 0.95 is 0.486, and we have got a good precision score of 0.90, like 90%,
and the recall score is 79.4%.
So these are good okay.
And this is the like precision confidence curve.
Like uh what we precision score we have got at different confidence thresholds like you can see.
And here we have the recall confidence curve.
Like what recall score we have got at different threshold.
And here we have the precision recall curve.
And uh here we have the F1 confidence curve.
Like what F1 score we have got at different uh confidence threshold like F1 score.
Tell us the trade off between the precision and recall.
Um so basically now we have the confusion matrix.
Confusion matrix tells us basically how our model handles different classes.
So um, here the testing is being performed on the validation data data set.
And now you can see that, uh, around at 56 instances, our model is able to detect correctly that
there is a license plate while and 12 instances when there was a license plate, our model is unable
to detect that, uh, there is a license plate, and with, uh, it is unable to detect anything.
Okay.
So here we have the confusion matrix over here.
Like you can see 82% of the times our model predicted that there is a license plate and 18% of the time
like then there is a license plate.
Our model is unable to detect anything.
And like you can see over here, our mean average precision score is continuously improving.
And uh, as we increase the number of epochs during training and these are the model predictions on
the training batches.
So we can ignore it because we are using the same data for training.
And these are the model prediction on the validation batch.
Uh, we can view it because these images are not used for the training.
So it's always better to take a look and see how our model is performing.
Like you can see there, there we have a number plate, but our model is unable to detect it.
While in all other cases the model is able to detect the license plate.
So after training the model have saved the model weights on the drive.
So I'm directly downloading the model weights from the drive into this Google Colab notebook.
And then I'm doing some inference on these images.
Like you can see over here, we are able to track the license plate.
Then next what I'm doing is that I'm testing my model on a demo video to see if I am able to detect
the license plate or not.
So let me download this video and show you how our output looks like.
So let me just navigate my screen towards it.
So now you can see over here, uh, we are able to detect a license plate like you can see over here.
And the detection results are quite impressive.
Like we are accurately able to detect the license plate by a very good margin.
Okay, so the detection results look quite impressive.
Uh, so now I have shown you how you can fine tune the YOLO model to detect the license plate.
So the step number one is done.
Now, as you can see over here, I have created a new project in my PyCharm community Edition.
So in the step number one we will clone the Yolo v ten GitHub repo over here.
So uh, as you can see over here, this is the official YOLO and GitHub repo.
So I will just pop over here and copy this stuff from here.
And just I will just write it down and I will just add this thing over here.
So now you can see the repository is being cloned over here.
So it will take few more seconds before it gets completed.
Okay.
So now in the next step we will install all the required packages.
So I will just write install hyphen a dot.
So now all the packages will get installed.
So this will take few more seconds.
Okay.
No.
Also, I have made a mistake.
I have not set.
Uh, so if I just go over here.
Yeah.
Uh, the repository is being cloned.
Here you can see we have the cloned repository.
I need to set this repository as my current directory.
And.
That's right.
So let's see.
Hopefully this will work.
So now you can see it's installing build dependencies over here.
Uh so this will take some time uh, to get completed.
But in the meanwhile, I will just create a script over here.
And pr.py and pz dot stands for automatic number plate recognition.
Okay.
So this now all the packages are being getting installed.
So this will take some time like you can see over here.
So this is a bit time consuming.
So we will also okay.
So this package is also installed.
So we don't need to install it separately.
Okay I think um all the packages are being getting installed over here.
So now I will just create another folder into this project with the name resources, where I will add
some images and videos so that I can test, uh, do the testing later on, uh, of our model, like
whether it is able to detect the license plate or read the license plate or not.
Here you can see that I have just created a folder inside this project over here, uh, by the name
resources.
Here you can see we have some car images.
And here we have some videos of cars over here.
So we will be detecting and recognizing the license plate in this video as well as in these images as
well.
So let's go back to the project over here okay.
So now if I just refresh this over here, we can see the uh resources folder over here.
Yeah.
So.
So let's get started.
So first of all, I will just write import cv2 and from.
So let's uh only read the video at the start.
So first we will create a video capture object over here.
Capture.
And we will go inside the resources folder.
And from there we will just write our lessons one dot mp4.
Okay.
We can add comments over here as well.
Uh, first we will create a, uh, import all the required libraries.
All the required libraries.
And here we are creating our video capture object.
Can you not?
Read this.
If read.
CV2 dot I am show radio.
Name and if CV two dot wait key one.
So then it will break.
And here we can simply write cap dot release.
And we can also write cv2 dot destroy all windows.
In this file.
Okay, so let's run this up now.
I think the indexing will take some time to collate.
Then we will be able to run this up.
So let's wait for the indexing to get complete and then we'll run the script.
Now you can see the indexing is being done.
So let's run this script and let's see.
Now you can see that, uh, the video is running very fine.
So if I just want to run another video, let's right over here and run r.com.
Now you can see the video is running very smoothly and a good frame rate as well.
And you can see that, uh the frame rate is quite good.
Yeah.
Okay.
So everything works currently looking very smooth and fine.
Um, one thing, uh, we can do, but, uh, next, like, uh, let's add the frame rate over here,
or let's keep it away from now.
Uh, we can, uh, do it further on for now.
First, uh, now we will see how we can do, uh, detect the license plate and read the text from the
latent license plate.
So, um, I will just write from ultralytics.
Uh, import yolo v ten.
Okay.
That's good.
Then I will just go over here and just write.
I will just initialize the yolo v and model The site model is equal to yolo v ten.
And then I will just go inside this uh weights directory where I have added the model best weights over
here.
So I will just go inside the weights factory and the site.
best.bt.
Okay.
So that looks good.
Plus, we can initialize the frame count over here as well.
Initialize the frame count and we'll say count is equal to zero.
And here we can write count plus one.
Uh print frame count.
City.
Right.
Name.
Number.
Okay, so let's look promising.
And let's write a result model dot date.
day.
And we can set the conference table to 0.45 over here.
And we can write for result in results.
So we'll loop through uh, each of the bounding boxes.
And uh, then we will draw bounding boxes on each of the license plates.
So first we'll look through each of the bounding boxes and simply write boxes equal to result dot boxes.
Right.
For box boxes.
We have x1 y1 x2 y2.
Okay.
And we can write box dot x y x y.
Why?
So the output which you get from here is in the form of tensors.
Well, let me show you as well.
So let's see if it works fine or if there is an error then we'll fix this up.
Okay, so this will take some time before it gets started to run.
Okay.
We have an error.
So let's see what's that error.
Also we are just facing an error here.
Okay.
So the issue we are just getting is uh this is not installed.
Okay.
So we can simply write, uh.
And let's check out this error.
We don't know what exact package I installed.
Uh, what is this?
Okay.
So we can simply copy this from here and just like.
so, let's see if this works or not.
Okay.
So let's run this again.
Okay.
So it's currently updating indexes.
So this will take some time.
So let's wait for it to get complete.
I think that's done.
And what is there?
NumPy is not available.
Well.
I just found out the solution of the problem that we are facing.
First we need to uninstall numpy and then we need to install numpy with this version.
So this will hopefully solve our problem.
So let's do this.
The meanwhile it gets uninstalled.
Let's run this up now.
Okay so now we are installing this version and hopefully this will work.
Okay.
Currently we are over here.
So now it's just completing the indexing and it will take few more seconds before it gets completed.
Um, next.
Okay, so it's been done.
So let's run this up.
Let's see how does it works.
Okay.
So we have the frame number one over here.
But currently okay.
So here we have the video.
Now currently no detection will be done.
But you can see over here we have the bounding box coordinates over here.
Uh currently it's in the form of tensors.
We need to convert it into integers.
Okay, so if I just press the one key this will stop.
So let's write the rest of the code.
Uh, we can simply move this up.
Then we have the frame.
Let's draw the bounding boxes around the license plates.
The color of the bounding box will be below.
And thickness will be two.
Okay.
And what different classes we have over here.
So we have only one class uh, which is uh, license.
Okay.
So the YOLO written model will give us the class name in the format integers.
So we have.
We can get it by writing box dots plus zero okay.
And now we'll also calculate the confidence score for this math.
Okay.
Then we have the label as.
Last name.
Confidence.
Uh, let's get the text size.
So we'll just write cv2 dot get text size.
One scale will be 0.5.
Thickness of the text will be two.
So we will display the uh uh label which contain the class name and confidence for above the bounding
box.
So for this we can simply write text size zero.
Then I will start with tango.
Over here we have the frame.
Due to.
The color of the bounding box below, which will be added above the bounding detected license plate.
And it will be filled with the blue color.
And we will just put text inside this.
The color of the text will be white.
Okay, so everything looks perfect for now.
Let's run this up now.
So now you can see over here we are able to detect the license plate.
And you can see we have drawn a bounding box.
Uh here we have the class name license.
And here you can see we have the confidence score over here.
Um, the results looks very promising.
Like, the results are good now.
Okay, so let's go ahead.
Let's read the text from license plate.
So we will just write.
We need to install the OCR package.
So let's see how we can do it.
So we need to just install paddle OCR on here so we can just write.
Install paddle OCR.
Uh, meanwhile, the package gets installed.
We can start writing down the code as well.
From OCR import.
Final OCR.
Only.
Here we will initialize the OCR.
OCR.
are.
I don't have a GPU in my local system, so I will just set it to false.
So now we'll also create a function over here for this.
In the frame and the bounding box.
Coordinates.
Okay.
Uh, we don't want to use the pedals here for reduction.
We only want to do recognition using pedal OCR.
And we only want to read that text from the sense plate.
So if nothing is text is read, then this will be empty.
But then we will loop through all the lessons played and we will just read the lesson.
Split text from lessons played.
plate.
Well, I have already done the necessary calculation like this.
Index contain the conference code.
So whenever we read the text from the license plate, we get the confidence code, like how much our
OCR pedal OCR model is confident that, uh, this, uh, that uh, text that the model model model has
read, uh, please.
Like, this is 60% confident that this is the correct text that it has read.
So here we have the following text.
We have the score.
If you want to check more details you can simply write print OCR and just print out the text that it
has read.
So you can have a better idea.
But I'm not doing it correctly because this is already taking so much time.
So if the score is not available, then you set the score is equal to zero.
Else if the score is available.
Then we'll simply multiply the score by 100, because the score will be in the form of 0.60.1 or so.
And if force is greater than 60%, like if the model is 60% confident or more, then we will just write
x or zero.
So after we have written the text.
So now we need to import free so that we can remove any irregularities in the text.
So if there are triple question marks or like such like this stuff.
So we will replace this in our text as well.
And if the text we have the O we will replace the O with zero.
Similarly if we have this as well.
So we have created a function over here.
So let's write down over here as well.
So we can comment this out correctly.
And we can simply write label.
Is equal to pad.
OCR.
And here we have name.
That's good.
So let's run this up and see how does it works.
For.
Yeah, okay.
So I've installed already installed Docker.
But.
So it's done.
So let's run this up now.
Okay.
So the indexing will take some time to complete.
So let's wait for it to get completed.
Then we can go ahead.
No updating Skelton.
So this will not take very much time.
And installed packages switched on.
So let's run this up now.
Okay, I'm already open.
Okay.
So let's resolve this error as well.
So we'll just write port OS.
AMP.
Dash.
Duplicate.
I hope this will solve this error.
So that we can solve any, uh, duplicate library issues.
Let's see how does it works.
So now you can see over here we are able to read the text from the license plate like our 183JF.
So we are able to read the text from the license plate and it looks good.
So let's see if we are able to read the text from the other license plates as well or not.
Um.
Let's see.
Okay.
For this current license plate, we are able to read the text from the license plate.
So now you can see that we have integrated YOLO v ten and OCR code.
We are using Yolo v ten to detect the license plate and to read the text from the license plate.
We are using paddle OCR.
Okay.
So currently you can see the text is not very clear, like it's N8N9 for j v.
So we are able to read the text on the license plate here as well.
So that looks amazing.
Like we have used pedal ACR to read the text from the license plate and the results are very impressive.
Okay, so now the next step we need to, uh, save the license plate data into a JSON file.
So let's work towards it.
So I will just create a function over here save JSON okay.
In the input will be the unique license plates.
Okay.
And the start time, because we need, uh, to save the license plates, uh, data after every 20s interval.
So we need to generate individual JSON files for each 22nd interval.
Okay.
So in the interval data we have.
We have our time.
Okay.
Start time will be in the ISO format.
Similarly, we also have the end time.
And end time will be also in the ISO format.
Then we have the license plate.
And the license plate will be in the form of lists.
And the interval file path will be as following.
Also we need to create a directory over here by the name Jason.
And inside this will write a data file with the name output.
And here we have um air.
Year.
Month.
Day.
Hours.
Minutes.
Seconds.
And just save it in the form of a JSON.
Okay, so that's no good.
And we'll just right click open.
Interval file path.
Interval data.
And inside this, uh, JSON file, we build up this interval data.
And we have the intern test.
So that's good.
So this will generate individual generation file for each 22nd interval.
Then next we need to generate a cumulative JSON file as well.
So.
we need to define the cumulative.
File path as well.
And this will be inside the JSON directory.
And the file name will be less since.
The data project.
And then we'll just try to.
If there exists a cumulative file path.
Then we'll open the cumulative file.
Read it.
Then we'll load the existing data over here.
That we have inside this file.
And the existing Existing data will be empty.
So now we'll add new interval data to this cumulative file.
Existing data dot.
Append.
One data.
I can simply write will open.
So that looks good.
So now next week, what we'll do is.
So now we can just try it over here.
So we have.
All this stuff.
Where I have initialized, we have.
Start time is equal to.
Date.
Time.
Dot.
Now.
Here we have the current timers.
Okay, so that looks good.
Next what we will do over here is.
Now we'll just separate the 20s time interval.
So if we have the time is greater or equal to 20s, then we have the end time.
Run.
Time.
Okay, so first we need to save the license plate data like we have to accumulate.
Add unique license plates into our JSON file okay.
Okay.
So for this I will just write over here.
Okay.
So if we have read some text then we'll just write if label.
So if we have label, then we will add this unique license plate over here.
Okay.
Then I will just write over here license plates.
Then we have the start time and time over here.
Okay.
Then we have the start time as run time.
Over here.
Okay.
Start time.
That's fine.
And then we will just clear all this data.
For the next 22nd, Jake's on file.
So let's run this and see how it works.
So this will take few more seconds.
Okay.
Where has this error?
Okay, so we need to write from date time.
Okay.
I think this will solve the error.
Let's see.
So now you can see that we are able to create the license plate.
Okay.
So let me open this up as well and see if we are able to save the status.
So here we will have a JSON files.
But let's see what does it do.
I think there's an error.
Okay.
So let's fix up this error.
Uh.
Okay.
I think this will fix this up.
And let's run this again.
So now you can see we are able to read the text of license plates over here.
And let's see if we have the JSON file over here or not.
Currently it's empty.
Okay.
I just got this error over here.
Let's run this again now and see how does it works.
Now let's run this again and see if it works or not.
So I will just run this script now.
So it should generate a JSON file after every 22nd interval.
So now you can see over here, uh, it will generate individual JSON files for each 22nd interval.
And there will be a cumulative JSON file, uh, which will contain the timestamps for all the intervals
as well as the license plate data for all the intervals as well.
So now it has started and we will see our JSON files in in this folder.
Currently it's empty.
Uh, it will be generating JSON files after every 22nd interval.
So let's see.
Okay.
So now we have our first, uh, JSON file over here.
Okay.
So let's uh see.
So now you can see over here we have uh our interval like 4440 and 45.
And here you can see this is the state that have been detected during this 22nd interval.
And this is the cumulative JSON file over here.
And you can see over here the same interval and the data which has been detected.
So now we can see after a 22nd interval we have another JSON file which is from this interval to this
interval.
And this is the license plate data detected during this interval.
And this is a completed file.
So now you can see this is the uh license plate detected during this first 22nd interval.
And these are the license plates that are detected during the next 22nd interval.
Okay.
So now this is the third JSON file.
So now you can see over here these are the license plate data detected during this interval provided
over here.
And this is accumulated this file which contains um all the data data for all the intervals which have
been currently processed.
So now this is how it works.
So I will not stop this code.
Uh uh uh, currently it will start continue producing the output like you can see over here.
I will not stop the script currently, but uh, we will go towards the next part.
So the next we will see how we can save the license plate data to the SQL database.
So now we will go ahead towards that part.
So we will be using SQLite.
Um so which is a very lightweight.
Lightweight disk based database.
And we will be using the SQL SQLite.
And it is very easy to set up and use as well.
So SQLite SQLite comes pre-installed.
So we not need to install it.
But we need to install uh the SQLite three module.
So let's get started with this.
Just right.
So we'll just copy this from here.
We install this so we can simply go to settings.
Um here we have.
Uh, now here we click on the plus sign.
So here we need to install this package.
So you can simply write, uh, this install this package from here.
Or you can simply write pip install in the terminal as well.
So this is how you can do this.
So here you can simply write import Sqlite3 over here.
So first we need to create an SQLite database and a table to store the license plate data.
So first we need to create a SQLite database and table.
So I will just write SQL.
Uh.
What should I write the name over here.
I will just try.
So first we will create, uh, the SQLite database and a table so that we can store the license plate
data.
So I will resign in protest to like three.
So first we will connect to the.
Light uh database.
Or we will create it.
That will create a cursor object.
Interact with the data base.
So now we will create a table to store the license plate data.
Let's also execute.
And table if not exists.
So we have.
Then you have the start time and this is in the form of text.
Then you have the end time.
Then we have the license plate like the license plate which are detected.
And this will be in the form of text as well.
So this looks fine.
So now in the meanwhile, like you can see over here, uh, this is ah, all the outputs.
And this is the accumulated JSON file which has been generated.
So this looks good.
Okay.
So now, uh, let's run this.
Now, this will create a SQLite database and a table so that we can where we can store the license plate
data.
So now you can see that, uh, SQLite database have been created.
And so here now we can store our license plate data which you can see over here.
And uh like you can see over here that this file has been created over here.
So, so far, so good.
Now we will save our license plate data to the database.
So now what I will do over here is, uh, you know, write save to.
Database.
Okay.
So the input will be the same which we can find over here.
The exact same input will be passed over here.
So now we'll just write connect Sqlite3 dot connect.
Uh, this is the function created.
Course.
Uh.
One that I saw for plate.
Plates.
Cursor.
Dot.
Execute.
Inside.
Our time and time.
again.
Since.
Then we have values.
I also format like which converted previously as well.
For now, we'll save data to SQL database.
Okay, everything looks fine to me, but, um, let's run this and see how this works.
Start time.
Uh, one thing you need to check.
I think they should match.
Okay, this looks fine.
Yeah, it looks good now.
Just checking it once more.
So let's run this up now.
You can start it.
Okay, so this will take some time.
Okay.
There's a.
Table has no column name and time.
Um.
My mistake.
Understand this.
Hopefully it will work fine now.
There is a mistake as well.
I can see it.
Yeah.
We should have start time and time.
Okay.
I'm now running it again and hopefully this will now work fine.
But let's see how does it goes.
Okay.
Let me remove this.
Previous entries.
On our program has started.
Okay.
And let's see if we have our JSON file.
So now you can see we have our JSON files.
Let's look good.
And if we see now you can see that it's updated as well from the date modified okay.
So now it's hopefully it's working fine.
So let's have some entries and then uh we will uh see our file.
Our database looks like.
So let's continue processing it.
This will take some time still.
I guess it will take much time.
So now you can see as I'm running on CPU machine, the processing is very slow, but if you have a good
GPU the processing will be fast.
Definitely.
So now it's going steady and slow and steady, but it's going smoothly.
So that is what I was expecting.
And it will look good.
Quite good.
Yeah.
So now you can see over here, um, like it's a bit blurred.
So therefore it's painful.
So this is now you can see we have these JSON files till now.
And like you can see over here, our database is being continuously updated like this is our current
database file.
So things look quite smooth and good.
Okay so.
Now to view our SQLite database file.
So I will just write SQLite viewer online.
And over here I will upload this.
So let's wait for it to complete.
And then we will upload our file over here.
By you can see currently we have this I'm just waiting for it to complete.
And then I will show you the file over here.
Currently we have this accumulated data.
That's good as well.
It's a long video.
It's still processing, but we can just pause it over here and currently upload this, our database
file and see.
So I will just go to next to Light Online viewer.
And over here you can see this is my license plate database.
And I will just upload this.
So now you can see these are all the entries we have in our database file.
This is the ID, this is the start time or this is the end time.
And you can see that um like 59 3759, 58 and like this is uh, 22nd time span.
And you can see over here, uh, we have these entries like, like the results were quite good for me
now.
Like, you can see, uh, this is our 22nd again, 22nd time span over here.
And you can see these are the entries which we have found 22nd time span over here as well.
And, uh, that is what looks good to me for now.
Like you can see this is again 22nd time span.
And this is the license plate that has been detected.
And we have just uploaded our database file.
And you can see all the entries over here okay.
3253 like 22nd time span 1333.
Like 26.
Like you can see over here.
So that's good.
So in this tutorial we have learned how we can uh, do uh automatic number plate detection and recognition
using YOLO and uh, OCR.
Plus we have also saved our license plate data into JSON file.
And we have also saved our license plate data into an SQLite database.
So that's all from this tutorial.
Thank you for watching.