Scanner-Shared Sparse Front-Ends for Cross-Scanner Segmentation

Medical segmentation networks that work well at one hospital often break at the next. On the AMOS abdominal benchmark, models lose more than 20% mean Dice when tested on MRI from scanners they never saw (AMOS). Much of that loss comes from things that are not anatomy: vendor-specific noise texture, reconstruction artifacts, and intensity quirks. Sparse coding offers a way to separate the two. It represents each image patch as a combination of a few elements, called atoms, from a learned dictionary, and repeated anatomical structure fits that description well while unstructured noise does not. An old line of work also showed that a sparse coder trained without labels makes a good starting point for a convolutional network's first layer (Ranzato et al.).

The plan is to learn the first stage of a 3D segmentation network as a sparse coder on unlabeled volumes pooled across several scanners. A penalty forbids any atom from being used much more by one scanner than by the others, so scanner-specific texture has no atom to live in and is pushed into the discarded residual. We then keep that stage close to its sparse behaviour during supervised training, so the property is not lost as soon as the labels arrive. The question is whether this cuts the cross-scanner gap more than heavy augmentation, a generic self-supervised start, or a fixed wavelet denoiser. The test is direct: does scanner identity become harder to read from the early features while anatomy stays readable?

Core Claim

Unsupervised initialization can fail when most of the variation in the inputs is irrelevant to the task. Bengio et al. call this the "uncooperative distribution" problem (Greedy Layer-Wise Training). In multi-scanner MRI that variation is largely scanner nuisance. We claim that sparsity alone does not solve this. Plain sparse coding will gladly spend atoms on a vendor's characteristic noise texture if that texture is common and has structure. What should work is sparsity combined with a constraint that atom usage be shared across scanners.

Concretely, $x$ is a patch from scanner $s$, $D$ is the dictionary, and $z$ is the patch's sparse code (the few atom weights that reconstruct it). We define $p_s$ as the vector of mean absolute activation of each atom over scanner $s$'s patches, and $\bar p$ as its average over all scanners. We then minimize

$$ \sum_{s}\mathbb{E}_{x\sim s}\Big[\|x-Dz\|_2^2+\lambda\|z\|_1\Big]+\mu\sum_s\|p_s-\bar p\|_2^2 . $$

Here $\lambda$ sets how sparse each code is, and $\mu$ sets how strongly atom usage is equalized across scanners. A fast feed-forward encoder is trained to predict $z$, following Ranzato et al.. This avoids the minutes-per-patch iterative inference that limits Poisson2Sparse. The encoder becomes the first stage of a 3D U-Net.

Relation to Prior Work

Three papers motivate the mechanism. DOLPHIn jointly learns a dictionary and an image from noisy phaseless measurements, and noise is removed because learned atoms cannot synthesize it. Poisson2Sparse unrolls the iterative shrinkage-thresholding algorithm into a network that denoises a single microscopy or perfusion-MRI image without clean targets. Sparse patch prostate segmentation shows that sparse patch libraries of normal anatomy do not reproduce rectal gas artifacts in CT. All three filter one image or one cohort at test time. None of them trains a reusable deep network, and none of them faces scanner shift. We use their premise but move the filtering into learned weights.

Two papers supply the method. Ranzato et al. train a fast sparse encoder on unlabeled patches and use it to initialize a convolutional network, reaching 0.39% MNIST error, but they evaluate only in-distribution 2D digits. Domain-shared group-sparse dictionary learning aligns domains by forcing source and target samples onto shared class sub-dictionaries, reaching 92.38% on Office+Caltech. That method works on fixed pre-extracted features, uses labels to define its groups, and does classification only. Our sharing constraint needs no labels, acts on raw voxels, and shapes the weights of a dense segmentor.

Deep Learners Benefit More from Out-of-Distribution Examples found that denoising-autoencoder pretraining on perturbed data helps transfer across distributions, which supports the idea that unsupervised starts can carry invariance. The uncooperative-distribution warning in Greedy Layer-Wise Training is the reason the sharing penalty exists.

Two results constrain the design. AMOS found a plain 3D U-Net (89.04% mDice on CT) beating Swin-UNetr (86.32%). FeTA 2024 found that augmented nnU-Net variants dominated (FeTA 2024). So we change nothing about the backbone and intervene only at the first stage and its starting weights.

Research Program

Dictionary learning runs on unlabeled 3D patches from the training scanners, separately for each modality. Equalizing atom usage between CT and MRI would be a meaningless constraint, so we never pool them.

One confound matters. Scanners at different centers also image different patients, and some atom-usage differences are genuine anatomy. We therefore measure usage on patches drawn within organ-agnostic body masks, and we sweep $\mu$, reporting the whole trade-off curve rather than a single chosen value.

The learned encoder initializes the first resolution stage of a 3D U-Net. During supervised training we add an anchoring loss: $\beta$ times the sparse-reconstruction-plus-sharing objective, computed on unlabeled source-scanner patches. This keeps the stage from drifting toward whatever source-scanner texture helps the labels.

The main setting is domain generalization: the target scanner contributes nothing at all to training. A secondary, transductive variant adds unlabeled target patches to the sharing term. It is reported separately because it answers a different question.

We also run a mechanism probe at the output of the first stage. One linear probe predicts scanner identity, and a second predicts a coarse organ label for each patch. This is how we tell "filters nuisance" apart from "regularizes generally."

Baselines

The naive reference is a 3D U-Net from random initialization with standard nnU-Net-style augmentation, covering intensity, gamma, elastic and affine transforms. AMOS reports this family at 89.04% mDice on CT in-domain and a drop of more than 20% on unseen MRI scanners (AMOS). It is the strongest competitor in practice, because both AMOS and FeTA 2024 show well-augmented convolutional baselines beating more elaborate architectures. On FeTA's 0.55T low-field set the challenge reports Dice 0.86, HD95 1.69 and Euler characteristic difference (ED) 6.26 for leading methods (FeTA 2024). We will treat those as external reference points, not as numbers to be beaten under different protocols.

The strongest generic alternative is self-supervised pretraining, such as masked-image reconstruction, on exactly the same unlabeled volumes. The file contains no reported result on AMOS or FeTA for this, so we will run it ourselves. A dense, non-sparse autoencoder of matched capacity is a closer cousin and isolates the role of sparsity.

Four ablations isolate the key ingredients:

  1. Sparse initialization with $\mu=0$ removes the scanner-sharing term.
  2. Sparse initialization with $\beta=0$ removes anchoring and tests whether the initialization simply washes out.
  3. A fixed wavelet-shrinkage front-end in the spirit of Johnstone's thresholding tests whether a learned dictionary is needed at all.
  4. Histogram-matching intensity harmonization tests a pure preprocessing fix.

Every method uses the same backbone, the same data splits, the same augmentation, the same number of training epochs, and the same tuning budget of 20 trials per method, selected on a held-out source-scanner validation split. Each configuration runs with 3 seeds.

Beating the augmented baseline means reducing its in-domain-to-unseen-scanner mDice gap on AMOS MRI by at least one third, while keeping in-domain mDice within one point. It must also beat the masked-reconstruction start by a margin outside seed variance.

Why not just…?

Why not just augment harder, as nnU-Net does? This is the real threat. FeTA 2024 shows that augmentation-heavy nnU-Net wins challenges. Yet even there, acquisition site still accounted for roughly 0.075 Dice and image quality for roughly 0.10 (FeTA 2024), and AMOS saw a drop of more than 20% across MRI scanners despite standard augmentation. Augmentation simulates shifts someone thought to model, whereas the sharing penalty removes whatever differs between real scanners. Because our method is trained with the same augmentation on top, the comparison isolates the added value. If the gap does not shrink beyond the augmented baseline, the idea fails, and we will report that.

Why not just use a modern self-supervised pretraining such as masked reconstruction? It uses the same unlabeled data and may well match us on Dice. But it is exactly the objective most exposed to the uncooperative-distribution problem, since reconstructing vendor texture is rewarded (Greedy Layer-Wise Training). The scanner-identity probe is the deciding experiment. If masked pretraining yields equal unseen-scanner Dice and equally low scanner decodability, our specific mechanism adds nothing.

Why not just use a fixed wavelet denoiser or histogram harmonization in front of the network? Both are cheaper, and both are included as ablations. A fixed transform cannot tell structured vendor texture from anatomy, because both can be compressible under wavelets. Histogram matching fixes global intensity but not local reconstruction texture. If either closes as much of the gap, we would conclude that learning is unnecessary.

Proposed Experiments and Decisive Checks

The primary experiment is leave-one-scanner-out on AMOS MRI, using AMOS scanner metadata, or a center-level split if per-scan vendor labels prove incomplete. We report mDice per organ, giving small organs such as the adrenal glands and duodenum separate attention, along with HD95.

The second experiment is FeTA 2024. We train on the KISPI and Vienna data and test on the unseen 0.55T cohort through the challenge's evaluation route, reporting Dice, HD95 and ED. Following FeTA's finding that overlap hides topological failures, ED is treated as a primary metric. We stratify gains by image-quality score to test whether they concentrate on low-quality scans, as the noise-filtering account predicts.

A third, smaller check uses the bSSFP-to-LGE cardiac transfer from Ouyang et al. and asks whether calibration improves without any post-hoc module. We compare against their reported ECE of 15.37% under the same setup.

The decisive mechanistic check combines three requirements. Scanner-identity probe accuracy at the first stage should fall sharply from the random and dense-autoencoder initializations to ours, while organ-probe accuracy holds. That drop should disappear when $\mu=0$, and unseen-scanner Dice should track it across the $\mu$ sweep. If Dice improves but scanner decodability does not fall, the gain is generic regularization and the central claim is wrong. If the $\beta=0$ variant matches the anchored one, initialization alone suffices and anchoring can be dropped.