Comparative analysis of the effect of color space transformations on transformer-based skin cancer classification
Abstract
Skin cancer is the most common type of cancer, a life-threatening condition that leads to serious health problems if not detected early, and its incidence is increasing worldwide. In recent years, computer vision and decision support systems have been used for disease detection in dermoscopic images. Furthermore, it has been observed that data representation methods affect the detection performance of these models, and the effect of color information on transformer-based models has not been sufficiently investigated. This study used the International Skin Imaging Collaboration (ISIC) 2017 dataset consisting of RGB images, and these images were converted into the HSV, LAB, and YCbCr color spaces. Transformer-based models, including visual transformer (ViT), swin transformer, data efficient image transformer (DeiT), and label-free self-distillation (DINO), were used for benign and malignant classification. According to the classification performance results, RGB and HSV color spaces particularly in the DeiT and Swin models, stable and high accuracy values were obtained. It was observed that the ViT and DINO models were more sensitive to color space transformations and achieved lower classification performance compared to other models. The highest performance in skin cancer classification was achieved with the DeiT model trained in the RGB color space, with the highest accuracy (0.7668). Furthermore, the explainability-based gradient-weighted class activation mapping (Grad-CAM) method was used to analyze where the models focused in image regions when making classification decisions. This study shows the effect and usability of color space transformations in transformer-based models for skin cancer classification and offers a comparative contribution to the literature.
Keywords
References
- [1] G. M. S. Himel, M. M. Islam, K. A. Al-Aff, S. I. Karim, and M. K. U. Sikder, “Skin cancer segmentation and classification using vision transformer for automatic analysis in dermatoscopy-based noninvasive digital system,” Int. J. Biomed. Imaging, vol. 2024, pp. 3022192, 2024.
- [2] N. C. F. Codella et al., “Skin lesion analysis toward melanoma detection: A challenge at the 2017 International symposium on biomedical imaging (ISBI), hosted by the international skin imaging collaboration (ISIC),” in 2018 IEEE 15th International Symposium on Biomedical Imaging (ISBI 2018), 2018.
- [3] G. H. Dagnaw, M. El Mouhtadi, and M. Mustapha, “Skin cancer classification using vision transformers and explainable artificial intelligence,” J. Med. Artif. Intell., vol. 7, 2024.
- [4] M. Arshad et al., “A computer-aided diagnosis system using deep learning for multiclass skin lesion classification,” Comput. Intell. Neurosci., vol. 2021, no. 1, 2021.
- [5] S. Khan, H. Ali, and Z. Shah, “Identifying the role of vision transformer for skin cancer-A scoping review,” Front. Artif. Intell., vol. 6, 2023.
- [6] M. A. Khan, T. Akram, Y.-D. Zhang, and M. Sharif, “Attributes based skin lesion detection and recognition: A mask RCNN and transfer learning-based deep learning framework,” Pattern Recognit. Lett., vol. 143, pp. 58–66, 2021.
- [7] A. Murugan, S. A. H. Nair, and K. P. S. Kumar, “Detection of skin cancer using SVM, Random Forest and kNN classifiers,” J. Med. Syst., vol. 43, no. 8, 2019.
- [8] R. Kaur, H. G. Hosseini, and R. Sinha, “Lesion border detection of skin cancer images using deep fully convolutional neural network with customized weights,” Annu. Int. Conf. IEEE Eng. Med. Biol. Soc., vol. 2021, pp. 3035–3038, 2021.
Details
Primary Language
English
Subjects
Deep Learning, Electrical Engineering (Other)
Journal Section
Research Article
Authors
Feyza Yılmaz
*
0000-0002-6989-2823
Türkiye
Publication Date
March 30, 2026
Submission Date
February 9, 2026
Acceptance Date
March 10, 2026
Published in Issue
Year 2026 Number: 064