1. Introduction
Schizophrenia is a debilitating mental illness characterized by disturbances in thinking, emotion, and behavior. The disease progression is variable, with typical onset occurring in early adulthood [
1]. Due to the unclear etiology and pathogenesis of the disease, there is a lack of objective laboratory diagnostic indicators and criteria. As a result, current clinical diagnostic techniques primarily rely on the patient’s psychiatric symptoms measured on a quantitative scale, and their medical history [
2,
3]. Consequently, diagnosis can be subject to physician bias, resulting in either false positives (misdiagnoses) or false negatives (missed diagnoses) [
4]. However, due to the subtle and diffuse nature of brain changes in individuals suffering from schizophrenia, neuroimaging techniques like fMRI (functional magnetic resonance imaging) are challenging to visually assess for diagnosis.
Recent advances in machine learning have enabled high-accuracy classification of psychiatric disorders, such as schizophrenia, from fMRI data. Approaches such as regions-of-interest (ROI) clustering [
5], adopting a two-step approach to process spatial and temporal information separately [
4,
6], and classifying using preprocessed features [
4,
7] have shown promise. Nonetheless, these techniques have significant drawbacks. They are prone to ignoring subtle variations across brain data and often fail to simultaneously capture relevant details in both spatial and temporal dimensions. This results in a loss of potentially valuable information crucial for an improved clinical understanding of a subject’s illness.
To address these challenges for our schizophrenia classification, we employ the Swin 4D fMRI Transformer (SwiFT)—an efficient, end-to-end deep neural network (DNN) for fMRI. Based on the Shifted-window Transformer architecture, SwiFT is a powerful model that enables learning brain dynamics directly from fMRI volumes [
8]. This is achieved through a 4D window multi-head self-attention mechanism and absolute positional embeddings [
9].
Despite their accuracy, fMRI classification models often lack output explainability. Those that do implement explainability methods typically do so via a model-agnostic approach, such as Integrated Gradients [
9]. These model-agnostic approaches do not leverage the specific characteristics of the architecture to which they are applied, as opposed to a model-dependent approach. Layer-wise relevance propagation (LRP) [
10,
11], a powerful explanation generation technique, offers a potential solution. LRP propagates predictions backward through the model, distributing relevance between layers according to local propagation rules. Recently, LRP rules have been created allowing application of the method to attention-based models; TransLRP [
12,
13,
14] was shown to outperform several benchmark algorithms according to a selection of model-agnostic explainable AI metrics [
15]. However, current implementations of LRP rely on rule sets based on convention, which may not be optimal for every model [
10].
In this study, we present an end-to-end system that processes high-dimensional Blood-Oxygen-Level-Dependent (BOLD) resting-state fMRI (rs-fMRI) for schizophrenia diagnosis and explanation. We explain SwiFT with TransLRP and introduce Swarm-LRP, a novel particle swarm optimization (PSO) method for refining LRP rules using Quantus explainable AI (XAI) toolkit metrics [
15]. TransLRP not only classifies rs-fMRI data but also provides interpretable visualizations of significant brain regions over time.
Our experimental results on a dataset of rs-fMRI scans from schizophrenia patients and controls demonstrate that our method yields accurate classifications. Moreover, our explainability method improves upon Integrated Gradients [
9], as well as multiple configurations of uniform LRP. Additionally, by optimizing on Quantus metrics such as faithfulness correlation, effective complexity, and average sensitivity, Swarm-LRP produces subject-level explanations that more faithfully represent the model’s decision-making process. These findings underscore the method’s potential for advancing neuroimaging diagnostics by delivering detailed and reliable insights into brain activity associated with schizophrenia, through enhanced interpretability.
This work does not propose a new classifier. Instead, it investigates architecture-aware explainability on an existing 4D fMRI transformer (SwiFT) using TransLRP and introduces Swarm-LRP for optimizing Layer-wise Relevance Propagation (LRP) rules. Accordingly, we focus on explanation quality, e.g., faithfulness, sensitivity, and complexity, rather than classification benchmarking. These dimensions operate independently of classification accuracy and instead quantify how faithfully and stably a model’s decisions can be interpreted.
2. Related Work
2.1. Deep-Learning Based Classification from fMRI
Recent years have seen significant progress in applying deep learning models to classify schizophrenia using both functional and structural MRI. Convolutional neural networks (CNNs) have been particularly effective in decoding spatial fMRI features [
16]. Building on this, combined CNN–LSTM (convolutional neural network–long short-term memory) architectures that capture both spatial and temporal features have achieved high accuracy in schizophrenia classification [
4,
6]. However, such approaches may miss subtle interactions that emerge only when spatial and temporal domains are analyzed jointly.
To address this, models such as the ST-CNN employ 3D-CNN layers with DenseNet blocks to simultaneously process spatial and temporal features [
17]. More recently, attention has shifted toward architectures designed to fully leverage the spatiotemporal information encoded in fMRI volumes. Inspired by the success of vision transformers (ViTs), several works have adapted transformers to higher-dimensional neuroimaging data, including fMRI [
5,
9]. Researchers have also explored different input representations, ranging from whole pre-processed fMRI images to learned functional connectivity graphs of key brain regions [
5], and extracted feature maps [
4,
18]. Collectively, these studies demonstrate that deep models can not only learn rich features from four-dimensional data but also deliver reliable diagnostic performance.
2.2. XAI in Healthcare
A wide range of XAI methods beyond LRP have been applied in healthcare to generate interpretable visualizations of model outputs. These approaches typically fall into categories such as gradient-based, attribution, saliency, backpropagation, or perturbation methods [
19,
20]. Early work in medical imaging frequently employed gradient-based techniques, including GradCAM for cancer detection [
21] and schizophrenia diagnosis [
22]. While these approaches produce plausible explanations, they often lack systematic evaluation of explanation correctness or benchmarking against standardized baselines.
Model-agnostic methods such as Integrated Gradients [
9,
23] have also been widely adopted. Derived metrics, including infidelity, have been proposed to assess explanation sensitivity and reliability across models [
24]. Additional domain-specific metrics have been validated on medical imaging datasets, such as those for Parkinson’s disease [
25] and breast cancer [
26]. A widely used tool for such evaluations is Quantus, a comprehensive library of interpretability metrics originally tested on datasets such as MNIST [
15]. In this work, we employ model-agnostic metrics from Quantus [
15] to benchmark our explanations against established XAI approaches.
Among existing techniques, LRP has often been shown to produce more faithful representations of learned features compared with attention rollout, GradCAM, LIME [
27], and partial LRP [
13]. Its family of rules offers a flexible framework adaptable to diverse model architectures. Variants such as uniform LRP—where a single rule is applied across all layers—and composite LRP have been applied in multiple domains [
10]. For example, Uniform-LRP-
has been used for colon polyp segmentation [
28], and Uniform-LRP-
has proven effective in diagnosing Alzheimer’s disease [
7]. More recently, TransLRP outperformed both LIME and attention-based visualization when explaining COVID-19 lung scan classification [
12].
2.3. LRP
LRP is a technique that leverages the graph structure of deep neural networks to compute explanations efficiently and reliably. It is grounded in the Deep Taylor Decomposition framework [
10], with a propagation procedure that follows a conservation principle: the relevance attributed to a neuron is proportionally redistributed to the preceding layer.
Prior work has outlined intuitions for distributing different LRP rules across the lower, middle, and upper layers of networks such as VGG16 [
10]. In the upper layers, where multiple neurons correspond to class labels and features often overlap, LRP-0 is appropriate because it closely follows the function and gradient, making it less sensitive to entangled representations. In middle layers, where many stacked operations and shared weights introduce variability, LRP-
helps filter noise and retain the most salient explanatory factors.
However, transferring these intuitions to more complex architectures is not straightforward. While the rules themselves are theoretically well-defined, few works provide comprehensive implementations of composite LRP that combine rules such as LRP-
and LRP-
. Moreover, parameter choices (e.g., values of
,
,
, and
) are often based on conventions or empirical testing rather than principled optimization. Only recently have efforts been made to algorithmically optimize these settings [
29].
3. Materials and Methods
3.1. Data and Preprocessing
3.1.1. Dataset
The Center for Biomedical Research Excellence (COBRE) dataset [
30] contains raw anatomical and functional MRI data from 72 patients with schizophrenia and 75 healthy controls, along with phenotypic information such as gender, age, handedness, and diagnosis. Diagnostic assessments were performed using the Structured Clinical Interview for DSM Disorders (SCID). Resting-state fMRI volumes were acquired with a matrix size of
and 32 slices, at a voxel resolution of
, over a 5-min period (150 frames). All 147 subjects were preprocessed using the Data Processing Assistant for Resting-State fMRI (DPARSF), a pipeline built on Statistical Parametric Mapping (SPM12) [
31,
32].
3.1.2. Preprocessing
Preprocessing followed standard rs-fMRI procedures. First, slice timing correction was applied to adjust for acquisition delays between slices, interpolating each slice to the reference (the first slice). Next, realignment was performed to correct for head motion by aligning all volumes in the time series to a reference volume. Covariate regression was then used to remove nuisance signals, improving data quality. Images were spatially normalized to the MNI152 template [
33], after which a bandpass filter of [0.01, 0.08] Hz was applied to suppress high-frequency noise. Symmetric normalization was conducted to ensure hemispheric consistency, and Gaussian spatial smoothing was used to increase the signal-to-noise ratio.
Following DPARSF processing, we applied an additional thresholding step to suppress low-amplitude noise: voxel intensities below 5 were set to 0, while values above 50 were capped at 50. This thresholding was determined by visually inspecting noise distributions with FSLeyes.
3.2. Model Architecture: SwiFT Transformer
The preprocessed data were reshaped from
to
before being passed into SwiFT for classification. Upsampling to this resolution did not affect peak classification performance. To improve generalization on the relatively small dataset, the full time sequence for each subject was segmented into seven overlapping chunks of 20 timesteps each, following the recommendations in the SwiFT paper [
9]. The whole preprocessing and classification flow is visualized in
Figure 1.
3.3. TransLRP
For explanation, we implemented a customized version of Transformer Layer-wise Relevance Propagation (TransLRP) adapted to SwiFT. This required mirroring the forward passes of individual blocks in the model and propagating relevance through both skip and non-skip connections, following Chefer et al. [
13]. Given SwiFT’s sequential Swin transformer blocks and the four-dimensional nature of fMRI input, attention relevance was propagated within the window attention module rather than via rollout, as used by Komorowski et al. [
12]. Specifically, we computed the Hadamard product of stored attention gradients with relevance scores to propagate them backward. Multiple LRP rules were integrated into this pipeline and combined in our composite Swarm-LRP framework.
The LRP rules implemented in this work are summarized below [
10]:
Redistributes relevance in proportion to each input’s contribution to the activation of neuron
k:
Stabilizes the denominator of LRP-0 by adding a small term
, which absorbs some relevance when contributions to neuron
k are weak or contradictory. In our implementation,
is sign-aware, scaled by the sign of the neuron’s output:
Increases the influence of positive contributions relative to negative ones. The parameter
determines the degree of positive weighting:
Balances positive and negative contributions using parameters
and
, constrained by
with
. When
and
, this reduces to LRP-0:
Here, j and k index neurons in successive layers, a denotes activations, and w the corresponding connection weights. Superscripts and indicate positive and negative components, respectively.
Evaluation Metrics
After generating TransLRP explanations, we evaluate them against alternative methods. Quantitative assessment of explanations is inherently challenging due to the absence of a definitive ground truth. Following prior work on explainability, we employ metrics that capture three key dimensions of XAI effectiveness: (i) faithfulness to the model, (ii) sensitivity to input perturbations, and (iii) relative complexity [
12].
Faithfulness correlation [
24] measures how well explanation attributions align with model behavior. It is computed as the average linear correlation between predicted logits of perturbed test points (for a subset of features) and their corresponding attribution values across multiple runs and samples. The metric returns a value between −1 and 1. We use the absolute value, maximizing it during PSO, to capture the overall strength of the attribution–prediction relationship regardless of direction.
Average sensitivity [
24,
34] evaluates explanation stability under small input perturbations using a Monte Carlo approximation. The principle is that similar inputs with nearly identical outputs should yield similar explanations. The metric outputs a positive value, where lower scores indicate greater robustness.
Effective complexity [
35] quantifies the sparsity of an explanation by measuring the proportion of attribution values exceeding a chosen threshold. Features above the threshold are considered important, while those below are treated as noise. The metric is reported as a ratio, with lower values generally reflecting simpler, more interpretable explanations.
All metrics are implemented using the Quantus framework [
15], with custom modifications to accommodate our 4D fMRI inputs.
3.4. Swarm-LRP
The motivation for using a meta-heuristic optimization strategy to tune the parameters
,
, and
of LRP is that such methods do not rely on gradient information. Genetic and other biologically inspired algorithms have proven effective for hyperparameter optimization [
36]. In this work, we adopt a sample-based approach and implement a proof-of-concept Particle Swarm Optimization (PSO) [
37], chosen for its simplicity, effectiveness, and widespread use in diverse optimization tasks. While PSO lacks a closed-form convergence guarantee, empirical studies have shown it to reliably approximate near-optimal solutions in high-dimensional, non-convex spaces [
37]. Our use here follows that precedent as a proof-of-concept search over explainability metrics rather than a deterministic optimizer.
We frame parameter selection Algorithm A1 as an
n-dimensional optimization problem, where
n corresponds to the number of LRP parameters to estimate. Fitness is evaluated through an objective function that jointly considers faithfulness (
F), sensitivity (
S), and effective complexity (
C). Because these metrics differ in magnitude and directionality, each is normalized by its relative percent change with respect to a baseline configuration:
,
, and
. The swarm then minimizes the following cost function:
where
by default. Higher faithfulness decreases the objective, while higher sensitivity or complexity increase it. This formulation ensures that each metric contributes equally once normalized. Parameter bounds are enforced for
to maintain stability and restrict updates to empirically valid LRP domains. This framework and information flow are detailed in
Figure 2.
To extend Swarm-LRP beyond parameter tuning, we also introduce a proof-of-concept discretized optimization over rule assignments to linear layers, using the same cost function defined above. Each layer is numerically encoded with a discrete label (0: LRP-0, 1: LRP-, 2: LRP-, 3: LRP-), and PSO is applied to search this space. At initialization, layers are randomly assigned rules, and at each iteration particle values are floored to maintain discreteness. To reduce the dimensionality of the search, we enforce weight sharing by duplicating rule assignments across SwiFT Basic Layer blocks.
Together, these value- and layer-level optimizations illustrate the flexibility of Swarm-LRP. Although our proof-of-concept focused on linear layers, the same framework can be generalized to optimize rule assignments across any subset or group of layers.
3.5. Reproducibility Considerations
To support reproducibility, we provide the following details:
Random seeds: Not explicitly fixed in our experiments; results may vary slightly across runs.
Split policy: The dataset was divided into training, validation, and test sets at the subject level, but precise split ratios were not recorded. Care was taken to avoid subject-level leakage between sets.
Hardware/software stack: Experiments were run on 4×80GB NVIDIA A100 GPUs, 128 CPUs, 503 GB RAM. Software stack included PyTorch v1.13.1, CUDA v11.7, Quantus v0.5.3, Captum v0.6.0, DPARSF v4.5, SPM12 r7219, and FSLeyes v1.4.3. More compute details can be found in
Appendix B.
Code availability: Code is not yet public. It will be provided upon reasonable request.
More information about hyperparameters and experiment settings can be found in
Appendix A.
3.6. Data Licensing and Ethics
The COBRE dataset is publicly available for secondary use through the 1000 Functional Connectomes Project (NITRC) under controlled access (
https://fcon_1000.projects.nitrc.org/indi/retro/cobre.html, accessed on 2 February 2024). Data are fully anonymized, and this study involved no new data collection. All analyses were conducted in compliance with the COBRE data usage agreement and ethical guidelines for secondary use of de-identified neuroimaging data.
4. Results
4.1. Comparison with Baseline Methods
To evaluate the effectiveness of TransLRP in explaining 4D spatiotemporal data, we benchmarked three Uniform-TransLRP configurations against Integrated Gradients. For consistency, explanation values were normalized to the same scale across methods. Hyperparameters were set to , , and .
Across the test set, TransLRP consistently produced superior explanations compared to Integrated Gradients. As shown in
Table 1, at least one Uniform-TransLRP configuration outperformed Integrated Gradients on each evaluation metric. In particular, TransLRP achieved higher faithfulness scores, indicating stronger alignment between feature attributions and model predictions. At the same time, its lower sensitivity and complexity values suggest that TransLRP explanations are both more stable under small input perturbations and more focused on salient features.
4.2. Class-Wise Performance of Uniform-Gamma
Table 2 presents class-wise results for the best-performing TransLRP configuration (Uniform Gamma). Performance differed across labels, with explanations for the schizophrenia class achieving higher scores than those for the
control class. This indicates that the model produced more faithful, stable, and sparse explanations for subjects with schizophrenia than for healthy controls.
4.3. Physiological Relevance of Uniform-Gamma
To evaluate the ability of the uniform-gamma method to identify physiologically relevant regions of interest (ROIs), attribution maps were fitted to the MNI-152 template and segmented into brain regions using the Harvard-Oxford Cortical and Subcortical atlases [
38].
Table 3 reports the regions with the highest relevance scores, and
Figure 3 displays the produced heatmaps. Across subjects, high-relevance voxels concentrated in limbic and paralimbic structures (e.g., amygdala, nucleus accumbens), medial and lateral prefrontal cortices (including superior frontal gyrus and cingulate gyrus), and temporal association areas (e.g., temporal pole). These areas are predominantly associated with the regulation of emotion and reward, memory, and higher-order sensory, cognitive, and social functions [
39]. Dysfunction across these domains is a hallmark of schizophrenia, providing convergent face validity for the resulting relevance patterns [
2]. Because atlas-based labeling depends on macroanatomical parcellation boundaries, we interpret these overlaps at the level of functional domains rather than as reverse-inference claims about single regions.
Taken together, quantitative explanation metrics (faithfulness, sensitivity, complexity) and the observed concentration of relevance within schizophrenia-implicated functional systems support TransLRP as a viable approach for linking model decisions to spatiotemporal brain patterns. The resulting visualizations lend themselves to expert review and, in future work, for systematic clinical evaluation against symptom scales and task-based probes.
4.4. Optimization with Swarm-LRP
Building on these findings of physiological plausibility, we next evaluated whether optimization of LRP parameters and rule assignments through Swarm-LRP could further enhance explanation quality. Although our current implementation of Swarm-LRP is computationally intensive and not yet suited for large-scale batch processing, we evaluated its optimization performance on single-subject explainability. Hyperparameters were initialized as
,
, and
, with an LRP rule structure informed by prior work on rule distributions in VGG16 networks [
10]. Differences in Quantus metrics between the baseline (with these initial settings) and the optimized results are reported in
Table 4. Across all metrics, Swarm-LRP demonstrated substantial improvements in explanation quality relative to both the LRP baseline and Integrated Gradients. Overall, these findings are presented as a proof-of-concept demonstration of explainability optimization rather than a claim of clinical-grade classification performance.
5. Discussion
Reliable diagnosis of schizophrenia from neuroimaging remains an open challenge. The neurobiological effects are subtle and heterogeneous, available datasets are relatively small, and current machine learning models often prioritize classification performance at the expense of interpretability. As a result, many approaches struggle to yield clinically actionable insights. In this study, we combined SwiFT, a 4D fMRI transformer, with TransLRP to produce architecture-aware, spatiotemporal explanations of resting-state fMRI. We additionally introduced Swarm-LRP, a particle-swarm-based optimization framework for tuning relevance rules against Quantus metrics, demonstrating measurable gains in faithfulness and parsimony on single-subject analyses.
Analyses in this study were conducted on a single-site dataset (COBRE), which limits assessment of cross-scanner and multi-population generalization. However, Swarm-LRP is designed as a dataset-specific optimization framework: relevance rules are re-tuned per dataset or clinical cohort to adapt to local acquisition protocols and distributions. Results should therefore be interpreted as a proof-of-concept demonstration of explainability improvement, rather than a fixed, transferable configuration.
Our findings contribute to two ongoing needs in the field. First, they show that it is possible to move beyond model-agnostic attribution methods and recover physiologically plausible spatiotemporal patterns that align with known domains of dysfunction in schizophrenia, including emotion regulation, memory, and higher-order cognitive processes. Second, they demonstrate that biologically inspired optimization strategies can systematically improve the quality of explanation metrics, rather than relying on fixed rule settings or ad hoc parameter choices. Together, these results provide a proof of concept for explanation frameworks that are both architecture-aware and quantitatively validated.
At the same time, several limitations constrain interpretation. The classification performance of our SwiFT model, while sufficient to demonstrate feasibility, remains below the threshold needed for clinical translation. Swarm-LRP, though effective, is computationally intensive and currently impractical for large-scale or real-time deployment. Moreover, our evaluation was limited to a single dataset of modest size, leaving open questions about robustness across populations, scanners, and acquisition protocols. Finally, our approach optimizes explanations against a limited set of quantitative metrics; although these capture important aspects of faithfulness, sensitivity, and complexity, they do not fully encompass clinical interpretability or human expert alignment.
Future work should address these limitations on multiple fronts. Larger, multi-site datasets are needed to validate reproducibility and generalizability of the identified spatiotemporal patterns. More efficient optimization strategies—potentially leveraging gradient-free approximations, surrogate models, or distributed search—could reduce computational demands and enable group-level or real-time applications. Expanding the range of evaluation criteria, including human-in-the-loop assessments by clinical experts, will also be important for grounding explanation quality in practical diagnostic utility. In parallel, extending Swarm-LRP beyond linear layers to the full hierarchy of transformer modules may further enhance explanatory power.
In sum, this study provides an initial demonstration that architecture-aware explainability methods can yield physiologically relevant insights into schizophrenia from resting-state fMRI. Although our implementation is not yet a clinical tool, it offers a framework for integrating advanced model architectures, principled attribution methods, and quantitative optimization into neuroimaging explainability research. With continued refinement, such approaches may help narrow the gap between predictive machine learning models and clinically interpretable diagnostics.
6. Conclusions
This work demonstrates how explainable deep learning can be applied to resting-state fMRI for schizophrenia classification. By linking model predictions to temporally and anatomically grounded explanations, our approach has the potential to reduce the subjectivity of current psychiatric assessments and support earlier or more reliable diagnoses. In the long term, transparent neuroimaging-based tools could complement clinical judgment, fostering trust in ML systems and potentially informing treatment planning.
At the same time, premature reliance on automated classifications carries important risks. Models trained on small, single-site datasets may fail to generalize, and overconfidence in algorithmic outputs could undermine the role of clinical expertise and patient-reported experience. Mitigating these risks will require rigorous validation across cohorts, integration with multimodal assessments, and close collaboration with clinicians throughout development.
Overall, the potential impact of this work lies not in immediate deployment but in demonstrating that architecture-aware explainability can bring neuroimaging models closer to clinical utility while keeping interpretability at the core of their design.
Author Contributions
Conceptualization, J.W., E.Z., N.S., A.M. and E.C.; Methodology, J.W., E.Z. and N.S.; Software, J.W. and E.Z.; Validation, J.W. and E.Z.; Formal Analysis, J.W. and E.Z.; Investigation, J.W. and E.Z.; Writing—Original Draft, J.W. and E.Z.; Writing—Review & Editing, J.W., E.Z., A.M. and E.C.; Visualization, J.W.; Supervision, E.C.; Project Administration, E.C. All authors have read and approved the final manuscript.
Funding
This research received no external funding.
Institutional Review Board Statement
Not applicable.
Data Availability Statement
The original data presented in this study are available in the COBRE repository at
https://fcon_1000.projects.nitrc.org/indi/retro/cobre.html (accessed on 2 Februrary 2024), pending registration with the 1000 Functional Connectomes Project on NITRC. The original contributions are included in the article. Code will be made available upon reasonable request.
Acknowledgments
During the preparation of this manuscript, the authors used generative AI to assist with language editing and formatting. The authors reviewed and edited the output and take full responsibility for the content.
Conflicts of Interest
The authors declare no conflicts of interest.
Abbreviations
The following abbreviations are used in this manuscript:
| AI | Artificial Intelligence |
| CNN | Convolutional Neural Network |
| COBRE | Center for Biomedical Research Excellence |
| DPARSF | Data Processing Assistant for Resting-State fMRI |
| LRP | Layer-wise Relevance Propagation |
| PSO | Particle Swarm Optimization |
| ROI | Region of Interest |
| rs-fMRI | Resting-State Functional Magnetic Resonance Imaging |
| SCID | Structured Clinical Interview for DSM Disorders |
| SPM | Statistical Parametric Mapping |
| SwiFT | Swin 4D fMRI Transformer |
| TransLRP | Transformer Layer-wise Relevance Propagation |
| XAI | Explainable Artificial Intelligence |
Appendix A. Implementation Details
Appendix A.1. SwiFT Hyperparameters
The results reported in
Section 4 were obtained by training SwiFT with the following hyperparameters:
Optimizer: AdamW
Dropout rate/Attention dropout rate: 0.1
Training epochs: 14
Output head: MLP
Window size: (4, 4, 4, 4)
Patch size: (6, 6, 6, 1)
Appendix A.2. Effect of Preprocessing on Classification Accuracy
Table A1 summarizes classification performance before and after correcting the preprocessing thresholding step. Checkpoint 1 reflects results with clipped voxel values, while Checkpoint 2 reflects results after applying the corrected thresholding procedure. Overall, AUROC and accuracy remain comparable across both versions, suggesting that our framework is relatively robust to small preprocessing variations. For downstream explainability analyses, we rely on the corrected Checkpoint 2 results.
Table A1.
Impact of preprocessing thresholding on classification accuracy.
Table A1.
Impact of preprocessing thresholding on classification accuracy.
| Metric | Checkpoint 1 | Checkpoint 2 |
|---|
| AUROC | 0.725 | 0.708 |
| Accuracy | 0.727 | 0.727 |
| Balanced Accuracy | 0.717 | 0.700 |
Appendix A.3. Swarm-LRP Pseudocode
The following algorithm outlines our adaptation of Particle Swarm Optimization (PSO) for optimizing LRP hyperparameters.
Termination is based on either reaching the maximum iteration count or observing no improvement in the global best for k consecutive iterations. Each fitness evaluation requires a forward pass for explanation generation and metric computation, yielding total complexity , where N is swarm size, T the number of iterations, and the cost of one evaluation. While PSO lacks formal convergence guarantees, it consistently achieves near-optimal solutions in high-dimensional, non-convex search spaces, which aligns with its intended use as a proof-of-concept optimizer for Swarm-LRP.
Appendix A.4. Swarm-LRP Hyperparameters
Swarm-LRP optimization in
Section 4 was performed with the following settings for each Uniform-LRP configuration:
| Algorithm A1: Particle Swarm Optimization for Swarm-LRP Hyperparameter Tuning |
![Algorithms 18 00701 i001 Algorithms 18 00701 i001]() |
Appendix A.5. Visualization
To generate the MNI-152 2 mm mapped visualizations of relevance, we used
fsleyes [
43]. Relevance maps were reshaped to match the MNI-152 2mm template dimensions (182 × 218 × 182) and overlaid onto the template. Maps were masked to include only voxels within the brain, with extraneous noise removed. Values were logarithmically scaled and thresholded between
and
. Finally, the maps were smoothed using linear interpolation.
Appendix B. Compute Resources
Experiments were run on a high-performance computing cluster with the following specifications:
GPU: 4 × 80 GB NVIDIA A100
CPU: 128 cores, x86-64 architecture, 1.843 GHz
Memory: 503 GiB RAM
Storage: 7.5 TB
Estimated runtimes:
SwiFT training: 15 min
TransLRP explanation (single run): 30 s
Swarm-LRP (single-subject run): 1 h
TransLRP explanation (test set): 1 h
Total end-to-end compute time: ~24 h
An additional, unquantified amount of time was devoted to code testing and debugging prior to the final runs.
References
- Häfner, H. From Onset and Prodromal Stage to a Life-Long Course of Schizophrenia and Its Symptom Dimensions: How Sex, Age, and Other Risk Factors Influence Incidence and Course of Illness. Psychiatry J. 2019, 2019, 9804836. [Google Scholar] [CrossRef]
- Jablensky, A. The diagnostic concept of schizophrenia: Its history, evolution, and future prospects. Dialogues Clin. Neurosci. 2010, 12, 271–287. [Google Scholar] [CrossRef]
- Patel, K.R.; Cherian, J.; Gohil, K.; Atkinson, D. Schizophrenia: Overview and treatment options. Pharm. Ther. 2014, 39, 638–645. [Google Scholar]
- Zheng, J.; Wei, X.; Wang, J.; Lin, H.; Pan, H.; Shi, Y. Diagnosis of Schizophrenia Based on Deep Learning Using fMRI. Comput. Math. Methods Med. 2021, 2021, 8437260. [Google Scholar] [CrossRef]
- Asadi, N.; Olson, I.R.; Obradovic, Z. A transformer model for learning spatiotemporal contextual representation in fMRI data. Netw. Neurosci. 2023, 7, 22–47. [Google Scholar] [CrossRef] [PubMed]
- Bengs, M.; Gessert, N.; Schlaefer, A. 4D Spatio-Temporal Deep Learning with 4D fMRI Data for Autism Spectrum Disorder Classification. arXiv 2020, arXiv:2004.10165. [Google Scholar]
- Böhle, M.; Eitel, F.; Weygandt, M.; Ritter, K. Layer-Wise Relevance Propagation for Explaining Deep Neural Network Decisions in MRI-Based Alzheimer’s Disease Classification. Front. Aging Neurosci. 2019, 11, 194. [Google Scholar] [CrossRef]
- Liu, Z.; Lin, Y.; Cao, Y.; Hu, H.; Wei, Y.; Zhang, Z.; Lin, S.; Guo, B. Swin Transformer: Hierarchical Vision Transformer using Shifted Windows. arXiv 2021, arXiv:2103.14030. [Google Scholar] [CrossRef]
- Kim, P.Y.; Kwon, J.; Joo, S.; Bae, S.; Lee, D.; Jung, Y.; Yoo, S.; Cha, J.; Moon, T. SwiFT: Swin 4D fMRI Transformer. arXiv 2023, arXiv:2307.05916. [Google Scholar]
- Montavon, G.; Binder, A.; Lapuschkin, S.; Samek, W.; Müller, K. Layer-Wise Relevance Propagation: An Overview. In Explainable AI: Interpreting, Explaining and Visualizing Deep Learning; Springer: Cham, Switzerland, 2023. [Google Scholar]
- Bach, S.; Binder, A.; Montavon, G.; Klauschen, F.; Müller, K.R.; Samek, W. On Pixel-Wise Explanations for Non-Linear Classifier Decisions by Layer-Wise Relevance Propagation. PLoS ONE 2015, 10, e0130140. [Google Scholar] [CrossRef]
- Komorowski, P.; Baniecki, H.; Biecek, P. Towards Evaluating Explanations of Vision Transformers for Medical Imaging. In Proceedings of the 2023 IEEE/CVF Conference on Computer Vision and Pattern Recognition Workshops (CVPRW), Vancouver, BC, Canada, 17–24 June 2023; IEEE: New York, NY, USA, 2023. [Google Scholar] [CrossRef]
- Chefer, H.; Gur, S.; Wolf, L. Transformer Interpretability Beyond Attention Visualization. arXiv 2021, arXiv:2012.09838. [Google Scholar] [CrossRef]
- Abnar, S.; Zuidema, W. Quantifying Attention Flow in Transformers. arXiv 2020, arXiv:2005.00928. [Google Scholar] [CrossRef]
- Hedström, A.; Weber, L.; Bareeva, D.; Krakowczyk, D.; Motzkus, F.; Samek, W.; Lapuschkin, S.; Höhne, M.M.C. Quantus: An Explainable AI Toolkit for Responsible Evaluation of Neural Network Explanations and Beyond. arXiv 2023, arXiv:2202.06861. [Google Scholar] [CrossRef]
- Hu, M.; Qian, X.; Liu, S.; Koh, A.J.; Sim, K.; Jiang, X.; Guan, C.; Zhou, J.H. Structural and diffusion MRI based schizophrenia classification using 2D pretrained and 3D naive Convolutional Neural Networks. Schizophr. Res. 2022, 243, 330–341. [Google Scholar] [CrossRef]
- Zhao, Y.; Li, X.; Huang, H.; Zhang, W.; Zhao, S.; Makkie, M.; Zhang, M.; Li, Q.; Liu, T. Four-Dimensional Modeling of fMRI Data via Spatio–Temporal Convolutional Neural Networks (ST-CNNs). IEEE Trans. Cogn. Dev. Syst. 2020, 12, 451–460. [Google Scholar] [CrossRef]
- Hu, M.; Sim, K.; Zhou, J.H.; Jiang, X.; Guan, C. Brain MRI-based 3D Convolutional Neural Networks for Classification of Schizophrenia and Controls. In Proceedings of the 2020 42nd Annual International Conference of the IEEE Engineering in Medicine & Biology Society (EMBC), Online, 20–24 July 2020; pp. 1742–1745. [Google Scholar] [CrossRef]
- Borys, K.; Schmitt, Y.A.; Nauta, M.; Seifert, C.; Krämer, N.; Friedrich, C.M.; Nensa, F. Explainable AI in medical imaging: An overview for clinical practitioners—Beyond saliency-based XAI approaches. Eur. J. Radiol. 2023, 162, 110786. [Google Scholar] [CrossRef]
- Singh, A.; Sengupta, S.; Lakshminarayanan, V. Explainable deep learning models in medical image analysis. arXiv 2020, arXiv:2005.13799. [Google Scholar]
- Suara, S.; Jha, A.; Sinha, P.; Sekh, A.A. Is Grad-CAM Explainable in Medical Images? arXiv 2023, arXiv:2307.10506. [Google Scholar] [CrossRef]
- Zhang, J.; Rao, V.M.; Tian, Y.; Yang, Y.; Acosta, N.; Wan, Z.; Lee, P.Y.; Zhang, C.; Kegeles, L.S.; Small, S.A.; et al. Detecting schizophrenia with 3D structural brain MRI using deep learning. Sci. Rep. 2023, 13, 14433. [Google Scholar] [CrossRef] [PubMed]
- Sundararajan, M.; Taly, A.; Yan, Q. Axiomatic Attribution for Deep Networks. arXiv 2017, arXiv:1703.01365. [Google Scholar] [CrossRef]
- Yeh, C.K.; Hsieh, C.Y.; Suggala, A.S.; Inouye, D.I.; Ravikumar, P. On the (In)fidelity and Sensitivity for Explanations. arXiv 2019, arXiv:1901.09392. [Google Scholar] [CrossRef]
- Munoz, C.; da Costa, K.; Modenesi, B.; Koshiyama, A. Evaluating explainability for machine learning predictions using model-agnostic metrics. arXiv 2014, arXiv:2302.12094. [Google Scholar]
- Silva, W.; Fernandes, K.; Cardoso, M.J.; Cardoso, J.S. Towards Complementary Explanations Using Deep Neural Networks. In Understanding and Interpreting Machine Learning in Medical Image Computing Applications; Stoyanov, D., Taylor, D., Kia, S.M., Oguz, I., Reyes, M., Martel, A., Maier-Hein, L., Marquand, A.F., Duchesnay, E., Löfstedt, T., Eds.; Lecture Notes in Computer Science; Springer: Berlin/Heidelberg, Germany, 2018; Volume 11038, Chapter 15. [Google Scholar] [CrossRef]
- Ribeiro, M.T.; Singh, S.; Guestrin, C. “Why Should I Trust You?”: Explaining the Predictions of Any Classifier. arXiv 2016, arXiv:1602.04938. [Google Scholar]
- Ahmed, A.M.A.; Ali, L.A.M. Explainable Medical Image Segmentation via Generative Adversarial Networks and Layer-wise Relevance Propagation. arXiv 2021, arXiv:2111.01665. [Google Scholar] [CrossRef]
- Bassi, P.R.A.S.; Dertkigil, S.S.J.; Cavalli, A. Improving deep neural network generalization and robustness to background bias via layer-wise relevance propagation optimization. Nat. Commun. 2024, 15, 291. [Google Scholar] [CrossRef] [PubMed]
- Aine, C.J.; Bockholt, H.J.; Bustillo, J.R.; Cañive, J.M.; Caprihan, A.; Gasparovic, C.; Hanlon, F.M.; Houck, J.M.; Jung, R.E.; Lauriello, J.; et al. Multimodal Neuroimaging in Schizophrenia: Description and Dissemination. Neuroinformatics 2017, 15, 343–364. [Google Scholar] [CrossRef]
- Chao-Gan, Y.; Yu-Feng, Z. DPARSF: A MATLAB Toolbox for "Pipeline" Data Analysis of Resting-State fMRI. Front. Syst. Neurosci. 2010, 4, 13. [Google Scholar] [CrossRef]
- Ashburner, J.; Barnes, G.; Chen, C.C.; Daunizeau, J.; Flandin, G.; Friston, K.; Gitelman, D.; Glauche, V.; Henson, R.; Hutton, C.; et al. SPM12 Manual; UCL Queen Square Institute of Neurology: London, UK, 2021. [Google Scholar]
- Mazziotta, J.; Toga, A.; Evans, A.; Fox, P.; Lancaster, J.; Zilles, K.; Woods, R.; Paus, T.; Simpson, G.; Pike, B.; et al. A four-dimensional probabilistic atlas of the human brain. J. Am. Med. Inform. Assoc. 2001, 8, 401–430. [Google Scholar] [CrossRef]
- Bhatt, U.; Weller, A.; Moura, J.M.F. Evaluating and Aggregating Feature-based Model Explanations. arXiv 2020, arXiv:2005.00631. [Google Scholar] [CrossRef]
- phi Nguyen, A.; Martínez, M.R. On quantitative aspects of model interpretability. arXiv 2020, arXiv:2007.07584. [Google Scholar] [CrossRef]
- Li, C.; Jiang, J.; Zhao, Y.; Li, R.; Wang, E.; Zhang, X.; Zhao, K. Genetic Algorithm based hyper-parameters optimization for transfer Convolutional Neural Network. arXiv 2021, arXiv:2103.03875. [Google Scholar] [CrossRef]
- Kennedy, J.; Eberhart, R. Particle swarm optimization. In Proceedings of the ICNN’95-International Conference on Neural Networks, Perth, WA, Australia, 27 November–1 December 1995; Volume 4, pp. 1942–1948. [Google Scholar] [CrossRef]
- Makris, N.; Goldstein, J.M.; Kennedy, D.; Hodge, S.M.; Caviness, V.S.; Faraone, S.V.; Tsuang, M.T.; Seidman, L.J. Decreased volume of left and total anterior insular lobule in schizophrenia. Schizophr. Res. 2006, 83, 155–171. [Google Scholar] [CrossRef] [PubMed]
- Alahmadi, A.A.S. Functional connectivity of sub-cortical brain regions: Disparities and similarities. Neuroreport 2023, 34, 214–219. [Google Scholar] [CrossRef]
- Sheffield, J.M.; Barch, D.M. Cognition and resting-state functional connectivity in schizophrenia. Neurosci. Biobehav. Rev. 2016, 61, 108–120. [Google Scholar] [CrossRef]
- Xu, J.; Liang, J.; Yan, H.; Zhang, C.; Zhang, X.; Li, X.; Huang, W.; Guo, H.; Yang, Y.; Ye, J.; et al. Alterations in amygdala subregions–Default mode network connectivity after treatment in patients with schizophrenia. J. Neurosci. Res. 2024, 102, e25376. [Google Scholar] [CrossRef]
- Cao, X.; Li, Q.; Liu, S.; Li, Z.; Wang, Y.; Cheng, L.; Yang, C.; Xu, Y. Enhanced Resting-State Functional Connectivity of the Nucleus Accumbens in First-Episode, Medication-Naïve Patients With Early Onset Schizophrenia. Front. Neurosci. 2022, 16, 844519. [Google Scholar] [CrossRef]
- Smith, S.M.; Jenkinson, M.; Woolrich, M.W.; Beckmann, C.F.; Behrens, T.E.; Johansen-Berg, H.; Bannister, P.R.; De Luca, M.; Drobnjak, I.; Flitney, D.E.; et al. Advances in functional and structural MR image analysis and implementation as FSL. NeuroImage 2004, 23, S208–S219. [Google Scholar] [CrossRef] [PubMed]
| Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2025 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).