3D ViewerRanking tableProxy metricsDistributionsData & downloads

Distance Map Auxiliary Loss for Brain Tumor Segmentation

A Fragment-Centric Analysis and the Saturation Ceiling of Post-hoc Connected-Component Consensus Filtering

Guillaume Cassez · ORCID 0009-0007-0987-3931 ·  2026

BraTS 2023 GLInnU-Net v2MedNeXt-B1196 patients5-fold CV
📄 Download PDF📥 arXiv (pending)💻 Code + data (GitHub)🇫🇷 HAL🔗 Zenodo DOI

Abstract

We study the use of a Signed Distance Transform (SDT) auxiliary loss on top of MedNeXt-B / nnU-Net v2 for 3D brain tumor segmentation on BraTS 2023 GLI. The SDT task brings a modest but statistically robust Dice improvement (+0.63 to +0.96 pp per region, Wilcoxon p < 10⁻⁶, n = 240) while introducing a new failure mode: spurious isolated connected components (fragments) not present in the ground truth, most acute in NCR and ED.

We propose a parameter-free post-hoc connected-component consensus filter (CC-consensus filter) : start from the DistMap prediction and, for each class, drop any connected component whose same-class mask has zero voxel overlap with the Baseline prediction. This rule is not a Mixture-of-Experts in the strict gating-network sense ; it is a hard-label consensus filter at the connected-component level. It reduces NCR fragments by 81 % (Wilcoxon p = 7 × 10⁻⁴) at no Dice cost.

A large-scale ceiling analysis on 1196 patients shows that the oracle per-class selection upper-bound is only +0.005 Dice avg above the default CC-consensus rule; 4 classifier families trained on 31 hand-crafted features (tumor morphology, topology, inter-model agreement) fail to robustly beat the default CC-consensus in 5-fold cross-validation. The gap cannot be closed without voxel-level probabilistic voting or architectural diversity — motivating a training-time fragment-aware loss over further post-hoc engineering.

Interactive 3D viewer

The viewer lets you explore every prediction (Baseline / DistMap / CC-Consensus / Ground Truth) on any of the 1196 patients. Six patients (C1–C6) are pinned at the top of the patient dropdown — each one illustrates a distinct ordering between the three outputs. Start there.

Tip — open the Patient dropdown and pick one of the ★ Research report 1 demo entries to see the C1–C6 case.

Headline results

1. DistMap auxiliary improves Dice on all 3 regions

VariantEpochsAvg DiceWTTCET
MedNeXt-B Baseline100.86380.8940.8690.829
MedNeXt-B + DistMap100.87130.90.8750.838
nnU-Net + DistMap100.86840.9030.8760.827

Per-region paired Wilcoxon (MedNeXt-B + DistMap vs Baseline, n = 240): WT p = 1.1×10⁻⁶, TC p = 7.9×10⁻⁷, ET p = 9.3×10⁻¹⁶. Largest gain on ET.

2. DistMap introduces fragments — the CC-consensus filter removes them

Fragments (CC ≤ 50 vx)BaselineDistMapCC-ConsensusΔ CC-Cons. vs DistMap
NCR116179.434.8−81 %
ED33.24919.2−61 %
ET0.81.80.8−56 %
Dice avg0.950.9490.948−0.04 pp (ns)

Wilcoxon paired fragments (CC-Consensus < DistMap): p = 7 × 10⁻⁴. Dice insensitive to these small CCs.

3. Cross-validated ceiling (1196 patients)

StrategyDice avgΔ vs CC-consensus
Baseline only0.9078−0.00115
DistMap only0.9088−0.00020
CC-Consensus (default rule)0.9090 (ref)
Oracle patient-level (best-of-3)0.9131+0.00412
Oracle per-class (best-per-region)0.9139+0.00494
Best 1-feature rule — fit on all data0.91016+0.00119 (overfit)
Best 1-feature rule — 5-fold CV0.90801−0.00096
Meta-RF 31 features per-region (CV)0.90807−0.00090
Meta-LR 31 features per-region (CV)0.90844−0.00053
Meta-GBM 31 features per-region (CV)0.90833−0.00064

4. Case distribution — the CC-consensus filter is asymmetric

Case (F = CC-consensus output vs B, D)n%
C1 — baseline beats distmap60250.3 %
C2 — distmap beats baseline59349.6 %
C3 — B < F < D (filter pulled baseline-side)39032.6 %
C4 — D < F < B (filter pulled distmap-side)16914.1 %
C5 — filter worst (F < min(B, D))46338.7 %
C6 — filter best (F > max(B, D))15713.1 %
The CC-consensus filter damages the patient-level score in 38.7 % of cases against only 13.1 % of synergy — a ~3:1 asymmetry. Per-region: the filter wins strictly only 2.7 % on WT, 21.7 % on TC, 6.9 % on ET (38 % ET ties from empty / trivial GT). The filter benefit is concentrated on TC.

The six demonstration patients (★ in the viewer)

CasePatient IDFoldBDFTake-away
C1 — B > D00048-00110.9830.3080.973DistMap hallucinates TC/ET on an oedema-only case
C2 — D > B01437-00020.5890.9230.923DistMap rescues an under-segmenting Baseline
C3 — B < F < D01428-00010.6180.6560.645Filter output sits between, pulled baseline-side
C4 — D < F < B00017-00100.9910.6570.89Filter output rescues DistMap via consensus
C5 — F < min(B, D)01530-00010.2410.5410.169Filter deletes a legitimate large DistMap CC
C6 — F > max(B, D)00540-00010.7850.7950.869Clean synergy

→ Open the viewer and pick any of these in the ★ Research report 1 demo group of the Patient dropdown.

Try the CC-consensus filter on your own predictions

The rule is parameter-free (only 26-connectivity). Plug your own two segmentation arrays (DistMap + Baseline, both label maps in {0, 1, 2, 3}) :

import numpy as np
from scipy import ndimage as ndi

STRUCT_26 = ndi.generate_binary_structure(3, 3)

def cc_consensus_filter(distmap_seg, baseline_seg, classes=(1, 2, 3)):
    """Connected-component consensus filter.
    Start from DistMap; for each class, drop any CC whose same-class mask has
    zero voxel overlap with Baseline. Parameter-free (26-connectivity)."""
    filtered = distmap_seg.copy()
    for c in classes:
        d_mask = (distmap_seg == c); b_mask = (baseline_seg == c)
        if not d_mask.any(): continue
        lab, n = ndi.label(d_mask, structure=STRUCT_26)
        for cc_id in range(1, n + 1):
            cc = (lab == cc_id)
            if not np.any(cc & b_mask):
                filtered[cc] = 0  # unconfirmed fragment
    return filtered

Reproducibility

All numbers in this paper are reproducible from the GitHub repo in under 10 min on a modern CPU.

Cite

@article{cassez2026ccconsensus,
  title   = {Distance Map Auxiliary Loss for Brain Tumor Segmentation:
             A Fragment-Centric Analysis and the Saturation Ceiling of
             Post-hoc Connected-Component Consensus Filtering},
  author  = {Cassez, Guillaume},
  journal = {arXiv preprint},
  year    = {2026},
  url     = {https://guillaume-cassez.fr/brats/paper1/},
  doi     = {10.5281/zenodo.19695264}
}

Links

Feedback welcome at cassez.guillaume@gmail.com, via the GitHub issues, or on Bluesky @guillaume-cassez.bsky.social.