mTREE: Multi-Level Text-Guided Representation End-to-End Learning for Whole Slide Image Analysis

Quan Liu, Ruining Deng, Can Cui, Tianyuan Yao, Vishwesh Nath, Yucheng Tang, Yuankai HuoarXiv 2024

This paper introduces mTREE (Multi-Level Text-Guided Representation End-to-End Learning), a novel framework that uses clinical text to navigate the "needle-in-a-haystack" problem of analyzing gigapixel Whole Slide Images (WSIs). By aligning textual pathology records with visual features at both global and local scales, mTREE achieves superior performance in cancer grading and survival prediction without requiring manual region annotations from pathologists.

TL;DR

mTREE is an end-to-end multi-modal framework that leverages clinical text to automatically identify and aggregate diagnostic regions within massive, gigapixel pathology images. It eliminates the need for manual region labeling and outperforms traditional multi-instance learning methods by using text as both a spatial guide and a feature filter.

What Problem Does This Paper Address?

In digital pathology, Whole Slide Images (WSIs) are incredibly large—often exceeding 100,000 x 100,000 pixels. Processing these "gigapixel" images in their entirety is computationally prohibitive.

Currently, researchers handle this in two ways:

  1. Manual Annotation: Pathologists manually label regions of interest (ROIs), which is time-consuming and expensive.
  2. Multi-Instance Learning (MIL): The image is broken into thousands of small patches, and models try to aggregate these patches into a slide-level diagnosis. However, these methods often struggle to distinguish diagnostic "hotspots" from irrelevant background tissue without explicit guidance.

The gap mTREE fills is the lack of a seamless, end-to-end process that integrates multi-scale image data with accompanying clinical text. The authors ask: Can we use the descriptive power of clinical records to tell the model where to look and what features are important?

Figure 1. Comparison between multi-instance learning, pathologist diagnosis, and our proposed mTREE. (a) Traditional multi- instance learning needs to process all patches without patch selection. (b) Pathologists in the diagnosis process focus on the most essential patches selected by manual efforts. (c) Our proposed mTREE generates text-guided attention to sample efficiently without manual annota- tion.

Methods

The mTREE pipeline operates through a "global-to-local" and "local-to-global" workflow, guided by a frozen CLIP text encoder.

  1. Global Alignment (Global-to-Local): The model takes a low-resolution version of the WSI (e.g., 5x magnification). It learns an image attention map that is aligned with a text attention map projected from clinical text features. This step essentially uses text to "highlight" likely diagnostic regions across the entire slide.
  2. Sampler: Based on the global attention map, the model selects only the top K high-resolution patches (e.g., at 40x magnification) for further analysis. This drastically reduces the computational load.
  3. Local Alignment (Local-to-Global): The selected high-resolution patches are encoded into features. The model then calculates the cosine similarity between these visual features and the clinical text features.
  4. Aggregation: The final slide-level representation is created by weighting the patch features based on their similarity to the text. This ensures that the most "clinically relevant" patches contribute most to the final prediction.
Figure 2. This figure demonstrates the proposed mTREE pipeline. The upper panel shows the text process flow. The text encoder is frozen with pre-trained weights. Text feature T0 is used for global alignment and alignment of image patch features. The lower panel shows the WSI analytic flow. The attention model learns an attention map from the WSI in low resolution. The attention map aligns with the text feature T0. The image patches tiled up from high-resolution WSI are ranked by attention score. The image features I0, I1...Ik abstracted from image patches with higher attention scores are aggregated with text feature T0.

Datasets

The authors evaluated mTREE using two major datasets from The Cancer Genome Atlas (TCGA):

  • TCGA-KIRC: 519 WSIs of Clear Cell Renal Cell Carcinoma.
  • TCGA-GBMLGG: 1,589 WSIs of Glioma.

These datasets include paired clinical records, which the authors used to curate text prompts related to "survival time" and "cancer grade."

Key Insights and Ideas

  • Text as a Dual-Purpose Tool: Text isn't just a label; in mTREE, it serves as both a spatial attention map (where to look) and a feature conduit (what to prioritize).
  • Efficiency via Sparsity: By using text to select only a few dozen patches (K=10 or 20) out of thousands, mTREE is more efficient than "dense" MIL methods like CLAM, which process every non-background patch.
  • End-to-End Optimization: Unlike multi-stage pipelines, mTREE allows gradients to flow from the final prediction back to the low-resolution attention model. This means the "where to look" part of the model improves as the "what is this" part gets better.
  • Explainability: The model naturally produces heatmaps that show which parts of a slide it found important, providing a "sanity check" for clinicians.
Figure 4. This figure presents the visualization of WSI-level attention and the automatically derived diagnosis patches. For WSIs in the TCGA-KIRC dataset and TCGA-GBMLGG dataset, the attention map (middle panels) is learned from WSI (left panels), highlighting essential tissue regions. Essential image patches (right panels) are selected according to the attention score. The image boundary color indicates the according attention score.

Key Results

mTREE consistently outperformed established baselines, including those that rely on manual annotations.

  • KIRC Grade Classification: mTREE achieved 64.7% accuracy with only 20 patches, significantly beating CLAM (57.5%), which processes over 5,000 patches.
  • Survival Prediction (C-Index): On the KIRC dataset, mTREE reached a C-Index of 65.1, outperforming PathomicFusion (63.1), a multi-modal baseline that uses manually selected regions.
  • Ablation Success: The authors showed that both global and local alignment are necessary; removing either component led to a drop in performance across all tasks.
Table showing mTREE outperforming baselines on the KIRC dataset.

Limitations and Future Work

  • Resolution Gap: The attention map is learned at low resolution (5x) but applied to high resolution (40x). While coordinate mapping works, subtle diagnostic features might be missed at the 5x scale.
  • Text Dependency: The model's performance is tied to the quality and relevance of the clinical text. Future work could explore how the model handles noisy or conflicting textual information.
  • Backbone Exploration: The study uses standard ResNet-50 and CLIP encoders; future iterations could leverage domain-specific foundation models for pathology to further boost accuracy.

Summary updated

BibTeX
@misc{liu2024mtree,
  author = {Quan Liu and Ruining Deng and Can Cui and Tianyuan Yao and Vishwesh Nath and Yucheng Tang and Yuankai Huo},
  title = {{mTREE: Multi-Level Text-Guided Representation End-to-End Learning for Whole Slide Image Analysis}},
  year = {2024},
  eprint = {2405.17824},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2405.17824},
}
Figure