Cancer prediction models often fail at a new hospital. One reason is that they learn hospital "signatures": scanner settings, coding habits, local triage rules. The standard fix is to penalize the model for encoding which hospital a patient came from. That fix has a hidden cost in oncology. Hospitals differ in which parts of an organ their tumors come from. An Eastern China colorectal cohort was 81.75% left-sided and had a BRAF mutation rate of only 2.30% (Song et al.). Proximal and distal colon tumors have very differently wired biology (Nishihara et al.). So hospital identity partly predicts tumor anatomy, and a penalty that removes everything predictive of hospital also removes the anatomical biology the model most needs.
We propose to remove hospital information from the learned representation only after accounting for where in the organ the tumor sits. Tumor location is treated as a soft probability over anatomical groups rather than a hard category, because many tumors sit on boundaries such as the rectosigmoid junction or are coded as "overlapping sites." In two sentences: penalize the information the representation carries about the hospital given a soft anatomical assignment, so that hospital artifacts are stripped while real differences between tumor locations survive. Then use external cohorts to test whether this beats both no penalty and the usual unconditional penalty, and to measure how much of the external performance drop comes from a shift in anatomical case mix versus hospital artifacts.
Core Claim
Our claim is that, for transporting tumor-risk models across hospitals, the correct invariance target is conditional. The representation $z$ should carry little information about the acquisition site $S$ once the anatomical group $C$ is known, where $C$ is a soft assignment. It should not be forced to be independent of $S$ outright. We write the training objective as
$$ \min_{f,\,g,\,w}\; \mathbb{E}\big[\ell(y, f(z))\big] + \lambda\, I(Z; S \mid C), \qquad z = g(x),\; C \sim w(\cdot \mid a, x). $$
Here $\ell$ is the prediction loss for outcome $y$, $g$ is the encoder, $f$ is the predictor, and $\lambda$ sets the strength of the penalty. $w(k \mid a, x)$ is the probability that a patient with recorded location code $a$ and features $x$ belongs to anatomical group $k$. Using the identity $I(Z;S\mid C) = H(S\mid C) - H(S\mid Z,C)$, the penalty can be estimated with two small site classifiers. One predicts site from $(z, c)$ and the other from $c$ alone, and both conditional entropies are computed under the soft weights $w$.
This choice of estimator is deliberate. LINDA maximizes the mutual information between an agent's latent and its teammates' trajectories using recurrent decoders, and it pays substantial compute for that. Because site is a discrete label, our penalty needs only classifiers.
Two strands of prior work supply the method. The first is information bottlenecks that remove dependence on group identity. MIPI minimizes the information an agent's policy carries about its team configuration, which yields zero-shot transfer to new team compositions. That paper removes identity information unconditionally, in games where no nuisance group is confounded with task-relevant structure. The second strand is soft group membership. PG-DRO replaces hard group indicators with group probabilities to optimize worst-group risk. It reports 90.8% versus 82.8% robust accuracy for hard G-DRO on a synthetic benchmark, and 91.0% worst-group accuracy on Waterbirds. PG-DRO uses soft groups to reweight losses and never regularizes the representation. We use soft groups as the conditioning variable of an invariance penalty, which is a different role. PG-DRO also notes that it depends heavily on the quality of the initial group estimator. That warning constrains our design, and it is why we initialize $w$ from recorded location codes and refine it jointly rather than trusting an external pseudo-labeler.
Research Program
The anatomical assignment model $w$ is a mixture over $K$ groups. Its prior is set by the recorded subsite code. For colorectal cancer we use the SEER-style categories that Chen et al. code as discrete predictors: cecum through rectosigmoid junction, plus overlapping sites. A temperature controls how far tumor features can move a patient's membership away from the code, and we regularize its entropy in the manner of the relaxed assignments in Elastic K-means using posterior probability. To avoid the covariance singularities that affect EM in high dimensions, the mixture operates on a low-dimensional projection of $z$ with diagonal covariances.
The penalty weight $\lambda$ is selected by leave-one-site-out validation within the derivation centers, and the external cohort stays locked. This matters because MIPI documents fragile sensitivity to its trade-off coefficient, and tuning on the external set would repeat the "mirage of internal success" problem that motivates external validation in the first place.
We study two settings. The first is tabular clinicopathological and molecular prediction. The target is synchronous metastasis risk in colorectal cancer, following Chen et al.'s endpoint. Following their own warning about information leakage, we exclude concurrent-metastasis predictors, so we use only Model A-type inputs. The second is imaging radiomics for rectal cancer. We mirror the multicenter mpMRI Ki-67 design of Yao et al., in which site effects are dominated by scanner and protocol.
The file does not index a public multicenter imaging dataset, and a TCGA lookup returned nothing. The real-data arm therefore requires assembling at least three centers with recorded subsite, locked before analysis. The semi-synthetic arm described below requires only one cohort.
Baselines
The naive reference is a pooled model with location one-hot encoded and no site handling, fit as logistic regression and as gradient-boosted trees. It corresponds to Chen et al.'s Model A, which reports an AUC of 0.716 on internal validation and 0.728 in training. There is no reported external-cohort result on Lacuna for this model, since the authors state that they lack one. We rerun it on our splits with the same features. Beating it means higher external AUC and a calibration slope closer to 1 at the held-out center.
For the radiomics arm, the strongest existing pipeline is mRMR plus LASSO feature selection feeding a Radscore nomogram, as in Yao et al. It reports an external AUC of 0.86 and accuracy of 0.85 on 60 patients from a second center. The glioblastoma diffusion pipeline of Park et al. (LASSO, SVM, and SMOTE) reports an external AUC of 0.800. It is the relevant evidence that static mutual-information filtering alone did not transport on contrast-enhanced T1 imaging. We reimplement the Yao pipeline on identical features and splits, with the same hyperparameter search budget as our model. We count a win only if our external AUC exceeds it with a DeLong test at $p<0.05$, or if AUC is equal and calibration is significantly better.
The strongest method-level competitors are PG-DRO run on the same soft anatomical groups and an unconditional site penalty ($\lambda\, I(Z;S)$, the MIPI-style bottleneck and in effect domain-adversarial training). Both receive an identical encoder, compute, and tuning grid.
Three ablations isolate our ingredients. The first uses hard conditioning on the recorded code, which tests whether soft assignment matters. The second uses conditioning on a continuous anatomical coordinate, which tests whether a mixture is needed at all. The third drops the penalty ($\lambda=0$) while keeping the soft groups as input features.
Why not just…?
Why not just penalize site information unconditionally, as domain-adversarial training does? This is the main alternative, and our hypothesis is that it fails in a specific, measurable way. When the site-to-anatomy association is strong, the unconditional penalty should erase subsite-specific signal. The semi-synthetic confounding sweep below tests this directly. If the unconditional penalty matches ours at every confounding level, the conditional idea is wrong and we will report that.
Why not just one-hot encode location, or add distance along the colon as a continuous feature? Encoding location as an input does nothing to stop the representation from also encoding scanner artifacts, so it addresses a different problem. The fairer version of this objection is that soft groups might be unnecessary inside our penalty. The hard-conditioning and continuous-coordinate ablations test exactly that. The PG-DRO results suggest that soft membership helps when groups are ambiguous, but that evidence comes from vision benchmarks, not tumor sites. If hard conditioning performs equally well, we will drop the soft mixture and present the conditional penalty on its own.
Why not just recalibrate locally at each hospital, as All models are local argues? Local recalibration repairs intercept and slope using labeled local data. It cannot restore ranking ability lost to scanner-driven features, and it needs local outcomes that a new site may not yet have. We therefore report external AUC before and after logistic recalibration for every method. If recalibrating the naive model closes the gap, then our method's advantage is only in calibration, and we would say so.
Proposed Experiments and Decisive Checks
The decisive experiment is semi-synthetic. We take one colorectal cohort and split it into pseudo-sites whose proximal/distal mix we control, from balanced to 80/20. We inject site-specific feature perturbations that mimic scanner shifts, and we evaluate on a held-out pseudo-site with a different mix. Because the true artifact is known, we can measure directly whether each method removed it and whether proximal-specific signal survived. For the latter we probe $z$ for MSI and BRAF status, which Nishihara et al. identify as hubs in proximal tumors.
The prediction is as follows. As confounding grows, the unconditional penalty should lose proximal-subgroup AUC and probe accuracy. The conditional penalty should hold both while still driving the site-probe accuracy toward chance. Soft conditioning should beat hard conditioning mainly for tumors coded as rectosigmoid or overlapping.
On real multicenter data, we run leave-one-center-out evaluation. We report AUC, calibration slope and intercept, worst-subsite AUC, and AUC restricted to boundary subsites. We also decompose each external drop by reweighting the external cohort to the derivation cohort's anatomical mix. The part of the drop that disappears after reweighting is case-mix shift; the remainder is attributable to site artifacts. Our method should shrink mainly the remainder.
One known threat is that some site-linked variation is real population biology beyond anatomy, such as the regional BRAF difference. Conditioning only on anatomy would wrongly suppress it. We test this by additionally conditioning on measured molecular markers where they are available, and by checking whether marker-probe accuracy in $z$ is preserved.
References
- Effect of Tumor Location on Clinicopathological and Molecular Markers in Colorectal Cancer in Eastern China Patients: An Analysis of 2,356 Cases
- Biomarker correlation network in colorectal carcinoma by tumor anatomic location
- LINDA: multi-agent local information decomposition for awareness of teammates
- Mutual-Information Regularized Multi-Agent Policy Iteration
- Distributionally Robust Optimization with Probabilistic Group
- Nomogram Development for Predicting Synchronous Lung Metastasis in Patients with T1 Colorectal Cancer: An SEER-Based Analysis
- Elastic K-means using posterior probability
- A novel radiomics based on multi-parametric magnetic resonance imaging for predicting Ki-67 expression in rectal cancer: a multicenter study
- Differentiation of Recurrent Glioblastoma from Radiation Necrosis Using Diffusion Radiomics: Machine Learning Model Development and External Validation
- All models are local: time to replace external validation with recurrent local validation