Source-linked AI summary

Current Pathology Foundation Models are unrobust to Medical Center Differences

Edwin D. de Jong, Eric Marcus, Jonas Teuwen

arXiv:2501.18055v2cs.LGcs.AI

TL;DR

The paper asks whether pathology foundation models robustly represent biological information despite medical-center confounders that matter for clinical reliability. It introduces the Robustness Index and evaluates current models through embedding neighborhoods, prediction errors, and visualization. The evaluated models strongly represent medical centers, with only one showing biological information slightly dominating confounding information.

  • Problem

    Pathology foundation models must be robust to medical-center differences because staining and other center-associated variations can bias clinical predictions.

  • Method

    The study introduces the Robustness Index and analyzes foundation-model embeddings, same-center confounders, downstream predictions, and embedding-space visualizations.

  • Results

    All evaluated pathology foundation models represent medical centers strongly, while only one model has a Robustness Index above one; medical-center clustering also exceeds biological clustering in most models.

  • Takeaways & Limitations

    Robustness to medical-center variation should be measured when assessing pathology foundation models for reliable clinical use.

  • Takeaways & Limitations

    The analysis uses patch-level prediction because whole-slide analysis would add a multiple-instance-learning layer that could obscure the link between embeddings and medical centers.

Abstract

from arXiv · show

Pathology Foundation Models (FMs) hold great promise for healthcare. Before they can be used in clinical practice, it is essential to ensure they are robust to variations between medical centers. We measure whether pathology FMs focus on biological features like tissue and cancer type, or on the well known confounding medical center signatures introduced by staining procedure and other differences. We introduce the Robustness Index. This novel robustness metric reflects to what degree biological features dominate confounding features. Ten current publicly available pathology FMs are evaluated. We find that all current pathology foundation models evaluated represent the medical center to a strong degree. Significant differences in the robustness index are observed. Only one model so far has a robustness index greater than one, meaning biological features dominate confounding features, but only slightly. A quantitative approach to measure the influence of medical center differences on FM-based prediction performance is described. We analyze the impact of unrobustness on classification performance of downstream models, and find that cancer-type classification errors are not random, but specifically attributable to same-center confounders: images of other classes from the same medical center. We visualize FM embedding spaces, and find these are more strongly organized by medical centers than by biological factors. As a consequence, the medical center of origin is predicted more accurately than the tissue source and cancer type. The robustness index introduced here is provided with the aim of advancing progress towards clinical adoption of robust and reliable pathology FMs.

1 Introduction

Pathology foundation models may capture clinically useful biological signals, but staining and medical-center differences can bias their representations and predictions. This section introduces a quantitative robustness analysis and finds that evaluated models often organize embeddings more by medical center than by biological factors.

  • Motivation: Staining variations between laboratories can reduce pathology models’ ability to generalize to unseen laboratories.These variations arise from staining procedures, fluids, and imaging equipment.
  • Motivation: Medical-center sensitivity can produce biased evaluations because center-associated staining differences may lead to different diagnoses or treatments.The concern is that technically irrelevant image differences influence patient assessment.
  • Contributions: The Robustness Index measures whether biological features dominate confounding features in the embedding-space neighborhood structure.The metric is intended to distinguish relevant biological information from irrelevant variation such as staining and medical-center differences.
  • Contributions: The study introduces a quantitative approach linking medical-center differences to foundation-model prediction performance through same-center confounders.Same-center confounders are images from the predicted sample’s center that belong to a different class.
  • Findings: Ten current pathology foundation models vary widely in robustness to medical-center variations.The study evaluates robustness as part of assessing whether foundation models capture relevant biological information reliably.
  • Findings: Most evaluated foundation models show clearer embedding-space clustering by medical center than by biological classes.The comparison uses two-dimensional t-SNE projections of model embeddings.

2 Related Work

Prior work identifies medical-center signatures, staining effects, and related robustness problems in pathology representations. These studies motivate measuring and reducing center-related influence in foundation-model embeddings.

  • Medical-center signatures: Earlier work found that DINO-trained ViT embeddings from TCGA clustered by medical center in two-dimensional t-SNE projections.That observation inspired the current study.
  • Robustness-related work: Related studies analyzed pathology batch effects, rotation invariance, stain normalization, and augmentation effects.These studies addressed robustness-related variation in pathology models, including CNN-based classification.
  • Medical-center signatures: Other work examined hospital representation, domain generalization, domain adaptation, and the predictability of acquisition sites from pathology data.These approaches targeted hospital-agnostic representations or reduced staining-related influence.
  • Downstream impact: Unrobust representations can produce biased predictions, while one pathology foundation model was proposed to address clustering by individual whole-slide images.The current evaluation includes that model.
  • Related developments: A newly available study also discussed measuring and optimizing robustness in pathology.It appeared while this paper was being finalized.

3 Robustness for Medical Foundation Models

The paper defines robustness as the relative prominence of biological versus confounding information in foundation-model embedding neighborhoods. Its Robustness Index is the ratio of same-biological-class to same-medical-center neighbors.

  • Conceptual distinction: Biological features reflect the patient’s true condition, whereas confounding features are irrelevant input variations caused by external influences.Examples of confounding variation include staining differences and medical-center differences.
  • Embedding neighborhoods: The embedding-space analysis examines the closest embeddings around each sample to characterize learned neighborhood structure.The analysis compares nearest neighbors by biological class and medical center.
  • Robustness Index: The medical-center Robustness Index is the ratio between total same-biological-class neighbors and total same-medical-center neighbors.Analogous indices can be defined for other biological classes or confounding factors.
  • Robustness Index: The index is computed for a dataset of n samples using k nearest neighbors and an indicator function for class or center matches.In this work, k = 50; y denotes biological classes and c denotes medical centers.
  • Embedding neighborhoods: Cosine distance is used to identify neighbors because cosine similarity is commonly used to evaluate embedding similarity.The same neighborhood information can be summarized across different neighbor indices k.
  • Interpretation: An index of 1 means biological and confounding information are represented equally strongly in the embedding space.A confounder-dominated space has many same-center neighbors and relatively few same-biological-class neighbors.

4 Experimental Setup

The experiments use a multi-center, five-cancer-type TCGA patch dataset to test biological classification and medical-center prediction. Simple k-nearest-neighbor models are used to assess information encoded in foundation-model embeddings.

  • Classification tasks: The study defines cancer-type classification across five TCGA projects: BRCA, COAD, LIHC, LUSC, and STAD.Because each cancer type corresponds one-to-one with a tissue of origin, the task also represents tissue-of-origin classification.
  • Dataset design: The five cancer types are paired with five medical centers so that each cancer type appears across multiple centers and each center contains multiple cancer types.The centers are Asterand, GPCC, ILSBio, IGC, and MSKCC.
  • Dataset design: The TCGA-2k dataset contains 2000 patches sampled from selected whole-slide images across available center–cancer-type combinations.Ten whole-slide images and ten informative foreground patches per available combination were selected, with 5-fold cross-validation used throughout.
  • Classification tasks: Medical-center prediction is evaluated as a control task to measure how strongly foundation-model embeddings encode image origin.This task directly tests center-related information in the representations.
  • Dataset design: Table 1 reports the composition of TCGA-2k using tissue source site, short name, and project-code combinations.
  • Evaluation procedure: The downstream classifier is k-nearest neighbor with k=3 and cosine similarity, minimizing the complexity added beyond the foundation-model embeddings.Default preprocessing and embedding extraction choices are used for each model.

5 Results

Across ten pathology foundation models, embedding neighborhoods and downstream predictions are strongly shaped by medical center differences, although robustness varies substantially. Virchow2 is the only model whose first-neighbor organization slightly favors cancer type over medical center, while classification errors and embedding visualizations otherwise reveal strong center-related confounding.

  • Evaluation: Ten pathology foundation models were evaluated using embeddings, neighborhood structure, prediction accuracy, and medical-center confounding analyses.The analyses covered tissue/cancer-type prediction and medical-center prediction.
  • Embedding Space Structure and Robustness Index: The Robustness Index averages same-cancer-type and same-center neighbor fractions through k = 50, then divides the biological by confounding average.Higher values indicate greater dominance of biological factors in embedding organization.
  • Embedding Space Structure and Robustness Index: 0.74 vs 0.84: Phikon-v2 is less robust than Phikon, whereas 0.93 vs 0.88: Uni2-h is more robust than Uni.These values show substantial variation among models.
  • Embedding Space Structure and Robustness Index: 1.2 vs 0.93: Virchow2 is more robust than Virchow and every other model, and is the only model above one.For Virchow2, cancer type dominates medical-center information among the first 50 neighbors, with the cancer-type curve remaining higher beyond 100 neighbors.
  • Quantification of Medical Center Influence: All models show medical-center sensitivity: incorrectly predicted nearest neighbors are more likely to share the sample’s center, sometimes extremely so.For Phikon-v2, same-center confounders comprise more than 95% of closest neighbors from the incorrectly predicted class.
  • Visualization and Prediction Performance: Medical-center clustering is generally clearer than cancer-type clustering in t-SNE embeddings, and several models predict medical center with very high accuracy.EXAONEPath, Phikon, and Phikon-v2 reach cross-validated medical-center accuracies of 0.987, 0.987, and 0.993 with logistic regression.
  • Relation between Prediction Performance and Robustness: With full-embedding kNN, Virchow2 is the only model whose cancer-type prediction exceeds medical-center prediction, indicating a closer relation between biological performance and robustness.Full-embedding kNN reduces both prediction accuracies relative to logistic regression and produces greater variation across models.

6 Methods

The methods compare embedding-based predictions of cancer type and medical center, using full or t-SNE-reduced embeddings, and relate classification errors to center-related errors.

  • Patch preparation: Patch extraction uses 512x512 patches at the highest available resolution, downscaled by a factor of 2 to 256x256.At a typical 40X source resolution, this corresponds to a typical 20X resolution patch.
  • Embedding visualization: The embedding visualizations show breast-cancer representations colored by medical center for Phikon, Phikon-v2, and Hibou-B.These figures provide model-specific views of center organization in the embedding space.
  • Prediction analysis: Full embeddings are evaluated with k-nearest neighbors and logistic regression for cancer-type and medical-center prediction.The comparison is visualized for both full embedding vectors and 2D t-SNE coordinates.
  • Error analysis: The analysis relates logistic-regression errors to medical-center k-nearest-neighbor errors.Samples frequently misclassified by center-based k-nearest neighbors are also more frequently misclassified by logistic regression.

7 Discussion

The discussion frames medical-center information as a clinical robustness concern, while emphasizing that patch-level analysis directly links foundation-model embeddings to center-related classification effects.

  • Patch-level versus WSI-level prediction: Patch-level classification may not achieve perfect accuracy because some patches lack enough information about tissue or cancer type.WSI-level prediction may achieve higher accuracy, but would add a multiple-instance-learning layer between embeddings and outputs.
  • Patch-level versus WSI-level prediction: The patch-level approach is used because it most directly links foundation-model embeddings to medical centers without an additional WSI-level modeling layer.The authors state that a WSI-level approach could obfuscate the relation under analysis.
  • Post-hoc correction: Removing medical-center influence post hoc may be difficult because center-related dimensions may not be orthogonal to biological information.Patient cohorts can differ between medical centers, creating correlations between center and medically relevant properties.
  • Generalization: Cancer-type prediction performance appears correlated with medical-center prediction, making generalization to unseen centers questionable.The discussion raises whether high cancer-type accuracy relies on confounding center features.
  • Clinical implications: Medical AI practitioners are urged to measure and reduce medical-center biases insofar as these may affect diagnosis, treatment options, and outcomes.The discussion places this responsibility in the context of clinical consequences.

8 Conclusion

The conclusion finds substantial medical-center representation across evaluated pathology foundation models, with robustness varying significantly and embedding organization favoring center over biological factors.

  • Robustness Index: Virchow2 is the only evaluated model with a Robustness Index above one at k = 50, meaning cancer-type information dominates medical-center information across its nearest neighbors.Uni2-h and Virchow2 are identified as the most robust models.
  • Embedding structure: Embedding distance correlates with both same-cancer-type and same-medical-center neighbors across the entire embedding space.The influence is reported as extending beyond local neighborhoods.
  • Medical-center influence: All evaluated pathology foundation models represent medical centers to a large extent.The conclusion bases this assessment on same-center confounder analysis.
  • Embedding structure: Two-dimensional embedding visualizations show stronger clustering by medical center than by tissue or cancer type.The visual organization therefore reflects center-related structure more strongly than the cited biological classes.
  • Implications: The Robustness Index and related analyses are intended to support development of more robust pathology foundation models.The stated aim is to advance tools for improving model robustness.

9 Appendix

The appendix describes the evaluated model set, embedding-generation conventions, and figures comparing biological predictions, medical-center predictions, and neighborhood organization by robustness.

  • 9 Appendix: Ten publicly available pathology foundation models and SRA MoCo v3 were selected for evaluation, with SRA MoCo v3 included despite not being a foundation model.SRA MoCo v3 was trained on a small single-tissue dataset and intended to provide a more robust model.
  • 9 Appendix: Virchow and Virchow2 use 2560-dimensional embeddings formed by concatenating averaged patch tokens with the class token, alongside 1280-dimensional class-token variants.The variants test whether expanding the embedding space affects performance.
  • 9 Appendix: Figure 11 compares tissue-or-origin/cancer-type accuracy, medical-center prediction accuracy, and the fraction of same-center confounders across models.All models show a substantial and significant influence of same-center confounders.
  • 9 Appendix: Figure 12 compares the fractions of same-cancer-type and same-medical-center k-th neighbors, with models ordered by increasing robustness.The figure contrasts biological and medical-center similarity as neighborhood rank changes.

10 Online resources

The authors intend to release the patch dataset online and are preparing an extended version of the work with related simultaneous research.

  • 10 Online resources: The patch dataset constructed and used in this work is intended to be made available online.The passage states an intention rather than a completed release.
  • 10 Online resources: An extended version of the work is in preparation.
  • 10 Online resources: The planned extended version will combine this work with related simultaneous research from the TU Berlin BIFOLD group and Aignostics.
Loading 2501.18055v2…