MaizeFormerX: a lightweight vision transformer with cross-scale attention for explainable maize leaf disease diagnosis
Md Mostafizur Rahman, Md Najmul Gony, Md Shafiq Ullah, Sd Maria Khatun Shuvra, Rezaul Haque, Md. Redwan Ahmed, S. M. Masfequier, Rahman Swapno,
American International Group (United States) · Grand Canyon University
Key points
From the paper's conclusion- Ablation studies highlighted the significance of the cross-scale attention module for high MCC during domain shifts.
Abstract
Early detection of maize leaf diseases is essential to prevent yield losses. Existing vision-based models face challenges in real-world environments due to data imbalance, lighting variations, and interpretability. This study presents MaizeFormerX, a lightweight Vision Transformer designed for cross-domain, explainable maize disease detection on resource-limited settings. MaizeFormerX employs multi-scale patch embeddings and a Cross-Scale Attention Fusion (CSAF) module to capture both detailed lesion textures and larger disease patterns. The CSAF output is processed through a transformer encoder stack using multi-head self-attention to model long-range dependencies. Robust preprocessing and dataset-specific augmentations were applied to improve feature extraction and address class imbalances in the Dataverse, Tanzania, and Plagues Maiz datasets. For interpretability, Grad-CAM was used for pixel-level saliency mapping in an efficient web application. When benchmarked against MobileViT, EfficientFormer, TinyViT, and Swin Transformer, MaizeFormerX achieved 97.8% accuracy on Dataverse, 97.5% on Tanzania, and 96.9% on Plagues Maiz, outperforming Swin Transformer V2 by 2–3%. Cross-domain testing yielded 88.9% accuracy when trained on Dataverse and tested on Tanzania, surpassing baseline performance by 3–6%. Class-wise analysis revealed F1 scores over 98% for Healthy and MLB classes with 6× augmentation, and over 97% for MSV. Ablation studies highlighted the significance of the cross-scale attention module for high MCC during domain shifts. This study introduces a precise, explainable, and efficient image-based method for classifying maize diseases, which could aid in more targeted crop management, reduce unnecessary agrochemical use, and promote sustainable maize production in future decision-support environments.
Read the paper
Discussion
Science Skim's AI key points, plus readers' public thoughts
Readers' thoughts
No reader thoughts yet.
Related papers
- A novel lightweight hybrid CNN–ViT for maize leaf disease classificationScientific Reports · 2026
- LMAPNet: a lightweight multi-scale attention network for real-time maize disease and pest detection on edge devicesFrontiers in Plant Science · 2026
- Precise Identification of Tomato Leaf Diseases: A VMamba-FCS Classification Model Based on Multi-Mechanism Synergistic EnhancementAgriculture · 2026
- Lightweight frequency-aware hybrid vision transformer for fine-grained plant disease recognition.Frontiers in plant science · 2026
- Cross-crop generalization in multi-species leaf disease recognition.Frontiers in plant science · 2026
- MultiBranchFusionNet: A Lightweight Attention-Guided Dual-Branch Framework for Tomato Leaf Disease Classification Using Heterogeneous Field and Public ImagesAI Systems Engineering · 2026