Abstract
Magnetic resonance imaging based dementia severity assessment facilitates timely diagnosis of Alzheimer’s disease (AD) progression. While convolutional neural networks (CNNs) have shown effectiveness in classifying AD stages, their performance can be limited by high computational demands and class imbalance in training data. The article introduces a derivative-free optimization (DFO) approach by integrating evolutionary algorithms, Bayesian optimization, simulated annealing, neural architecture search, and pruning techniques to optimize both trainable parameters and network topology to design a lightweight CNN model (DAPA-CNN) for classifying brain MRI images into four Alzheimer-related Dementia stages (ARDS): non-Dementia (ND), mild Dementia (MD), very mild Dementia (VMD) and moderate Dementia (MoD). The proposed framework balances the dataset using Tomek links and deep SMOTE, and enhances model interpretability with class activation maps (CAMs). DAPA-CNN achieved an accuracy of 99.59% on the Alzheimer’s disease dataset (ADD), along with balanced precision (99.60%), sensitivity (99.66%), specificity (99.87%), and F1score (99.63%). across all classes. All class-wise dice and Jaccard indices and correlation metrics (Matthews correlation coefficient and Cohen’s Kappa) exceeded 0.99. Compared to a baseline CNN and contemporary architectures, DAPA-CNN reduces the number of parameters by 85.6%, processing time by 42.8%, and memory usage by 76.6%, making it suitable for resource-constrained clinical environments.
Subject terms: Computational biology and bioinformatics, Diseases, Mathematics and computing, Neurology, Neuroscience
Introduction
Dementia is an umbrella term describing loss of memory and cognitive abilities in humans that interfere with activities of Daily Living (ADL) while AD is the leading cause of dementia, accounting for approximately 60–80% of cases.It is a progressive neurodegenerative condition that causes brain atrophy and cognitive decline1,2. Early and accurate staging of ARDS is crucial, as timely intervention can help patients and caregivers manage symptoms and plan care. Structural brain imaging, particularly Magnetic Resonance Imaging (MRI), provides detailed anatomical biomarkers of ARDS progression that includes, hippocampal atrophy, cortical thinning, and ventricular enlargement which aid in assessing dementia severity3. CNNs have emerged as effective Deep Learning (DL) models for MRI analysis because they can automatically learn subtle neuroanatomical patterns from high-dimensional scans4. Various CNN-based approaches have achieved high accuracy in distinguishing different dementia stages; for example, one deep CNN model accurately classified AD severity using longitudinal MRI data, while another study integrated functional MRI to improve performance5,6. However, many state-of-the-art CNNs employ very deep architectures with millions of parameters, demanding substantial computation and memory7,8.These complex models are difficult to deploy in resource-constrained clinical settings. Deep learning optimizers face nonconvex problems and risk overfitting on small high-dimensional datasets9. Gradient descent variants differ in update strategy: Batch GD uses the entire training set for each update (stable but too slow for very large data), Stochastic GD updates per sample (fast but noisy), and Mini-Batch GD uses small batches (a balance between speed and stability, popular in CNNs like AlexNet, VGG, and ResNet10. Advanced optimizers accelerate training and help avoid getting trapped in local minima. Momentum methods (accumulating a velocity term to smooth updates, with Nesterov Accelerated Gradient adding a lookahead11) speed up learning, while adaptive learning-rate algorithms provide per-parameter adjustments: Adagrad (learning rates decrease over time12), Adadelta and RMSprop (mitigate Adagrad’s rate decay issue), and Adam (combining momentum and adaptive techniques for fast convergence are popular choices. Each optimizer has strengths and weaknesses –plain SGD often generalizes well but converges slowly and is sensitive to the learning rate, whereas Adam finds solutions faster but can overfit or get stuck in sharp minima13. No single method is universally best for all problems – the “no free lunch” principle applies, meaning the optimal choice depends on the dataset and loss landscape14. Moreover, training deep models on medical images is challenging due to limited data and class imbalance – mild and moderate AD cases are often far fewer than non-demented cases. This imbalance biases models toward the majority class and undermines sensitivity to early-stage dementia15. Additionally, the “black-box” nature of DL raises concerns about interpretability, since clinicians need transparency in how the model makes decisions16,17. To address these challenges, we propose a lightweight CNN framework optimized through derivative-free algorithms to classify Alzheimer’s Related Dementia Severity (ARDS) from MRI. Unlike conventional approaches that rely on gradient-based training and manual hyperparameter tuning, our method leverages derivative-free optimization – including evolutionary strategies, Bayesian hyperparameter search, neural architecture search, and pruning – to automatically refine the network topology and training parameters without explicit gradients. This approach yields a compact model (termed DAPA-CNN) with dramatically reduced complexity. In parallel, we employ advanced data balancing techniques (Tomek Links and Deep SMOTE) to counter class imbalance, enabling the model to learn effectively from all dementia stages. We also incorporate Class Activation Maps (CAMs) to enhance interpretability by highlighting the brain regions most influential in each decision. By integrating data balancing, model optimization, and explainability in one framework, our approach directly tackles the key limitations of current AD classification methods. This holistic strategy produces a high accuracy model but also efficient and transparent, moving a step closer to trustworthy AI deployment in clinical practice. In summary, the proposed DAPA-CNN achieves high accuracy in classifying four dementia stages ND, VMD, MD and MoD while significantly reducing computational overhead, bridging the gap between accurate AI-driven AD diagnosis and practical clinical implementation.
Results
Overall performance DAPA-CNN vs baseline
Our DAPA-CNN delivers substantially better classification performance on ADD, pooled ADNI than the baseline CNN as presented in Fig. 1 [Confusion matrices of CNN: BL and DAPA-CNN, Online Resource 2 (ESM_2, Supplementary Fig. 7)] respectively and the performance metrics are calculated and summarized in Table 4 and the detailed ARDS class-wise metrics values are presented in Online Resource 2 (ESM_2: Supplementary Tables 4, 5, 6 and 7). As shown, overall accuracy improved from 93.9% with the baseline to 99.59% for ADD, 87.23% to 93.70% for ADNI with DAPA-CNN. Precision improved from 93.9% to 99.6% for ADD, and from 84.02% to 94.24% for ADNI, while recall increased from 93.38% to 99.66% for ADD, and from 84.82% to 94.05% for ADNI, indicating that the optimized model makes very few errors. In fact, all class-specific precision and recall values exceed 99% for DAPA-CNN (versus values in the 90s for the baseline on the ADD dataset). This means the model correctly recognizes each dementia stage with near-perfect reliability. Such gains are especially important in a medical context, as the DAPA-CNN drastically reduces both false negatives and false positives compared to the original CNN. The performance metrics comparison between CNN: BL and contemporary models are summarized in Table 5.
Fig. 1.
Confusion matrix of the DAPA-CNN model for ADD dataset and ADNI dataset showing relation between predicted and true labels across all dementia severity classes.
Table 4.
Performance metrics comparison between CNN: BL and DAPA-CNN.
| Metric | CNN: BL (%) | DAPA-CNN (%) | Improvement in % (DAPA-CNN – CNN: BL) | |||
|---|---|---|---|---|---|---|
| ADD | ADNI | ADD | ADNI | ADD | ADNI | |
| Sensitivity (recall) | 93.38 | 84.82 | 99.66 | 94.05 | +5.98 | +9.23 |
| Specificity | 97.47 | 94.78 | 99.87 | 98.06 | +2.40 | +3.28 |
| Precision | 93.90 | 84.02 | 99.60 | 94.24 | +5.70 | +10.22 |
| F1-score | 93.86 | 84.34 | 99.63 | 94.13 | +5.77 | +9.79 |
| Accuracy | 93.90 | 87.23 | 99.59 | 93.70 | +5.69 | +6.47 |
| MCC | 91.90 | 84.45 | 99.45 | 92.00 | +7.55 | +7.55 |
| Cohen’s Kappa | 91.90 | 86.45 | 99.52 | 93.00 | +7.62 | +6.55 |
Table 5.
Performance Metrics Comparison between DAPA-CNN and Contemporary Models.
| Model | Sensitivity (in %) | Specificity (in %) | Precision (in %) | F1 Score (in %) | Accuracy (in %) |
|---|---|---|---|---|---|
| CNN + Hessian Free Optimization19 | 74.3 | 80.0 | – | 76.5 | 77.2 |
| DenseNet12120 | 76.8 | 95.8 | 79.4 | 78.0 | 84.6 |
| GoogleNet20 | 82.0 | 96.7 | 82.7 | 82.3 | 86.9 |
| Mobile Net20 | 81.7 | 95.2 | 84.2 | 83.0 | 88.4 |
| Pre-trained CNN + multi-class support vector machines (MSVM) + ANNs21 | 68.0 | 90.0 | 95.0 | 80.0 | 91.0 |
| MobileNetV220 | 92.0 | – | 93.0 | 80.3 | 92.3 |
| MCLSO-SpinalNet21 | 93.6 | 93.3 | – | 91.7 | 92.6 |
| ANN + Deep Hyper Optimization22 | 98.1 | – | 97.2 | – | 98.2 |
| CNN: BL (ADD) | 95.63 | 98.68 | 95.70 | 95.61 | 95.27 |
| DAPA-CNN (ADD) | 99.66 | 99.87 | 99.60 | 99.63 | 99.59 |
| CNN: BL (ADNI) | 84.82 | 94.78 | 84.02 | 84.34 | 87.23 |
| DAPA-CNN (ADNI) | 94.05 | 98.06 | 94.24 | 94.13 | 93.70 |
Model efficiency
In addition to accuracy gains, our optimized model is more efficient. DAPA-CNN’s architecture uses only 301,379 parameters (compared to 2,096,963 parameters in the baseline CNN), representing an 85.6% reduction in model size. This leaner network requires significantly less memory (0.35 GB vs 1.5 GB, approximately 76.6% less memory usage) and trains much faster, as shown in Table 6. Empirically, DAPA-CNN converges in 15 epochs (versus 20 epochs for the baseline), and each epoch runs quicker due to the smaller model; overall training time is reduced by 42.8% compared to the baseline CNN, as illustrated in Online Resource 2 (ESM_2: Supplementary Tables 8 and 9). This reduction in computational cost and model size makes the proposed approach more feasible for real-world clinical deployment, where memory and time are often limited. Importantly, these efficiency improvements were achieved without sacrificing accuracy; in fact, accuracy improved despite the model being simpler. This highlights the effectiveness of the derivative-free optimization approach in pruning unnecessary complexity while preserving crucial predictive features.
Table 6.
Computational Efficiency Metrics Comparison between DAPA-CNN and CNN: BL.
| Metric | CNN: BL | DAPA-CNN (in %) | Reduction in computational cost |
|---|---|---|---|
| Time duration (in minutes) | 35 | 20 | Reduced by 15 minutes (42.8% reduction) |
| Memory usage (in GB) | 1.5 | 0.35 | Reduced by 1.15 GB (76.6% reduction) |
Comparison to state-of-the-art
Our DAPA-CNN exhibits improved performance over contemporary published approaches and the CNN baseline, as presented in Table 5. In comparison with recent studies of CNN-based MRI classifiers18–21, reported accuracies and F1-scores typically range in the mid-90s. In contrast, DAPA-CNN achieves higher overall accuracy and more balanced precision and recall. Specifically, the model’s accuracy (99.59%) and F1-score (99.63%) on the ADD dataset exceed those of earlier state-of-the-art 2D CNN models on similar tasks. These results suggest that the combination of data balancing and DFO-driven architecture optimization enables high-yield performance for ARDS classification.
Segmentation quality assessment and training dynamics
Table 7 summarizes the DAPA-CNN model’s segmentation performance using the Dice Coefficient (DC) and Jaccard Index (JI) for each Alzheimer’s stage (ND, VMD, MD, MoD). All categories exhibit high overlap between predicted and true labels, confirming accurate classification. The VMD and MD classes yield the highest scores (DC = 0.9989, JI = 0.9962 for ADD; DC = 0.9531, JI = 0.9105 for ADNI), indicating excellent distinction of these categories. ND and MoD also achieve DC and JI values of 0.9961 and 0.9922, and DC and JI values of 0.9969 and 0.9940, respectively, on the ADD dataset. These values demonstrate the model’s robustness and reliable segmentation across all classes, effectively validating DAPA-CNN’s classification accuracy. During training, the model converges rapidly with stable, high performance, as shown in Online Resource (ESM_3: Supplementary Fig. 9a and b). Training accuracy approaches its optimal value within the first 10 epochs, and training loss drops near zero in the same period. This rapid convergence indicates efficient learning and reflects the effectiveness of the DFO pipeline for CNN architecture and parameter optimization. Similarly, both training and validation JI reach and stabilize close to 1.0 within 10 epochs, indicating excellent segmentation accuracy with minimal overfitting, as shown in Online Resource (ESM_3: Supplementary Fig. 9c and d). The DC follows the same trend, with training and validation values near 1.0 early in training, further confirming precise segmentation, as shown in Online Resource (ESM_3: Supplementary Fig. 9e and f). Validation accuracy likewise climbs to near-optimal values and remains stable, while validation loss approaches zero, reflecting outstanding generalization to unseen data, as shown in Online Resource (ESM_3: Supplementary Fig. 9g and h). The consistent convergence and near-perfect metrics across accuracy, loss, JI, and DC underscore the effectiveness of the derivative-free optimized DAPA-CNN and highlight its reliability for clinical applications.
Table 7.
DC and JI for DAPA-CNN Model in Alzheimer’s MRI Classification.
| Dementia category | Dice coefficient | Jaccard coefficient | ||
|---|---|---|---|---|
| ADD | ADNI | ADD | ADNI | |
| ND | 0.9961 | 0.9408 | 0.9922 | 0.8882 |
| VMD | 0.9989 | 0.9451 | 0.9962 | 0.8958 |
| MD | 0.9969 | 0.9531 | 0.9940 | 0.9105 |
| MoD | 0.9955 | 0.9263 | 0.9911 | 0.8628 |
Model generalization and discriminatory power
The model’s discriminative ability is highlighted by the Receiver Operating Characteristic (ROC) curves for each class shown in Fig. 2. The Precision–Recall curves for ND, VMD, MD, and MoD shown in Fig. 2b nearly reach the top-left corner of the plot, corresponding to area under the curve (AUC) values approaching 1.00 for all classes. These results denote near-perfect sensitivity and specificity in distinguishing among ARDS stages. Such high AUC values demonstrate that DAPA-CNN can accurately separate each category with minimal false positives, which is an essential quality in medical diagnostics. Together, the high DC, JI, and AUC results demonstrate DAPA-CNN’s strong generalization capabilities and confirm that it sets a performance benchmark compared to conventional CNN models, making it a promising tool for Alzheimer’s MRI classification and segmentation in clinical settings. To address generalizability concerns, external validation was performed using the multi-center ADNI dataset. Performance remained consistent, confirming improved robustness, scanner independence, and clinical translation potential of the proposed model.
Fig. 2.
ROC curves for training (a) and validation (b) demonstrating high discriminative ability with AUC values approaching for all classes.
Interpretability using CAMs
To increase clinical trust in the model, Class Activation Maps (CAMs) were incorporated to visualize the anatomical regions used by the CNN for its predictions, as presented in Fig. 3. The CAM outcomes provide intuitive explainability for each dementia stage. For example, in Mild and Very Mild Dementia cases, the DAPA-CNN CAMs highlight the hippocampal formation and surrounding medial temporal lobe structures, which are well known to undergo early atrophy in Alzheimer’s disease. In Moderate Dementia cases, the CAM heatmaps extend to broader cortical areas, reflecting widespread cortical thinning and ventricular enlargement in more advanced stages. In contrast, scans from Non-Demented patients show only diffuse or minimal activation. This progression of highlighted regions, from focal hippocampal activation in mild impairment to diffuse cortical involvement in moderate Alzheimer’s disease, aligns with established clinical understanding and provides qualitative validation that the model localizes meaningful neuroanatomical biomarkers.
Fig. 3.
CAM visualizations highlighting clinically relevant brain regions used by DAPA-CNN for distinguishing progressive dementia severity stages.
Conclusion
In summary, this article presents that a balanced training set and derivative-free optimization provides improved CNN performance for ARDS. By correcting class imbalance using Deep SMOTE + Tomek Links and systematically tuning the architecture, we obtained a DAPA-CNN model that yields high accuracy and lightweight model. It achieves near-perfect classification of dementia severity on the ADD dataset overall accuracy 99.59%, accomplishing 85.6% reduction in parameters, and 42.8% reduction in time per epoch. This efficiency will facilitate real-world deployments, as it enables faster inference and makes the model feasible on modest hardware. Moreover, we enhanced the transparency of the model through CAM-based visualizations, which highlight severity-relevant brain regions and thus make the results more interpretable for clinicians. This manuscript used rigid standards for imaging in our study, there is a planned prospective validation with multiple centers to generalize the use of our technology to many other different clinical environments. This would be the next logical step to validate its use in real-world applications. The data from our baseline of the ADD/ADNI validation provide a basis for all future research; further longitudinal studies will provide insight into the temporal stability of the findings of this study as well as the ability to track the progression of AD. The GPU processing time required for the optimization of our advanced DFO pipeline demonstrate that it is feasible for these types of pipelines to be optimized our goal is to make the process for optimizing these pipelines faster and easier so that they will be accessible to more researchers. Our DAPA-CNN was validated using a computer model, our plan is to move forward with prospective clinical trials approved by an Institutional Review Board (IRB), to incorporate input from clinicians regarding how best to utilize the technology, and to conduct pilot studies in actual clinical settings.
Methods
We propose DAPA-CNN, a lightweight CNN optimized through a pipeline of DFO algorithms. This workflow illustrated in Fig. 4 combines four techniques – Evolutionary Algorithm (EA), Bayesian Optimization (BO), Neural Architecture Search (NAS), and Network Pruning (PT) to reduce model complexity and computational load. The comprehensive mathematical design procedure is illustrated in Online Resource 1(ESM_1). We evaluate our approach on the publicly available Alzheimer’s Disease Dataset (ADD)22, pooled which contains MRI scans categorized into four stages: ND, VMD, MD, and MoD and a pooled and class-mapped Alzheimer’s Disease Neuroimaging Initiative (ADNI) dataset. We reserved 20% of the dataset as a validation set for model selection and hyperparameter tuning throughout the optimization process. To enhance disease-specific features in these MRI slices, we apply a preprocessing pipeline of frequency filtering, brain region segmentation, and intensity normalization. Additionally, to counter the class imbalance in ADD, we remove ambiguous majority-class images by using a unique combination of Tomek Links and Deep SMOTE23, an oversampling technique that operates by learning deep feature representations through an autoencoder architecture, then applying SMOTE interpolation in the learned latent space to generate synthetic minority images. This yields a more balanced ADD set and reduces overfitting. Finally, we incorporate Class Activation Maps (CAMs) to highlight which brain regions influence each prediction, improving the model’s interpretability for clinical use.
Fig. 4.
LCNN framework for four-stage ARDS classification, showing the transition from a heavier baseline model to the optimized lightweight DAPA-CNN architecture designed for efficient clinical deploymentt.
Preprocessing pipeline
Each MRI slice is first converted to the frequency domain using a 2D Fourier transform to accentuate high-frequency details (while attenuating low-frequency components) that includes sharp boundaries of ventricles and lesions that indicate structural changes. We then perform segmentation to isolate Alzheimer’s relevant brain regions (such as the hippocampus and enlarged ventricles) from background tissue. We filtered non-brain areas (skull, background) and ensure the input to the CNN only contains the brain region of interest, focusing the analysis on relevant anatomy. This includes an intensity thresholding step to discard non-brain pixels and a region-growing algorithm to capture contiguous areas of abnormal intensity around seed points. After segmentation, we normalize image intensities (using z-score normalization) to correct for scanner-specific brightness and contrast variations. By combining these steps, we highlight critical anatomical changes (enlarged ventricles, hippocampal atrophy, cortical thinning) and ensure consistent intensity scaling which together facilitate more robust feature learning by the CNN. The illustrations are presented in Online Resource (ESM_3: Supplementary Fig. 4a–c).
Baseline CNN architecture
Our baseline CNN (CNN: BL) is designed to capture the hierarchical neuroanatomical patterns of ARDS. It takes a preprocessed 128
128 MRI slice as input and passes it through five convolutional 2D layers with increasing filter counts (32, 64, 128, 256, 512). Early layers (with 3
3 filters) learn fine-grained textures that differentiate healthy tissue from subtle lesions, while deeper layers (with larger 5
5 receptive fields) capture broader structures like hippocampal atrophy, ventricular enlargement, and cortical thinning. Each convolutional layer uses ReLU activation and is followed by a 2
2 max pooling layer (applied after the first four convolutional layers) that reduces spatial resolution, thus concentrating salient features and reducing noise. We also apply batch normalization to stabilize feature distributions across layers and mitigate intensity differences between scans. After the convolutional layer-pooling layer stack, the feature maps are flattened and fed into two fully connected layers (with 512 and then 4 neurons). The final layer uses Softmax to output probabilities for the four classes. While this baseline model effectively learns AD biomarkers, it is computationally heavy with 2.1 million parameters (rounded) and the detailed architecture details is presented in Online Resource 2 (ESM_2: Supplementary Table 1).
Derivative-free optimization for DAPA-CNN
We integrate four gradient-free optimization strategies to optimize and fine-tune the baseline CNN into the final DAPA-CNN architecture as given in Online Resource 3 (ESM_3: Supplementary Fig. 1). Optimization: We first apply an EA to perform a coarse search over network architectures, evolving a population of network configurations via selection, crossover, and mutation to maximize a fitness score balancing accuracy and simplicity. This EA yields a pared-down architecture (down from 5 layers and 992 filters in the baseline) with only 3 convolutional layers and a total of 224 filters, significantly trimming redundant functionality. The NAS controller, a RNN, then fine-tunes this architecture, exploring different 3-layer configurations and using policy-gradient reinforcement learning to favor architectures with higher validation accuracy. The NAS also reduced the dense layer from 512 to 256 units, further cutting down parameters with minimal impact on accuracy and the impact analysis is presented in Table 1.
Table 1.
Impact Analysis of EA and NAS in terms of architectural features between CNN: BL and DAPA-CNN.
| Feature | CNN: BL | DAPA-CNN |
|---|---|---|
| Convolutional layers | 5 | 3 |
| Total Kernels | 992 | 224 |
| Dense layer units | 512 units | 256 units |
Hyperparameter and weight optimization
With the architecture fixed, we apply BO to fine-tune key training hyperparameters. Using a Gaussian-process surro-gate to model the validation loss, BO converges on an op-timal learning rate(
)of 0.002, size (64), and dropout rate (0.20). After training the CNN with these optimized set-tings, we further improve the model through post-training weight refinement. SA is employed to perturb the convolutional weights and escape any remaining local minima in the loss surface; weight updates that reduces the validation loss is accepted based on a gradually decreasing temperature schedule. Finally, we perform magnitude-based pruning to remove approximately 20% of the least important weights (those with the smallest absolute values), eliminating redundant connections and further downsizing the model (a brief fine-tuning is then applied to recover any slight accuracy loss). After all these steps, the resulting DAPA-CNN is extremely compact, with only 301,379 parameters an 85.6% reduction in model size compared to the baseline’s 2,096,393 parameters while maintaining high classification performance. This level of optimization makes DAPA-CNN feasible to deploy in re-source-constrained clinical settings and the contributions of DFO is presented in: Table 2, Online Resource 2 (ESM_2: Supplementary Table 3), and the resultant DAPA-CNN architecture details are presented in Table 3.
Table 2.
DAPA-CNN Training strategy and respective DFO contributions.
| Setting | Value / Strategy | DFO contribution |
|---|---|---|
| Population-based search | EA NAS determined a 3-conv/224-kernel backbone |
macro + micro architecture |
| Hyperparameter tuning | Bayesian Optimisation on validation loss | Learning rate = 0.002, batch = 64, dropout schedule 0 0.20 |
| Post-training weight polish | Simulated Annealing, T = 0.1, = 0.95 |
gradient-free fine-tuning |
| Pruning | Magnitude-based 20 % sparsity, fine-tune 5 epochs | 85.6 % net parameter cut |
| Early stopping | patience = 10, val-acc < 0.001 |
convergence guard |
Table 3.
Architecture Details of DAPA-CNN.
| S. no. | Parameter | Value |
|---|---|---|
| 1 | Input layer | (128, 128, 1) |
| 2 | Total number of layers (including input, flatten, dense) | 9 |
| 3 | Convolutional 2D layers (Conv2D) | 3 |
| 4 | Total number of kernels | 224 |
| 5 | Pooling layers | 3 |
| 6 | Activation function | ReLU |
| 7 | Dense layer | 2 (256, 4 units) |
| 8 | Flatten layer | 1 |
| 9 | Batch normalization | No |
| 10 | Classification function | Softmax (4 units) |
Model interpretability
To ensure the optimized model’s decisions remain clinically meaningful, we employ CAMs to visualize the regions of each MRI that DAPA-CNN deems important for its prediction as presented in Fig. 3. We generate CAM heatmaps by taking a weighted sum of the model’s final convolutional feature maps (using the output layer’s weights for a given class) to identify which brain areas contribute most to the classification. DAPA-CNN’s CAMs highlight the expected anatomical areas: minimal activation in healthy scans (ND), focused activation in hippocampal and ventricular regions for very mild dementia, and widespread cortical and hippocampal activation for more advanced dementia. This alignment with known AD pathology suggests that despite it
Dataset and training protocol
Dataset
We use the public ADD dataset of T1-weightedbrain MRI scans with four classes of Alzheimer’s disease severity: ND, VMD, MD, and MoD whose statistical dimensions are given in Online Resource 2 (ESM_2: Supplementary Table 2) and the sample images are presented in Online Resource. In total, there are 36,880 2D axial MRI slices after data augmentation and preprocessing and a ADNI dataset comprising of 1,828 MRI images. To preserve alignment with classification nomenclature we mapped ADNI labels as Cognitively Normal (CN) as ND, Early Mild Cognitive Impairment (EMCI) as VMD, Late MCI(LMCI) as MD, Alzheimer’s Dementia (AD) as MoD. Each image is standardized to 128
128 resolution, and all scans were acquired under similar MRI settings (1.5T scanner, MPRAGE sequence), ensuring consistent image quality across subjects and the sample images are shown in Online Resource 3(ESM_3: Fig. 2). The dataset initially showed a class imbalance (MoD being the smallest class with only 6,464 images, versus 9,600 in VMD) as shown in Online Resource (ESM_3: Fig. 3). We addressed this imbalance by applying a combination of Deep SMOTE and Tomek Links oversampling: this expanded the minority class (MoD) to roughly 9,200 samples, achieving an approximately balanced 1:1:1:1 ratio for ND:VMD:MD: MoD as shown in Fig. 5. This approach not only equalized class frequencies but also removed ambiguous borderline samples by Tomek Links, thus improving training data quality.
Fig. 5.
Class distribution before and after applying Tomek Links Deep SMOTE, demonstrating improvement from an imbalanced dataset to a clean and balanced class ratio.
Train–validation–test split
We partitioned the balanced dataset into training, validation, and test sets using a 60%/20%/20% split, stratified by class. This stratification preserved the equal class proportions in each subset. To avoid any information leakage, no subject’s scans appear in more than one set (all images from a given patient were confined to a single subset). Model hyperparameters were tuned on the validation set, and we employed early stopping based on validation loss to prevent overfitting. Both the baseline CNN and the optimized DAPA-CNN were trained using the same partitioning and training protocol for a fair head-to-head comparison. We used the Adam optimizer for training in both cases, with identical initial learning rates and regularization settings; the optimized model’s training was stopped when validation performance ceased improving (early stopping), and the weights at the lowest validation loss were saved for final evaluation on the hold-out test set.
Supplementary Information
Author contributions
Saravana Kumar Ganesan (S.K.G) ; Parthasarathy Velusamy (P.V); Praveen Parthasarathy (P.V) ; Asokan Vasudevan (A.V) Conceptualization, S.K.G. and P.V.; Methodology, S.K.G.; Software, P.V.; Validation, P.P., A.V. and P.V.; Formal Analysis, P.V.; Investigation, S.K.G. and P.P; Resources, P.V, P.P.; Data Curation, S.K.G and P.V.; Writing – Original Draft Preparation, S.K.G.; Writing – Review & Editing, P.V, A.V.; Visualization, P.P.; Supervision, P.V.; Project Administration, P.V.
Data availability
Data is provided within the manuscript and in supplementary materials.
Declarations
Competing interests
The authors declare no competing interests.
Footnotes
Publisher’s note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Contributor Information
Saravana Kumar Ganesan, Email: ishanga7gurubiksha@gmail.com.
Asokan Vasudevan, Email: asokan.vasudevan@newinti.edu.my.
Supplementary Information
The online version contains supplementary material available at 10.1038/s41598-026-36037-9.
References
- 1.Alzheimer’s disease and dementia. (accessed 3 January 2025); https://www.alz.org/alzheimers-dementia
- 2.Difference between dementia and alzheimer’s. (accessed 3 January 2025); https://www.alz.org/alzheimers-dementia/difference-b etween-dementia-and-alzheimer-s
- 3.Alzheimer’s disease treatments. (accessed 3 January 2025); https://www.alz.org/alzheimers-dementia/treatments
- 4.Litjens, G. et al. A survey on deep learning in medical image analysis. Med. Image Anal.42, 60–88 (2017). [DOI] [PubMed] [Google Scholar]
- 5.Suk, H.-I., Lee, S.-W. & Shen, D. Deep ensemble learning of sparse regression models for brain disease diagnosis. Med. Image Anal.37, 101–113 (2017). [DOI] [PMC free article] [PubMed] [Google Scholar]
- 6.Li, F., Liu, M. & Initiative, A. D. N. Deep learning-based imaging data completion for improved brain disease diagnosis. IEEE Trans. Med. Imaging33, 2037–2046 (2014). [DOI] [PMC free article] [PubMed] [Google Scholar]
- 7.Sim, H. & Yang, S. Classification of alzheimer’s disease and frontotemporal dementia using electroencephalography and deep-learning based approach. Alzheimers & Dementia10.1002/alz.082896 (2023). [Google Scholar]
- 8.Herzog, N. J. & Magoulas, G. D. Convolutional neural networks-based framework for early identification of dementia using mri of brain asymmetry. Int. J. Neural Syst.32, 2250053. 10.1142/s0129065722500538 (2022). [DOI] [PubMed] [Google Scholar]
- 9.Li, Z., Liu, F., Yang, W., Peng, S. & Zhou, J. A survey of convolutional neural networks: Analysis, applications, and prospects. IEEE Trans. Neural Netw. Learn. Syst.33, 6999–7019 (2022). [DOI] [PubMed] [Google Scholar]
- 10.Krizhevsky, A., Sutskever, I. & Hinton, G. E. Imagenet classification with deep convolutional networks. Commun. ACM60 (2017).
- 11.Simonyan, K. & Zisserman, A. Very deep convolutional networks for large-scale image recognition. arXiv (2014). ArXiv:1409.1556.
- 12.Reddi, S. J., Kale, S. & Kumar, S. On the convergence of adam and beyond. arXiv (2019). ArXiv:1904.09237.
- 13.Duchi, J. & Hazan, E. Adaptive subgradient methods for online learning and stochastic optimization. J. Mach. Learn. Res.12, 2121–2159 (2011). [Google Scholar]
- 14.Srivastava, N. et al. Dropout: A simple way to prevent neural networks from overfitting. J. Mach. Learn. Res.15, 1929–1958 (2014). [Google Scholar]
- 15.Chen, H., Zhou, H. & Zhao, L. Class imbalance learning in deep neural networks for Alzheimer’s diagnosis. IEEE Trans. Med. Imaging40, 925–934 (2021). [Google Scholar]
- 16.Kim, H., Lee, J. & Park, S. Explainable deep learning for neuroimaging: Interpretability and insights in Alzheimer’s disease. Front. Aging Neurosci.10, 321 (2018).30405394 [Google Scholar]
- 17.Mahmud, T. et al. An explainable AI paradigm for Alzheimer’s diagnosis using deep transfer learning. Diagnostics (Basel)14, 345. 10.3390/diagnostics14030345 (2024). [DOI] [PMC free article] [PubMed] [Google Scholar]
- 18.Pafitis, M., Constantinou, M. & Christodoulou, C. Accelerating training of convolutional neural networks with hessian-free optimization for detecting Alzheimer’s disease in brain mri. IEEE Access12, 176184–176198. 10.1109/ACCESS.2024.3487114 (2024). [Google Scholar]
- 19.Alwakid, G. N., Tahi, S., Humayun, M. & Gouda, W. Improving Alzheimer’s detection with deep learning and image processing techniques. IEEE Access12, 153445–153449. 10.1109/ACCESS.2024.3481238 (2024). [Google Scholar]
- 20.Alayba, A. M., Senan, E. M. & Alshudukhi, J. S. Enhancing early detection of Alzheimer’s disease through hybrid models based on feature fusion of multi-CNN and handcrafted features. Sci. Rep.14, 31203. 10.1038/s41598-024-82544-y (2024) (PMID: 39732953; PMCID: PMC11682306.). [DOI] [PMC free article] [PubMed] [Google Scholar]
- 21.Neethu, M. & Jayasingh, R. J. K-net based segmentation and manta crow light spectrum optimization enabled DNFN for classification of Alzheimer’s disease using MRI images. Multim. Tools Appl.10.1007/s11042-024-18967-6 (2024). [Google Scholar]
- 22.Yakkundi, A. Alzheimer’s disease dataset. Mendeley Data, V1, 10.17632/ch87yswbz4.1 (2023).
- 23.Dablain, D., Krawczyk, B. & Chawla, N. V. Deepsmote: Fusing deep learning and smote for imbalanced data. IEEE Trans. Neural Netw. Learn. Syst.34, 6390–6404. 10.1109/TNNLS.2021.3136503 (2023). [DOI] [PubMed] [Google Scholar]
Associated Data
This section collects any data citations, data availability statements, or supplementary materials included in this article.
Supplementary Materials
Data Availability Statement
Data is provided within the manuscript and in supplementary materials.










