Development and Validation of an Image Dataset for Automatic Recognition of the Olive Fruit Fly (Bactrocera oleae) Using Machine Learning

The olive fruit fly Bactrocera oleae (Rossi) (Diptera: Tephritidae) is the primary pest of olive crop globally, causing serious economic losses each year. Early and accurate detection of this pest is essential for implementing integrated management strategies and minimizing the use of chemical inputs. In this context, the application of advanced technologies such as computer vision and machine learning through modelling emerges as a promising solution for monitoring and managing this pest. However, the absence of a robust and efficient dataset has hindered the development of reliable models for its recognition. This study details the creation procedure of a dataset comprising 2440 images collected from field and laboratory environments, along with data augmentation and training of three different models using machine learning algorithms. The models were implemented with YOLOv5 and optimized with different versions (s, m, and epoch). All three models achieved accuracy exceeding 90%. The optimisation process, which combined different YOLOv5 versions (s and m) and epochs (300 and 150), determined that the model trained with the s version and 300 epoch provided the best trade-off between accuracy, robustness, and computational efficiency. This makes it the most suitable option for implementation on low-cost, resource-limited platforms such as the Raspberry Pi. This study represents a step toward the integration of artificial intelligence into olive cultivation, bringing significant benefits to both producers and the environment. This study differs from previous YOLOv5-based pest detection research by providing a heterogeneous dataset that combines field and laboratory conditions, and by validating its deployment on a low-cost embedded platform (Raspberry Pi), thus enabling practical automation in Integrated Pest Management (IPM) systems.

Authors

Institutions

Publication Details

Journal
AgriEngineering
Published
2025-12-08
DOI
https://doi.org/10.3390/agriengineering7120422
Primary Topic
Insect behavior and control techniques
Type
article
Field-Weighted Citation Impact
0.00

Funders

Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

Development and Validation of an Image Dataset for Automatic Recognition of the Olive Fruit Fly (Bactrocera oleae) Using Machine Learning

Juan Manuel Díaz‐Cabrera, Luis Miguel Cámara-Díaz, J. Ramírez-Faz, Meelad Yousef-Yousef et al.
AgriEngineering
Insect behavior and control techniques
article

Development and Validation of an Image Dataset for Automatic Recognition of the Olive Fruit Fly (Bactrocera oleae) Using Machine Learning

Juan Manuel Díaz‐Cabrera, Luis Miguel Cámara-Díaz, J. Ramírez-Faz, Meelad Yousef-Yousef, Enrique Quesada‐Moraga, Flora Moreno-Alcaide
article en

Abstract

The olive fruit fly Bactrocera oleae (Rossi) (Diptera: Tephritidae) is the primary pest of olive crop globally, causing serious economic losses each year. Early and accurate detection of this pest is essential for implementing integrated management strategies and minimizing the use of chemical inputs. In this context, the application of advanced technologies such as computer vision and machine learning through modelling emerges as a promising solution for monitoring and managing this pest. However, the absence of a robust and efficient dataset has hindered the development of reliable models for its recognition. This study details the creation procedure of a dataset comprising 2440 images collected from field and laboratory environments, along with data augmentation and training of three different models using machine learning algorithms. The models were implemented with YOLOv5 and optimized with different versions (s, m, and epoch). All three models achieved accuracy exceeding 90%. The optimisation process, which combined different YOLOv5 versions (s and m) and epochs (300 and 150), determined that the model trained with the s version and 300 epoch provided the best trade-off between accuracy, robustness, and computational efficiency. This makes it the most suitable option for implementation on low-cost, resource-limited platforms such as the Raspberry Pi. This study represents a step toward the integration of artificial intelligence into olive cultivation, bringing significant benefits to both producers and the environment. This study differs from previous YOLOv5-based pest detection research by providing a heterogeneous dataset that combines field and laboratory conditions, and by validating its deployment on a low-cost embedded platform (Raspberry Pi), thus enabling practical automation in Integrated Pest Management (IPM) systems.

AgriEngineeringVol. 7(12)
University of Córdoba (ES)
European Commission, Universidad de Córdoba
Openalex Percentile: Top 65%
Insect behavior and control techniques
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.