IJEM Vol. 16, No. 3, 8 Jun. 2026
Cover page and Table of Contents: PDF (size: 1822KB)
PDF (1822KB), PP.193-217
Views: 0 Downloads: 0
Depth-wise Separable Convolution, Lightweight Neural Network, Linear Time and Space Complexity, Neighbourhood Attention
Plant disease detection is vital for agricultural sustainability and food security. While Convolutional Neural Networks (CNNs) and Vision Transformers (ViTs) have achieved high accuracy in this domain, CNNs often require millions of parameters and substantial computation. ViTs suffer from the quadratic time and space complexity of self-attention (SA), limiting their use on resource-constrained devices. Although SA is capable of modelling long-range dependencies when symptoms are dispersed, many plant diseases exhibit small, localized lesions or texture changes; therefore, Neighborhood Attention (NA) offers a more efficient and targeted alternative by focusing on nearby regions rather than the entire image.
This work proposes a custom Localized NA block implemented in TensorFlow/Keras that operates directly on CNN feature maps, bypassing patch embedding and transformer modules. A lightweight CNN is then developed by combining depth-wise separable convolutions with the proposed localized NA block. In addition, a 100-category plant disease dataset covering 16 crops is presented. The dataset is curated, class-balanced, and made publicly available to support reproducibility and encourage further research.
The proposed 9-layer CNN, with just 1.7M parameters and a size of 6.74 MB, achieved a favorable balance between accuracy, model size, and computational efficiency, compared with MobileNetV1, MobileNetV2, DenseNet121, InceptionV3, MobileViT-XXS, and EfficientViT-M0, achieving 98.97%± 0.33% accuracy on PlantVillage and 93.36%± 0.28% on the proposed dataset. The ablation study showed that the NA block improved test accuracy by approximately 2–3%, while Grad-CAM visualizations indicated more precise targeting of diseased areas in the leaf image.
Rithambara Rajput, Suneeta Budihal, Saroja Siddamal, Dattaprasad Torse, "A Lightweight Convolutional Neural Network with Neighbourhood Attention and a 100-Category Dataset for Plant Disease Detection", International Journal of Engineering and Manufacturing (IJEM), Vol.16, No.3, pp.193-217, 2026. DOI:10.5815/ijem.2026.03.12
[1]G. Bv, & U. D. G. (2019). A survey on plant disease prediction using machine learning and deep learning techniques. International Journal of Artificial Intelligence, 22(63), 0–18. DOI: 10.4114/intartif.vol22iss63pp0-19
[2]K. Alibabaei et al. (2022). A review of the challenges of using deep learning algorithms to support decision-making in agricultural activities. Remote Sensing, 14(3), 1–43. DOI: 10.3390/rs14030638
[3]C. Jackulin, & S. Murugavalli. (2022). A comprehensive review on detection of plant disease using machine learning and deep learning approaches. Measurement: Sensors, 24, 100441. DOI: 10.1016/j.measen.2022.100441
[4]A. Krizhevsky, I. Sutskever, & G. E. Hinton. (2017). ImageNet classification with deep convolutional neural networks. Communications of the ACM, 60(6), 84–90. DOI: 10.1145/3065386
[5]K. Simonyan. (2015). Very deep convolutional networks for large scale image recognition. International Conference on Learning Representations (ICLR 2015), 1–14.
[6]K. He, X. Zhang, S. Ren, & J. Sun. (2016). Deep residual learning for image recognition. Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 770–778. DOI: 10.1109/CVPR.2016.90
[7]S. Wang, B. Z. Li, M. Khabsa, H. Fang, & H. Ma. (2020). Linformer: Self-attention with linear complexity. arXiv preprint. Available: http://arxiv.org/abs/2006.04768
[8]S. Mehta, & M. Rastegari. (2022). MobileViT: Light-weight, general-purpose, and mobile-friendly vision transformer. International Conference on Learning Representations (ICLR 2022).
[9]Z. Liu, H. Mao, C. Y. Wu, C. Feichtenhofer, T. Darrell, & S. Xie. (2022). A ConvNet for the 2020s. Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, 11966–11976. DOI: 10.1109/CVPR52688.2022.01167
[10]X. Liu, H. Peng, N. Zheng, Y. Yang, H. Hu, & Y. Yuan. (2023). EfficientViT: Memory efficient vision transformer with cascaded group attention. Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, 14420–14430. DOI: 10.1109/CVPR52729.2023.01386
[11]K. Wu et al. (2022). TinyViT: Fast pretraining distillation for small vision transformers. Lecture Notes in Computer Science, 13681, 68–85. DOI: 10.1007/978-3-031-19803-8_5
[12]R. Kumar, A. Chug, A. P. Singh, & D. Singh. (2022). A systematic analysis of machine learning and deep learning based approaches for plant leaf disease classification: A review. Journal of Sensors, 2022. DOI: 10.1155/2022/3287561
[13]H. Li, X. Yue, C. Zhao, & L. Meng. (2023). Lightweight deep neural network from scratch. Journal Name Not Provided, 18868–18886.
[14]A. Hassani, S. Walton, J. Li, S. Li, & H. Shi. (2022). Neighborhood attention transformer. arXiv preprint. DOI: 10.48550/arXiv.2204.07143
[15]L. Kaiser, F. Chollet, & A. N. Gomez. (2018). Depthwise separable convolutions for neural machine translation. International Conference on Learning Representations (ICLR 2018), 1–10.
[16]A. Hassani, & H. Shi. (2022). Dilated neighborhood attention transformer. arXiv preprint. DOI: 10.48550/arXiv.2209.15001
[17]S. P. Mohanty, D. P. Hughes, & M. Salathé. (2016). Using deep learning for image-based plant disease detection. Frontiers in Plant Science, 7, 1–10. DOI: 10.3389/fpls.2016.01419
[18]J. Amara, B. Bouaziz, & A. Algergawy. (2017). A deep learning-based approach for banana leaf diseases classification. Lecture Notes in Informatics, 79–88.
[19]L. G. Nachtigall, R. M. Araujo, & G. R. Nachtigall. (2017). Classification of apple tree disorders using convolutional neural networks. Proceedings of the 2016 IEEE 28th International Conference on Tools with Artificial Intelligence, 472–476. DOI: 10.1109/ICTAI.2016.75
[20]J. G. Ha et al. (2017). Deep convolutional neural network for classifying Fusarium wilt of radish from unmanned aerial vehicles. Journal of Applied Remote Sensing, 11(04). DOI: 10.1117/1.jrs.11.042621
[21]D. Oppenheim, & G. Shani. (2017). Potato disease classification using convolution neural networks. Advances in Animal Biosciences, 8(2), 244–249. DOI: 10.1017/S2040470017001376
[22]M. Brahimi, K. Boukhalfa, & A. Moussaoui. (2017). Deep learning for tomato diseases: Classification and symptoms visualization. Applied Artificial Intelligence, 31(4), 299–315. DOI: 10.1080/08839514.2017.1315516
[23]K. P. Ferentinos. (2018). Deep learning models for plant disease detection and diagnosis. Computers and Electronics in Agriculture, 145, 311–318. DOI: 10.1016/j.compag.2018.01.009
[24]A. Ramcharan, K. Baranowski, P. McCloskey, B. Ahmed, J. Legg, & D. P. Hughes. (2017). Deep learning for image-based cassava disease detection. Frontiers in Plant Science, 8, 1–7. DOI: 10.3389/fpls.2017.01852
[25]K. Zhang, Q. Wu, A. Liu, & X. Meng. (2018). Can deep learning identify tomato leaf disease? Advances in Multimedia, 2018. DOI: 10.1155/2018/6710865
[26]M. Sibiya, & M. Sumbwanyambe. (2019). A computational procedure for the recognition and classification of maize leaf diseases out of healthy leaves using convolutional neural networks. AgriEngineering, 1(1), 119–131. DOI: 10.3390/agriengineering1010000
[27]I. Z. Mukti, & D. Biswas. (2019). Transfer learning based plant diseases detection using ResNet50. Proceedings of the 2019 4th International Conference on Electrical Information and Communication Technology, 1–6. DOI: 10.1109/EICT48899.2019.9068805
[28]S. T., R. Khilar, & M. Subaja Christo. (2021). A comparative analysis on plant pathology classification using deep learning architecture – ResNet and VGG19. Materials Today: Proceedings. DOI: 10.1016/j.matpr.2020.11.993
[29]L. Mkonyi et al. (2020). Early identification of Tuta absoluta in tomato plants using deep learning. Scientific African, 10. DOI: 10.1016/j.sciaf.2020.e00590
[30]E. Elfatimi, R. Eryigit, & L. Elfatimi. (2022). Beans leaf diseases classification using MobileNet models. IEEE Access, 10. DOI: 10.1109/ACCESS.2022.3142817
[31]J. V. Y. Bordin Yamashita, & J. P. R. R. Leite. (2023). Coffee disease classification at the edge using deep learning. Smart Agricultural Technology, 4, 100183. DOI: 10.1016/j.atech.2023.100183
[32]U. Sanath Rao et al. (2021). Deep learning precision farming: Grapes and mango leaf disease detection by transfer learning. Global Transitions Proceedings, 2(2), 535–544. DOI: 10.1016/j.gltp.2021.08.002
[33]S. Anwarul, M. Mohan, & R. Agarwal. (2023). An unprecedented approach for deep learning assisted web application to diagnose plant disease. Procedia Computer Science, 218, 1444–1453. DOI: 10.1016/j.procs.2023.01.123
[34]G. Geetharamani, & A. P. J. (2019). Identification of plant leaf diseases using a nine-layer deep convolutional neural network. Computers and Electrical Engineering, 76, 323–338. DOI: 10.1016/j.compeleceng.2019.04.011
[35]U. P. Singh, S. S. Chouhan, S. Jain, & S. Jain. (2019). Multilayer convolution neural network for the classification of mango leaves infected by anthracnose disease. IEEE Access, 7, 43721–43729. DOI: 10.1109/ACCESS.2019.2907383
[36]J. Chen, Q. Liu, & L. Gao. (2019). Visual tea leaf disease recognition using a convolutional neural network model. Symmetry, 11(3). DOI: 10.3390/sym11030343
[37]B. Liu, Z. Ding, L. Tian, D. He, S. Li, & H. Wang. (2020). Grape leaf disease identification using improved deep convolutional neural networks. Frontiers in Plant Science, 11, 1–14. DOI: 10.3389/fpls.2020.01082
[38]J. A. Pandian et al. (2022). A five convolutional layer deep convolutional neural network for plant leaf disease detection. Electronics, 11(8). DOI: 10.3390/electronics11081266
[39]P. S. Thakur, P. Khanna, T. Sheorey, & A. Ojha. (2022). Explainable vision transformer enabled convolutional neural network for plant disease identification: PlantXViT. arXiv preprint. DOI: 10.48550/arXiv.2207.07919
[40]S. T. Y. Ramadan, T. Sakib, R. Jahangir, & S. Rahman. (2024). Maize leaf disease detection using vision transformers and CNN-based classifiers: Comparative analysis. Smart Innovation, Systems and Technologies, 376, 513–524. DOI: 10.1007/978-981-99-7711-6_41
[41]W. Abdullah, C. Kim, & Y. Nam. (2024). A fresh look at tomato leaf disease recognition using vision transformers. Optimization in Agriculture, 1, 105–114. DOI: 10.61356/j.oia.2024.1274
[42]M. H. Alnamoly, A. A. Hady, S. M. Abd El-Kader, & I. El-Henawy. (2024). FL-ToLeD: An improved lightweight attention convolutional neural network model for tomato leaf diseases classification for low-end devices. IEEE Access, 12, 73561–73580. DOI: 10.1109/ACCESS.2024.3401733
[43]M. Zhang et al. (2025). Dual-attention-enhanced MobileViT network: A lightweight model for rice disease identification in field-captured images. Agriculture, 15(6), 1–22. DOI: 10.3390/agriculture15060571
[44]M. R. Tonmoy, M. M. Hossain, N. Dey, & M. F. Mridha. (2025). MobilePlantViT: A mobile-friendly hybrid ViT for generalized plant disease image classification. arXiv preprint, 1–8. Available: http://arxiv.org/abs/2503.16628
[45]S. K. Upadhyay, & A. Kumar. (2022). A novel approach for rice plant diseases classification with deep convolutional neural network. International Journal of Information Technology, 14(1), 185–199. DOI: 10.1007/s41870-021-00817-5
[46]X. Li, & S. Li. (2022). Transformer help CNN see better: A lightweight hybrid apple disease identification model based on transformers. Agriculture, 12(6). DOI: 10.3390/agriculture12060884
[47]S. Nishankar, V. Pavindran, T. Mithuran, S. Nimishan, S. Thuseethan, & Y. Sebastian. (2025). ViT-RoT: Vision transformer-based robust framework for tomato leaf disease recognition. AgriEngineering, 7(6), 185. DOI: 10.3390/agriengineering7060185
[48]M. A. Hasan et al. (2025). Mulberry leaf disease detection by CNN-ViT with XAI integration. PLOS ONE, 20(6), 1–29. DOI: 10.1371/journal.pone.0325188
[49]G. Shandilya, S. Gupta, H. G. Mohamed, S. Bharany, A. U. Rehman, & S. Hussen. (2025). Enhanced maize leaf disease detection and classification using an integrated CNN-ViT model. Food Science & Nutrition, 13(7). DOI: 10.1002/fsn3.70513
[50]A. Hassani, S. Walton, J. Li, S. Li, & H. Shi. (2023). Neighborhood attention transformer. Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, 6185–6194. DOI: 10.1109/CVPR52729.2023.00599
[51]A. Hassani. (2023). Neighborhood attention: Dynamic restriction of self-attention. University of Oregon Area Exam Report. Available: https://www.cs.uoregon.edu/Reports/AREA-202307-Hassani.pdf
[52]A. Hassani, W. Hwu, & H. Shi. (2024). Faster neighborhood attention: Reducing the O(n²) cost of self-attention at the threadblock level. arXiv preprint. DOI: 10.48550/arXiv.2403.04690
[53]A. Ouamane et al. (2025). Optimized vision transformers for superior plant disease detection. IEEE Access, 13, 48552–48570. DOI: 10.1109/ACCESS.2025.3547416
[54]S. Duhan, P. Gulia, N. S. Gill, & E. Narwal. (2025). RTR_Lite_MobileNetV2: A lightweight and efficient model for plant disease detection and classification. Current Plant Biology, 42, 100459. DOI: 10.1016/j.cpb.2025.100459
[55]O. Jouini, M. O. E. Aoueileyine, K. Sethom, & A. Yazidi. (2024). Wheat leaf disease detection: A lightweight approach with shallow CNN based feature refinement. AgriEngineering, 6(3), 2001–2022. DOI: 10.3390/agriengineering6030117
[56]A. Dosset et al. (2025). Cassava disease detection using a lightweight modified soft attention network. Pest Management Science, 81(2), 607–617. DOI: 10.1002/ps.8456
[57]A. Chakrabarty, S. T. Ahmed, M. F. U. Islam, S. M. Aziz, & S. S. Maidin. (2024). An interpretable fusion model integrating lightweight CNN and transformer architectures for rice leaf disease identification. Ecological Informatics, 82, 102718. DOI: 10.1016/j.ecoinf.2024.102718
[58]E. Zhang, N. Zhang, F. Li, & C. Lv. (2024). A lightweight dual-attention network for tomato leaf disease identification. Frontiers in Plant Science, 15, 1–18. DOI: 10.3389/fpls.2024.1420584