Bus-Route-Detection-and-Classification
Bus Route Detector and Classifier for Visually Impaired People
Explore the docs »
View Demo
·
Report Bug
·
Request Feature
Table of Contents
About the Project :
Real-time object recognition and classification of objects through static data-frames is implemented in this work. This is a promising sector to implement innovative ideas related to computer vision applications. Visually impaired individuals undergo through difficult situations and complications faced while recognizing visual information as well as processing that information in a state of chaos, like a crowded area such as bus stop. Things get even harder for them when there is a need to step up and examine whether the bus or any transport they want to board into, mainly public transports, are actually routing from their boarding destination towards their target destination. The chaotic situation makes it almost impossible for any blind person to summarize that information and board onto that transport medium correctly. There are hardly any aids for the visually impaired people that will actually help them classify between buses specifically. The idea of personal help can be held under consideration but that is not always liable and viable. This paper describes a novel approach for recognizing buses and providing the corresponding routes. The bus images are captured in real-time, then the token number is extracted and the user is informed about the route information.
Getting Started
This project can be setup locally by cloning the repo and installing the requirements.
Prerequisites
This is an example of how to list things you need to use the software and how to install them.
pip
python -m pip install --upgrade pip
opencv-python
pip install opencv-python
Dependencies
pip install -r requirements.txt
JupyterNB implementation with Anaconda
Download Conda from Here. Then create new conda environment if you donot have conda installed previously or have not set up the environment
conda create -n env pip python=3.10
Activate the V-env by typing this command,
conda activate env
install jupyter notebook
pip install jupyter notebook
then install the dependencies as mentioned in the Prerequisites section.
Flow of Implementation
The project proposes the following flow for implementation of this idea :
![Flowchart of the Process](https://raw.githubusercontent.com/Shr3yash/Bus-Route-Detection-and-Classification/main/DemoImages/Picture1.png)
Following is the flowchart for the back-end process which has been implemented :
![Flowchart of the Process](https://raw.githubusercontent.com/Shr3yash/Bus-Route-Detection-and-Classification/main/DemoImages/Picture2.png)
Optical Character Recognition :
After the classification of buses we implemented EasyOCR for reading the token numbers any other alternate Optical Character Recognition algorithm can be used here but it is advised to go for EasyOCR as it is easier to implement and gives almost 100% accuracy in character recognition.
The algorithm for the easy OCR is as follows :
Input: Bus image with route number pasted on it. Output: Recognised text that is number from the image
Stages of Initialization:
Start
- Convert RGB image to Grey image
- Apply bilateral filter for noise reduction
- Apply canny filter for edge detection
- Finding contours
- Apply Masking
- Extracting text from the masked image using easy OCR
- Running if-else statement to find bus route
End
Results
The following implementation with TensorFlow yeilded 98.6% Accuracy on classification of Buses from non-Bus vehicles and 99.99% Accuracy in Optical Character Recognition.
![](https://user-images.githubusercontent.com/60093808/150591368-bbdf0b5f-aa36-466d-b9d7-2c76b5f90649.png)
![](https://user-images.githubusercontent.com/60093808/150591426-cec2cb78-f4fb-4f35-a017-e8c1e47c87c2.png)
![](https://user-images.githubusercontent.com/60093808/150591454-6c1aa74e-d7a5-42e2-b579-15c40cb7c149.png)
![](https://user-images.githubusercontent.com/60093808/150591484-d53cbf55-d9db-4771-b93e-12283f618210.png)
![](https://user-images.githubusercontent.com/60093808/150591513-22698ecc-3e4a-4875-bc6d-b0a82e887292.png)
Positive Classification ➡ Pre-Processing, then applying Canny Edge and Bilateral Filters ➡ Contour-Detection and Saving the cotour features. ➡ Output Number ➡ Corresponding Route ➡ Save as Text ➡ Audio Queue
License
Distributed under the CC0 License. See LICENSE.txt
for more information.
Contact
Twitter/Email - @DrCybernotix - 12shreyashh@gmail.com
Project Link: Bus-Route-Detection-and-Classification