Deep Learning for Pathology: YOLOv8 with EigenCAM for Reliable Colorectal Cancer Diagnostics

Mohamed Farsi, Hanaa Y. ZainEldin, Hanaa A. Sayed, Rasha F. El-Agamy, El-Sayed Atlam, Shatha Abed Alsaedi, Majed M. Alwateer, Hossam Magdy Balaha, Mahmoud Badawy, Mostafa A. Elhosseini · Bioengineering · 2025

Colorectal cancer (CRC) is one of the most common causes of cancer-related deaths globally, making a timely and reliable diagnosis essential. Manual histopathology assessment, though clinically standard, is prone to observer variability, while existing computational approaches often trade accuracy for interpretability, limiting their clinical utility. This paper introduces a deep learning framework that couples the YOLOv8 architecture for multiclass lesion classification with EigenCAM for transparent model explanations. The pipeline integrates three core stages: (i) acquisition and preprocessing of 5000 hematoxylin-and-eosin-stained slides from the University Medical Center Mannheim, categorized into eight tissue types; (ii) comparative evaluation of five YOLOv8 variants (Nano, Small, Medium, Large, XLarge); and (iii) interpretability through EigenCAM visualizations to highlight discriminative regions driving predictions. Extensive statistical validation (including box plots, empirical cumulative distribution functions, Bland-Altman plots, and pair plots) demonstrated the robustness and reliability of the framework. The YOLOv8 XLarge model achieved 99.38% training accuracy and 96.62% testing accuracy, outperforming recent CNN- and Transformer-based systems (≤95%). This framework establishes a clinically dependable foundation for AI-assisted CRC diagnosis by uniting high precision with visual interpretability. It represents a significant step toward real-world deployment in pathology workflows.

Read the paper · More papers on PaperTik