Master’s Thesis Presentation • Artificial Intelligence | Machine Learning • Visual Segmentation with Explanations for Medical Decision Making: A CNN Architecture with a Transformer-Attention Extension

Friday, May 8, 2026 12:00 pm - 1:00 pm EDT (GMT -04:00)

Please note: This master’s thesis presentation will take place online.

Mahmoud Khalaf, Master’s candidate
David R. Cheriton School of Computer Science

Supervisor: Professor Robin Cohen

Medical image segmentation is essential for assisting medical professionals in locating anomalies in images. However, the lack of explainability in current segmentation frameworks limits clinical trust and adoption.

This thesis presents two complementary frameworks for explainable medical image segmentation, demonstrating that accuracy and interpretability can be achieved simultaneously through innovative architectural design. The first framework introduces an attention-based CNN architecture that generates model-specific visual explanations through spatial attention gates integrated directly into the network. The proposed model achieves a Dice score of 0.8621 on the Kvasir-SEG polyp segmentation dataset, outperforming all evaluated explainable models, while producing attention heatmaps that faithfully reflect the model’s decision-making process. The second framework advances this by introducing a dual encoder architecture combining a pretrained ResNet-34 CNN encoder with a pretrained Swin Transformer encoder, fused through a learned directional attention-gated mechanism at multiple scales. The dual encoder achieves a Dice score of 0.907 on Kvasir-SEG, outperforming all single encoder baselines, while generating richer multi-scale visual explanations that reflect the complementary contributions of both encoders. Finally, this thesis outlines a pathway in detail towards a fully multimodal explainability system, integrating textual explanations through SigLIP, Retrieval Augmented Generation, and a Large Language Model alongside the visual heatmaps.

We explore future directions regarding breast cancer and echocardiogram segmentation, more specifically applications for ejection fraction computation, and insights gained from trials and errors that led to the innovative designs of the thesis.


Attend this master’s thesis presentation virtually on Zoom.