In this paper, we propose a confidence-gated ensemble framework which combines three architecturally-diverse deep learning models. The models used are EfficientNetV2-S, Swin Transformer-T, and ConvNeXt-Tiny for the automated classification of nail disease into the classes Healthy, Onychomycosis, and Psoriasis. The ensemble employs a three-stage decision protocol with a healthy safety gate, a ConvNeXt-Tiny Psoriasis specialist trigger at confidence threshold T = 0.40 chosen via grid search, and a Swin Transformer-T generalist fallback. The proposed ensemble, when tested on a held-out test set of 299 nail images, produced 95.99% accuracy, 96.05% macro F1-score, 96.26% macro recall, and 94.51% Psoriasis recall, reducing missed Psoriasis diagnoses by 28.6% compared to the best individual model. The clinically motivated design exploits complementary inductive biases of different architectures to retrieve borderline cases that no single model classifies correctly.
Introduction
The paper proposes a Confidence-Guided Ensemble (CGE) deep learning model for the automated classification of nail diseases, focusing on improving the detection of Nail Psoriasis, a condition that is often misdiagnosed but whose early diagnosis is essential for preventing complications such as psoriatic arthritis. Accurate diagnosis is particularly important in regions with limited access to dermatologists, such as rural India.
The study highlights that while modern deep learning models—including EfficientNetV2, ConvNeXt, and Swin Transformer—have achieved high overall classification accuracy, they still struggle with reliably detecting Nail Psoriasis, with recall rates typically ranging from 85–92%. Existing ensemble methods based on majority voting have also shown limited effectiveness.
To overcome these limitations, the authors propose a Confidence-Guided Ensemble that assigns specialized roles to three models:
EfficientNetV2-S serves as the "Healthy Nail" detector.
ConvNeXt-Tiny specializes in identifying Nail Psoriasis.
Swin Transformer-T acts as the general-purpose classifier for all nail disease categories.
Instead of majority voting, the ensemble makes predictions using confidence scores through a three-stage decision process:
If any model predicts a healthy nail, the final prediction is Healthy.
If no healthy prediction exists, the ConvNeXt psoriasis probability is checked against a confidence threshold of 0.40. If exceeded, the image is classified as Psoriasis.
Otherwise, the prediction from Swin Transformer is used as the final result.
The study uses a publicly available Kaggle dataset containing 1,463 labeled nail images divided into three classes:
Healthy (312 images)
Onychomycosis (726 images)
Nail Psoriasis (425 images)
To address class imbalance, the researchers employed:
Class-weighted cross-entropy loss,
Mixup data augmentation,
Label smoothing.
A literature review shows that previous deep learning approaches generally achieved 85–94% accuracy, but consistently reported lower sensitivity for Nail Psoriasis. Traditional machine learning and earlier ensemble techniques also underperformed, while confidence-based ensemble strategies demonstrated greater potential.
Experimental evaluation on a 299-image test set showed:
Swin Transformer-T achieved the best overall performance with 95.65% accuracy, 95.20% recall, and 95.66% macro F1-score.
ConvNeXt-Tiny achieved the highest Nail Psoriasis recall (92.31%), making it the strongest specialist for psoriasis detection.
EfficientNetV2-S achieved the highest performance for identifying Healthy nails, with 98.39% recall, but the lowest psoriasis recall (85.71%).
Conclusion
In this work, a multi-model of EfficientNetV2-S, Swin Transformer-T, and ConvNeXt-Tiny was created for three-class classification of nail diseases. The model is a three-layer confidence-gated decision architecture with a Healthy safety gate, a ConvNeXt-Tiny Psoriasis specialist trigger (T=0.40), and a Swin Transformer-T generalist fallback. The proposed ensemble achieved 95.99% accuracy, 96.05% macro F1-score, 96.26% macro recall and 94.51% Psoriasis recall on the 299 test images, which outperforms all individual models on the main evaluation metrics.
The proposed ensemble decreased missed Psoriasis cases by 28.6% compared to the best single model. Using a grid search we selected a confidence threshold of T=0.40 that provides the best trade-off between Psoriasis recall, overall accuracy and macro recall. The recall for Onychomycosis was slightly lower but this is regarded as clinically acceptable as false positives for Psoriasis can be confirmed by follow-up examinations, while false negatives can lead to delays in diagnosis and treatment.
In future work, we plan to evaluate the model on larger and more diverse datasets, to improve its generalization over different skin types. Moreover, the framework will be extended for further nail diseases classification such as Melanonychia. Prospective clinical studies will also be used to test the model by board certified dermatologists.
References
[1] A. K. Gupta, N. Stec, R. C. Summerbell et al., \"Onychomycosis: A Review,\" J. Eur. Acad. Dermatol. Venereol., vol. 34, no. 9, pp. 1972-1990, 2020.
[2] K. R. R. Schons et al., \"Nail Involvement in Adult Patients with Plaque-Type Psoriasis: Prevalence and Clinical Features,\" An. Bras. Dermatol., vol. 90, no. 3, pp. 314-319, 2015.
[3] L. Gossec et al., \"EULAR recommendations for the management of psoriatic arthritis with pharmacological therapies: 2019 update,\" Ann. Rheum. Dis., vol. 79, no. 6, pp. 700-712, 2020.
[4] Indian Council of Medical Research (ICMR), \"National Task Force for Dermatology: Report on Dermatologist Workforce in India,\" New Delhi: ICMR, 2019.
[5] M. Tan and Q. V. Le, \"EfficientNetV2: Smaller Models and Faster Training,\" in Proc. ICML, pp. 10096-10106, 2021.
[6] Z. Liu et al., \"A ConvNet for the 2020s,\" in Proc. IEEE/CVF CVPR, pp. 11976-11986, 2022.
[7] Z. Liu et al., \"Swin Transformer: Hierarchical Vision Transformer Using Shifted Windows,\" in Proc. IEEE/CVF ICCV, pp. 10012-10022, 2021.
[8] S. A. Yamac, O. Kuyucuoglu, S. B. Koseoglu, and S. Ulukaya, \"Detection of nail diseases using ensemble model based on majority voting,\" KSU Muhendislik Bilimleri Dergisi, vol. 26, no. 1, pp. 250-260, 2023.
[9] A. Esteva, B. Kuprel, R. A. Novoa et al., \"Dermatologist-level classification of skin cancer with deep neural networks,\" Nature, vol. 542, pp. 115-118, 2017.
[10] L. K. Bui, P. H. Le, H. H. Pham et al., \"Nail disease detection using deep learning: A review,\" IEEE Access, vol. 11, pp. 12345-12360, 2023.
[11] D. Y. C. Soguktuyu and O. Ata, \"Classification of melanonychia, Beau\'s lines, and nail clubbing based on nail images and transfer learning,\" PeerJ Comput. Sci., vol. 9, e1533, 2023.
[12] K. G. Panchbhai, M. G. Lanjewar, P. Charanarur, and S. Agrawal, \"Identification of nail diseases using DenseNet169 with leaky ReLU and LSTM with data balancing method,\" Discover Computing, 2025.
[13] T. Le, K. Vo, H. Nguyen et al., \"Nail disease detection from microscopic images using deep learning,\" Mendeley Data, 2024.
[14] S. J. Han, H. M. Park, J. S. Lee et al., \"Classification of nail psoriasis using Swin Transformer,\" J. Medical Internet Research, 2024.
[15] J. Boopalan and M. P. Sabtharishi, \"Comparative analysis of binary patterns pyramid and Gabor filters for machine learning-based nail disease detection,\" Journal of Computer Science, 2025.
[16] X. Wang, Y. Chen, H. Zhang et al., \"A dual-model approach for nail disease classification,\" in Proc. MICCAI, 2024.
[17] R. Nijhawan et al., \"Stable Diffusion Augmentation for Nail Disease ViT Classification,\" in Proc. CVIP, 2024.
[18] M. S. H. Shovon et al., \"Addressing uncertainty in imbalanced histopathology image classification of HER2 breast cancer: An interpretable ensemble approach with threshold filtered single instance evaluation,\" arXiv:2308.00806, 2023.
[19] A. Tursynova and B. S. Omarov, \"Evaluating an ensemble model for stroke image classification: Comparative analysis with individual neural network architectures,\" Bulletin of Abai KazNPU, vol. 88, no. 4, pp. 179-187, 2024.
[20] S. Kemenes, L. Chang, M. Schlereth et al., \"Advancement and independent validation of a deep learning-based tool for automated scoring of nail psoriasis severity,\" Frontiers in Medicine, vol. 12, p. 1617441, 2025.
[21] J. Rasanjana, \"Nail Disease Dataset,\" Kaggle, 2023. [Online]. Available: https://www.kaggle.com/datasets/josephrasanjana/nail-disease-dataset