Classification performance comparison
Perform anatomy-based 3D whole-brain DeepSHAP analysis
The classification performance of MDFAG-Net was compared with representative MRI-based methods for Alzheimer’s disease classification, including 3D-CNN, ResNet34, DenseNet121, PlgFormer, PDMML, 3D Swin Transformer, 2D-CNN, ViT, BrainMAE, MSA3D, and PMF-Net. All methods were evaluated on the same ADNI cohort using identical subject-level data partitions and evaluation metrics, following the implementation and hyperparameter-tuning procedures described in the Protocol. The quantitative results are presented in Table 53,5,8,9,10,13,15,16,20,21,22.
As shown in Table 5, MDFAG-Net achieved the best overall classification performance, with an accuracy of 0.661 ± 0.027, a precision of 0.683 ± 0.030, an F1-score of 0.658 ± 0.020, and a macro-AUC of 0.798 ± 0.030, together with a recall of 0.650 ± 0.030. These results demonstrate the benefit of jointly exploiting multiview 2D slice representations and whole-brain 3D structural features for AD classification.
Compared with the traditional 3D-CNN, MDFAG-Net improved the accuracy from 0.609 to 0.661 and the F1-score from 0.592 to 0.658. Relative to ViT, MDFAG-Net increased the accuracy, F1-score, and macro-AUC from 0.641, 0.643, and 0.782 to 0.661, 0.658, and 0.798, respectively. Compared with 3D Swin Transformer, BrainMAE, and PMF-Net, MDFAG-Net improved the macro-AUC by 0.017, 0.009, and 0.014, respectively, further supporting the effectiveness of jointly modeling multiview slice information and whole-brain 3D structural information. Two-sided paired t-tests based on the fold-matched macro-AUC results showed statistically significant improvements over 3D-CNN, ResNet34, PDMML, and 2D-CNN. Although MDFAG-Net also achieved higher mean macro-AUC values than the remaining methods, these differences did not reach statistical significance (Table 5).
Regarding class-specific discriminative ability, the ROC curves shown in Figure 6 yielded AUC(OvR) values of 0.825, 0.708, and 0.897 for NC, MCI, and AD, respectively, for MDFAG-Net. Notably, although MCI is typically characterized by relatively subtle structural alterations, MDFAG-Net achieved the highest MCI-specific AUC among the evaluated methods (0.708), exceeding ViT (0.696), BrainMAE (0.697), and 3D Swin Transformer (0.685). This finding suggests that jointly exploiting multiview 2D slice information and whole-brain 3D structural features may facilitate the identification of subtle structural differences associated with MCI.
Ablation studies
Hyperparameter sensitivity analysis
Hyperparameter sensitivity analyses were conducted to evaluate the effects of base_keep_ratio, , and on the performance of MDFAG-Net. Figure 7 shows the classification performance under different base_keep_ratio and settings, while Table 6 further reports the effect of on both classification performance and the distribution of slice-level attention weights.
As shown in Figure 7, variations in base_keep_ratio and affected model performance, although the overall fluctuations were relatively small. For base_keep_ratio, the best performance was obtained at 0.45; a lower retention ratio may discard informative slices, whereas further increasing the ratio provided no additional benefit, suggesting increased redundancy. For, the model performed best at 1.0, while deviations from this value generally reduced performance, indicating that a moderate temperature facilitates effective adaptive gating across feature dimensions. Overall, base_keep_ratio = 0.45 and .
Table 6 further shows the effect of on slice-level attention sparsity. As increased, progressively decreased, indicating that the attention weights became less concentrated across the retained slices. However, stronger sparsity did not necessarily result in better classification performance. The best performance was achieved at , whereas either lower or higher values resulted in reduced performance. These results indicate that an intermediate attention concentration provides a better balance between emphasizing informative slices and preserving complementary information. Therefore, was used in the final model.
Impact of different dimensions
In this experiment, the impact of different dimensions on the classification performance of the proposed MDFAG-Net framework was studied. While keeping the model architecture and training strategy unchanged, different 2D slice dimensions on the basis of the original 3D MRI dimensions were added. The changes in model performance to quantify the contribution of each dimension were evaluated, as shown in Figure 8.
As shown in Figure 8, the MDFAG-Net model achieved the best performance across all evaluation indicators, fully verifying the effectiveness of the proposed multidimensional fusion strategy. In contrast, the performance of the 3D-CNN baseline model, which relies only on 3D MRI data, is relatively low, indicating that pure 3D imaging has limitations in capturing subtle pathological features. When the single-view 2D slice sequence was introduced into the 3D-CNN baseline model, its performance was improved to varying degrees. This clearly shows that 2D slice images from different perspectives can provide unique and complementary diagnostic information for 3D MRI data. Overall, the MDFAG-Net model that fully integrates all modalities is better than any combination model that relies only on a single 2D perspective. This emphasizes that integrating multidimensional information can achieve a more comprehensive and robust feature representation, which is crucial to improving the classification performance.
Impact of the enhanced sparse MIL aggregation module
We used Enhanced Sparse MIL in the MDFAG-Net model to fully model the correlation between slices at the slice-level feature extraction stage, so as to effectively distinguish between key focal slices and unrelated or noise slices. In this subsection, an ablation experiment was designed to verify the effectiveness of the aggregation module by removing the module from MDFAG-Net and naming the modified model MDFAG-Net-1, as shown in Figure 9.
As shown in Figure 9, MDFAG-Net outperformed MDFAG-Net-1 in all indicators. For example, the accuracy of MDFAG-Net reached 0.661, while MDFAG-Net-1 is 0.631. For AUC, MDFAG-Net reached 0.798, 3 percentage points higher than the 0.768 of MDFAG-Net-1. These results show that the Enhanced Sparse MIL aggregation module is crucial to the excellent performance of MDFAG-Net. Its multiscale scoring and adaptive sparse selection can more effectively filter and aggregate slice features with diagnostic value.
Impact of the adaptive gating module
We adopted adaptive gating technology in the MDFAG-Net model to adaptively adjust the contribution weight of each dimension in the multidimensional feature fusion stage. In order to verify the effectiveness of the adaptive gating module, an ablation experiment was designed to remove the module from MDFAG-Net and name the model obtained as MDFAG-Net-2, as shown in Figure 10.
As shown in Figure 10, the performance comparison of MDFAG-Net and MDFAG-Net-2 in NC/MCI/AD multiclassification tasks shows that the adaptive gating module has a positive impact on the performance of the model. Although the improvement of these individual indicators is not as significant as that of the aggregation mechanism, the adaptive gating module has enhanced all key indicators. These results show that the adaptive gating module optimizes the integration process of multidimensional information. By dynamically adjusting the contribution of each dimension, the model significantly improves its ability to classify Alzheimer's disease.
Model interpretability analysis
Slice-level multiview Grad-CAM analysis
To characterize the adaptive slice-selection behavior of the Enhanced Sparse MIL module, the adaptive keep ratio and the actual number of retained slices were summarized separately for the axial, coronal, and sagittal views across the NC, MCI, and AD groups (Table 7).
As shown in Table 7, the slice retention ratios varied across diagnostic groups and anatomical views, reflecting the adaptive selection of informative slices by the Enhanced Sparse MIL module.
To further assess the anatomical relevance of the selected high-importance slices, Grad-CAM analysis was performed on representative high-importance slices from the three diagnostic groups (Figure 11). Distinct spatial response patterns were observed across diagnostic groups and anatomical views. Responses in the NC group were relatively dispersed and mainly involved cortical and some periventricular regions. The MCI group showed more concentrated responses in the periventricular and medial cortical regions, whereas the AD group exhibited more extensive responses involving the periventricular and medial cortical regions.
Further region-based analysis using the Hammersmith 95-region atlas localized the high Grad-CAM responses primarily to the posterior cingulate gyrus, precuneus, and medial frontal regions. These regional findings were spatially consistent with the medial cortical responses observed in the high-importance slices. In particular, the posterior cingulate and precuneus are among the medial cortical structures frequently implicated in AD-related structural alterations43,44,45. Together, the anatomical distribution of the Grad-CAM responses and the atlas-based regional localization indicate that the high-importance slices selected by the Enhanced Sparse MIL module contain information about AD-associated brain structural alterations, thereby supporting the biological plausibility of the adaptive slice-selection mechanism.
Anatomy-based 3D whole-brain SHAP analysis
DeepSHAP attribution analysis was performed with normal-control samples as the baseline, following the computational workflow described in the Protocol. The Hammersmith 95-region atlas was used to aggregate voxel-wise SHAP values into regional attribution scores, and the top 15 contributing brain regions were identified for MCI-predicted and AD-predicted test subjects (Figure 12).
As shown in Figure 12, in the MCI group (Figure 12A), the attribution weights of the 3D CNN branch are primarily dominated by the Left/Right lateral ventricle posterior part and the Left/Right posterior cingulate gyrus. As a core brain region of the default mode network (DMN), the high attribution proportion of the posterior cingulate gyrus indicates that the system's decision-making relies heavily on the specific network topological degradation features during the prodromal phase46. In addition, the Left/Right amygdala, Left/Right hippocampus, Left/Right parahippocampal gyrus anterior part, and Left/Right anterior cingulate gyrus also ranked among the top, directly providing a quantitative characterization of medial temporal lobe atrophy and limbic system damage during the MCI stage.
In contrast, in the AD group (Figure 12B), the spatial distribution of SHAP scores exhibits a combined characteristic of brain parenchyma atrophy and ventricular enlargement. Compared with the MCI group, the attribution weights of the Left/Right amygdala and Left hippocampus/Right hippocampus increase significantly, corresponding to the typical anatomical features of medial temporal lobe atrophy in clinical AD47. Simultaneously, the system's attention is widely distributed across the ventricular system; except for the Left/Right lateral ventricle posterior part, the rankings of the Left/Right lateral ventricle anterior part and the Left/Right temporal horn of the lateral ventricle both increase. The aforementioned statistical results at the group level highly conform to the classic pathological imaging characteristics of “medial temporal lobe atrophy combined with compensatory holoventricular enlargement” in AD patients45.
The complete MDFAG-Net implementation, including data preparation, Enhanced Sparse MIL, adaptive gating, model training and evaluation, Grad-CAM visualization, and DeepSHAP analysis, is available at GitHub: https://github.com/MDFAG-Net/MDFAG-Net.
Data analyzed in this study were obtained from the Alzheimer’s Disease Neuroimaging Initiative (ADNI) database. ADNI data are hosted by the LONI Image and Data Archive (IDA). Researchers must complete academic registration and accept the ADNI data‑use agreement to gain access. The main project portal is available at https://adni.loni.usc.edu/, and the data‑access application page is at https://ida.loni.usc.edu/collaboration/access/appLicense.jsp. No universal dataset‑level DOI or accession identifier exists for the full ADNI repository. The processed derivative data generated in this study are not essential for reproducing the study’s analyses and results, as they can be regenerated from the original ADNI data using the procedures described in this protocol.

Figure 1: Comparison of original and preprocessed brain MRI slices (Axial/Coronal/Sagittal). (A) Before preprocessing. (B) After preprocessing. Please click here to view a larger version of this figure.

Figure 2: Overall architecture of MDFAG-Net. The framework integrates multiview slice-level representations and whole-brain structural features for NC/MCI/AD classification through enhanced sparse MIL aggregation and adaptive gating-based feature fusion. Please click here to view a larger version of this figure.

Figure 3: Structure of the enhanced sparse MIL aggregation module. Slice importance and feature diversity are jointly evaluated to perform adaptive Top-k selection. The selected slices and all candidate slices are aggregated through sparse and dense pathways to obtain the final representation. Please click here to view a larger version of this figure.

Figure 4: Structure of the multiscale slice scoring module. Local slice information and global contextual information are jointly modeled to generate the final slice-importance score used for slice ranking. Please click here to view a larger version of this figure.

Figure 5: Structure of the feature diversity assessment module. Feature diversity among slices is estimated and combined with the base_keep_ratio to determine the adaptive_keep_ratio for Top-k selection. Please click here to view a larger version of this figure.

Figure 6: ROC curves for different competitive methods across categories. (A) NC (B) MCI (C) AD. The curves show one-vs-rest receiver operating characteristic (ROC) performance, with the corresponding area under the curve (AUC) reported for each method. Please click here to view a larger version of this figure.

Figure 7: Hyperparameter sensitivity analysis of MDFAG-Net. Macro-AUC and accuracy are compared under different (A) base_keep_ratio and (B) temperature parameter settings. Error bars indicate the variability across the five folds. Please click here to view a larger version of this figure.

Figure 8: Impact of different feature dimensions on classification performance. The 3D-only, single-view axial, coronal, and sagittal configurations are compared with the complete MDFAG-Net using Accuracy, Precision, Recall, F1-score, and AUC. Please click here to view a larger version of this figure.

Figure 9: Impact of the enhanced sparse MIL aggregation module. Classification performance of the complete MDFAG-Net is compared with that of the model without the enhanced sparse MIL module across five evaluation metrics. Please click here to view a larger version of this figure.

Figure 10: Impact of the adaptive gating module. Classification performance of the complete MDFAG-Net is compared with that of the model without adaptive gating across five evaluation metrics.Please click here to view a larger version of this figure.

Figure 11: Grad-CAM visualization saliency maps across multiple orthogonal planes for NC, MCI, and AD subjects. From left to right, representative cases of NC, MCI, and AD are presented. Each row corresponds to the Axial, Coronal, and Sagittal planes, respectively. In each pair, the left image shows the original MRI, while the right image displays the Grad-CAM overlay. Please click here to view a larger version of this figure.

Figure 12: Population-level anatomical brain region contributions based on DeepSHAP. (A) Top 15 ROIs ranked by absolute SHAP scores in the predicted-MCI group. (B) Top 15 ROIs ranked by absolute SHAP scores in the predicted-AD group. The x-axis denotes the accumulated absolute SHAP value per region based on the Hammersmith atlas, representing the macroscopic attribution of the 3D CNN branch. Please click here to view a larger version of this figure.
| Category | Gender(Male/Female) | Age (years) | Weight (kg) |
| AD | 141/99 | 75.81 ± 7.92 | 74.34 ± 15.33 |
| MCI | 167/89 | 75.97 ± 7.47 | 76.47 ± 14.85 |
| NC | 174/172 | 75.43 ± 5.87 | 76.05 ± 15.26 |
Table 1: Clinical information of ADNI study participants. Demographic and clinical characteristics of participants in the NC, MCI, and AD groups are summarized.
| Block | Input Channels | Output Channels | Convolution (Kernel/Stride) | Pooling(Kernel/Stride) | Normalization & Activation |
| 1 | 1 | num | Conv(7/2) | Pool(3/2) | BN + ReLU |
| 2 | num | 2 * num | Conv(4/1) | Pool(2/2) | BN + ReLU |
| 3 | 2 * num | 4 * num | Conv(3/1) | Pool(2/2) | BN + ReLU |
| 4 | 4 * num | 8 * num | Conv(3/1) | Pool(2/2) | BN + ReLU |
Table 2: Structural parameters of the CNN_Bone backbone network. The architecture and parameter settings of the four ConvLayer blocks used for whole‑brain 3D feature extraction are summarized. Here, “num” denotes the configurable base number of output channels; num was set to 20 in the experiments reported in this study.
| Data subset | NC | MCI | AD | Total | Proportion |
| Original training set | 242 | 179 | 168 | 589 | 70.00% |
| Original validation set | 35 | 26 | 24 | 85 | 10.00% |
| Independent test set | 69 | 51 | 48 | 168 | 20.00% |
| Total | 346 | 256 | 240 | 842 | 100.00% |
Table 3: Dataset partition for NC, MCI, and AD subjects. The numbers and proportions of NC, MCI, and AD subjects in the training, validation, and independent test sets are reported.
| Method | Implementation source | Input configuration | Selected learning rate |
| 3D-CNN [8] | Reproduced using the authors’ publicly available code | 3D T1-weighted MRI | 5 × 10-4 |
| ResNet34 [9] | Reproduced using the authors’ publicly available code | 3D T1-weighted MRI | 1 × 10-4 |
| DenseNet121 [10] | Reproduced using the authors’ publicly available code | 3D T1-weighted MRI | 1 × 10-4 |
| PlgFormer [13] | Reimplemented in-house based on the original publication | 3D T1-weighted MRI | 5 × 10-4 |
| 3D Swin Transformer [15] | Reproduced using the authors’ publicly available code | 3D T1-weighted MRI | 5 × 10-4 |
| BrainMAE [16] | Reproduced using the authors’ publicly available code and pretrained weights | 3D T1-weighted MRI | 1 × 10-4 |
| PDMML [3] | Reproduced using the authors’ publicly available code | Local 3D MRI patches | 1 × 10-4 |
| 2D-CNN [20] | Reproduced using the authors’ publicly available code | Axial, coronal, and sagittal MRI slices | 5 × 10-4 |
| ViT [21] | Reproduced using the authors’ publicly available code | Multi-view MRI slices resized to 224 × 224 | 5 × 10-4 |
| PMF-Net [22] | Reimplemented in-house based on the original publication | Axial, coronal, and sagittal MRI slices | 1 × 10-4 |
| MSA3D [5] | Reimplemented in-house based on the original publication | Multi-view 2D MRI slices and 3D T1-weighted MRI | 1 × 10-4 |
Table 4: Implementation details of the comparison methods. The implementation source, input configuration, and selected learning rate are provided for each comparison method.
| Method | Accuracy | Precision | Recall | F1-Score | AUC | P‑value |
| 3D-CNN [8] | 0.609 ± 1.3% | 0.640 ± 0.01 | 0.579 ± 0.01 | 0.592 ± 0.01 | 0.749 ± 0.02 | 0.021 |
| ResNet34 [9] | 0.620 ± 1.2% | 0.641 ± 0.03 | 0.620 ± 0.01 | 0.619 ± 0.01 | 0.754 ± 0.01 | 0.028 |
| DenseNet121 [10] | 0.631 ± 2.2% | 0.649 ± 0.04 | 0.632 ± 0.03 | 0.642 ± 0.03 | 0.771 ± 0.03 | 0.104 |
| PlgFormer [13] | 0.639 ± 2.2% | 0.664 ± 0.04 | 0.637 ± 0.03 | 0.649 ± 0.03 | 0.782 ± 0.03 | 0.237 |
| 3D Swin Transformer [15] | 0.641 ± 2.0% | 0.661 ± 0.03 | 0.636 ± 0.03 | 0.647 ± 0.02 | 0.781 ± 0.02 | 0.146 |
| PDMML [3] | 0.640 ± 1.9% | 0.659 ± 0.03 | 0.649 ± 0.02 | 0.654 ± 0.03 | 0.762 ± 0.01 | 0.043 |
| 2D-CNN [20] | 0.614 ± 2.1% | 0.636 ± 0.03 | 0.619 ± 0.02 | 0.620 ± 0.02 | 0.731 ± 0.02 | 0.011 |
| BrainMAE [16] | 0.653 ± 1.6% | 0.672 ± 0.02 | 0.651 ± 0.02 | 0.657 ± 0.02 | 0.789 ± 0.02 | 0.381 |
| ViT [21] | 0.641 ± 1.6% | 0.663 ± 0.02 | 0.647 ± 0.02 | 0.643 ± 0.02 | 0.782 ± 0.01 | 0.129 |
| PMF-Net [22] | 0.646 ± 2.2% | 0.671 ± 0.02 | 0.643 ± 0.01 | 0.652 ± 0.02 | 0.784 ± 0.02 | 0.264 |
| MSA3D [5] | 0.637 ± 2.5% | 0.651 ± 0.02 | 0.646 ± 0.03 | 0.641 ± 0.01 | 0.769 ± 0.02 | 0.053 |
| This study | 0.661 ± 2.7% | 0.683 ± 0.03 | 0.650 ± 0.03 | 0.658 ± 0.02 | 0.798 ± 0.03 | — |
Table 5: Classification performance of different methods on the ADNI dataset. Results are reported as mean ± standard deviation across five folds. The p-values represent paired comparisons of fold‑matched macro‑AUC values between each method and MDFAG‑Net.
| τ1 | Satt | Accuracy | AUC |
| 0.6 | 0.438 ± 0.05 | 0.644 ± 0.03 | 0.781 ± 0.02 |
| 0.8 | 0.379 ± 0.04 | 0.653 ± 0.02 | 0.789 ± 0.03 |
| 1.0 | 0.334 ± 0.05 | 0.651 ± 0.02 | 0.787 ± 0.02 |
| 1.2 | 0.292 ± 0.04 | 0.661 ± 0.03 | 0.798 ± 0.03 |
| 1.4 | 0.257 ± 0.03 | 0.656 ± 0.02 | 0.792 ± 0.04 |
| 1.6 | 0.229 ± 0.04 | 0.649 ± 0.04 | 0.785 ± 0.02 |
Table 6: Effect of the temperature parameter on model performance and attention sparsity. Classification performance and slice‑level attention sparsity under different temperature settings are reported.
| Diagnostic group | View | Adaptive _keep_ratio | Retained slices |
| NC | Sagittal | 0.68 ± 0.06 | 33.3 ± 2.8 |
| NC | Coronal | 0.71 ± 0.06 | 34.8 ± 3.0 |
| NC | Axial | 0.65 ± 0.04 | 31.9 ± 2.0 |
| MCI | Sagittal | 0.74 ± 0.07 | 36.3 ± 3.2 |
| MCI | Coronal | 0.66 ± 0.05 | 32.4 ± 2.5 |
| MCI | Axial | 0.71 ± 0.05 | 34.8 ± 2.3 |
| AD | Sagittal | 0.69 ± 0.07 | 33.8 ± 3.5 |
| AD | Coronal | 0.72± 0.08 | 35.3 ± 3.7 |
| AD | Axial | 0.73± 0.04 | 35.8 ± 1.9 |
Table 7: Adaptive slice retention across diagnostic groups and anatomical views. Adaptive keep ratios and the corresponding numbers of retained slices are reported for the sagittal, coronal, and axial views across the NC, MCI, and AD groups.