Skip to content

This repository uses a custom trained model trained on SSDMobileNetV2 to detect licence plates in images

Notifications You must be signed in to change notification settings

zafarRehan/licence_plate_detection

Repository files navigation

Licence Plate Detection

This repository uses custom-trained MobileNet-SSD V2 model for Object Detection to detect Licence plates in Images

This model will only detect one class of object i.e. Licence Plates
The explained training of the model can be found in my training repo here : https://github.com/zafarRehan/tensorflow_transfer_learning

Required Libraries

pip install opencv-python
pip install numpy
pip install tensorflow

Contents

1. exported-model:

This folder contains the trained model that we got as the result from tensorflow_transfer_learning

2. models:

This folder is the official Tensorflow's models library https://github.com/tensorflow/models which is needed for custom training a tensorflow model and in this case loading the custom trained model. This repo also has cool drawing functionalities which I used for drawing the bounding boxes over image.

3. custom.pbtxt:

This file contains the class labels and is the same file used while training the model.

4. detect.py:

The python file which consists the code to
1. Load Model
2. Detect Licences
3. Draw the output over image

Running the code

1. In order to run the code you must have tensorflow 2.2 or above intalled
2. Make sure to change your present working directory to path to repo folder + licence_plate_detection/models/research
3. Run the following code:
protoc object_detection/protos/*.proto --python_out=.

4. Change the BASE_PATH in line 10 of the code as guided in comment
5. Proceed to run the code



The code is well-commented so more details can be found in comments



Input Images



Output Images

About

This repository uses a custom trained model trained on SSDMobileNetV2 to detect licence plates in images

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published