An Explainable and Comparative Transfer Learning Framework for Brain Tumor Classification from MRI Images
Automated detection of brain tumors from Magnetic Resonance Imaging (MRI) can accelerate diagnosis and reduce inter-reader variability, yet many existing studies report only top-line accuracy on small datasets, omit efficiency analysis, and provide no interpretability, limiting their clinical credibility. We present a reproducible, comparative, and explainable transfer- learning framework for binary brain-tumor classification. Our framework (i) standardizes a configurable preprocessing pipeline combining CLAHE contrast enhancement and unsharp-mask sharpening, (ii) evaluates a custom CNN baseline and pretrained backbones under an identical training budget, (iii) reports a full metric suite (accuracy, precision, recall, F1, ROC-AUC, PR-AUC, parameter count, and inference latency), and (iv) applies Grad- CAM for spatial interpretability. On a public 253-image MRI dataset (38-image held-out test set), MobileNetV2 achieves the best overall performance (94.74% accuracy, 0.994 ROC-AUC, 0.996 PR-AUC) with only 2.59M parameters and 5.9 ms per- image inference, making it the most deployment-friendly model. Larger backbones (Xception, EfficientNetB0) and the custom CNN converge to degenerate all-positive predictions under the same limited budget, illustrating the small-data overfitting risk that accuracy-only reporting conceals. Grad-CAM confirms that the best model attends to the tumor region. All source code, con- figuration files, and trained evaluation scripts are publicly avail- able at https://github.com/blck-iris/explainable-brain-tumor-mr