Enhancing Strawberry Yield Prediction Using YOLOv8 for Flower Counting and RNN model for Time Series Forecasting
Abstract
Strawberry yield prediction plays a crucial role in optimizing agricultural productivity and resource management. Recent advancements in computer vision and time-series forecasting have opened new opportunities to enhance yield forecasting accuracy. This study integrates the YOLOv8 model for object detection to count flowers and fruits, combined with recurrent neural networks (RNNs) such as Long Short-Term Memory (LSTM), Gated Recurrent Unit (GRU), and hybrid Convolutional Neural Networks (CNNs) for time-series prediction. A dataset of 500 daily images was collected using timelapse cameras deployed across three greenhouses operated by farmers A, B, and C. Images were annotated, and flower and fruit counts were aligned with yield data to support time-series forecasting. YOLOv8 achieved a mean average precision (mAP) of 0.82 for green fruits and 0.78 for red fruits, while flower detection was comparatively lower at 0.66 due to colour distortion and overlapping objects. Augmented datasets improved detection generalization. For yield prediction, the dataset from farmer A showed the highest performance, achieving a validation R2 of 0.477, MAE of 7.702, and MSE of 86.559, while datasets from farmer B and C exhibited lower accuracy due to missing data. The results demonstrate the potential of combining computer vision and time-series models for agricultural forecasting, although addressing data gaps remains crucial to enhancing model robustness.