This project demonstrates the use of the YOLO (You Only Look Once) object detection model on the COCO dataset. It processes images from the dataset and provides object detection results. The model used is a YOLOv8 Large model for better accuracy.
The project requires the following packages:
cv2
json
glob
pycocotools
ultralytics
YOLO
To run the project, follow these steps:
-
Clone the repository:
git clone https://github.com/thisishamody/yolo_paper_project.git
-
Install the necessary dependencies:
pip install opencv-python pycocotools glob2 ultralytics
-
Download the model weights and place them in the
Yolo-Weights
directory. You can download them from here. In this project, we useyolov8l.pt
for better accuracy.
The main.py
script runs the object detection process on images located in coco/val2017
.
The script evaluates the model's predictions and saves them in a JSON file named predictions.json
. It also calculates the mean Average Precision (mAP) for the model's predictions.
To run the script: