{"id":29105248,"url":"https://github.com/saif-gitreps/alpd-for-bd-plates","last_synced_at":"2025-10-04T23:55:02.731Z","repository":{"id":300443046,"uuid":"1003723752","full_name":"saif-gitreps/ALPD-For-Bd-Plates","owner":"saif-gitreps","description":"Automatic License Plate Detection and Recognition System for Challenging Bangladeshi License Plate using YOLOv8, fine-tuned EfficientNetB0 model and EasyOCR hybrid recognition.","archived":false,"fork":false,"pushed_at":"2025-09-18T15:12:18.000Z","size":65175,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-09-18T18:13:30.710Z","etag":null,"topics":["cnn","efficientnetb0","keras","matplotlib","opencv","python","yolov8"],"latest_commit_sha":null,"homepage":"","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/saif-gitreps.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-06-17T15:10:59.000Z","updated_at":"2025-09-18T15:16:51.000Z","dependencies_parsed_at":"2025-07-07T18:37:46.180Z","dependency_job_id":"431e8a33-9fdf-4757-82d8-8ee7ca5ae53e","html_url":"https://github.com/saif-gitreps/ALPD-For-Bd-Plates","commit_stats":null,"previous_names":["saif-gitreps/alpd-for-bd-plates"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/saif-gitreps/ALPD-For-Bd-Plates","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saif-gitreps%2FALPD-For-Bd-Plates","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saif-gitreps%2FALPD-For-Bd-Plates/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saif-gitreps%2FALPD-For-Bd-Plates/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saif-gitreps%2FALPD-For-Bd-Plates/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/saif-gitreps","download_url":"https://codeload.github.com/saif-gitreps/ALPD-For-Bd-Plates/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saif-gitreps%2FALPD-For-Bd-Plates/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278391185,"owners_count":25978945,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-04T02:00:05.491Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cnn","efficientnetb0","keras","matplotlib","opencv","python","yolov8"],"created_at":"2025-06-29T01:38:46.308Z","updated_at":"2025-10-04T23:55:02.721Z","avatar_url":"https://github.com/saif-gitreps.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Bangladeshi License Plate Detection \u0026 Recognition 🚘\n\n**Automatic License Plate Recognition (ALPR) system** tailored for Bangladeshi vehicles.  \nIt combines **YOLOv8** for plate detection with a hybrid recognition pipeline using **EfficientNetB0** and **EasyOCR**, supported by preprocessing and confidence-based voting mechanisms.\n\n---\n\n## 📖 Overview\n\nLicense plate recognition is a crucial component in **traffic management, automated toll collection, parking systems, and vehicle surveillance**.  \nUnlike English or numeric plates, Bangla license plates present unique challenges due to:\n\n-  Complex **Bangla script morphology** (consonants, vowels, compound characters).\n-  **Inconsistent fonts** and plate designs.\n-  **Lighting variations, noise, and occlusion** in real-world scenarios.\n\nThis project addresses these challenges through a robust, deep-learning-based pipeline.\n\n---\n\n## 🏗️ System Architecture\n\n1. **Input Image** → Raw vehicle image.\n2. **Detection Module** → YOLOv8 detects the license plate region.\n3. **Plate Extraction** → Cropped region passed to preprocessing.\n4. **Preprocessing Pipelines** → Thresholding (Otsu, Adaptive Gaussian, Adaptive Mean).\n5. **Dual Recognition** →\n   -  **EfficientNetB0 CNN** (character recognition).\n   -  **EasyOCR** (end-to-end text extraction).\n6. **Confidence-Based Voting** → Final license plate prediction.\n\n## ![alt text](public/image.png)\n\n## 🛠️ Methodology\n\n### 🔍 Detection (YOLOv8)\n\n-  Small variant (`yolov8s`) trained on **785 annotated images**.\n-  Achieved **99% detection accuracy**.\n\n### 🧠 Recognition (EfficientNetB0 + EasyOCR)\n\n-  **EfficientNetB0** trained on ~17,000 cropped character images across **29 Bangla classes**.\n-  **EasyOCR** used as a complementary OCR method for robustness.\n-  Final results fused using **confidence-based voting**.\n\n### 🖼️ Preprocessing\n\n-  Image Enhancement (unsharp masking, bilateral filtering).\n-  Grayscale \u0026 contrast adjustment (top-hat, black-hat filtering).\n-  Multi-thresholding (Otsu, Adaptive Gaussian, Adaptive Mean).\n-  Noise removal \u0026 morphological operations.\n-  Character segmentation \u0026 resizing (64×64).\n\n---\n\n## 📊 Results\n\nTested using 722 unseen vehicle images.\n\n-  **YOLOv8 Detection**:\n\n   -  mAP@0.5: **98.79%**\n   -  Precision: **96.13%**\n   -  Recall: **98.73%**\n\n-  **EfficientNetB0 CNN**:\n\n   -  Character classification accuracy: **99%**\n   -  Full plate recognition: **73.84%**\n\n-  **EasyOCR**:\n\n   -  Full plate recognition: **74.79%**\n\n-  **Hybrid Ensemble (CNN + EasyOCR)**:\n   -  Full plate recognition: **94.90%**\n\n![alt text](public/image-7.png)\n\n---\n\n## Full working\n\n1. Detection:\n\n   ![alt text](public/image-1.png)\n\n2. Cropping using detected bounding box:\n\n   ![alt text](public/image-6.png)\n\n3. Preprocessing steps for EfficientNet:\n\n   ![alt text](public/image-2.png)\n\n4. Contour detection and classification:\n\n   ![alt text](public/image-3.png)\n\n5. Preprocessing and Recongition for EasyOCR\n\n   ![alt text](public/image-5.png)\n\n6. Ensemble voting between EfficientNetB0 and EasyOCR\n\n7. Final Text Extraction:\n\n   ![alt text](public/image-4.png)\n\n## 📂 Dataset\n\nThe system was trained and tested using publicly available **Bangladeshi license plate datasets**:\n\n-  [Bangladeshi Vehicle License Plate (Kaggle)](https://www.kaggle.com/datasets/sifatkhan69/bangladeshi-vehicle-license-plate)\n-  [Bangla License Plate Dataset with Annotations](https://www.kaggle.com/datasets/mirzamahfujhossain/bangla-license-plate-dataset-with-annotations)\n-  [Bangladeshi Bus \u0026 Truck Plates](https://www.kaggle.com/datasets/mdfahimbinamin/bangladeshi-bus-and-truck-license-plate-dataset)\n\n---\n\n## 🔮 Future Work\n\n-  Expand dataset with more diverse conditions (rain, night, low quality).\n-  Adaptive preprocessing selection based on input quality.\n-  Transformer-based OCR to directly predict full plates (reducing segmentation dependency).\n\n---\n\n## 🙌 Acknowledgments\n\n-  Kaggle contributors for open datasets.\n-  Ultralytics YOLO \u0026 EasyOCR community.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaif-gitreps%2Falpd-for-bd-plates","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsaif-gitreps%2Falpd-for-bd-plates","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaif-gitreps%2Falpd-for-bd-plates/lists"}