Skip to content

Repository files navigation

Number Plate Detection

Automatic License Plate Recognition (ALPR) using YOLOv5 for plate detection and Tesseract OCR for character recognition. This is a college project implemented as a Google Colab notebook.

What it does

  1. Detection — a YOLOv5 model is trained to localize license plates in car images (COCO annotations are converted to YOLOv5 label format).
  2. Recognition — the detected plate region is passed through PyTesseract (with a Haar cascade for plate-region refinement) to read the plate text.
  3. State mapping — Indian RTO codes (e.g. DL, MH, KA) are mapped to their states using Indian RTO.csv.

The pipeline is tested on OpenALPR benchmark images (US, EU and BR sets).

Repository contents

  • final_code_vr_iit2018138.ipynb — the full pipeline as a Colab notebook (dataset preparation, YOLOv5 training, detection, OCR).
  • Indian RTO.csv — mapping of RTO codes to states.
  • Visual Recognition Project.pdf — project report.

Setup

The notebook is designed for Google Colab. Open final_code_vr_iit2018138.ipynb in Colab and run the cells top to bottom. Notable steps:

  • Mounts Google Drive and clones the YOLOv5 repository.
  • Extracts the car dataset and converts COCO annotations to YOLOv5 labels.
  • Trains YOLOv5 (yolov5s, 416×416) on the prepared dataset.
  • Runs detection and reads plates with Tesseract OCR.

License

MIT — see LICENSE.

About

Automatic license plate recognition using computer vision and machine learning.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages