Week 4 — Project LEAFS

Baha Kırbaşoğlu
AIN311 Fall 2022 Projects
3 min readDec 9, 2022

Hi everyone,

Last week, we talked about our data preprocessing stage which contains cleaning duplicates and watermarks. This week, we took a small portion which contains 100 images for training and 10 images for testing per class of the dataset that we obtained using web scraping. Then, we labelled this sample for the YOLOv5 model using a labelling tool which is called YoloLabel.

Labelling Process

Labelling is a procedure before the YOLOv5 model training stage. We labelled train and test images with using the YoloLabel tool shown in Fig[1]. The first step of this tool is, uploading the data source and then also uploading the text file which contains classes shown below the name in Fig[1]. After these steps, we labelled the images based on classes.

Fig 1. Raising Hand and Taking Notes Classes labelled with YoloLabel Tool.

Model

We trained our model on Google Colab. First, we uploaded our labelled dataset to Google Drive for future usage. Then, we set our parameters which are image size, batch size and the number of epochs. Our parameters are 640, 64 and 100 respectively. The training process is shown in Fig[2].

Fig 2. First six epochs and their values

After the training process, we obtained our model and some evaluation metrics. One of the evaluation metrics which is the PR Curve is shown in Fig[3].

Fig 3. Precision—Recall Curve depending on epochs.

Results and Conclusion

As a result of a testing process, some of the classes are detected as approximately correct as shown in Fig[4].

Fig 4. Correctly Detected

On the other hand, some of the classes made the model indecisive and wrong as shown in Fig[5].

Fig 5. Incorrect Detected

--

--