Transformer-based skin lesion segmentation using optimized SwinUNet and KL divergence loss on HAM10000 dataset
摘要
Accurate identification of skin lesions is vital for finding skin cancer early, but there are problems like having too many images of one type of lesion and complicated edges around the lesions, which make it hard to get good results. This study presents an enhanced version of the SwinUNet model, accompanied by a loss function based on the Kullback–Leibler (KL) Divergence, to more effectively distinguish skin lesions using the HAM10000 dataset. The new method achieves a Dice score of 91.52 and an Intersection over Union of 92.10, indicating it performs better than other methods and models. Compared with models like SegNet and TransUNet and other loss functions such as Binary Cross-Entropy and Hinge Loss, the SwinUNet with KL Divergence achieves the best overall accuracy of 98.90%. Using SwinUNet’s ability to focus on important parts of the image and the KL Divergence’s help in dealing with the imbalance of different lesion types, this method can reliably identify lesions even in difficult real-world cases. These results show that this approach could be very helpful to dermatologists in making accurate, early diagnoses of skin cancer.