# Integrating Explanations into CNNs by Adopting Spiking Attention Block for Skin Cancer Detection
## 1 Introduction  
Skin cancer is a prevalent kind of cancer worldwide, with melanoma being responsible for the highest yearly mortality rate. Melanoma is an extremely dangerous kind of skin cancer that exhibits rapid growth and can metastasize to other organs. The World Health Organization (WHO) has forecasted that there will be around 7990 fatalities caused by melanoma in 2025, along with an estimated 97,610 new cases in the United States [1]. To prevent negative outcomes from occurring, it is necessary to promptly identify and treat the situation. Artificial intelligence (AI)-driven decision support systems have recently experienced a notable increase in interest across many domains owing to their remarkable capabilities. However, the use of AI in sensitive domains, especially those that impact human decision-making, such as healthcare, has raised ethical concerns about the lack of transparency in AI-driven decisions [2]. In skin image classification, the decision-making process of deep learning models lacks interpretability, thus making the interaction between the AI system and practitioner difficult. Therefore, it is imperative to expand current classification architectures with explainability features to enable more profound relations and offer supplementary diagnostic tools [3]. In conventional Computer-Aided Diagnostic (CAD)systems for skin cancer prediction, the training data are fed into a learning model, typically consisting of a convolutional neural network (CNN) model with multiple layers. This model predicts if the input image is malignant or non-cancerous [4; 5; 6]. A limitation of these CAD systems is their black box nature, which means that the end-user is unaware of the inner workings of the trained model. The end-user receives the outcome with satisfactory accuracy but lacks knowledge of the underlying mechanisms of the CAD system, which determines why the image is classified as malignant rather than non-cancerous. What factors contribute to the accuracy of the trained model in predicting the class of an image? What prevents it from making incorrect predictions? These questions have significantly diminished the end-user's faith in the CAD system. Unlike conventional CAD systems, XAI-based CAD solutions for skin cancer prediction address these inquiries. XAI-based CAD systems not only yield outcomes but also provide justifications for their decision-making process. Figure 1 illustrates a juxtaposition between a conventional CAD system and the XAI-based CAD system for the purpose of predicting skin cancer. A range of XAI methods have been proposed to rectify the deficiencies of CNN models. These methods aim to enhance the transparency of reasoning of AI systems. There are two main branches of XAI techniques: first, post-hoc algorithms, which are specifically developed to provide retrospective explanations for decisions made by a given CNN, such as Grad-CAM [7], Layer-wise Relevance Propagation (LRP) [8], and other similar methods [9]. These techniques are generally used for groups of deep neural networks that have similar components, such as convolutional layers, and are, therefore, mainly independent of the specific model. Depending on the context, post-hoc XAI can be utilized with varying degrees of model parameter access. Some methods are as simple as needing to know the input and output of the model. Inherently interpretable algorithms make up the second group of XAI approaches [10]. These algorithms are specifically designed to be easily comprehensible, which allows them to address issues about the accuracy of explanations that arise in post-hoc XAI [11]. However, there are additional constraints on both the training process and the model construction due to the interconnected nature of these XAI methods. Aside from the integration of explanatory algorithms into a CNN, XAI approaches differ in providing explanations either at a global level, applicable to the entire  
Figure 1: Comparison of traditional CAD systems and XAI-based CAD systems.