journal article·2026-06-18Open access

Attention-Enhanced Hybrid CNN–ViT Framework for Genus-Level Classification of Selected Macrofungi from Basidiospore Micrographs

Şuheda Aldemir Terman, Mustafa Emre Akçay, Ebubekir Seyyarer, Faruk Ayata, İsmail Acar

Applied Sciences· Volume 16· Issue 12

Abstract

The development of rapid and reproducible image analysis approaches that support genus-level pre-classification of macrofungi is important for taxonomic pre-evaluation and controlled microscopic data analysis. In this study, an advanced deep learning-based approach, namely the Attention-Enhanced Hybrid CNN–ViT Framework, was rigorously evaluated for genus-level classification, using basidiospore micrographs of five carefully selected macrofungal genera. The proposed approach integrates the ability of convolutional neural networks to identify local texture and contour patterns with the global context-modelling capability of Vision Transformer structures. The objective is to enhance the extraction of distinctive representations from microscopic spore images through feature fusion and attention mechanisms. A series of experiments was conducted on a curated dataset consisting of light microscopy images of the genera Agaricus, Hebeloma, Inocybe, Amanita, and Russula. The models were compared using a range of evaluation metrics, including accuracy, F1-score, MCC, ROC-AUC, and PR-AUC. The results showed that the InceptionV3 + ViT-B16 + Fusion configuration was the most successful hybrid model, achieving an accuracy of 0.9213 ± 0.0182, an F1-score of 0.9212 ± 0.0179, a Matthews correlation coefficient (MCC) of 0.9040 ± 0.0222, a receiver operating characteristic (ROC)-area under the curve (AUC) of 0.9896 ± 0.0069, and a precision-recall (PR)-AUC of 0.9684 ± 0.0192, respectively. The present findings demonstrate that basidiospore images can carry distinctive visual information for genus-level automated classification under controlled conditions. However, it is important to note that these results should not be interpreted as claims of species-level identification or field generalisability. This is due to the use of a single microscope-camera system, a single preparation protocol, and the absence of an independent external test set. The present study demonstrates that deep learning-based microscopic image analysis can be evaluated as a preliminary classification tool in macrofungal taxonomy. It also shows that such tools can provide a foundation for future work supported by specimen-level validation, external test sets, and different imaging protocols.
Source: crossref · Quality: baseline

Research context

OpenAlex topics: Cell Image Analysis Techniques · Mycorrhizal Fungi and Plant Interactions · Fungal Biology and Applications

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

Affiliations

Department of Molecular Biology and Genetics, Faculty of Science, Van Yüzüncü Yıl University, 65080 Tuşba, Van, Türkiye

Department of Biology, Faculty of Science, Van Yüzüncü Yıl University, 65080 Tuşba, Van, Türkiye

Department of Computer Engineering, Faculty of Engineering, Van Yüzüncü Yıl University, 65080 Tuşba, Van, Türkiye

Department of Computer Programming, Başkale Vocational School, Van Yüzüncü Yıl University, 65080 Tuşba, Van, Türkiye

Department of Organic Agriculture, Başkale Vocational School, Van Yüzüncü Yıl University, 65080 Tuşba, Van, Türkiye

References (41)

Show source-provided references
1. Lodge, D.J., Ammirati, J.F., O’Dell, T.E., and Mueller, G.M. (2004). Collecting and Describing Macrofungi. Biodiversity of Fungi: Inventory and Monitoring Methods, Elsevier Academic Press.
2. Singer, R. (1986). The Agaricales in Modern Taxonomy, Koeltz Scientific Books. [4th ed.].
3. Determination of the Elemental Impurity Levels in Different Mushroom Species and Probabilistic Risk Assessment10.1002/tox.24556 ↗
4. Largent, D.L., Johnson, D., and Watling, R. (1977). How to Identify Mushrooms to Genus III: Microscopic Features, Mad River Press.
5. Clémençon, H. (2009). Methods for Working with Macrofungi: Laboratory Cultivation and Preparation of Larger Fungi for Light Microscopy, IHW.
6. Fungal identification using molecular tools: A primer for the natural products research community10.1021/acs.jnatprod.6b01085 ↗
7. Edible macrofungi determined in Gürpınar (Van) district10.30616/ajb.498433 ↗
8. A revision of the genus Inocybe in Europe I. Subgenus Inosperma and the smooth-spored species of subgenus Inocybe
9. The taxonomy of the European species of Hebeloma section Denudata subsections Hiemalia, Echinospora subsect. nov. and Clepsydroida subsect. nov. and five new species10.1016/j.funbio.2015.09.014 ↗
10. Nuclear ribosomal internal transcribed spacer (ITS) region as a universal DNA barcode marker for Fungi10.1073/pnas.1117018109 ↗
11. Chemotaxonomical identification of spores of macrofungi: Possibilities of Raman spectroscopy10.1007/s00216-007-1150-1 ↗
12. Quantitative evaluation of composition and biomolecular mapping of macrofungi spores by Raman spectroscopy10.1016/j.saa.2025.125813 ↗
13. FunVIP: Fungal Validation and Identification Pipeline based on phylogenetic analysis10.71150/jm.2411017 ↗
14. Zieliński, B., Sroka-Oleksiak, A., Rymarczyk, D., Piekarczyk, A., and Brzychczy-Wloch, M. (2020). Deep learning approach to describe and classify fungi microscopic images. PLoS ONE, 15.10.1371/journal.pone.0234806 ↗
15. Species determination using AI machine-learning algorithms: Hebeloma as a case study10.1186/s43008-022-00099-x ↗
16. Picek, L., Sulc, M., Matas, J., Heilmann-Clausen, J., Jeppesen, T.S., Laessoe, T., and Froslev, T.G. (March, January 26). Danish Fungi 2020—Not Just Another Image Recognition Dataset. Proceedings of the IEEE/CVF Winter Conference on Applications of Computer Vision, Tucson, AZ, USA.
17. Developing a microscope image dataset for fungal spore classification in grapevine using deep learning
18. Zhou, H., Lai, Q., Huang, Q., Cai, D., Huang, D., and Wu, B. (2024). Automatic detection of rice blast fungus spores by deep learning-based object detection: Models, benchmarks and quantitative analysis. Agriculture, 14.10.3390/agriculture14020290 ↗
19. Ozsari, S., Kumru, E., Ekinci, F., Akata, I., Guzel, M.S., Acici, K., Ozcan, E., and Asuroglu, T. (2024). Deep Learning-Based Classification of Macrofungi: Comparative Analysis of Advanced Models for Accurate Fungi Identification. Sensors, 24.10.3390/s24227189 ↗
20. A case study on the application of spore sampling for the monitoring of macrofungi10.1111/1755-0998.13941 ↗
21. Ekinci, F., Ugurlu, G., Ozcan, G.S., Acici, K., Asuroglu, T., Kumru, E., Guzel, M.S., and Akata, I. (2025). Classification of Mycena and Marasmius Species Using Deep Learning Models: An Ecological and Taxonomic Approach. Sensors, 25.10.3390/s25061642 ↗
22. Deep learning application to hyphae and spores identification in fungal fluorescence images10.1038/s41598-025-11228-y ↗
23. Explainable convolutional neural network architectures for high-performance taxonomic classification of gasteroid macrofungi10.1038/s41598-025-23974-0 ↗
24. Hu, J., Shen, L., Albanie, S., Sun, G., and Wu, E. (2018, January 18–22). Squeeze-and-Excitation Networks. Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Salt Lake City, UT, USA.10.1109/CVPR.2018.00745 ↗
25. He, K., Zhang, X., Ren, S., and Sun, J. (2016, January 11–15). Deep residual learning for image recognition. Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Denver, CO, USA.10.1109/CVPR.2016.90 ↗
26. Yan, H., Mubonanyikuzo, V., Komolafe, T.E., Zhou, L., Wu, T., and Wang, N. (2025). Hybrid-RViT: Hybridizing ResNet-50 and vision transformer for enhanced Alzheimer’s disease detection. PLoS ONE, 20.10.1371/journal.pone.0318998 ↗
27. Exploring the effectiveness of deep learning architectures for colorectal polyp detection: Performance analysis and insights10.1007/s42979-024-02825-1 ↗
28. 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 ↗
29. Chatterjee, U., Paul, H., and Palodhi, K. (2024). Comparative Study of Different CNN Architectures for B-ALL Diagnosis from Peripheral Blood Smear Images. 2024 6th International Conference on Computational Intelligence and Networks (CINE), IEEE.10.1109/CINE63708.2024.10880907 ↗
30. MRI-based classification of lumbar spinal stenosis using a hybrid quantum and deep learning model10.1140/epjp/s13360-025-07148-5 ↗
31. Szegedy, C., Vanhoucke, V., Ioffe, S., Shlens, J., and Wojna, Z. (July, January 26). Rethinking the inception architecture for computer vision. Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Las Vegas, NV, USA.
32. Howard, A.G., Zhu, M., Chen, B., Kalenichenko, D., Wang, W., Weyand, T., and Adam, H. (2017). Mobilenets: Efficient convolutional neural networks for mobile vision applications. arXiv.
33. Sandler, M., Howard, A., Zhu, M., Zhmoginov, A., and Chen, L.C. (2018, January 18–22). Mobilenetv2: Inverted residuals and linear bottlenecks. Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Salt Lake City, UT, USA.10.1109/CVPR.2018.00474 ↗
34. Lightweight Deep Learning Architectures for Ophthalmic Disease Detection: MobileNet Variants Applied to Glaucoma Classification
35. Simonyan, K., and Zisserman, A. (2014). Very deep convolutional networks for large-scale image recognition. arXiv.
36. Tan, M., and Le, Q. (2019). Efficientnet: Rethinking model scaling for convolutional neural networks. International Conference on Machine Learning 2019, PMLR.
37. Sharma, S.K.D. (2024). Oral squamous cell detection using deep learning. arXiv.
38. Deep Learning-Driven MRI analysis for accurate diagnosis and grading of lumbar spinal stenosis10.1016/j.measurement.2025.117294 ↗
39. Dosovitskiy, A., Beyer, L., Kolesnikov, A., Weissenborn, D., Zhai, X., Unterthiner, T., and Houlsby, N. (2020). An image is worth 16x16 words: Transformers for image recognition at scale. arXiv.
40. Fu, Z. (2022). Vision transformer: Vit and its derivatives. arXiv.
41. Huo, Y., Jin, K., Cai, J., Xiong, H., and Pang, J. (2023). Vision transformer (ViT)-based applications in image classification. 2023 IEEE 9th Intl Conference on Big Data Security on Cloud (BigDataSecurity), IEEE Intl Conference on High Performance and Smart Computing,(HPSC) and IEEE Intl Conference on Intelligent Data and Security (IDS), IEEE.10.1109/BigDataSecurity-HPSC-IDS58521.2023.00033 ↗