This is a road sign recognition project based on YOLOv5, developed with a PyQt5 interface, YOLOv5 trained model, and MySQL database. The project consists of five modules: parameter initialization, sign recognition, database, data analysis, and image processing(Please refer to the Chinese document for details).
Road Sign Recognition System Based on YOLOV5
Run main.py
.
Here are the default login credentials:
Username | Password |
---|---|
admin | 123456 |
1 | 2 |
Modify the main function in main.py
to enter the system directly without authentication.
pt
folder: Contains the YOLOv5 model filebest.pt
for road sign recognition.main_with
folder: Containslogin.py
for the login UI andwin.py
for the main UI.dialog
folder: Contains the RTSP pop-up interface.apprcc_rc.py
: The resource file for the project.login_ji.py
: Implements the login logic for the UI.run/run-exp52
: The YOLOv5 road sign recognition model trained for 300 epochs.utils/tt100k_to_voc-main
folder: Tool for converting JSON annotations to YOLO format.result
: Folder to save inference results.run
: Folder to save training logs and outputs.- Dataset: Download from TT100k : Traffic-Sign Detection and Classification in the Wild.
- Database files: Located in the
data
folder, see-regn_mysql.sql
for setup.
To install the required dependencies, run:
pip install -r requirements.txt
This project uses YOLOv5 v6.1.
For database connections, you need to set up your MySQL database as per the configurations below:
def get_db_connection():
return pymysql.connect(
host='localhost',
user='root',
password='123456',
database='traffic_sign_recognition'
)
There are two identical database links in the code that need to be modified, please check the database sql file under the data folder to establish the test database
- For converting the TT100K dataset to VOC format and selecting more than 100 images and XMLs for each category, see this CSDN blog post.
- The PyQt5-YOLOv5 integration was inspired by this GitHub repository.
Track the GitHub star history of this project: