Using PyTessaract and OpenCV to read car's license plate and their speed and then sort them into two (overspeeding/non-overspeeding) from a live video stream in Python.
- opencv-python
- numpy
- requests
- pytesseract
- datetime
- time
- csv
- pandas
to convert image byte data to an array
pip install numpy
to recognize text from the image
pip install pytesseract
to read an image and perform certain image-processing techniques
pip install opencv-python
to fetch images from the wifi-camera(URL)
pip install requests
for logging the current time when a car is detected
pip install DateTime
to calculate the Speed of the car detected (YOLO)
pip install time
for cleaning the CSV file data
pip install pandas
Important
- start the camera and change the URL in the "license_speed.py" file in the 'AI' directory.
- Run the file "license_speed.py" in the 'AI' directory.
- Run the file "clean.py" in the 'AI' directory.
- check the output in the "vehicle_details.csv" or "filtered_file.csv" in the 'data' directory.
- start the camera and change the URL in the "main_web.html" file in the 'website' directory.
- open website. (run that HTML file)
- you can change the speed limit of the car. (which is later sorted into two list {overspeeding/non-overspeeding})
Note
- Remember to perform the initial setup before test-driving.
- you have to provide a constant video feed to the camera.
- you can use multimedia to test the code.
Footnotes
-
.whl files are given in the "for_package_installation_error" directory ↩