Classifying fungi biodiversity using hybrid transformer models.
Journal:
Journal of microbiological methods
Published Date:
Jun 1, 2025
Abstract
Fungi are essential members of ecosystems, playing key roles in nutrient cycling, agriculture, and medicine. Their classification into proper species helps us to understand their biodiversity, allowing us to leverage their ecological and practical benefits. A new hybrid deep learning-based technique has been proposed, merging the Vision Transformer and Swin Transformer models with transfer learning frameworks like MobileNetV2, DenseNet121, and EfficientNetB0 for Fungi multiclass classification. This study utilized a publicly available dataset containing 9115 images of five fungal species from UC Irvine Machine Learning Repository. To address significant class imbalance, several data augmentation techniques were employed. The results showed that the Swin Transformer combined with DenseNet121 achieved the highest classification accuracy of 96.96 % for training, 95.97 % for validation, and 95.57 % for testing, while other models like ViT-DenseNet121 and Swin-MobileNetV2 also delivered competitive results. Using confusion matrices and benchmark classification metrics, and paired statistical testing, the analysis highlights the models' ability to generalize effectively and minimize misclassifications. To further ensure the robustness of the findings, a five-fold cross-validation was performed across all hybrid models. Additionally, explainable AI techniques, specifically Grad-CAM visualizations, were employed to interpret the model's focus areas, confirming attention to biologically significant structures. This research demonstrates a balance between modeling local features and capturing global context. Indeed, these hybrid models prove to be scalable and efficient for complex biological datasets. This interdisciplinary study bridges ecology and advanced technology by applying deep learning to enhance fungal classification. This study aims to improve the management and understanding of fungal biodiversity for the promotion of conservational and sustainable practices for the betterment of our ecosystem. The findings have significant applications, including sustainable agriculture through early detection of fungal plant pathogens, improved medical diagnostics for fungal infections, and biodiversity conservation through precise species monitoring.
Authors
Keywords
No keywords available for this article.