Object Detection using YOLOv8
This project aims to utilize YOLOv8 for creating custom-trained models in diverse applications, including license plate detection , potholes detection, and Personal Protective Equipment (PPE) detection. Additionally, the trained-models will be utilized
into creating a fully functional object-detection app using Streamlit.
1. Annotate Images:
• Annotate dataset with bounding boxes around objects of interest. Tools like RoboFlow or CVAT can be used for this.2. Split Data:
• Divide dataset into training and validation sets. The training set is used to train the model, while the validation set is used to evaluate its performance during training.3. Pre-process the images:
• Standard image pre-processing steps are resizing images to the same size to ensure consistency. Default value used for yolov8 training is 640x640.4. Augment Images (if needed):
• Data augmentation techniques can be applied to artificially increase the diversity5. Select YOLOv8 model variant:
• A model with more parameters will generally perform better in terms of accuracy6. Train the model: (NOTE: model trained using yolov8's default hyperparameters)
• Fine-tune the YOLOv8 model on the annotated dataset using the training set. Monitor metrics such as loss and mAP during training.7. Validate the Model:
• Evaluate the trained model on the validation set to ensure it generalizes well8. Inference on Test Set:
• After training, perform inference on a separate test set to assess the model's performance on completely unseen data.Model | mAP50 | mAP50-95 |
---|---|---|
Potholes detection (yolov8m) | 0.721 | 0.407 |
Car License plate detection (yolov8m) | 0.995 | 0.828 |
PPE Detection (yolov8m) | 0.991 | 0.738 |
Example 1: Detecting car license plate
Example 2: Reading license plate using EasyOCR
Hi! How can I help you today?