Improve Object Detection with YOLOv8
Introduction
In this tutorial, you will learn how to improve object detection predictions from YOLOv8 using Label Studio. You will create a project in Label Studio, import images, and annotate them with bounding boxes. You will then use the annotations to fine-tune the YOLOv8 model.
First install the required packages:
To ensure that the model is working correctly, you can load the model from the checkpoint.
Create a Label Studio project
Create a Label Studio project with the YOLOv8 labels. You need to define the labeling configuration with the YOLOv8 labels.
Now use this label_config
to create a project.
Import images
You can import images from cloud storage. If you use AWS S3, connect your project to storage bucket:
Import images from the storage:
Create YOLO predictions
You can collect object detections from the model and convert it to Label Studio JSON format.
Now, create YOLO predictions for the imported images and save them to the Label Studio project.bucket You can specify scores and model versions for the predictions.
Annotate Low Confidence Predictions
We can use views
to filter and organize tasks in Label Studio. For example, we can create a view that shows only tasks with low confidence predictions for the person
class:
Mark them as COMPLETED
when done.
Export Annotations
Finally, in order to export annotations that correspond to the batch of tasks, we can use the following code:
Convert Annotations to YOLO format
Coming soon! :)