Abstract / Summary
Accurate brain tumor analysis from magnetic resonance imaging (MRI) requires both tumor localization and tumor-type classification. Existing pipelines often treat segmentation and classification as isolated or sequential tasks, limiting shared representation learning and potentially introducing error propagation when predicted masks are used directly for classification. This study presents DenseUNet-SC , a shared-encoder multi-task deep learning framework for binary tumor segmentation and three-class tumor-type classification from 2D MRI slices. The architecture uses a densely connected encoder with two parallel branches: a U-Net decoder for pixel-wise tumor/background segmentation and a global-average-pooling classification head for tumor-type prediction. The predicted segmentation mask is not used as classifier input. Instead, segmentation and classification interact through encoder-mediated multi-task optimization, where gradients from both objectives jointly update the shared dense representation. The methodological distinction of DenseUNet-SC therefore lies not in the isolated use of DenseNet or U-Net, but in the integration of dense cross-layer feature reuse with a parallel segmentation–classification design under a reproducible subject-aware evaluation protocol. Binary segmentation is adopted as a controlled and annotation-efficient formulation for tumor localization; its limitations relative to multi-class BraTS subregion segmentation are explicitly acknowledged. To reduce slice-correlation bias, partitioning uses verified patient identifiers where available (documented file-level fallback otherwise) before slice extraction; classification probabilities are aggregated at the subject level during testing. Experiments using BraTS 2021 for segmentation evaluation and the Figshare brain tumor dataset for three-class classification/joint experiments yield five-seed mean BraTS segmentation scores of Dice 0.99573 and IoU 0.9915. On the primary Figshare held-out split, DenseUNet-SC correctly classifies 46/47 subject groups (accuracy 0.9787), with macro-precision 0.9722, macro-recall 0.9841, macro-F1 0.9774, and macro-specificity 0.9907; the five-split mean classification accuracy is 0.9830 ± 0.0178. These results are supported by per-class confusion analysis, standalone classifier comparisons, ablation experiments, and practical inference discussion. Importantly, this work is a retrospective algorithmic validation study, not a clinical trial, and the reported results should not be interpreted as evidence of clinical efficacy or immediate deployability. Prospective multi-center validation, scanner/protocol generalization testing, external validation of calibration and uncertainty robustness, together with radiologist reader studies, is required before future clinical use. Source code is publicly available in the project GitHub repository .