Abstract:
Fungi offer vital solutions to humanity through
roles in medicine, agriculture, and ecological balance while
presenting potential threats. They have yielded antibiotics, food
fermentation, and nutrient recycling however, fungal infections,
crop diseases, and spoilage highlight their dark side. Therefore,
it is important to identify fungi to harness their potential
benefits and mitigate threats. Offering quick and accurate
identification through image classification improves the
aforementioned features. Therefore, this study classified images
of five types of fungi using convolutional neural networks
(CNN). Initially, dataset distribution was observed, and it was
identified that there was a class imbalance in the dataset. To
address this issue, data augmentation technique was used.
Several preprocessing techniques were also applied to
understand the model training behavior with their application.
Then the images were rescaled into six different resolution
combinations such as original images, low-resolution images,
high-resolution images, a mix of original and low-resolution
images, a mix of original and high-resolution images, and a mix
of low and high-resolution images. Then these data were trained
using 13 pre-trained CNN models such as Xception, VGG16,
VGG19, InceptionResNetV2, ResNet152, EfficientNetB6,
EfficientNetB7, ConvNeXtTiny, ConvNeXtSmall,
ConvNeXtBase, ConvNeXtLarge, ConvNeXtXLarge,
BigTransfer (BiT). To evaluate these models, accuracy, macro
average precision, macro average recall, macro average f1-
score, and loss learning curve assessment were used. According
to the results, the BiT model preprocessed with normalization,
which used a mix of original and high-resolution images,
performed the best, producing a model accuracy of 87.32% with
optimal precision, recall, and f1-score. The loss learning curve
of the BiT model also depicted a low overfitting aspect proving
the model’s optimal behavior. Therefore, it was concluded that
the BiT model with the mix of original and high-resolution data
can be used to detect fungi efficiently.