journal article·2025-02-26Open access

A New Hybrid ConvViT Model for Dangerous Farm Insect Detection

Anil Utku, Mahmut Kaya, Yavuz Canbay

Applied Sciences· Volume 15· Issue 5

Abstract

This study proposes a novel hybrid convolution and vision transformer model (ConvViT) designed to detect harmful insect species that adversely affect agricultural production and play a critical role in global food security. By utilizing a dataset comprising images of 15 distinct insect species, the suggested approach combines the strengths of traditional convolutional neural networks (CNNs) with vision transformer (ViT) architectures. This integration aims to capture local-level morphological features effectively while analyzing global spatial relationships more comprehensively. While the CNN structure excels at discerning fine morphological details of insects, the ViT’s self-attention mechanism enables a holistic evaluation of their overall configurations. Several data preprocessing steps were implemented to enhance the model’s performance, including data augmentation techniques and strategies to ensure class balance. In addition, hyperparameter optimization contributed to more stable and robust model training. Experimental results indicate that the ConvViT model outperforms commonly used benchmark architectures such as EfficientNetB0, DenseNet201, ResNet-50, VGG-16, and standalone ViT, achieving a classification accuracy of 93.61%. This hybrid approach improves accuracy and strengthens generalization capabilities, delivering steady performance during training and testing phases, thereby increasing its reliability for field applications. The findings highlight that the ConvViT model achieves high efficiency in pest detection by integrating local and global feature learning. Consequently, this scalable artificial intelligence solution can support sustainable agricultural practices by enabling the early and accurate identification of pests and reducing the need for intensive pesticide use.
Source: crossref · Quality: baseline

Research context

OpenAlex topics: Smart Agriculture and AI · Mosquito-borne diseases and control · Insect and Arachnid Ecology and Behavior

SciVX discovery tags are terminology-based. OpenAlex topics are source-provided classifications.

Affiliations

Department of Computer Engineering, Munzur University, 62000 Tunceli, Turkey

Department of Artificial Intelligence and Data Engineering, Fırat University, 23119 Elazığ, Turkey

Department of Computer Engineering, Sutcu Imam University, 46050 Kahramanmaraş, Turkey

References (30)

Show source-provided references
1. Insect detection from imagery using YOLOv3-based adaptive feature fusion convolution network10.1071/CP21710 ↗
2. Teixeira, A.C., Ribeiro, J., Morais, R., Sousa, J.J., and Cunha, A. (2023). A systematic review on automatic insect detection using deep learning. Agriculture, 13.10.3390/agriculture13030713 ↗
3. High performing ensemble of convolutional neural networks for insect pest image detection10.1016/j.ecoinf.2021.101515 ↗
4. Classification and detection of insects from field images using deep learning for smart pest management: A systematic review10.1016/j.ecoinf.2021.101460 ↗
5. An improved YOLOX algorithm for forest insect pest detection10.1155/2022/5787554 ↗
6. Popescu, D., Dinca, A., Ichim, L., and Angelescu, N. (2023). New trends in detection of harmful insects and pests in modern agriculture using artificial neural networks. A review. Front. Plant Sci., 14.10.3389/fpls.2023.1268167 ↗
7. A new mobile application of agricultural pests recognition using deep learning in cloud computing system10.1016/j.aej.2021.03.009 ↗
8. Manchanda, M., Kukreti, V., Kumar, A., Katiyar, A., and Nikhurpa, Y. (2024, January 24–26). Optimizing Farm Insect Image Classification: A Transfer Learning Approach with Model Selection. Proceedings of the 2024 International Conference on Inventive Computation Technologies (ICICT), Lalitpur, Nepal.10.1109/ICICT60155.2024.10544571 ↗
9. Bhandare, T.V., Bendre, S.S., Deshmukh, D., Nere, A.G., and Patil, A.B. (2024, January 25–27). Bug (Insect) Detection using Deep Learning. Proceedings of the 2024 MIT Art, Design and Technology School of Computing International Conference (MITADTSoCiCon), Pune, India.10.1109/MITADTSoCiCon60330.2024.10575206 ↗
10. Satpute, B.S., Yadav, R., and Yadav, P.K. (2023, January 24–26). Dangerous Farm Insects Detection Using Transfer Learning and CNN. Proceedings of the 2023 2nd International Conference on Futuristic Technologies (INCOFT), Belagavi, India.10.1109/INCOFT60753.2023.10425454 ↗
11. Liu, Z., Gao, J., Yang, G., Zhang, H., and He, Y. (2016). Localization and classification of paddy field pests using a saliency map and deep convolutional neural network. Sci. Rep., 6.10.1038/srep20410 ↗
12. IoT-based pest detection and classification using deep features with enhanced deep learning strategies10.1016/j.engappai.2023.105985 ↗
13. An effective pest detection method with automatic data augmentation strategy in the agricultural field10.1007/s11760-022-02261-9 ↗
14. Tang, Z., Chen, Z., Qi, F., Zhang, L., and Chen, S. (2021, January 7–10). Pest-YOLO: Deep image mining and multi-feature fusion for real-time agriculture pest detection. Proceedings of the 2021 IEEE International Conference on Data Mining (ICDM), Auckland, New Zealand.10.1109/ICDM51629.2021.00169 ↗
15. Agarwal, A., Vats, S., Agarwal, R., Ratra, A., Sharma, V., and Jain, A. (2023, January 15–17). Efficient NetB3 for Automated Pest Detection in Agriculture. Proceedings of the 2023 10th International Conference on Computing for Sustainable Global Development (INDIACom), New Delhi, India.
16. Kuzuhara, H., Takimoto, H., Sato, Y., and Kanagawa, A. (2020, January 23–26). Insect pest detection and identification method based on deep learning for realizing a pest control system. Proceedings of the 2020 59th Annual Conference of the Society of Instrument and Control Engineers of Japan (SICE), Chiang Mai, Thailand.10.23919/SICE48898.2020.9240458 ↗
17. AF-RCNN: An anchor-free convolutional neural network for multi-categories agricultural pest detection10.1016/j.compag.2020.105522 ↗
18. Mango Pest Detection Using Entropy-ELM with Whale Optimization Algorithm10.32604/iasc.2023.028869 ↗
19. Monis, J.B., Sarkar, R., Nagavarun, S., and Bhadra, J. (2022, January 28–29). Efficient net: Identification of crop insects using convolutional neural networks. Proceedings of the 2022 International Conference on Advances in Computing, Communication and Applied Informatics (ACCAI), Chennai, India.10.1109/ACCAI53970.2022.9752514 ↗
20. Vision-based pest detection based on SVM classification method10.1016/j.compag.2017.03.016 ↗
21. (2024, June 24). Dangerous Farm Insects Dataset. Available online: https://www.kaggle.com/datasets/tarundalal/dangerous-insects-dataset.
22. Tan, M., and Le, Q. (2019, January 9–15). Efficientnet: Rethinking model scaling for convolutional neural networks. Proceedings of the 36th International Conference on Machine Learning, PMLR, Long Beach, CA, USA.
23. Detection of Dust on Solar Panels with Deep Learning10.17780/ksujes.1493906 ↗
24. Huang, G., Liu, Z., Van Der Maaten, L., and Weinberger, K.Q. (2017, January 21–26). Densely connected convolutional networks. Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Honolulu, HI, USA.10.1109/CVPR.2017.243 ↗
25. Canbay, Y., Adsiz, S., and Canbay, P. (2024). Privacy-Preserving Transfer Learning Framework for Kidney Disease Detection. Appl. Sci., 14.10.3390/app14198629 ↗
26. He, K., Zhang, X., Ren, S., and Sun, J. (2016, January 27–30). Deep residual learning for image recognition. Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Las Vegas, NV, USA.10.1109/CVPR.2016.90 ↗
27. Bilgen, Y., and Kaya, M. (2024, January 16–18). Detection of the Quality of Zivzik Pomegranate Grown in Siirt Using Deep Learning Methods. Proceedings of the 2024 Innovations in Intelligent Systems and Applications Conference (ASYU), Ankara, Turkiye.10.1109/ASYU62119.2024.10757065 ↗
28. Simonyan, K., and Zisserman, A. (2015, January 7–9). Very deep convolutional networks for large-scale image recognition. Proceedings of the 3rd International Conference on Learning Representations, San Diego, CA, USA.
29. Deep Learning Based Video Event Classification
30. Dosovitskiy, A. (2021, January 3–7). An image is worth 16×16 words: Transformers for image recognition at scale. Proceedings of the 9th International Conference on Learning Representations, Virtual.