When an expert annotates a blood vessel, a nerve canal or a retinal capillary, the natural cheap gesture is a quick stroke along the middle of the structure, not a careful trace of its outline. This proposal starts from a simple observation. Such a stroke already tells us that every point on it belongs to one connected piece of foreground, and a background scribble tells us that no foreground path should reach it. Both are statements about topology, the connectivity pattern of the structure, and neither requires a dense mask. We propose to turn them directly into a training loss on the network's continuous probability map. The loss asks that the strongest path between two points on the same stroke never drops below a confidence level $\tau$, and that the strongest path from a foreground stroke to a background scribble never rises above it. Because the gradient of such a path constraint lands on the single weakest or strongest voxel along the path, it pushes the model exactly at the faint gap where a vessel fades in low contrast, or at the thin bridge where the prediction leaks into surrounding tissue.
This matters because the methods that keep thin structures connected all assume the expensive annotation that scribbles are meant to avoid, while the methods that work from scribbles ignore connectivity and were tested only on bulky organs. A loss that gets topological supervision from strokes, works on soft maps instead of thresholded masks, and scales to 3D volumes would let experts annotate vessel trees in minutes and still train models whose outputs survive downstream graph extraction.
Core Claim
For tubular structures, the information topology losses need can be supplied by centerline scribbles plus background scribbles. It does not require a full mask. It can be enforced as a differentiable, spatially anchored constraint on the continuous likelihood map. We claim that this anchored connectivity loss, trained end to end, reduces fragmentation on faint segments better than the two-stage alternative: propagate scribbles into pseudo-masks, then apply a mask-based topology loss. The alternative fails because pseudo-label propagation either stops at low-contrast gaps or bleeds past them, and the topology loss then faithfully enforces the wrong connectivity.
Where the Gap Sits
The topology-preserving losses that constrain this design are clDice, TopoMatch and cbDice. clDice extracts soft skeletons by iterated min/max pooling. It scores "topology sensitivity" (does the true skeleton lie inside the prediction) and "topology precision" (does the predicted skeleton lie inside the true mask). TopoMatch matches persistence features through a joint comparison image. It shows that unanchored barcode matching pairs up to 99.4% of features at the wrong locations, but it costs $O(n^3)$ in the number of pixels. cbDice adds boundary distance and inverse-radius weighting so thin vessels are not drowned out by thick ones. All three need the dense ground-truth mask $G$.
The scribble side supplies the training recipe we compare against. Learning to Segment Medical Images with Scribble-Supervision Alone expands scribbles with random walks and a conditional random field (a pixel-affinity model that spreads labels along intensity similarity). It filters the results with Monte Carlo dropout uncertainty, and gets within 2.9 Dice points of full supervision on cardiac MRI. That work evaluated only bulky structures and used no connectivity term.
Two further results motivate operating on soft maps. Content-aware adaptive tracing on CNN probability maps shows that continuous probability maps preserve weak signal across staining breaks that binarization destroys, but its gap-jumping is a heuristic applied after training. The scribble-only reading of clDice is half-implicit already: the sensitivity term needs only the true skeleton, which a centerline stroke partially provides. It is the precision term, and connectivity beyond the stroke, that need something new.
Research Program
Let $p(v)\in[0,1]$ be the network's foreground probability at voxel $v$. For two voxels $a,b$, define the maximin path strength
$$s(a,b) = \max_{\pi: a \to b} \; \min_{v \in \pi} p(v),$$
the confidence of the strongest path between them. In words, $s(a,b)$ is the highest threshold at which $a$ and $b$ would still be in the same connected component. It is therefore the 0-dimensional persistent homology of the superlevel-set filtration, read at two specific annotated locations. All pairwise values are obtained from one maximum spanning tree over the voxel grid, with each edge weighted by the smaller of its two endpoint probabilities. This costs $O(n \log n)$ instead of $O(n^3)$, which makes 3D patches practical.
Let $\mathcal{P}^+$ be pairs of points sampled along the same foreground stroke, optionally extended by cheap "these two strokes join" clicks. Let $\mathcal{P}^-$ be pairs linking a foreground stroke point to a background scribble point. The anchored connectivity loss is
$$L_{\text{conn}} = \sum_{(a,b)\in\mathcal{P}^+} \big[\tau + m - s(a,b)\big]_+ \; + \sum_{(a,c)\in\mathcal{P}^-} \big[s(a,c) - \tau + m\big]_+ ,$$
with margin $m$. The subgradient of $s$ flows only to the bottleneck voxel of the optimal path. Positive pairs therefore raise the faintest voxel along an annotated vessel, and negative pairs lower the single voxel through which foreground leaks toward annotated background.
Because pairs are tied to annotated locations, the loss cannot suffer the location mismatch TopoMatch identified. Because the constraint is posed at $\tau$, any bridge it creates survives thresholding at $\tau$. This addresses the known weakness that soft maps lose low-magnitude bridges at decision time.
The full objective adds three terms to $L_{\text{conn}}$. The first is partial cross-entropy on scribbled voxels. The second is the clDice sensitivity term computed with the strokes as the reference skeleton. The third is a weak, uncertainty-gated soft target near strokes in place of hard pseudo-masks. No conditional random field and no dense pseudo-label is used, so boundaries in low-contrast regions stay soft rather than being forced to a leaky binary edge.
We will also study pair sampling: uniform along strokes versus concentrated across low-contrast stretches. We will study whether annotator "join" clicks buy more topology per second of expert time than additional strokes do.
Baselines
The naive reference is a 3D nnU-Net style network trained with partial cross-entropy on scribbled voxels only. It uses identical architecture, patch size, augmentation, epoch budget and scribbles. It sets the floor for how much fragmentation scribbles produce without any propagation or topology term.
The established scribble method is the iterative random-walk, conditional-random-field and Monte Carlo dropout pipeline of Learning to Segment Medical Images with Scribble-Supervision Alone. We will reimplement it on the same backbone with its hyperparameters tuned on the same validation scribbles we use for our own. The file reports 88.0% Dice on ACDC and 78.1% on NCI-ISBI prostate for this method, but no reported result was found on Lacuna for it on any tubular benchmark. We will therefore establish its vessel numbers ourselves.
The strongest competitor, and the one this proposal must beat, is a two-stage pipeline: take that method's final pseudo-masks and train a fresh network with Dice plus cbDice using the public cbDice code. This is the obvious composition of existing tools, and it gets dense-mask topology supervision for free once pseudo-masks exist. It receives the same total GPU budget as our method, counting both stages, and an equal hyperparameter search.
A second strong competitor for partial-label vessel data is Study Group Learning. It trains $K$ out-of-fold models and distills their consensus, and it reports an AUC of 0.9857 on DRIVE with 50% of vessel labels erased (K=8). We will run its released code on our scribble-derived partial labels with matched total compute, which means fewer epochs per member.
For the zero-annotation end we will use CaPro. It reports 58.68% mIoU and 64.23% F1 on OCTA-500 (6M) and 64.33% mIoU on OCT1600, which shows what is achievable with no expert input at all.
The ceiling is full-mask supervision with cbDice. For orientation, published full-supervision numbers include cbDice at 43.4% Dice on TopCoW communicating arteries and the mandibular canal transformer with clDice at 0.844 Dice.
Ablations isolate the key ingredient. We will drop the negative pairs, drop the positive pairs, and replace $L_{\text{conn}}$ with only the scribble-referenced clDice sensitivity term. That last variant tests whether path-level constraints add anything beyond "cover the stroke". A final ablation applies the same loss to thresholded instead of soft predictions.
Beating the strongest baseline means two things. First, a statistically significant reduction in Betti-0 error and in held-out branch disconnection rate, across seeds, on at least three of the benchmarks. Second, Dice within one point of the two-stage pipeline.
Why not just…?
Why not just propagate scribbles into pseudo-masks and train with cbDice? This is the real threat, and the experiments are built around it. Our expectation of failure comes from the file's own record. Propagation by conditional random fields follows intensity gradients and leaks at low-contrast edges, and the scribble pipeline needed uncertainty masking just to avoid reinforcing hallucinations even on bulky organs. If uncertainty masking deletes faint vessel segments from the pseudo-mask, cbDice then actively rewards the break. The decisive measurement is fragmentation stratified by local contrast. If the two-stage pipeline matches us in the lowest-contrast bins, the anchored loss is not justified and we will report that.
Why not just treat scribbles as partially erased labels and use Study Group Learning? That method is robust to missing vessel labels, but it was evaluated by AUC rather than by connectivity. It also multiplies training cost by $K$, and thin vessels still degrade at high erasure rates. The matched-compute comparison on Betti error and held-out branch connectivity will settle whether consensus distillation already recovers topology without explicit path constraints.
Why not just use clDice's sensitivity term with strokes as the skeleton? It is the simplest scribble-compatible topology loss and is included as an ablation. It rewards covering the stroke voxels themselves, but it says nothing about leakage toward background or about connectivity off the stroke. If it matches the full loss, the maximin machinery is unnecessary.
Why not just prompt a foundation model and skip training? Vanilla SAM reaches only 3.30% F1 on OCTA-500 (6M) according to CaPro. CaPro's repair relies on 2D handwritten-digit shape priors with no obvious extension to 3D branching trees. We include CaPro on the 2D benchmarks to quantify what a few minutes of expert strokes buy over zero annotation.
Proposed Experiments
We will use 2D benchmarks (DRIVE, CHASE_DB1, OCTA-500) and 3D benchmarks (TopCoW, IRCAD, Parse 2022, and the ToothFairy mandibular canal set). Scribbles are simulated from dense masks: skeletonize the ground truth, keep a random fraction of branches as jittered strokes, and sample background strokes from tissue at a controlled distance from the vessel. ToothFairy's natively sparse annotations, 290 volumes, serve as a non-simulated check that our simulator is not flattering the method.
Metrics are Dice, clDice, HD95, Betti-0 and Betti-1 errors, and two connectivity measures computed over a threshold sweep. The first is the held-out branch disconnection rate on vessels never scribbled. The second is the leakage rate into annotated-background regions. All are additionally stratified by local vessel-to-background contrast.
The decisive checks are three. First, on unscribbled branches, does the anchored loss reduce disconnection relative to pseudo-mask plus cbDice, especially in the lowest-contrast bins? Second, are Betti errors stable across thresholds, as the $\tau$-margin construction predicts, or do they collapse away from $\tau$? Third, on the annotation-budget curve, which plots each metric against simulated expert seconds, how much stroke coverage is needed to approach full-mask cbDice? A complementary timing study with two annotators on ten ToothFairy volumes will convert the simulated budgets into real minutes.
References
- clDice - A Novel Topology-Preserving Loss Function for Tubular Structure Segmentation
- Topologically Faithful Image Segmentation via Induced Matching of Persistence Barcodes
- Centerline Boundary Dice Loss for Vascular Segmentation
- Learning to Segment Medical Images with Scribble-Supervision Alone
- Automated Neuron Tracing Using Content-Aware Adaptive Voxel Scooping on CNN Predicted Probability Map
- Study Group Learning: Improving Retinal Vessel Segmentation Trained with Noisy Labels
- CaPro: Curvilinear-aware Prompt Learning with Single Unlabeled Image for Cost-effective Curvilinear Structure Segmentation
- Automatic segmentation of mandibular canal using transformer based neural networks