Skip to Content
  • Proceeding Paper
  • Open Access

8 April 2026

6 Pages

Cognitive Vision-Based Pruning Region Identification Using Deep Learning †

,
and
School of Electrical, Electronics, and Computer Engineering, Mapua University, Manila 1002, Philippines
*
Author to whom correspondence should be addressed.
†
Presented at the 7th Eurasia Conference on IoT, Communication and Engineering 2025 (ECICE 2025), Yunlin, Taiwan, 14–16 November 2025.

Abstract

Pruning is a critical horticultural practice that requires continuous interpretation of plant structure to maintain crop health and prevent disease. Manual identification of pruning-relevant regions is labor-intensive and limits scalability in precision agriculture. This study presents a cognitive vision-based pruning region identification system using a You Only Look Once version 9 model to detect lateral branches, lower leaves, and diseased leaves in Solanum lycopersicum. A custom dataset of 4905 augmented images was used for training and evaluation. The model achieved 82.86% precision, 77.24% recall, 79.96% F1-score, and 83.21% mAP. Deployment on Raspberry Pi 5 demonstrated real-time, cloud-independent edge inference, indicating the feasibility of low-cost cognitive vision systems for smart agriculture.

1. Introduction

Pruning is an essential horticultural practice in tomato cultivation, contributing to improved airflow, reduced fungal and bacterial infections, and enhanced fruit quality and yield [1]. Effective pruning requires accurate visual interpretation of plant structure, including the identification of lateral branches, senescent leaves, and diseased regions. These tasks are traditionally performed by skilled workers through manual inspection, making pruning labor-intensive and highly dependent on human expertise.
Recent advancements in AI have enabled the application of deep learning techniques to agricultural problems such as plant disease detection, crop quality assessment, and phenotypic analysis. Prior studies have successfully applied convolutional neural networks (CNNs) to disease detection in abaca plants [2,3] and defect classification in beans [4]. Several tomato-related computer vision studies have largely focused on disease identification and fruit ripeness classification using CNN-based architectures, Fast R-CNN, Faster R-CNN, Mask R-CNN, and early You Only Look Once (YOLO) models [5,6,7].
Researchers have investigated tomato pruning-point recognition using improved Mask R-CNN architectures [8,9,10]. While these approaches achieve high detection accuracy, they typically require substantial computational resources, limiting their applicability for real-time deployment in field environments. In contrast, YOLO-based object detection models have gained popularity in agricultural applications due to their single-stage architecture, computational efficiency, and suitability for real-time inference. YOLO has been applied to tasks such as snail detection [11], coffee leaf detection [12], rice disease identification [13], aquarium fish recognition [14], and rice grain quality inspection [15].
YOLOv9—the latest version at the time of this study—offers improved accuracy and efficiency compared with earlier YOLO variants. We introduce a YOLOv9-based pruning region identification system that expands detection beyond lateral branches to include lower leaves and diseased leaves, as in the figure below (Figure 1). By integrating efficient visual perception with embedded deployment, the proposed system aligns with cognitive computing principles by enabling data-driven visual inference and localized decision support on low-cost edge hardware.
Figure 1. Tomato plant images with pruning regions.

2. Methodology

2.1. Dataset Collection

Three samples each of Cherry, Roma, and Rio Grande tomato plants were acquired from Quezon City, Philippines. A Raspberry Pi 5 equipped with a Raspberry Pi Camera Module V2 was used to capture 1200 initial images under natural lighting conditions. The dataset includes examples of lateral branches, lower leaves, diseased leaves, and plants without visible pruning regions. This data collection approach follows common practices used in agricultural imaging studies [4,13].

2.2. Preprocessing and Annotation

Captured images with a resolution of 1920 × 1080 pixels were processed to improve training effectiveness. Preprocessing steps included background noise removal, resizing for compatibility with YOLOv9 input requirements, and data augmentation to increase variability and improve generalization. Manual annotation was performed using bounding boxes corresponding to three pruning-related classes. After augmentation, the dataset size increased to 4905 images.

2.3. YOLOv9 Training

YOLOv9 was trained for 50 epochs using standard object detection evaluation metrics, including precision, recall, F1-score, and mean average precision (mAP). These metrics follow evaluation practices used in previous YOLO-based agricultural detection studies [11,12,13,14,15]. The model functions as the core visual perception module within the proposed cognitive vision framework (Figure 2).
Figure 2. Pruning region identification process.

2.4. System Deployment

The trained YOLOv9 model was deployed using the components shown in the hardware block diagram below (see Figure 3). We used Raspberry Pi 5 as the microcomputer for the system. A 3.5-inch liquid crystal display was connected to the Raspberry Pi for display, and a Camera Module V2 was connected for the image capture. The SD card was used to store the model in the microcomputer. This edge-based deployment supports localized decision-making and aligns with cognitive computing principles by eliminating dependence on cloud-based processing.
Figure 3. Hardware block diagram.

3. Results and Discussion

The YOLOv9 pruning-region identification system achieved the following performance metrics on the test dataset:
  • Precision: 82.86%
  • Recall: 77.24%
  • F1-Score: 79.96%
  • mAP: 83.21%
Precision = T P T P + F P
Recall = T P T P + F N
F 1   Score = P ⋅ R e c a l l P ⋅ R e c a l l 2
mAP = 1 N ∑ i = 1 N A P i
The model achieved a precision of 82.86%, indicating a high proportion of correctly identified pruning regions among all predicted detections. A recall of 77.24% was obtained, reflecting the system’s capability to detect most true pruning regions present in the images. The resulting F1-score of 79.96% confirms a balanced trade-off between precision and recall. Furthermore, the model attained a mean average precision (mAP) of 83.21%, demonstrating robust overall detection accuracy across evaluation thresholds. These results indicate that the proposed cognitive vision framework is effective for automated pruning-region identification under the evaluated conditions.
Training curves demonstrated rapid convergence, stabilizing after approximately 10 epochs (Figure 4). An epoch represents one iteration of the whole training dataset through the model. Training loss reflects the error computed on the dataset used for parameter optimization, while validation loss indicates error on an unseen validation dataset and serves as a measure of generalization performance. Performance variation was observed among tomato varieties, with Roma plants exhibiting increased detection difficulty due to irregular leaf shapes and occlusions, consistent with challenges reported in previous plant-detection studies [5,6].
Figure 4. Training and validation loss curve.
Sample test inferences showed accurate lateral branch detection, reliable lower leaf identification, and competent diseased leaf detection comparable to YOLO-based disease recognition systems [13]. The figure below (see Figure 5) shows inferences on a cherry tomato plant, wherein suckers and lower foliage were detected. Two detections of suckers were made with confidence levels of 0.96 and 0.98, while one detection has a confidence level of 0.70. A lower confidence level for lower foliage as the pruning region could be attributed to varying backgrounds and plant pots used in generating the raw dataset.
Figure 5. Sample test inference.
The proposed system expands pruning-region detection beyond lateral branches, addressing limitations in prior studies that focused solely on pruning points [8,9,10]. Compared with Mask R-CNN-based approaches, the YOLOv9 implementation is significantly lighter and more suitable for real-time deployment on embedded hardware. The results demonstrate that learning-based visual perception can effectively support pruning-related decision-making in agricultural environments.
Limitations of the study include limited environmental diversity during data collection, moderate dataset size, and class imbalance. Future work may incorporate multi-location datasets, additional sensing modalities such as multispectral or depth sensors, robotic actuators for autonomous pruning, and cloud-linked cognitive models for adaptive learning across growing seasons.

4. Conclusions

We developed a cognitive vision-based YOLOv9 system for pruning region identification in tomato plants. A custom dataset was generated for the training of the YOLOv9 model, which achieved an 82.86% precision, 77.24% recall, 79.96% F1-Score, and 83.21% mAP. Results for the F1-score and mAP indicate a good balance of the precision and recall metrics and sufficient capability of the model in identifying pruning regions. The system achieved strong detection performance across multiple pruning-related classes and demonstrated successful real-time deployment on Raspberry Pi hardware. These findings highlight the potential of low-cost, embedded cognitive vision systems for smart agriculture. Enhancing dataset diversity and integrating multi-sensor fusion may further support the development of fully autonomous pruning systems.

Author Contributions

Conceptualization, M.S.U.; methodology, J.A.N.T.T. and M.S.U.; software, J.A.N.T.T.; validation, M.S.U., J.A.N.T.T. and N.B.L.; formal analysis, M.S.U.; investigation, M.S.U.; resources, J.A.N.T.T.; data curation, J.A.N.T.T. and M.S.U.; writing—original draft preparation, M.S.U.; writing—review and editing, M.S.U., J.A.N.T.T. and N.B.L.; visualization, M.S.U.; supervision, N.B.L.; project administration, N.B.L.; funding acquisition, J.A.N.T.T. and M.S.U. All authors have read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Data Availability Statement

Solanum lycopersicum plants were used in this study. Cherry, Rio Grande, and Roma Variants were selected from different local plant sources within Metro Manila. The authors themselves procured the samples used in this study. The original contributions presented in this study are included in the article. Further inquiries can be directed to the corresponding author.

Conflicts of Interest

The authors declare no conflicts of interest.

References

  1. Ferrandino, F.J. Pruning, Training, and Supporting Tomatoes. Available online: https://portal.ct.gov/-/media/caes/documents/publications/fact_sheets/plant_pathology_and_ecology/pruningtrainingandsupporitngtomatoesferrandinopdf.pdf?rev=4b8b15da43b3459c832c9a29d80e67c5&hash=A400FF8864A2E66B17B0AD72C0530B3F (accessed on 1 January 2025).
  2. Buenconsejo, L.T.; Linsangan, N.B. Detection and Identification of Abaca Diseases Using a Convolutional Neural Network (CNN). In Proceedings of the IEEE Region 10th Annual International Conference (TENCON), Kota Kinabalu, Malaysia, 27–30 October 2025. [Google Scholar]
  3. Buenconsejo, L.T.; Linsangan, N.B. Classification of Healthy and Unhealthy Abaca Leaf Using a Convolutional Neural Network (CNN). In Proceedings of the 2021 IEEE 13th International Conference on Humanoid, Nanotechnology, Information Technology, Communication and Control, Environment, and Management (HNICEM), Manila, Philippines, 28–30 November 2021. [Google Scholar]
  4. Yumang, A.N.; Sta. Juana, M.C.M.; Diloy, R.L.C. Detection and Classification of Defective Fresh Excelsa Beans Using Mask R-CNN Algorithm. In Proceedings of the 2022 14th International Conference on Computer and Automation Engineering (ICCAE), Brisbane, Australia, 25–27 March 2022; pp. 97–102. [Google Scholar]
  5. Priyadharshini, G.; Judie Dolly, D.R. Comparative Investigations on Tomato Leaf Disease Detection and Classification Using CNN, R-CNN, Fast R-CNN and Faster R-CNN. In Proceedings of the 2023 9th International Conference on Advanced Computing and Communication Systems (ICACCS), Coimbatore, India, 17–18 March 2023; pp. 1540–1545. [Google Scholar]
  6. Legaspi, J.; Pangilinan, J.R.; Linsangan, N. Tomato Ripeness and Size Classification Using Image Processing. In Proceedings of the 2022 5th International Seminar on Research of Information Technology and Intelligent Systems (ISRITI), Yogyakarta, Indonesia, 8–9 December 2022. [Google Scholar]
  7. Pangilinan, J.R.; Legaspi, J.; Linsangan, N. InceptionV3, ResNet50, and VGG19 Performance Comparison on Tomato Ripeness Classification. In Proceedings of the 2022 5th International Seminar on Research of Information Technology and Intelligent Systems (ISRITI), Yogyakarta, Indonesia, 8–9 December 2022. [Google Scholar]
  8. Xiang, R.; Zhang, M. Tomato Stem Classification Method Based on Improved Mask R-CNN. J. Hunan Univ. Nat. Sci. 2023, 50, 31–39. [Google Scholar]
  9. Liang, X.; Zhang, X.; Wang, Y. Recognition Method for the Pruning Points of Tomato Lateral Branches Using Improved Mask R-CNN. Trans. Chin. Soc. Agric. Eng. 2022, 38, 112–121. [Google Scholar]
  10. Feng, Q.; Cheng, W.; Li, Y.; Wang, B.; Chen, L. Method for Identifying Tomato Plants Pruning Point Using Mask R-CNN. Trans. Chin. Soc. Agric. Eng. 2022, 38, 128–135. [Google Scholar]
  11. Yumang, A.N.; Bautista, J.A.; Borreta, J.R.I. Snail Detection Using YOLO. In Proceedings of the 2023 IEEE 5th Eurasia Conference on IoT, Communication and Engineering (ECICE), Huwei, Taiwan, 27–29 October 2023; pp. 792–795. [Google Scholar]
  12. Javierto, D.P.P.; Martin, J.D.Z.; Villaverde, J.F. Robusta Coffee Leaf Detection Based on YOLOv3-MobileNetv2 Model. In Proceedings of the 2021 IEEE 13th International Conference on Humanoid, Nanotechnology, Information Technology, Communication and Control, Environment, and Management (HNICEM), Manila, Philippines, 28–30 November 2021. [Google Scholar]
  13. Agbulos, M.K.; Sarmiento, Y.; Villaverde, J. Identification of Leaf Blast and Brown Spot Diseases on Rice Leaf with YOLO Algorithm. In Proceedings of the 2021 7th International Conference on Control Science and Systems Engineering (ICCSSE), Qingdao, China, 30 July–1 August 2021; pp. 307–312. [Google Scholar]
  14. Chan, C.J.L.; Reyes, E.J.A.; Linsangan, N.B.; Juanatas, R.A. Real-Time Detection of Aquarium Fish Species Using YOLOv4-Tiny on Raspberry Pi 4. In Proceedings of the 2022 4th IEEE International Conference on Artificial Intelligence in Engineering and Technology (IICAIET), Sabah, Malaysia, 26–28 August 2025. [Google Scholar]
  15. Yadao, G.G.; Julkipli, O.M.Y.; Manlises, C.O. Performance Analysis of EfficientNet for Rice Grain Quality Control—An Evaluation against YOLOv7 and YOLOv8. In Proceedings of the 2024 7th International Conference on Information and Computer Technologies (ICICT), Honolulu, Hawaii, 15–17 March 2024; pp. 93–98. [Google Scholar]
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Article Metrics

Citations

Article Access Statistics

Multiple requests from the same IP address are counted as one view.