Manuscript Offprint
arXiv:2610.39880What Survives Label Downsampling? Exact Region Survival for Coarse Segmentation Targets
Zhiyuan Zhang Yukun Ou San Tek Choi
East China Jiaotong University Imperial College London University of Macau
*Equal contribution. Correspondence: 2025028081100018@ecjtu.edu.cn
a

b
Image with labels
29 nuclei
MatchDown (ours): built once, before training
lost or missed nucleus
certificate cell (Thm. 4)
nucleus
coarse cell
support edge
matched cell
Figure 1. Overview. One held-out BBBC039 crop (192×288 pixels, 29 nuclei), downsampled by a factor of 16 and chosen because majority pooling loses many of its nuclei (10.1% of all BBBC039 nuclei at this factor). (a) The image with its labels; the dashed square is the 5×5-cell window shown in (c). (b) Majority pooling gives each cell the label that covers most of its pixels, so a nucleus that is not the majority in any cell is missing from the target. Here 21 nuclei are missing (outlined), and the affinity head trained on this target misses 14 (seed 0, default thresholds). (c) MatchDown on the window: the label map on the grid; the support graph linking each nucleus to every cell it overlaps (Theorem 1); the minimum-cost matching (filled cells, Theorem 3), in which two nuclei share only the top-left cell, so one of them must be lost and that cell (dashed) certifies the loss (Theorem 4); and the resulting target, which loses exactly that nucleus. (d) The MatchDown-P target of the whole crop loses one nucleus, and the head trained on it misses 3.
Abstract
Segmentation networks that predict at an output stride are trained against label maps downsampled by strided sampling, nearest-neighbor resampling or majority pooling. These methods label each coarse grid cell on its own, so a region that wins no cell is absent from the target and receives no positive label. We present MatchDown, which builds the coarse target from a minimum-cost matching between regions and the grid cells they occupy. It keeps as many regions as any one-region-per-cell target can, certifies how many losses are unavoidable, and with priority tiers (MatchDown-P) keeps every evaluated region (a region that a metric scores) of at least one cell's area. On COCO, Cityscapes and BBBC038 at factors 2 to 16, MatchDown-P loses exactly the minimum number of regions, whereas the downsampling used by StarDist, nnU-Net and connectomics pyramids loses four to five times as many on COCO at factor 8. Keeping a region in the target and reconstructing its shape are different problems: we show that no region lost by majority pooling can be reconstructed above IoU 0.5 by upsampling any coarse target, yet on BBBC038 a star-convex head trained on MatchDown targets segments 35% of the nuclei that majority pooling loses above IoU 0.5, against 15% when trained on majority targets and 24% on StarDist's strided target. On two nucleus datasets, with thresholds cross-validated for count error, this head has instance accuracy at IoU 0.5 (Acc ) 2.6 to 4.2 points above the strided target and at most 2.8 points below cell-center sampling, and a lower count error than the strided and cell-center targets on BBBC039. On BBBC039, an affinity head, which outputs one label per cell, lowers count error relative to majority targets by 9.3 nuclei per image at 7.2 points lower Acc . MatchDown runs once, before training, in place of the label-downsampling step.
1. Introduction
Many segmentation networks learn from labels at a coarser resolution than the image. Grid-based object heads such as StarDist build their target by sampling the label map with a stride, lbl[::f, ::f] [48], and nnU-Net v2 resamples the labels of its deep-supervision heads with nearest-exact interpolation [15, 28]. DeepLab subsampled its ground truth by 8 [8], and connectomics pyramids pool labels per level with the mode [49]. Each of these methods labels every coarse grid cell independently of the others, so a region that is not selected in any cell it touches is missing from the target (Fig. 1). These losses are not limited to tiny regions: at factor 8, the standard methods lose 150 to 195 regions of a cell or more on 1,000 COCO panoptic images, and majority pooling loses 8.8% of the nuclei of BBBC038 (Sec. 4.2).
For some heads the coarse target cannot be avoided. Grid-based instance heads such as StarDist, CenterNet and SOLO assign one object to each output cell [48, 53, 57], StarDist's 3D models predict on a subsampled grid to fit volumes in memory [54], deep supervision needs a label at every scale [28], and label pyramids are built once and reused [49]. Patch-token heads of vision transformers [16, 42] face the same choice whenever their loss is computed on the token grid rather than after upsampling. A region missing from the coarse target receives no positive label in that image; a network may still find it by generalizing from other images, but it is not trained to.
A coarse target faces two separate limits: whether a region is assigned a cell at all, and how well whole cells reproduce its shape. A nucleus inside an cell of background is lost by majority pooling; kept, its whole-cell mask reaches an IoU of only 4/64. Both fail an IoU-0.5 test, but only the kept nucleus gives a shape-predicting head a cell from which to regress its outline. Small size alone does not force a loss: tiny regions survive whenever enough distinct cells are available, whereas of k regions that lie inside a single cell and touch no other, at most one can be kept. Keeping every region is therefore not always possible, because several regions can compete for the same few cells. Soft-label downsampling [1] keeps the class proportions of each cell but does not specify which regions are kept. Greedy rescue recovers about half of the lost regions on COCO and nearly all lost nuclei, but it has no guarantee and can keep as few as of regions (Sec. 3.7). Chen and Peng's topology-preserving integer program [7] handles binary masks and can be infeasible. None of these methods determines how many regions can be kept on a given grid, which losses are unavoidable, or which target attains the maximum.
We answer these questions with MatchDown (matching-based downsampling), which builds coarse targets from the support graph between regions and the grid cells that contain them (Fig. 1c). With priority tiers (MatchDown-P), it keeps every evaluated region of at least one cell's area and loses only the minimum number of evaluated regions. Our analysis has three parts. Exact survival: the sets of regions that can be kept together are the independent sets of a transversal matroid, and every region of at least one cell's area can be kept, because k such regions touch at least k cells. A single minimum-cost matching attains the maximum with the least pixel disagreement. Lower bound and certificates: every unavoidable loss is certified by a cluster of k regions that share fewer than k cells. Costs: a coverage threshold admits the same exact count, a per-region bound limits the IoU that any coarse target can reach (no region that majority pooling loses can exceed IoU 0.5), and a constrained repair removes some of the spurious adjacencies that keeping more regions introduces. We build on classical results [17, 18, 25] and solve with standard minimum-cost matching [29]; our contribution is the formulation and its guarantees.
On COCO, Cityscapes and BBBC038 at factors 2 to 16, MatchDown-P loses exactly the minimum number of evaluated regions and none of a cell or more, while the standard methods lose four to five times the minimum on COCO at factor 8 (Fig. 2). The kept regions are reconstructed coarsely: on COCO-R at factor 8, the share of reachable regions reconstructed at IoU 0.5 falls from 98.4% for majority pooling to 89.5% (Tab. 1), and none of the regions that majority pooling loses can be reconstructed above IoU 0.5 by upsampling any coarse target (Proposition 5). The kept regions still help a shape-predicting head: trained on MatchDown targets, a star-convex head segments 35% of the BBBC038 nuclei missing from the majority target above IoU 0.5, against 15% on majority targets and 24% on StarDist's strided target. With cross-validated thresholds it has the lowest count error of the targets in Tab. 2, with 2.6 to 4.2 points above the strided target and at most 2.8 below cell-center sampling; on BBBC038 the strided head has the lower count error when the NMS range is extended to 0.1 (Tab. S13). On BBBC039 at factor 16, an affinity head, which outputs one label per cell, detects 30% of the nuclei missing from the majority target, against 3% for the head trained on that target, and lowers count error by 9.3 nuclei per image at 7.2 points lower . On BBBC038 at factor 8, greedy rescue and a full-resolution loss match MatchDown's count reduction, the latter at higher ; building a MatchDown target takes 1.7 to 1.9 times as long as majority pooling.
Our contributions are summarized as follows:
• Exact region survival on a fixed coarse grid: a matching formulation of label downsampling with maximum-survival targets at minimum disagreement, loss certificates and the one-cell guarantee.
• Assignment versus reconstruction: a per-region IoU bound that no region lost by majority pooling can exceed, and evidence that a shape-predicting head recovers such regions beyond it.
• A label-level evaluation and training results against the downsampling of StarDist, nnU-Net and connectomics pyramids, with two heads on two nucleus datasets. Code and all coarse targets will be released.
Soft and full-resolution targets. Soft-label downsampling replaces the hard coarse label by the class proportions of each cell [1]. Soft labels keep class information that a hard argmax discards, but they do not distinguish two regions of the same class or specify which regions remain represented. We produce hard, region-valued targets with a guarantee on which regions are kept, and Sec. 4.6 trains both kinds on the same images.
Topology-preserving downsampling and representations. Chen and Peng [7] downsample binary images with an integer program. Whenever the program is feasible, it keeps every component and the region adjacency graph, and hence and . Its constraints give every component a cell of its own, so it is infeasible whenever Hall's condition fails on its support graph; our reimplementation returns no solution in 22 of 300 cases (21 infeasible, one time-out), four of them for this reason (Appendix D). We address partitions with many labels and always return a labeling, but we guarantee less: maximum survival, and a repair that never increases the number of coarse components of a region; we guarantee neither holes nor exact adjacency (Sec. 3.7). SEMIR [39] and topology-preserving transformations [13, 41, 45] change the lattice or preserve topology under resampling, without an objective on which regions are kept; we keep the regular coarse grid that standard networks predict on.
Assignment to grid cells. Matching regions to cells appears in grid-map layout [20], where regions may be placed in any cell rather than only in cells they occupy. Our survival theorems apply Hall's theorem, the transversal-matroid theorem and the Dulmage–Mendelsohn decomposition [17, 18, 25, 27, 31, 37, 43, 44] to the support graph of a downsampling, and we solve the resulting problems with standard minimum-cost matching algorithms [11, 29, 32, 40].
3. Exact Region Survival
MatchDown takes three inputs: a label map, the factor f at which the loss is computed, and the labels that a metric scores. It returns the coarse target that the loss is computed against, together with a certificate for the regions that no coarse target could have kept (Fig. 1). It runs once, before training, in place of the label-downsampling step, and the network, its loss at stride f and inference do not change. Algorithm 1 in the supplement lists the construction.
3.1. Problem
A source label map on a grid of P pixels is split into R regions, the 4-connected components of its labels; two pieces of one label are two regions. A downsampling factor f partitions the grid into C coarse cells of pixels, clipped at the border. Let be the number of pixels of region r in cell c, and the cell's pixel count. The support graph G is bipartite between regions and cells, with an edge whenever (Fig. 1c). A coarse labeling a gives each cell one region of its support, , and region survives if some cell carries it. We measure survival and pixel disagreement , the source pixels whose region differs from their cell's after nearest upsampling. Spurious and missing adjacencies and count the region pairs that are 4-adjacent on the coarse grid but not in the source, and the reverse; is the number of coarse components of region . Experiments count evaluated regions, those of the labels a metric scores (not void or crowd); the theorems count all regions.
3.2. Survivable sets and the one-cell guarantee
Theorem 1 (Matroid structure). A set S of regions can survive together in some labeling if and only if G has a matching that saturates S. The survivable sets are the independent sets of the transversal matroid of G on the regions. Hence every maximal survivable set has regions, the maximum matching size, and for any ranking of the regions into priority tiers the greedy rule (add the next region, in tier order, if the set stays survivable) returns a survivable set that, for every t, contains the maximum possible number of regions of the t highest priority tiers.
The first sentence holds because surviving regions need distinct cells, and any matching extends to a labeling by filling the unmatched cells with any region of their support. The rest is the transversal-matroid theorem of Edmonds and Fulkerson [18] and the greedy property of matroids. Our construction, MatchDown-P (P for priority), ranks regions in four tiers: evaluated regions of at least pixels ( ), smaller evaluated regions ( ), non-evaluated regions of at least pixels ( ) and smaller non-evaluated regions ( ); pixels is the area of one cell, from which Theorem 2 guarantees survival. It solves the minimum-cost matching of Theorem 3 with every real edge of region raised by and the dummy cost set to (Algorithm 1), so keeping a region of tier saves about . Because the survivable sets form a matroid, the result keeps the largest possible number of tier-4 regions, of tier-4 and tier-3 regions together, and so on (Theorem 1, Proposition 6); because exceeds any total pixel cost, disagreement is minimized only among these sets.
Theorem 2 (One-cell survival). Some labeling with maximum survival keeps every region of at least pixels.
Hall’s condition holds for the large regions because of them hold at least pixels and a cell holds at most , so they touch at least cells [25]; the matching that saturates them extends to one of size by matroid augmentation (Theorem 1, Appendix A). None of the per-cell methods we compare (majority, nearest, strided, interpolation followed by argmax) has this property. They lose regions of any size when a larger region dominates every cell the smaller one touches, and Sec. 4.2 counts how many. MatchDown-P puts the large evaluated regions in the top tier, so it keeps all of them. The unweighted construction, MatchDown, has no such guarantee; it is the target we train on BBBC038, where both forms lose no nucleus at factor 8 (Tab. S12).
3.3. Exact survival by matching, and its certificate
Theorem 3 (Exact survival). Every labeling has . Give each region a private dummy cell, set and , weight real edges and dummy edges , solve a minimum-weight full matching of the regions [29], fill every cell with its majority region and overwrite each matched cell with its region. The result attains and minimizes among all labelings with .
The dummy penalty exceeds any total cost , so a minimum-weight full matching has exactly real edges and, among those, the least cost. Majority completion adds no cost, and it cannot reintroduce an unmatched region without exceeding ; the full proof is in Appendix A. With tier weights the same construction gives MatchDown-P; with equal weights it gives the unweighted MatchDown.
Theorem 4 (Lower bound and certificates). The number of regions any labeling loses is at least the deficiency over region sets with neighborhood , and the matching of Theorem 3 loses exactly . The regions reachable by alternating paths from the unmatched regions of a maximum matching, with their cells, split into connected clusters, each of regions in cells, and .
The first sentence is the König–Ore formula [31, 43], and the second is the Dulmage–Mendelsohn decomposition [17]. Each cluster is a certificate that can be checked by counting: its regions share cells, so they cannot all survive and at least of them are lost, although the certificate does not single out which (Fig. 1c; a worked example is in Fig. S1). The same statement holds for the evaluated regions on the subgraph they induce, and Sec. 4.2 shows that MatchDown-P’s losses equal this lower bound on every dataset and factor.
3.4. Adjacency repair and forced adjacencies
Starting from , a repair sweeps the cells at most twice. It relabels a cell only to a region of its support that already survives elsewhere, only if the old region keeps another cell and neither region gains a 4-connected coarse component, only if the disagreement stays within (half a percent of the pixels), and only if decreases lexicographically (Proposition 7). The set of surviving regions is therefore unchanged, no increases, and at most
2C cells are relabeled. Maximum survival can force spurious adjacencies: on the source of Fig. S2, the only labeling that keeps all four regions has two (Proposition 8).
3.5. Survival under a coverage threshold
Keeping a region as small as one pixel per cell inflates it up to -fold. A coverage threshold assigns a region only to cells it covers by at least a fraction , and the same exact count holds on the thresholded support graph. The number of regions kept through such cells is at most the matching number of the thresholded graph, the construction of Theorem 3 attains it with the least disagreement, and a tiered form that ranks the regions already kept by uncovered cells below all others attains the minimum loss of evaluated regions (Theorem 9, Appendices A.5 and D).
3.6. A per-region IoU upper bound
Instance metrics count a predicted segment as correct only if its IoU with a ground-truth segment exceeds 0.5, and a coarse target reconstructed by nearest upsampling gives each kept region whole cells.
Proposition 5 (Per-region IoU bound). Under any one-region-per-cell target reconstructed by nearest upsampling, region O reaches at most
and the maximum is attained by a prefix of 's cells sorted by in decreasing order. If and contains at least one full cell, .
With the optimum, a cell raises the ratio exactly when , so the optimum takes every cell above and none below; the sub-cell case follows from and . The bound depends only on the grid and the region, so it holds for every coarse target; the IoU of a network that reproduces its target is bounded in the same way (Fig. 2b). We call a region reachable if . Majority pooling keeps every reachable region: and give , so some cell has and is won by . Hence no region that majority pooling loses is reachable, on any image and at any factor. The bound concerns targets reconstructed cell by cell; a decoder that predicts sub-cell geometry, such as a star-convex polygon, is not limited by it.
3.7. Greedy rescue, complexity and scope
A simpler alternative, greedy rescue, starts from majority pooling and lets each lost region, smallest first, take its best-covered cell unless this removes the region currently in that cell. Any rescue that continues until no lost region has a support cell that a surviving region can spare keeps at least regions; maximal rescue, which gives each lost region its best-covered spare cell, is such a rescue, while greedy rescue is not and can keep only of regions (Proposition 10, Appendix A.6). The assignment is one rectangular minimum-weight full matching, and the certificate one maximum matching with a breadth-first search; a full Cityscapes frame at factor 8 takes 1.29 s on one CPU core (Tab. S8). The method always returns a labeling, but it guarantees neither holes, homotopy type, the source adjacency graph nor 8-connected counts; Appendix A.7 describes how we verified the implementation.
4. Experiments
4.1. Setup
Data and regions. We use BSDS500 [2], three disjoint sets of 1,000 COCO panoptic validation images [30, 33] (COCO-A, COCO-B and a held-out set, COCO-R), and Cityscapes with its fine annotations [10]. The nucleus datasets are BBBC038 [4] and BBBC039 [5, 35]. Regions are 4-connected components of instances (things) and of classes (stuff); the evaluated regions are those of the labels that a metric scores, i.e., not void or crowd. Table S1 in the supplement lists the dataset statistics.
Baselines. We compare MatchDown with the downsampling methods of existing pipelines: strided sampling (StarDist's target, and PyTorch's default nearest interpolation), nearest-exact (nnU-Net v2's deep supervision), nearest sampling at the cell center, majority pooling (the mode, as in connectomics pyramids), max pooling, one-hot bilinear interpolation with argmax, and nnU-Net's per-label interpolation [28]. We also compare soft labels [1], greedy and maximal rescue, a full-resolution loss where one can be computed, and, at the label level, Chen and Peng's integer program [7]. MatchDown denotes the unweighted construction (Theorem 3 with the repair) and MatchDown-P its tiered form (Algorithm 1).
Training. We train two heads on the 670 BBBC038 images at factor 8, and on the 197 BBBC039 images at factor 16 (Tab. 2); the factor is the output stride of the head, which StarDist calls the grid. Each head is trained with nine seeds and three folds, so every image is predicted by a model that never saw it, and we score at full resolution. Some BBBC038 models come from a second set of runs with the same protocol (App. C); every difference is computed within one set. The affinity head (ResNet-18 FPN [26, 34]) predicts foreground and same-nucleus affinities at the target stride and is decoded by thresholding and connected components. The star-convex head predicts an object probability and 32 radial distances in each grid cell, as
Table 1. Label-level evaluation on COCO-R at factor 8 (1,000 held-out images, 25,963 evaluated regions). Lost: evaluated regions missing from the target; cell: lost regions of at least pixels; Recon.: share (%) of the reachable regions (Proposition 5) reconstructed at IoU by nearest upsampling. The lower bound (Theorem 4) is 1,854. Keeping the small regions costs reconstruction quality (Tab. S6). All factors and datasets: Tabs. S3 and S4. Best in bold, second best underlined.
| Target | Lost ↓ | ≥1 cell ↓ | Recon. ↑ |
|---|---|---|---|
| Majority pooling | 9,207 | 195 | 98.4 |
| Strided (StarDist) | 8,498 | 176 | 81.1 |
| Nearest-exact (nnU-Net) | 8,481 | 150 | 97.7 |
| Max pooling | 7,849 | 933 | 74.5 |
| Greedy rescue | 4,921 | 69 | 89.9 |
| Maximal rescue | 4,381 | 9 | 89.6 |
| MatchDown (ours) | 3,185 | 0 | 89.5 |
| MatchDown-P (ours) | 1,854 | 0 | 89.5 |
StarDist does [48] (our reimplementation), and is decoded by non-maximum suppression. Both heads require a coarse target, because each grid cell carries one object. We name each model by its head and target (e.g., the MatchDown affinity head); Tab. S2 lists the hyper-parameters.
Metrics. We report count error (the absolute difference between the predicted and true numbers of nuclei per image), the centroid-based F1 of the predicted objects, F1 at IoU > 0.5, and instance accuracy with one-to-one matching at IoU > , computed per image at a fixed decoder operating point and averaged over images. This is the accuracy measure of Weigert et al. [54], which Schmidt et al. [48] report as AP. is , Acc the mean over , and differences in are given in points (0.01). We also report the share of the nuclei missing from the majority target that a model detects or matches (Appendix B), at the default thresholds and at thresholds tuned by three-fold cross-validation to minimize count error (cross-validated thresholds, Appendix C). Differences come with 95% confidence intervals from a bootstrap over seeds and images [14, 19]. We chose BBBC039 over NuInsSeg [38] as a stress test, by a rule fixed before training: the largest difference in oracle count error between the majority and MatchDown-P targets (Appendix B).
4.2. Comparison with standard downsampling
Theorem 4 lets us measure how far each method is from the minimum loss. Table 1 counts the evaluated regions each method loses on 1,000 held-out COCO images at factor 8, and Fig. 2a extends the comparison to every factor. At factor 8, majority pooling, strided and nearest-exact sampling lose 4.6 to 5.0 times the minimum. Each of them loses regions of a cell or more, and greedy rescue halves the loss.
a

b
Figure 2. Regions lost against the lower bound, and loss by nucleus size. (a) Evaluated regions lost on COCO-R as a multiple of the lower bound of Theorem 4. At factor 2, majority pooling loses 29 times the minimum and strided and nearest-exact sampling (which nearly coincide) 21 times; at factors 8 and 16 they lose 3.5 to 5 times, greedy rescue 2.6 to 5.7 times across factors, and MatchDown-P exactly the minimum. (b) BBBC038 at , by region area (nuclei and their 4-connected pieces; bins labeled by their lower edge; dotted line: one cell): the share of regions lost by majority pooling and by MatchDown-P (38 pieces below a sixteenth of a cell, all certified; MatchDown-P loses no nucleus), and the share that is reachable, i.e., whose IoU bound exceeds 0.5 (Proposition 5, shaded). Other datasets: Figs. S3 and S4.
MatchDown-P loses exactly the lower bound at every factor, as Proposition 6 requires, and never loses a region of a cell or more. The same holds for all 20 dataset–factor pairs (Tabs. S3 and S4), and the three standard methods lose regions of a cell or more on each.
4.3. Effect on trained networks
Star-convex head. Table 2 reports both heads on both datasets with cross-validated thresholds; Tabs. S10, S12, S14 and S15 add the default thresholds, the differences with their intervals and the shares of missing nuclei that are detected. On BBBC038 at factor 8 and the default thresholds, the strided head's is about ten points below those of the heads trained on cell-center, rescue and MatchDown targets (Tab. S12); cross-validated thresholds narrow the difference to 4.2 points. Of the four BBBC038 star-convex heads in Tab. 2, the MatchDown head has the lowest count error and the highest F1 at IoU > 0.5, and it matches 35% of the nuclei missing from the majority tar-
Table 2. Main results with cross-validated thresholds: count error (CE, nuclei per image), F1 at IoU > 0.5 and of both heads on both datasets; BBBC038 (670 images) at factor 8, BBBC039 (197 images) at factor 16 and, for the star-convex head, also at factor 8; 9 seeds 3 folds. *MatchDown on BBBC038 and MatchDown-P on BBBC039 (on BBBC038 both lose no nucleus). Best of the targets shown in bold (ties share the mark), second underlined. Other targets: Tab. 3; details: Tabs. S10, S12, S14 and S15.
| Target | BBBC038 | BBBC039 | |||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Affinity, f=8 | Star-convex, f=8 | Affinity, f=16 | Star-convex, f=16 | Star-convex, f=8 | |||||||||||
| CE ↓ | F1 ↑ | CE ↓ | F1 ↑ | CE ↓ | F1 ↑ | CE ↓ | F1 ↑ | CE ↓ | F1 ↑ | ||||||
| Majority pooling | 5.01 | 0.689 | 0.541 | 6.50 | 0.830 | 0.750 | 13.05 | 0.660 | 0.497 | 13.30 | 0.897 | 0.872 | 6.80 | 0.922 | 0.871 |
| Cell center | 3.91 | 0.696 | 0.558 | 5.78 | 0.841 | 0.770 | 10.43 | 0.698 | 0.539 | 11.57 | 0.922 | 0.855 | 5.51 | 0.926 | 0.871 |
| Strided (StarDist) | 4.10 | 0.440 | 0.270 | 4.84 | 0.809 | 0.728 | 8.70 | 0.080 | 0.070 | 5.62 | 0.888 | 0.799 | 4.29 | 0.915 | 0.847 |
| MatchDown* (ours) | 3.69 | 0.673 | 0.530 | 4.10 | 0.854 | 0.770 | 3.77 | 0.591 | 0.425 | 3.35 | 0.904 | 0.827 | 2.90 | 0.932 | 0.873 |
Table 3. Ablation on the affinity head, BBBC038 at factor 8; soft labels as in [1]. Count error at the default thresholds, then, with cross-validated thresholds, the differences from the majority model and F1 at IoU > 0.5. Masked: majority targets with the cells of the missing nuclei left out of the loss, from the second set of runs, differences against its majority model (in that set, MatchDown's difference is -1.34). Intervals and further columns: Tabs. S10 and S11; the star-convex head: Tab. S12. Best in bold, second best underlined.
| Target | Count err. ↓ default | Δcount err. ↓ cross-validated | ΔAcc50 ↑ | F1 ↑ |
|---|---|---|---|---|
| Majority pooling | 5.93 | ref. | ref. | 0.689 |
| Masked† | 5.02 | -0.77 | +0.000 | 0.689 |
| Greedy rescue | 3.93 | -1.43 | -0.010 | 0.679 |
| Soft labels | 6.46 | -1.64 | -0.082 | 0.598 |
| Full-res. loss | 3.56 | -1.34 | +0.018 | 0.690 |
| MatchDown (ours) | 4.03 | -1.32 | -0.011 | 0.673 |
get at IoU > 0.5, against 24% for the strided head. On BBBC039 at factor 16, its count error is 4.0 nuclei per image below the strided head's at the default thresholds and 2.3 below with cross-validated thresholds, with 2.7 points higher (paired difference, Tab. S15); majority leads in , whereas cell center leads in F1. At factor 8 on the same images the count-error differences are smaller and every difference from the strided head has the same sign (Tab. S15). With cross-validated thresholds at factor 4, MatchDown also improves both count error (3.80 against 4.20) and (0.795 against 0.781) over the strided target (Tab. S12). When the NMS search range is extended to 0.1, the strided head has the lower count error at factors 8 and 4 (4.02 against 5.13, and 3.61 against 4.49), and the difference narrows to 1.9 and 0.4 points (Tab. S13).
Affinity head. The affinity head is trained to predict foreground only where its target has it, so a nucleus missing from the target receives no positive label. At the default thresholds, the affinity head trained on majority targets at factor 8 has a count error of 5.93 nuclei per image, and the one trained on MatchDown targets 4.03 (Tab. S10). Most of the difference comes from the missing nuclei (Sec. 4.5): the MatchDown head detects of the nuclei missing from the majority target, against for the majority head (cross-validated thresholds, Tab. S10; detection is defined in Appendix B). At factor 16 on BBBC039 and the default thresholds, the count error is 15.9 nuclei per image for the majority head and 3.95 for the MatchDown-P head. This difference, 11.9 nuclei, matches the gap of 11.7 nuclei between the targets themselves, and the MatchDown-P head detects of the nuclei missing from the majority target, against (Tab. S14, Fig. 3). is lower for the MatchDown-P head, by 5.4 points at the default thresholds and by 7.2 with cross-validated thresholds (F1 0.591 against 0.660), where its count error is still 9.3 nuclei lower than the majority head's (Sec. 4.5).
4.4. Where the count reduction comes from
On BBBC038 at factor 8 and the default thresholds, the per-image count-error reduction of the MatchDown affinity head grows with the number of nuclei missing from the majority target, by 0.45 per missing nucleus (with cross-validated thresholds the interval of this slope includes zero), and the trained network recovers about half of the difference between the targets' own count errors; on BBBC039 at factor 16 it recovers all of it (Fig. S8). Over the whole threshold grid, the MatchDown model has lower count error at every foreground threshold and lower at every threshold. At thresholds that give both models the same false positives per image, the count difference is (Tab. S10), so on BBBC038 the count reduction comes with more predicted objects; selecting thresholds within each held-out fold gives the same count reduction with more false positives (Appendix C).
4.5. Assignment versus reconstruction
The nuclei that majority pooling and the other methods lose are mostly smaller than a grid cell (Fig. 2b), and by Proposition 5 none of the regions that majority pooling loses is reachable; on BBBC038 at factor 8 the mean IoU bound of

Image
59 nuclei
Majority target
15 lost
MatchDown-P target
5 lost
Trained on majority
12 missed
Trained on MatchDown-P
3 missed
b
Star-convex head

Labels
Strided target
15 lost
MatchDown-P target
5 lost
Trained on strided
19 missed at IoU > 0.5
Trained on MatchDown-P
15 missed at IoU > 0.5
Figure 3. Qualitative results on a held-out BBBC039 image at factor 16 (192×320-pixel window, 59 nuclei; seed 0, default thresholds). (a) Affinity head: the image, two targets with their lost nuclei outlined, and the predictions of the models trained on them, with the nuclei that no predicted object covers by a fifth outlined. (b) Star-convex head: the same for the strided and MatchDown-P targets, with the nuclei that no prediction matches at IoU > 0.5 outlined. More images: Fig. S10.
these nuclei is 0.30. The reachable share falls below half on all three datasets at factor 16 (Fig. S4b). An affinity head outputs one label per cell, so it can detect these nuclei but not segment them at IoU > 0.5: 89% of its count reduction on BBBC038 comes from nuclei that the majority model misses and the MatchDown model detects, and no affinity model matches any of them at IoU > 0.5. Each such detection counts as a false positive at IoU > 0.5 and lowers the of the MatchDown affinity models (Fig. S8c). The star-convex head decodes polygons at full resolution and is not limited by the bound: it matches more of these nuclei at IoU > 0.5 whenever its target keeps them, 33% on rescue, 35% on MatchDown and 40% on dilated targets, against 15% on majority and 24% on strided targets (Tab. S12).
4.6. Ablation study
Components of MatchDown. The tiers decide which regions are kept when not all can be: on COCO-R at factor 8, MatchDown-P loses 1,854 evaluated regions, the lower bound, and the unweighted MatchDown 3,185 (Tab. 1), at a cost of at most 0.02% of pixels (Appendix D).
Simpler targets. On BBBC038 at factor 8, greedy rescue loses 103 of the 29,461 nuclei and performs as well as MatchDown with both heads (Tabs. 3 and S12). Exact matching matters where cells are scarce: on BBBC039 at factors 16 to 32, rescue loses more nuclei than MatchDown-P on 33 to 99% of the images (Tab. S9); at factor 16 its heads have 1.4 to 3.1 points higher , and only the affinity head counts worse, by 0.60 nuclei per image (Tab. S16). Soft labels match or exceed MatchDown's count reduction on BBBC038 with cross-validated thresholds, at 8.2 points below majority. At factor 16 their count error is 11.5 nuclei per image higher than MatchDown-P's at the default thresholds, because a nucleus that fills less than half of every cell it touches never reaches a foreground value of 0.5. Training with a full-resolution loss, where one can be computed, gives the same count reduction as MatchDown with 2.9 points higher (Tab. 3).
5. Conclusion
The regions a coarse target can keep are determined exactly by a matching problem: every region of a cell or more can be kept, a minimum-cost matching attains the maximum, and every unavoidable loss has a certificate. Keeping a region in the target and reconstructing its shape are separate bottlenecks: the regions that majority pooling loses cannot be reconstructed above IoU 0.5 by upsampling any coarse target, yet on BBBC038 a star-convex head trained on MatchDown targets segments 35% of them above that IoU, against 15% when trained on majority targets and 24% on StarDist's strided target. Across the three star-convex settings, with cross-validated thresholds, this head has the lowest count error of the targets in Tab. 2 and 2.6 to 4.2 points above the strided target. An affinity head, with cell-level output, lowers count error but loses , because it can only reconstruct what the cells can.
Limitations. Training covers two nucleus datasets, factors 2 to 16 and two heads, without natural images; BBBC039 at factor 16 is a stress test. Thresholds are cross-validated for count error, so and F1 are count-calibrated, and on BBBC038 the star-convex count ranking depends on the NMS range (Tab. S13).
LLM Usage Statement
We used large language model assistants (Claude, Anthropic; Codex, OpenAI) to write, run and review the implementation, experiment, analysis and figure code, to check reported numbers against the run outputs, and to edit the text. The authors designed the method and the experiments, verified every proof, number and reference, and take full responsibility for the paper.
References
[1] Roberto Alcover-Couso, Marcos Escudero-Viñolo, Juan C. SanMiguel, and José M. Martínez. Soft-labelling for budget-constrained semantic segmentation: Bringing coherence to label down-sampling. Computational Visual Media, 12:765–785, 2026. 2, 3, 5, 7, 15, 23, 25
[2] Pablo Arbeláez, Michael Maire, Charless Fowlkes, and Jitendra Malik. Contour detection and hierarchical image segmentation. IEEE Transactions on Pattern Analysis and Machine Intelligence, 33(5):898–916, 2011. 5
[3] Min Bai and Raquel Urtasun. Deep watershed transform for instance segmentation. In CVPR, pages 5221–5229, 2017. 3
[4] Juan C. Caicedo, Allen Goodman, Kyle W. Karhohs, Beth A. Cimini, Jeanelle Ackerman, Marzieh Haghighi, CherKeng Heng, Tim Becker, Minh Doan, Claire McQuin, Mohammad Rohban, Shantanu Singh, and Anne E. Carpenter. Nucleus segmentation across imaging experiments: the 2018 Data Science Bowl. Nature Methods, 16:1247–1253, 2019. 5
[5] Juan C. Caicedo, Jonathan Roth, Allen Goodman, Tim Becker, Kyle W. Karhohs, Matthieu Broisin, Csaba Molnar, Claire McQuin, Shantanu Singh, Fabian J. Theis, and Anne E. Carpenter. Evaluation of deep learning strategies for nucleus segmentation in fluorescence images. Cytometry Part A, 95(9):952–965, 2019. 5
[6] Nicolas Carion, Francisco Massa, Gabriel Synnaeve, Nicolas Usunier, Alexander Kirillov, and Sergey Zagoruyko. End-to-end object detection with transformers. In ECCV, 2020. 3
[7] Chia-Chia Chen and Chi-Han Peng. Topology-preserving downsampling of binary images. In ECCV, pages 416–431, 2024. 2, 3, 5, 17
[8] Liang-Chieh Chen, George Papandreou, Iasonas Kokkinos, Kevin Murphy, and Alan L. Yuille. DeepLab: Semantic image segmentation with deep convolutional nets, atrous convolution, and fully connected CRFs. IEEE Transactions on Pattern Analysis and Machine Intelligence, 40(4):834–848, 2018. 2, 3
[9] Bowen Cheng, Ishan Misra, Alexander G. Schwing, Alexander Kirillov, and Rohit Girdhar. Masked-attention mask transformer for universal image segmentation. In CVPR, pages 1290–1299, 2022. 3
[10] Marius Cordts, Mohamed Omran, Sebastian Ramos, Timo Rehfeld, Markus Enzweiler, Rodrigo Benenson, Uwe Franke, Stefan Roth, and Bernt Schiele. The Cityscapes dataset for semantic urban scene understanding. In CVPR, pages 3213–3223, 2016. 5
[11] David F. Crouse. On implementing 2D rectangular assignment algorithms. IEEE Transactions on Aerospace and Electronic Systems, 52(4):1679–1696, 2016. 3
[12] Kevin J. Cutler, Carsen Stringer, Teresa W. Lo, Luca Rappez, Nicholas Stroustrup, S. Brook Peterson, Paul A. Wiggins, and Joseph D. Mougous. Omnipose: a high-precision morphology-independent solution for bacterial cell segmentation. Nature Methods, 19(11):1438–1448, 2022. 3
[13] Etienne Decencière and Michel Bilodeau. Adaptive crossing numbers and their application to binary downsampling. Image Analysis & Stereology, 26(2):73–81, 2007. 3
[14] Thomas J. DiCiccio and Bradley Efron. Bootstrap confidence intervals. Statistical Science, 11(3):189–228, 1996. 6, 15
[15] Division of Medical Image Computing, German Cancer Research Center. batchgeneratorsv2: data augmentation used by nnU-Net v2. https://github.com/MIC-DKFZ/batchgeneratorsv2, 2024. 2
[16] Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, Jakob Uszkoreit, and Neil Houlsby. An image is worth words: Transformers for image recognition at scale. In ICLR, 2021. 2
[17] A. L. Dulmage and N. S. Mendelsohn. Coverings of bipartite graphs. Canadian Journal of Mathematics, 10:517–534, 1958. 2, 3, 4
[18] Jack Edmonds and D. R. Fulkerson. Transversals and matroid partition. Journal of Research of the National Bureau of Standards B, 69:147–153, 1965. 2, 3, 4
[19] Bradley Efron. Bootstrap methods: Another look at the jackknife. The Annals of Statistics, 7(1):1–26, 1979. 6, 15
[20] David Eppstein, Marc van Kreveld, Bettina Speckmann, and Frank Staals. Improved grid map layout by point set matching. International Journal of Computational Geometry & Applications, 25(2):101–122, 2015. 3
[21] Jan Funke, Fabian Tschopp, William Grisaitis, Arlo Sheridan, Chandan Singh, Stephan Saalfeld, and Srinivas C. Turaga. Large scale image segmentation with structured loss based deep learning for connectome reconstruction. IEEE Transactions on Pattern Analysis and Machine Intelligence, 41(7):1669–1680, 2019. 3
[22] Naiyu Gao, Yanhu Shan, Yupei Wang, Xin Zhao, Yinan Yu, Ming Yang, and Kaiqi Huang. SSAP: Single-shot instance segmentation with affinity pyramid. In ICCV, pages 642–651, 2019. 3
[23] Zheng Ge, Songtao Liu, Zeming Li, Osamu Yoshie, and Jian Sun. OTA: Optimal transport assignment for object detection. In CVPR, 2021. 3
[24] Simon Graham, Quoc Dang Vu, Shan E Ahmed Raza, Ayesha Azam, Yee Wah Tsang, Jin Tae Kwak, and Nasir Rajpoot. HoVer-Net: Simultaneous segmentation and classification of nuclei in multi-tissue histology images. Medical Image Analysis, 58:101563, 2019. 3
[25] Philip Hall. On representatives of subsets. Journal of the London Mathematical Society, 10(1):26–30, 1935. 2, 3, 4, 11
[26] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In CVPR, pages 770–778, 2016. 5
[27] John E. Hopcroft and Richard M. Karp. An algorithm for maximum matchings in bipartite graphs. SIAM Journal on Computing, 2(4):225–231, 1973. 3
[28] Fabian Isensee, Paul F. Jaeger, Simon A. A. Kohl, Jens Petersen, and Klaus H. Maier-Hein. nnU-Net: a self-configuring method for deep learning-based biomedical image segmentation. Nature Methods, 18(2):203–211, 2021. 2, 5
[29] Roy Jonker and Ton Volgenant. A shortest augmenting path algorithm for dense and sparse linear assignment problems. Computing, 38:325–340, 1987. 2, 3, 4, 11
[30] Alexander Kirillov, Kaiming He, Ross Girshick, Carsten Rother, and Piotr Dollár. Panoptic segmentation. In CVPR, pages 9404–9413, 2019. 5
[31] Dénes König. Gráfok és mátrixok. Matematikai és Fizikai Lapok, 38:116–119, 1931. 3, 4
[32] Harold W. Kuhn. The Hungarian method for the assignment problem. Naval Research Logistics Quarterly, 2(1–2):83–97, 1955. 3
[33] Tsung-Yi Lin, Michael Maire, Serge Belongie, James Hays, Pietro Perona, Deva Ramanan, Piotr Dollár, and C. Lawrence Zitnick. Microsoft COCO: Common objects in context. In ECCV, pages 740–755, 2014. 5
[34] Tsung-Yi Lin, Piotr Dollár, Ross Girshick, Kaiming He, Bharath Hariharan, and Serge Belongie. Feature pyramid networks for object detection. In CVPR, pages 2117–2125, 2017. 5
[35] Vebjorn Ljosa, Katherine L. Sokolnicki, and Anne E. Carpenter. Annotated high-throughput microscopy image sets for validation. Nature Methods, 9(7):637, 2012. 5
[36] Jonathan Long, Evan Shelhamer, and Trevor Darrell. Fully convolutional networks for semantic segmentation. In CVPR, pages 3431–3440, 2015. 3
[37] László Lovász and Michael D. Plummer. Matching Theory. North-Holland, 1986. 3
[38] Amirreza Mahbod, Christine Polak, Katharina Feldmann, Rumsha Khan, Katharina Gelles, Georg Dorffner, Ramona Woitek, Sepideh Hatamikia, and Isabella Ellinger. NuInsSeg: A fully annotated dataset for nuclei instance segmentation in H&E-stained histological images. Scientific Data, 11:295, 2024. 6, 14
[39] Luke James Miller and Yugyung Lee. SEMIR: Topology-preserving graph minors for thin-structure segmentation. arXiv:2606.24935, 2026. 3
[40] James Munkres. Algorithms for the assignment and transportation problems. Journal of the Society for Industrial and Applied Mathematics, 5(1):32–38, 1957. 3
[41] Phuc Ngo, Nicolas Passat, Yukiko Kenmochi, and Hugues Talbot. Topology-preserving rigid transformation of 2D digital images. IEEE Transactions on Image Processing, 23(2): 885–897, 2014. 3
[42] Maxime Oquab, Timothée Darcet, Théo Moutakanni, Huy V. Vo, Marc Szafraniec, Vasil Khalidov, Pierre Fernandez, Daniel Haziza, Francisco Massa, Alaaeldin El-Nouby, Mido
Assran, Nicolas Ballas, Wojciech Galuba, Russell Howes, Po-Yao Huang, Shang-Wen Li, Ishan Misra, Michael Rabbat, Vasu Sharma, Gabriel Synnaeve, Hu Xu, Hervé Jégou, Julien Mairal, Patrick Labatut, Armand Joulin, and Piotr Bojanowski. DINOv2: Learning robust visual features without supervision. Transactions on Machine Learning Research, 2024. 2
[43] Oystein Ore. Graphs and matching theorems. Duke Mathematical Journal, 22(4):625–639, 1955. 3, 4
[44] James Oxley. Matroid Theory. Oxford University Press, 2nd edition, 2011. 3
[45] Nicolas Passat, Phuc Ngo, Yukiko Kenmochi, and Hugues Talbot. Homotopic affine transformations in the 2D Cartesian grid. Journal of Mathematical Imaging and Vision, 64(7):786–806, 2022. 3
[46] Joseph Redmon, Santosh Divvala, Ross Girshick, and Ali Farhadi. You only look once: Unified, real-time object detection. In CVPR, 2016. 3
[47] Olaf Ronneberger, Philipp Fischer, and Thomas Brox. U-Net: Convolutional networks for biomedical image segmentation. In MICCAI, pages 234–241, 2015. 3
[48] Uwe Schmidt, Martin Weigert, Coleman Broaddus, and Gene Myers. Cell detection with star-convex polygons. In MICCAI, pages 265–273, 2018. 2, 3, 6
[49] Seung Lab. tinybrain: image pyramid generation specialized for connectomics data. https://github.com/seung-lab/tinybrain, 2024. Software. 2
[50] Carsen Stringer, Tim Wang, Michalis Michaelos, and Marius Pachitariu. Cellpose: a generalist algorithm for cellular segmentation. Nature Methods, 18(1):100–106, 2021. 3
[51] Zhi Tian, Chunhua Shen, Hao Chen, and Tong He. FCOS: Fully convolutional one-stage object detection. In ICCV, pages 9627–9636, 2019. 3
[52] Srinivas C. Turaga, Kevin L. Briggman, Moritz Helmstaedter, Winfried Denk, and H. Sebastian Seung. Maximin affinity learning of image segmentation. In NeurIPS, 2009. 3
[53] Xinlong Wang, Tao Kong, Chunhua Shen, Yuning Jiang, and Lei Li. SOLO: Segmenting objects by locations. In ECCV, 2020. 2, 3
[54] Martin Weigert, Uwe Schmidt, Robert Haase, Ko Sugawara, and Gene Myers. Star-convex polyhedra for 3D object detection and segmentation in microscopy. In WACV, pages 3666–3673, 2020. 2, 3, 6
[55] Steffen Wolf, Constantin Pape, Alberto Bailoni, Nasim Rahaman, Anna Kreshuk, Ullrich Köthe, and Fred A. Hamprecht. The mutex watershed: Efficient, parameter-free image partitioning. In ECCV, 2018. 3
[56] Shifeng Zhang, Cheng Chi, Yongqiang Yao, Zhen Lei, and Stan Z. Li. Bridging the gap between anchor-based and anchor-free detection via adaptive training sample selection. In CVPR, 2020. 3
[57] Xingyi Zhou, Dequan Wang, and Philipp Krähenbühl. Objects as points. arXiv preprint arXiv:1904.07850, 2019. 2, 3
What Survives Label Downsampling? Exact Region Survival for Coarse Segmentation Targets
Supplementary Material
Appendix A proves the results of Sec. 3 and describes how we verified the implementation, Appendix B defines the datasets, metrics and baselines, Appendix C gives the training protocol, and Appendices D and E report the label-level and training results.
A. Proofs
Notation. Regions , cells and counts are as in Sec. 3.1. Let and . Let on supported edges, so that every labeling satisfies .
A.1. Proof of Theorem 3
Step 1 (upper bound and attainability). Select one cell carrying each region represented in . The selected cells are distinct and their edges form a matching, so . Conversely, label the cells of a maximum matching with their matched regions and fill the rest arbitrarily within their support. At least regions survive, and by the bound no more.
Step 2 (penalty dominance). A full matching with real edges has weight , where over its real edges. Real-matched cells are distinct, so . Raising by one lowers by at least . A minimum-weight full matching therefore has real edges, and among those it minimizes .
Step 3 (majority completion). Cells not used by the matching keep a majority region and contribute zero cost, so . An unmatched region cannot be the majority region of such a cell: that would give distinct representatives, contradicting Step 1.
Step 4 (pixel optimum). For any with , choose distinct representative cells. Their cost is a sub-sum of nonnegative cell costs, so . Hence . The implementation enforces , so that float64 weights are exact integers.
A.2. Algorithm, one-cell survival and a worked example
Proof of Theorem 2. Take regions of at least pixels each, and let be the set of cells they touch. Those cells hold at least of their pixels, and a cell holds at most pixels, so . Hall's condition therefore holds for the large regions, and a matching saturates them [25]. By the augmentation property of the matroid of Theorem 1, it
Algorithm 1 MatchDown-P: a coarse target with maximum survival
1: the pixels of region (4-connected components of the labels) in cell ; has an edge wherever 2: for evaluated regions of at least pixels, smaller evaluated regions, non-evaluated regions of at least pixels, smaller non-evaluated regions 3: ; edge costs ; each region also has a private dummy cell at cost 4: solve the minimum-cost full matching of the regions [29] 5: the majority region of for every cell, then for every matched real edge 6: repair: at most two sweeps of single-cell relabelings under the conditions of Sec. 3.4 7: certificate: the regions reachable by alternating paths from the unmatched regions, in clusters of regions sharing cells (Theorem 4)
extends to a survivable set of regions that still contains them, which is the survivor set of a labeling with .
Proposition 6 (Tier optimality). For every , the MatchDown-P labeling keeps the largest number of regions of the highest tiers that any labeling can keep. Before the repair (line 6 of Algorithm 1), it has the least pixel disagreement among the labelings that do so for every ; the repair keeps the surviving regions and adds at most to the disagreement.
Proof. Keeping a region of tier instead of its dummy saves with and the total of all below , so a minimum-cost full matching maximizes first and minimizes second. On a matroid, the independent sets of maximum weight for a weight that is constant on each tier are exactly the bases that, for every , contain the most elements of the highest tiers (Gale optimality of the greedy algorithm, Theorem 1). Among these, the second criterion is the disagreement of Step 4 of the proof of Theorem 3.
A.3. Repair invariants
Starting from , a repair sweeps the cells at most twice and relabels cell from to only if is in the support of b
a

Source, f=4

matched: 7 of 8 regions
lower bound: 1 lost
C

Majority
lost: 6 of 8
d
MatchDown-P (ours)
lost: region 3
Figure S1. A worked example of survival as matching. (a) A source at : seven regions on a background. (b) Its support graph. Bold edges are a maximum matching ( of 8 regions); regions 2, 3 and 4 share only cells c2 and c5, so one of them must be lost, and this Dulmage–Mendelsohn cluster certifies the single unavoidable loss (Theorem 4). (c) Majority pooling keeps 2 of the 8 regions, the background and region 1. (d) MatchDown-P keeps 7 of 8 and loses only region 3, one of the three regions of the cluster certified in (b); the matching drawn in (b) loses region 4 instead, at the same survival.
c and already survives, u keeps another cell, D stays within , the pair strictly decreases lexicographically, and neither u nor v gains a 4-connected coarse component.
Proposition 7 (Repair invariants). Every accepted relabeling of the repair of Sec. 3.4 keeps the set of surviving regions and every cell supported, keeps , strictly decreases , and never increases any ; the number of relabelings is at most , with the set of source adjacencies.
Consider an accepted relabeling of cell c from u to v.
-
Survivors and support. v is taken from the support of c and from the surviving regions, and u keeps another cell. No region appears or disappears, and all other cells are unchanged.
-
Budget. Only cell c changes, so D changes by exactly , which is checked against the budget.
-
Adjacency descent. A single-cell change affects at most four grid edges. The multiplicities of adjacent region pairs are updated exactly, so F and L are exact. Only candidates with are accepted.
-
Component counts. The guard compares the 4-connected component counts of u and v on the whole grid before and after the change, and accepts only if neither increases. Every other region's mask is unchanged. By induction, for all r.
-
Termination. drops by at least one per accepted relabeling, because a drop in can be offset by at most in . At most one relabeling is accepted per cell per sweep, and there are two sweeps.
4-connectivity is essential. Take region pixels at , and and remove . The 4-connected count stays at 2, while the 8-connected count rises from 1 to 2. □
a

Source, f=2
b

Majority
keeps 1 of 4
c

Keeps 4 of 4
+2 spurious adjacencies
Figure S2. Spurious adjacencies forced by maximum survival. (a) A source at : a connected background with single-pixel regions at three corners. (b) Majority pooling keeps one region and creates no spurious adjacency. (c) Of the eight supported labelings, only this one keeps all four regions, and it creates the adjacencies and , which the source does not have.
A.4. Forced adjacencies
Proposition 8 (Forced adjacencies). On the source of Fig. S2 at , exactly one of the eight supported labelings keeps all four regions, and it has two spurious adjacencies; majority pooling keeps one region and has none.
The four cells of Fig. S2 have supports , , and , in row order. This gives supported labelings. Only contains all four regions. It has the coarse adjacencies , , , . Against the source adjacencies , , , two are spurious and is missing.
A.5. Survival under a coverage threshold
For let keep the edges with . Cells with no edge (uncovered cells) take their majority region, and a region is kept with coverage if it holds a cell through a edge; a labeling that obeys these rules is admissible.
Theorem 9 (Exact survival under coverage). The number of regions kept with coverage by any admissible labeling is at most , and the construction of Theorem 3 on with fixed uncovered cells attains it with the least disagreement. Let be the regions kept by uncovered cells. Every admissible labeling loses at least as many evaluated regions as the deficiency of the evaluated regions outside in , and the tier-weighted construction in which every region of ranks below all other regions attains that minimum.
The ranking of matters: at and , let one cell hold 9 pixels of and 7 of , and its neighbor 3 pixels each of , , , and 2 each of , , with first in index order and 4-connected across both cells. The neighbor is uncovered and takes ; a matching that ranks and equally gives the first cell to , at lower pixel cost, and loses , whereas ranking last keeps both. Our implementation ranks last, and on every image of Tab. S7 its loss equals the minimum computed separately as in the proof. On Cityscapes at the minimum, as a fraction of the losses of class-first majority pooling, is 0.5621; the unweighted construction reaches 0.5627.
Proof. Let be the cells incident to , and the uncovered cells, fixed to their lowest-index majority region.
• Upper bound. The witnessing cells of distinct regions kept with coverage are distinct cells of joined by edges, so they form a matching of .
• Attainability. Label a maximum matching of , fill the other cells with any region joined to them in , and keep fixed.
• Pixel optimum. Steps 2–4 of the proof of Theorem 3 apply to , with dummy penalty where is the number of pixels on edges; contributes a fixed disagreement.
• Minimum evaluated loss. Regions of are kept whatever the covered cells hold. The other regions a labeling keeps with coverage hold distinct cells of through edges, a matching of , so the evaluated ones among them number at most the largest number of evaluated regions that a matching of saturates; regions with no edge outside are lost. With ranked last, the tier weights make the minimum-cost matching saturate that largest number (Proposition 6, with the regions of in the lowest tiers).
• . is the full support graph and , so the construction is that of Theorem 3.
The restricted repair adds three conditions to Proposition 7: both edges of a relabeling lie in , the old region keeps another cell with coverage , and the new region already has one. Uncovered cells never change, so both survivor sets are unchanged and the component argument carries over. Regions kept only by uncovered cells cannot be counted as kept with coverage : a grid of 16 distinct pixels at and has and four regions kept by uncovered cells.
Lower bound from uncovered regions. Let be the regions with no edge, and those that are the fixed majority region of some uncovered cell. In every admissible labeling a covered cell holds a region joined to it in , so a region of can appear only in uncovered cells, which are fixed. Hence every region of is lost by every admissible labeling, and the evaluated ones give the lower bound of Tab. S7. On Cityscapes and COCO at , contained no evaluated region. The losses of a -restricted labeling are these regions plus the evaluated regions with edges that the restricted matching cannot place.
A.6. Rescue bounds
Proposition 10 (Rescue bounds). A rescue that gives each lost region a cell of its support not needed by a surviving region keeps at least regions. Greedy rescue, which takes each lost region's best-covered cell, has no such bound: for every k there is a map at with on which it keeps regions, while the matching keeps all .
The first statement holds because the representative cells of the surviving regions form a maximal matching, which has at least half the edges of a maximum one. For the second, at block is a array of cells on a common background . Cell holds 10 pixels of and 2 pixels of each of , and each continues with one pixel into its own neighboring cell , whose other 15 pixels are ; the two remaining cells are all . Majority pooling keeps and . The best-covered cell of each is (2 pixels against 1), which holds and would remove it, so greedy rescue keeps regions of , while the matching and maximal rescue keep all .
A.7. Verification of the implementation
We verified the implementation against exhaustive enumeration of every supported labeling on small grids (survivor count, disagreement, the coverage construction and the per-region IoU bound), against a Hopcroft–Karp maximum matching written independently of the solver, and against the invariants of Proposition 7, on synthetic label maps of seven kinds (random labels, blobs, thin lines, ties, clipped borders, disconnected labels and one region per pixel) at factors 2 to 16. All checks passed; the tests will be released with the code.
B. Datasets, metrics and baselines
Datasets. Table S1 summarizes the datasets. We chose the second training dataset among BBBC039 and NuInsSeg
Table S1. Datasets. Evaluated regions are the 4-connected components of instances and of stuff classes that a metric scores (not void or crowd); for the nucleus datasets the second number counts annotated nuclei, of which a few consist of several 4-connected pieces. COCO-A, COCO-B and COCO-R are disjoint random sets of COCO panoptic validation images; COCO-R was held out from all development. Majority loss: share of evaluated regions (COCO, Cityscapes) or nuclei (BBBC038, BBBC039) missing from the majority-pooling target at factor 8 (factor 16). From 256×256 to 1040×1388 pixels. Use: L, label-level evaluation (factors 2 to 16 unless stated); T, training; BSDS500 serves the repair-optimality and binary-topology comparisons (Appendix D).
| Dataset | Image size | Images | Evaluated regions | Per image | Majority loss (%) | Use |
|---|---|---|---|---|---|---|
| COCO-A | up to 640×640 | 1,000 | 25,860 | 25.9 | 34.9 | L |
| COCO-B | up to 640×640 | 1,000 | 25,909 | 25.9 | 34.7 | L |
| COCO-R | up to 640×640 | 1,000 | 25,963 | 26.0 | 35.5 | L |
| Cityscapes (6 cities) | 1024×2048 | 900 | 104,234 | 115.8 | 27.9 | L |
| BBBC038 (stage 1) | varied | 670 | 29,668 / 29,461 | 44.3 | 8.8 | L, T (f=8) |
| BBBC039 | 520×696 | 197 | 23,615 nuclei | 119.9 | 10.1 | T, L (f=8-32) |
| BSDS500 | 481×321 | 200 crops of 64×64; 50 masks | - | - | - | repair, binary |
[38] at factors 8 and 16 by a rule fixed before training: among the pairs whose majority and MatchDown-P targets differ by at least 2 nuclei per image in oracle count error, take the largest difference. The differences are 11.7 (BBBC039, factor 16), 6.9 (BBBC039, factor 8), 2.6 (NuInsSeg, factor 16) and -0.2 (NuInsSeg, factor 8); BBBC038 at factor 8 gives 3.7. BBBC039 at factor 16 is therefore a stress test with many lost nuclei (10.1% under majority pooling). We use the 197 of its 200 fields that contain nuclei. A small fraction of BBBC039 images also appear in BBBC038; each dataset is split, trained and evaluated on its own, so no image is used for training and evaluation of the same model.
Metrics. Count error is the absolute difference between the number of predicted objects and the number of nuclei in an image. At a fixed decoder operating point, with one-to-one matching at IoU > ; is and Acc the mean over . These scores are computed at one operating point, without integrating over a precision-recall curve as COCO AP does. FP50 is the number of false positives per image at IoU > 0.5. Centroid F1 matches predicted and true objects one to one by increasing centroid distance, up to 8 pixels. F1 at IoU > 0.5 is with the counts of pooled over images and seeds, so it weights large images more than , which averages per-image values. A nucleus missing from a target counts as detected when a greedy one-to-one matching by overlap gives it its own predicted object that is no larger, in cells, than its support plus one cell, and as matched when that object reaches IoU > 0.5. PQ is averaged over classes, , with the mean IoU of the matched segments of class k and ; a PQ difference splits exactly into an SQ term, an RQ term and their product, computed per class from the pooled counts and averaged over classes.
Downsampling methods. Strided sampling takes the first pixel of each cell (1b1[::f,::f], PyTorch's default nearest interpolation and StarDist's target). Nearest (cell center) takes pixel of each cell along each axis, and nearest-exact pixel f/2 (PyTorch's nearest-exact, used by nnU-Net's deep supervision). Majority pooling gives each cell its most frequent region (lowest index on ties); the class-first variant takes the most frequent class, then the most frequent region of that class, with void and crowd counted as classes. Max pooling takes the largest label index in each cell. One-hot bilinear + argmax interpolates the one-hot label maps bilinearly and takes the argmax. nnU-Net per-label interpolation is resize_segmentation of batchgenerators with order 1: each region is interpolated separately and written where it reaches 0.5, in ascending order, and our implementation reproduces the library output exactly. Smallest-region priority gives each cell the smallest region that covers at least a quarter of it. Greedy and maximal rescue are defined in Sec. 3.7, and dilated targets label every cell a nucleus touches with that nucleus.
C. Training details
Folds and targets. The 670 BBBC038 stage-1 training images are split into three folds stratified by image size, and the 197 BBBC039 images into three folds; each fold's model trains on the other two, so every image is predicted once per target and seed by a model that never saw it. Every target is computed once per image before training and cropped and transformed with the image. On BBBC038, the nearest-target affinity model in Tab. S10, all star-convex models (Tabs. S12 and S13), and the models in Tab. S11 use a second run set with the same protocol. The cell-center affinity model in Tab. 2 was rerun in the first set. Every difference is computed within one run set.
Targets of the two heads. The affinity head's target gives each cell its region's foreground label and each pair of
Table S2. Training and decoding settings. Every model of a seed and fold uses the same initialization, image crops and augmentations for all targets, so that differences between targets are paired.
| Affinity head | Star-convex head | |
|---|---|---|
| Backbone | ResNet-18 (ImageNet weights) with a feature pyramid of 128 channels, laterals down to the target stride | |
| Output stride | 8 (BBBC038), 16 (BBBC039) | 8 (BBBC038, also 4 and 2), 16 and 8 (BBBC039) |
| Outputs per cell | foreground, affinities to 4 of the 8 neighbors | object probability, center offset (2), 32 ray distances |
| Loss | BCE on foreground over all cells + BCE on affinities over valid cell pairs | BCE on probability + L1 on offsets + L1 on distances (assigned cells) |
| Optimizer | AdamW, learning rate , , weight decay | |
| Schedule | 500-iteration linear warm-up, then polynomial decay (power 0.9); 8,000 iterations | |
| Batch and crops | 16 crops of pixels at offsets that are multiples of 16, so targets of every method align | |
| Augmentation | one of the 8 rotations and flips by quarter turns, applied exactly to image and labels | |
| Input | ImageNet normalization; 16-bit BBBC039 images stretched to 8 bits between the 1st and 99.8th percentiles | |
| Precision, hardware | bfloat16; one NVIDIA A100 (BBBC038) or RTX 4090 (BBBC039) per run | |
| Seeds and folds | 9 seeds 3 folds; each image is predicted by the model of the fold that did not train on it | |
| Decoding | foreground > ; neighbors joined if affinity > ; connected components | candidates with probability > , greedy NMS at polygon IoU |
| Default thresholds | , (StarDist) | |
| Cross-validation grid | ; (BBBC038), (BBBC039) | |
neighboring foreground cells an affinity of 1 when they hold the same region; unassigned cells are background. Soft labels replace these by the nucleus fraction of each cell and, for two neighboring cells, the probability that a nucleus pixel drawn from each belongs to the same nucleus [1]. The full-resolution loss upsamples the stride-f logits bilinearly and supervises every pixel with the foreground and the same-nucleus label of the pixel pair that its cell-level channel describes. In the masked target, the cells of the nuclei missing from the majority target carry no loss. Every cell of the star-convex target that is assigned to a nucleus is supervised with the same description of it: probability 1, the offset from the cell center to the pixel of the nucleus farthest from its boundary (which always lies inside the nucleus), and the 32 ray distances from that pixel, computed as in StarDist.
Threshold cross-validation. For each model, seed and held-out fold, the cross-validated thresholds minimize the mean count error over the images of the other two folds on the grid of Tab. S2, each image scored by its own held-out model; ties go to the point nearest the default, then to the smaller thresholds. For the equal-FP point, each model takes the pair with the lowest count error among those whose FP50 on the tuning folds does not exceed the majority model's at its cross-validated pair, or the pair with the fewest false positives if none does. With every point of the grid decoded, the default points reproduce the default-threshold scores exactly. Because the thresholds minimize count error, and F1 at them describe a count-calibrated operating point. The models that predict the tuning folds were trained on images that include the evaluated fold. In a fully nested check, we selected the affinity thresholds of BBBC038 on one half of each held-out fold and evaluated them on the other half, so that neither the model nor the thresholds saw the evaluated images. The MatchDown model's count error is then 1.03 nuclei per image lower than the majority model's, lower in all nine seeds, with 1.2 points lower and 1.6 more false positives per image, the same pattern as with cross-validated thresholds; the equal-FP constraint can be met in 37 of the 54 seed, fold and half combinations.
Confidence intervals. A difference between two targets is the mean over the nine seeds of the per-seed mean over images of the per-image difference. Its 95% interval comes from 10,000 bootstrap samples that resample seeds and then images, with all targets sharing each resample, so that the pairing of targets on the same seed, fold and image is kept [14, 19]; the seed-level spread is scaled by a Student-t factor for nine seeds. Thresholds are fixed across bootstrap samples, so the intervals cover the variation over seeds and images.
D. Label-level results
Table S3 gives the share of evaluated regions each method loses on COCO-R, Cityscapes and BBBC038 at factors 2 to 16, and Tab. S4 the remaining columns at factor 8; Fig. S3 shows the losses at factor 8 by region area on COCO-R and Cityscapes. MatchDown-P's losses equal the lower bound of Theorem 4 for all 20 dataset–factor pairs (COCO-A, COCO-B, COCO-R, Cityscapes and BBBC038 at factors 2, 4, 8 and 16), and neither form of MatchDown loses an evaluated region of a cell or more on any of them. Every other method does on every pair, except maximal rescue on nine pairs and greedy rescue on BBBC038 at factors 2
Table S3. Evaluated regions lost (%) by every method, dataset and factor. Lower bound: the minimum of Theorem 4; reachable: share of evaluated regions whose IoU bound exceeds 0.5 (Proposition 5). MatchDown-P equals the lower bound in every column. At the cell-center pixel is the first pixel of the cell, so nearest (cell center) equals strided. Majority pooling counts the most frequent region in each cell; the class-first variant picks the most frequent class, then its most frequent region. On COCO-A and COCO-B every entry is within one percentage point of COCO-R. Best in bold, second best underlined.
| Method | COCO-R (25,963 regions) | Cityscapes (104,234 regions) | BBBC038 (29,668 regions) | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| f=2 | 4 | 8 | 16 | f=2 | 4 | 8 | 16 | f=2 | 4 | 8 | 16 | |
| Strided (StarDist) | 17.6 | 26.5 | 32.7 | 40.1 | 8.7 | 15.1 | 24.0 | 38.3 | 0.42 | 0.95 | 6.2 | 26.4 |
| Nearest (cell center) | 17.6 | 26.8 | 32.8 | 40.2 | 8.7 | 15.0 | 24.0 | 38.1 | 0.42 | 0.69 | 5.3 | 26.2 |
| Nearest-exact (nnU-Net) | 17.9 | 26.9 | 32.7 | 40.1 | 8.6 | 15.0 | 24.0 | 38.1 | 0.41 | 0.78 | 5.2 | 26.0 |
| Max pooling | 12.9 | 21.4 | 30.2 | 41.6 | 9.8 | 17.5 | 28.2 | 41.6 | 0.23 | 0.43 | 1.3 | 7.4 |
| Majority pooling | 24.2 | 30.5 | 35.5 | 43.2 | 14.2 | 18.7 | 27.9 | 44.0 | 0.58 | 1.1 | 9.3 | 39.0 |
| Majority, class first | 24.0 | 30.7 | 35.5 | 43.1 | 10.7 | 17.9 | 27.6 | 43.9 | 0.51 | 1.1 | 9.3 | 39.0 |
| Greedy rescue | 4.7 | 10.8 | 19.0 | 29.6 | 0.24 | 1.2 | 3.4 | 10.8 | 0.04 | 0.11 | 0.52 | 4.8 |
| Maximal rescue | 4.2 | 9.7 | 16.9 | 26.5 | 0.19 | 0.88 | 2.5 | 7.1 | 0.03 | 0.10 | 0.20 | 2.1 |
| MatchDown | 1.3 | 6.2 | 12.3 | 18.7 | 0.18 | 0.82 | 2.1 | 5.1 | 0.02 | 0.10 | 0.14 | 0.94 |
| MatchDown-P (ours) | 0.84 | 3.5 | 7.1 | 11.6 | 0.17 | 0.80 | 2.0 | 4.7 | 0.02 | 0.08 | 0.13 | 0.90 |
| Lower bound (Theorem 4) | 0.84 | 3.5 | 7.1 | 11.6 | 0.17 | 0.80 | 2.0 | 4.7 | 0.02 | 0.08 | 0.13 | 0.90 |
| Reachable (IoU bound > 0.5) | 71.4 | 66.0 | 59.4 | 47.9 | 84.5 | 76.3 | 60.7 | 40.4 | 99.4 | 98.0 | 80.5 | 44.1 |
Table S4. Label-level evaluation at factor 8, further columns. Lost (%): evaluated regions lost on the two COCO development sets. cell: lost regions of at least pixels per 1,000 evaluated regions. Recon.: share of the reachable regions that the target reconstructs at IoU under nearest upsampling. Void/crowd lost: share of the 157,318 void and crowd components of COCO-R missing from the target; MatchDown and MatchDown-P lose the same total number of components (70,559) and differ only in which ones. -: not computed for this method. Best in bold, second best underlined.
| Method | Lost (%) ↓ | ≥1 cell (per 1,000) ↓ | Recon. (%) ↑ | Void/crowd lost (%) ↓ | |||||
|---|---|---|---|---|---|---|---|---|---|
| COCO-A | COCO-B | COCO-R | Cityscapes | BBBC038 | COCO-R | Cityscapes | BBBC038 | ||
| Strided (StarDist) | 32.2 | 32.1 | 6.8 | 26.6 | 12.2 | 81.1 | 69.1 | 59.8 | 93.3 |
| Nearest (cell center) | 32.2 | 32.1 | 6.2 | 27.7 | 4.4 | 97.8 | 96.0 | 96.7 | - |
| Nearest-exact (nnU-Net) | 32.3 | 32.0 | 5.8 | 27.4 | 5.3 | 97.7 | 95.9 | 96.7 | 93.3 |
| Max pooling | 29.5 | 30.0 | 35.9 | 76.8 | 1.6 | 74.5 | 64.6 | 60.3 | 97.8 |
| Majority pooling | 34.9 | 34.7 | 7.5 | 35.1 | 16.5 | 98.4 | 96.1 | 94.8 | 96.8 |
| Majority, class first | 34.9 | 34.6 | 8.0 | 33.0 | 16.5 | 98.3 | 96.4 | 94.8 | - |
| Greedy rescue | 18.0 | 18.0 | 2.7 | 0.91 | 0.34 | 89.9 | 94.8 | 94.1 | 44.1 |
| Maximal rescue | 16.2 | 16.1 | 0.35 | 0.02 | 0.00 | 89.6 | 94.7 | 94.1 | - |
| MatchDown | 11.9 | 12.1 | 0.00 | 0.00 | 0.00 | 89.5 | 94.9 | 94.3 | 42.8 |
| MatchDown-P (ours) | 6.7 | 6.6 | 0.00 | 0.00 | 0.00 | 89.5 | 94.9 | 94.3 | 43.7 |
and 4. On Cityscapes, MatchDown-P also equals the lower bound in each of the six cities. Against MatchDown, the tiers lower the losses most on COCO (from 3,073 to 1,728 regions on COCO-A at factor 8) at a disagreement cost of at most of pixels; on the BBBC038 images both keep the same nuclei. Keeping more regions adds spurious adjacencies: on COCO-A at factor 8, MatchDown-P has 4,634 spurious and 8,655 missing adjacencies among evaluated regions, against 3,367 and 10,196 for MatchDown.
Figures S5 to S7 show majority and MatchDown-P targets at factor 8 on images at the 25th, 50th and 75th percentiles of the per-image difference between the evaluated regions the two targets lose.
Label pyramids. A label pyramid built by repeated majority pooling loses more than one direct pooling to the same factor: 7,277 evaluated regions against 2,772 on BBBC038 at factor 8 (Fig. S4a). Direct MatchDown-P never loses more than an iterated construction, because an iterated labeling is one supported labeling of the same grid. On Cityscapes the pyramid loses 36,331 evaluated regions at factor 8 against 29,100 for direct pooling, and 9,302 against 9,207 on COCO-R; iterated MatchDown-P loses 71 against 38 on BBBC038 and 2,858 against 2,077 on Cityscapes.
Reconstruction quality. Tables S5 and S6 report the panoptic quality of the reconstructed targets. At factor 2, MatchDown loses 336 evaluated regions on COCO-R at a PQ cost of 0.58 points against class-first majority pooling, and greedy rescue loses 1,228 at the same PQ cost. At larger factors, keeping regions that are not reachable lowers recog-

Figure S3. Loss by region area on COCO-R and Cityscapes at factor 8 (BBBC038 is Fig. 2b). Per area bin, labeled by its lower edge: the share of evaluated regions each method loses, the share that is reachable (IoU bound above 0.5, shaded), and the share that the MatchDown-P target reconstructs at IoU > 0.5. The dotted vertical line marks one cell.
a

b

Figure S4. Every factor. (a) Evaluated regions lost on BBBC038 at factors 2 to 16, with the label pyramids built by repeated downsampling (dotted, open markers). Iterated majority pooling loses more than direct pooling to the same factor, and iterated MatchDown-P never loses fewer regions than direct MatchDown-P, which equals the lower bound at every factor. (b) Share of evaluated regions that are reachable (IoU bound above 0.5) on COCO-R, Cityscapes and BBBC038.
nition quality: on COCO at factor 8, and 2/8 lower PQ by 1.29 and 0.69 points against class-first majority, almost entirely through RQ (RQ terms -1.13 and -0.64, SQ terms -0.16 and -0.05).
Coverage threshold. The coverage threshold trades the number of kept regions against their overlap with the cells they hold, and Theorem 9 gives the minimum loss at each (Tab. S7). On 900 Cityscapes training images at factor 8, raises class IoU by 0.36 points over class-first majority pooling (95% interval lower end 0.20), with 27% fewer lost regions, comparable mIoU and 7.5% more spurious adjacencies; removes 44% of majority's losses. At factor 2 on COCO-R, without repair loses 16% fewer evaluated regions than class-first majority (5,231 against 6,230) with PQ 0.016 points higher (Tab. S5). On the 1,000 COCO-A images at factor 4, with repair loses 7.6% fewer evaluated regions than one-hot bilinear interpolation with argmax, with 1.09 points higher reconstruction PQ (95% interval ) and 26% fewer spurious adjacencies; against majority pooling, it loses 12.9% fewer regions at 0.41 points lower PQ.
Repair, binary topology and run time. An exact integer program (HiGHS) found the fewest spurious adjacent pairs at maximum survival on 200 random BSDS crops: the repair attains it on 92.0 to 92.5% of the crops, with a mean gap of 0.09 pairs and a maximum of 3, against 0.19 to 0.20 for the assignment alone. The program omits the component guard, so the gap is conservative. On 100 binary masks (50 BSDS, 50 COCO) at factors 2, 4 and 8, our reimplementation of Chen and Peng's integer program [7] preserves binary topology exactly whenever it returns a solution, but it returns none in 22 of the 300 cases: 21 are infeasible and one reaches the time limit, which does not establish infeasibility. We test Hall's condition on the program's own support graph, which differs from ours: its components are 8-connected in the foreground and 4-connected in the

COCO-R 308476: 7 evaluated regions
Majority target: 1 lost
MatchDown-P target: 0 lost
b

COCO-R 292456: 25 evaluated regions
Majority target: 5 lost
MatchDown-P target: 1 lost
C

COCO-R 319721: 22 evaluated regions
Majority target: 10 lost
MatchDown-P target: 0 lost
Figure S5. Majority and MatchDown-P targets at factor 8 on three COCO-R images, at ranks 250, 500 and 749 of 1,000 by the per-image difference in lost evaluated regions. Left: the photograph with the region boundaries; middle and right: the majority-pooling and MatchDown-P targets drawn over it, void and crowd components in gray, each lost evaluated region outlined and ringed. (a) Image 308476, 7 evaluated regions, majority loses 1. (b) 292456, 25 regions, 5 against 1. (c) 319721, 22 regions, 10 against 0.
background, the mask is padded with a background ring of f pixels, and a component may take any cell whose block, dilated by pixels, holds one of its pixels. Because the program gives every component a cell of its own, a Hall violation on this graph makes it infeasible. Four of the infeasible cases violate the condition, and in all four the deficient components are background pieces enclosed by foreground; the other 17 infeasible cases and the time-out sat-

Cityscapes, Mönchengladbach: 57 evaluated regions
Majority target: 14 lost
MatchDown-P target: 2 lost
b

Cityscapes, Mönchengladbach: 62 evaluated regions
Majority target: 21 lost
MatchDown-P target: 0 lost
C

Cityscapes, Hamburg: 101 evaluated regions
Majority target: 34 lost
MatchDown-P target: 2 lost
Figure S6. Majority and MatchDown-P targets at factor 8 on three Cityscapes frames, chosen as in Fig. S5 (ranks 225, 450 and 674 of 900). Each row shows the -pixel window with the most regions lost by majority pooling; the left panel shows the semantic label map with the region boundaries. (a) Mönchengladbach 000000_000383, 57 evaluated regions in the window, majority loses 14 and MatchDown-P 2. (b) Mönchengladbach 000000_021104, 62 regions, 21 against 0. (c) Hamburg 000000_105464, 101 regions, 34 against 2.
isfy it, so the 17 fail for other constraints of the program, and no solved case violates the condition. MatchDown always returns a labeling and preserves binary topology exactly on 60 to 88% of the masks; it loses 0 to 11 of 170 BSDS components and 0 to 21 of 300 COCO components, against 27 to 58 and 74 to 110 for majority pooling, with a mean IoU at most 0.023 lower. Table S8 gives the run time.
Where greedy rescue fails. On BBBC039 (Tab. S9), MatchDown-P loses exactly the lower bound at every factor from 8 to 32 and never more nuclei than greedy rescue on any image. Rescue loses 3.3 times the lower bound at factor 16 and 6.3 times at factor 32, where its oracle count error is 9.5 nuclei per image against 1.5 for MatchDown-P and it loses more nuclei than MatchDown-P on 98.5% of the images.
E. Training results
Tables S10 and S12 give every BBBC038 model at the default and cross-validated thresholds, and Tab. 2 summarizes them; Fig. S8 shows where the count reduction of the affinity head comes from. Table S11 separates keeping the nuclei from how their cells are assigned. Excluding the cells of the missing nuclei from the loss recovers 0.93 nuclei per image of majority's count error at no cost, and MatchDown recovers a further 1.08 [0.84, 1.32] at an cost of 1.3 points (paired difference between the two models). A dilated target keeps every nucleus but enlarges each one by up to a ring of cells; its affinity model loses 23 points, and its star-convex model reaches 2.9 points below MatchDown at the default thresholds, with 12 more false positives per image. At factor 4 the strided target loses only 0.43% of the nuclei and recovers most of the difference to factor 8, at 3.3 more false positives per image.
Threshold sensitivity. Figure S9 shows the affinity models over the threshold grid. For the star-convex head the

BBBC038 f0c9f135: 24 nuclei
Majority target: 0 lost
MatchDown-P target: 0 lost
b

BBBC038 136000dc: 34 nuclei
Majority target: 2 lost
MatchDown-P target: 0 lost
C

BBBC038 d910b2b1: 24 nuclei
Majority target: 4 lost
MatchDown-P target: 0 lost
Figure S7. Majority and MatchDown-P targets at factor 8 on three BBBC038 images, chosen as in Fig. S5 (ranks 167, 334 and 502 of 670). (a) f0c9f135, 24 nuclei; neither target loses one, as on 27% of the images. (b) 136000dc, 34 nuclei, majority loses 2 and MatchDown-P 0. (c) d910b2b1, 24 nuclei, 4 against 0.
selected NMS threshold lies at the lower edge of the grid, 0.3, for the strided and MatchDown models; Tab. S13 extends the grid to 0.1. Under the extension, the difference between MatchDown and strided shrinks from 4.2 to 1.9 points at factor 8 and from 1.4 to 0.4 at factor 4, and the count errors move in both directions because a few large images dominate them at the new points. On BBBC038 the nearest model's cross-validated count error (5.78) is above its default (5.04), because thresholds selected on the tuning folds remove too many detections on the held-out fold.

b

C

Figure S8. Where the count reduction of the affinity head comes from. (a) BBBC038, , default thresholds: per-image count-error reduction of the MatchDown model over the majority model (mean over nine seeds) against the nuclei missing from the majority target (one image, at 126, is off the axis). (b) Every comparison of MatchDown with a baseline on both datasets and heads: the count-error reduction of the trained models against the difference between the targets themselves under oracle decoding (each target used as the prediction); letters name the baseline, followed for BBBC039 by the factor. Points on the diagonal recover the whole difference; the affinity head does so at factor 16 and recovers about half of it at factor 8. (c) Count error against of the majority and MatchDown models at every point of the threshold grid, with the default, cross-validated and equal-FP points marked (for majority the last two coincide). The MatchDown model has lower count error at every foreground threshold and lower at every threshold.
Table S5. Reconstruction quality and survival on COCO-R at factor 2 (1,000 images, 25,963 evaluated regions): reconstruction PQ over all 133 classes, evaluated regions lost, and spurious adjacencies among evaluated regions per image. “Void last” and “highest id” change only how ties are broken; the tie rule alone moves the PQ of majority pooling by 1.08 to 1.15 points. MatchDown’s PQ is 0.58 [0.48, 0.68] points (90% interval) below class-first majority. At , and 2/8 give the MatchDown target. Best in bold, second best underlined.
| Method | PQ ↑ | Lost (%) ↓ | Spurious / img ↓ |
|---|---|---|---|
| Majority, class first (void first) | 93.54 | 24.0 | 0.76 |
| Majority, class first (void last) | 94.67 | 22.6 | 1.41 |
| Majority pooling | 93.51 | 24.2 | 0.59 |
| Majority pooling (void last) | 94.66 | 22.2 | 1.47 |
| Majority pooling (ties to highest id) | 94.59 | 20.8 | 1.72 |
| One-hot bilinear + argmax | 93.40 | 23.7 | 0.66 |
| nnU-Net per-label | 94.22 | 22.9 | 1.12 |
| nnU-Net per-label (void last) | 94.27 | 21.7 | 1.40 |
| Smallest-region priority | 92.15 | 4.00 | 2.94 |
| Greedy rescue | 92.94 | 4.73 | 1.83 |
| κ=4/8, no repair | 93.56 | 20.1 | 0.81 |
| κ=4/8, repair | 93.56 | 20.1 | 0.59 |
| MatchDown, no repair | 93.01 | 1.29 | 2.52 |
| MatchDown (ours) | 92.96 | 1.29 | 1.70 |
BBBC039. Tables S14 and S15 give the nine BBBC039 models and the differences between their targets, and Fig. S10 shows two more images with all trained models. With cross-validated thresholds, the MatchDown-P affinity model has a count error 9.3 [8.2, 10.4] nuclei per image lower than the majority model at an cost of 7.2 Table S6. Reconstruction PQ on COCO-A (1,000 images, all 133 classes) at factors 2, 4 and 8, and the share of all components, void and crowd included, lost at factor 4. Smallest-region priority gives each cell the smallest region covering at least a quarter of it. Keeping more regions lowers PQ at factors 4 and 8, because many of the kept regions are not reachable (Proposition 5). Best in bold, second best underlined.
| Method | PQ ↑ | Lost (%) ↓ | ||
|---|---|---|---|---|
| f=2 | 4 | 8 | f=4 | |
| Nearest (cell center) | 93.65 | 87.92 | 78.21 | 76.7 |
| Majority pooling | 93.81 | 88.58 | 78.86 | 86.7 |
| One-hot bilinear + argmax | 93.69 | 87.08 | 75.36 | 75.8 |
| Smallest-region priority | 92.51 | 86.50 | 77.30 | 79.1 |
| Greedy rescue | 93.28 | 85.31 | 71.33 | 19.3 |
| MatchDown, no repair | 93.35 | 85.23 | 70.86 | 17.1 |
| MatchDown (ours) | 93.32 | 84.90 | 70.05 | 17.1 |
[6.7, 7.7] points. The majority and nearest affinity models select the corner of the grid (lowest foreground and highest affinity threshold), so no MatchDown-P threshold pair reaches their false-positive rate; the MatchDown-P models select interior points. Table S16 adds greedy rescue and soft labels at factor 16. The affinity model trained on rescue targets has a count error 0.60 [0.26, 0.97] higher than the MatchDown-P model, 0.85 of the difference between the targets themselves, with 4.7 fewer false positives, 3.1 points higher, and 4.6 points fewer of the nuclei missing from its own target detected. Soft labels raise the count error by 11.5 [10.6, 12.5] and detect 24.8 points fewer of the nuclei missing from the majority target, at
Table S7. Coverage threshold . Evaluated regions lost, as a fraction of those lost by class-first majority pooling on the same images. Uncovered-region bound: regions with no cell covered to and no fixed majority cell, which every -restricted labeling loses (Appendix A.5). Unweighted: the unweighted construction on the thresholded support graph. The tiered construction, with the regions already kept by uncovered cells ranked last, attains the exact minimum of Theorem 9 on every image, checked against the minimum computed separately; on Cityscapes at that minimum is 0.5621.
| Dataset | Uncovered-region bound | Unweighted | |
|---|---|---|---|
| Cityscapes () | 1/8 | 0.5589 | 0.5627 |
| 2/8 | 0.7254 | 0.7274 | |
| 4/8 | 0.9816 | 0.9816 | |
| COCO () | 1/8 | 0.8280 | 0.8303 |
| 2/8 | 0.9149 | 0.9159 | |
| 4/8 | 0.9988 | 0.9988 | |
| COCO-R () | 4/8 | 0.8396 | 0.8396 |
Table S8. Run time on one core of an Intel Xeon Platinum 8468: median over 120 inputs at factor 4 (five repeats) relative to majority pooling, and a full 1024×2048 Cityscapes frame at factor 8. Time grows about linearly with image size (log–log slopes 0.92 to 1.01). The target is built once before training; training and inference are unchanged.
| Method | Relative time | Cityscapes frame |
|---|---|---|
| Majority pooling | ||
| MatchDown | ||
| , no repair | ||
| , with repair |
Table S9. Where greedy rescue fails, BBBC039 at factors 8 to 32 (197 images, 23,615 nuclei), label level. Bound (the lower bound of Theorem 4), rescue and MatchDown-P: nuclei lost (%); ×: rescue's loss as a multiple of the lower bound; ≥1 cell: nuclei of at least pixels lost by rescue (MatchDown-P loses none); gap: oracle count-error difference, rescue minus MatchDown-P, per image; images: share of images on which rescue loses more nuclei than MatchDown-P. MatchDown-P never loses more nuclei than rescue on any image.
| Bound | Rescue | × MatchDown-P | ≥1 cell | Gap | Images (%) | |
|---|---|---|---|---|---|---|
| 8 | 0.025 | 0.182 | 7.2× | 0.025 | 0 +0.18 | 13.2 |
| 16 | 0.271 | 0.885 | 3.3× | 0.271 | 3 +0.71 | 32.5 |
| 24 | 0.648 | 3.231 | 5.0× | 0.648 | 55 +3.10 | 86.3 |
| 32 | 1.266 | 7.948 | 6.3× | 1.266 | 15 +8.01 | 98.5 |
Acc 5.5 points higher. With the star-convex head, rescue and MatchDown-P have equal count error within the interval (-0.36 [-2.95, +1.09]), rescue's Acc is 1.4 points higher, and its matched share of the nuclei missing from the strided target is within 0.015 of MatchDown-P's.
a

b

Figure S9. Operating curves of the affinity head on BBBC038 at (means over 670 images and nine seeds): count error (a) and Acc (b) against the foreground threshold, at the default affinity threshold (thick) and at the other 18 affinity thresholds (thin, majority and MatchDown only), for five of the targets of Tab. S10. Squares mark the cross-validated thresholds (mean over the 27 selections) and diamonds the equal-FP points; for majority the two coincide. MatchDown has the lower count error at every foreground threshold and the lower Acc at every threshold.
Table S10. Affinity head on BBBC038 at factor 8 (670 images, 29,461 nuclei; 9 seeds × 3 folds, held-out predictions). Count error at the default thresholds; then differences from the majority model with 95% confidence intervals, at cross-validated thresholds and at the equal-FP point (each model's thresholds chosen so that its false positives per image do not exceed the majority model's); detected: share (%) of the 2,587 nuclei missing from the majority target that the model detects, cross-validated. From the second set of runs, whose majority model has a count error of 5.95 (Tab. S11); its differences are taken against that model. Of the MatchDown model's count-error reduction, 89% comes from nuclei that the majority model misses and the MatchDown model detects; the mean IoU bound of the 2,587 nuclei is 0.30 (Sec. 4.5). Lost nuclei: Tab. S12. Best in bold, second best underlined, in the count-error and detected columns.
| Target | Count err. ↓ | Δcount err. ↓ | ΔAcc ↑cross-validated | Δcentroid F1 ↑cross-validated | Detected (%) ↑ | |
|---|---|---|---|---|---|---|
| cross-validated | equal FP | |||||
| Majority pooling | 5.93 | ref. | ref. | ref. | ref. | 31.4 |
| Cell center | 4.64 | -1.01 [-1.34, -0.70] | -1.00 [-1.34, -0.70] | +0.022 [+0.015, +0.030] | +0.016 [+0.011, +0.021] | - |
| Greedy rescue | 3.93 | -1.43 [-2.46, -0.89] | -0.51 [-1.47, +0.23] | -0.010 [-0.016, -0.004] | +0.023 [+0.018, +0.028] | 53.0 |
| Soft labels [1] | 6.46 | -1.64 [-2.65, -1.10] | -1.38 [-2.40, -0.86] | -0.082 [-0.106, -0.056] | +0.019 [+0.013, +0.026] | 60.4 |
| Full-res. loss | 3.56 | -1.34 [-2.40, -0.75] | -0.57 [-1.56, +0.15] | +0.018 [+0.011, +0.025] | +0.028 [+0.024, +0.032] | 59.4 |
| MatchDown (ours) | 4.03 | -1.32 [-2.41, -0.75] | -0.03 [-1.08, +0.81] | -0.011 [-0.017, -0.004] | +0.022 [+0.017, +0.027] | 52.8 |
Table S11. How the target keeps nuclei, affinity head on BBBC038 at factor 8, default thresholds, from a second set of runs with the same protocol (so majority and MatchDown differ slightly from Tab. S10). Masked: majority targets with the cells of the missing nuclei excluded from the loss. Dilated: every cell a nucleus touches is labeled with it. Differences from majority with 95% confidence intervals. Best in bold (ties share the mark), second best underlined, in the lost, count-error and Acc columns.
| Target | Lost (%) | Count err. | Δcount err. | ΔAcc | Acc |
|---|---|---|---|---|---|
| Majority pooling | 8.8 | 5.95 | ref. | ref. | |
| Masked | 8.8 | 5.02 | |||
| Dilated | |||||
| MatchDown |
Table S12. Star-convex head on BBBC038 (670 images, 29,461 nuclei; 9 seeds × 3 folds). Top: lost nuclei (%), count error and Acc at the default and cross-validated thresholds, and the share of the 2,587 nuclei missing from the majority target that the model matches at IoU > 0.5 (cross-validated). Bottom: differences in Acc with 95% confidence intervals. With default thresholds tuned for factor 8, the factor-2 strided model produces 27.7 false positives per image, and 5.7 with cross-validated thresholds. All models come from the second set of BBBC038 runs (Appendix C). Best in bold, second best underlined, over all nine models.
| Factor | Target | Lost (%) ↓ | Count err. ↓ | Acc ↑ | Missing nuclei matched ↑ | ||
|---|---|---|---|---|---|---|---|
| default | cross-val. | default | cross-val. | ||||
| f=8 | Strided (StarDist) | 5.6 | 8.08 | 4.84 | 0.664 | 0.728 | 0.241 |
| Nearest (cell center) | 4.7 | 5.04 | 5.78 | 0.764 | 0.770 | 0.273 | |
| Majority pooling | 8.8 | 6.34 | 6.50 | 0.746 | 0.750 | 0.152 | |
| Greedy rescue | 0.35 | 5.14 | 4.77 | 0.765 | 0.772 | 0.331 | |
| Dilated | 0 | 14.47 | 10.47 | 0.732 | 0.767 | 0.399 | |
| MatchDown (ours) | 0 | 4.96 | 4.10 | 0.761 | 0.770 | 0.347 | |
| f=4 | Strided | 0.43 | 6.37 | 4.20 | 0.747 | 0.781 | 0.400 |
| MatchDown (ours) | 0 | 7.22 | 3.80 | 0.754 | 0.795 | 0.438 | |
| f=2 | Strided (StarDist default) | 0.04 | 22.90 | 4.30 | 0.713 | 0.786 | 0.421 |
| Difference in Acc | default | cross-validated | |||||
| Nearest – strided, f=8 | +0.100 [+0.087, +0.113] | +0.042 [+0.034, +0.049] | |||||
| Majority – strided, f=8 | +0.082 [+0.071, +0.093] | +0.022 [+0.015, +0.028] | |||||
| Dilated – strided, f=8 | +0.068 [+0.054, +0.082] | +0.039 [+0.031, +0.046] | |||||
| MatchDown – strided, f=8 | +0.097 [+0.084, +0.110] | +0.042 [+0.034, +0.049] | |||||
| MatchDown – greedy rescue, f=8 | -0.005 [-0.010, +0.001] | -0.001 [-0.007, +0.004] | |||||
| Strided, f=4 – strided, f=8 | +0.083 [+0.070, +0.097] | +0.053 [+0.046, +0.060] | |||||
| MatchDown – strided, f=4 | +0.007 [+0.003, +0.011] | +0.014 [+0.010, +0.017] | |||||
| Strided, f=2 – strided, f=8 | +0.049 [+0.033, +0.065] | +0.057 [+0.050, +0.065] | |||||
| Strided, f=2 – MatchDown, f=8 | -0.048 [-0.055, -0.041] | +0.015 [+0.009, +0.021] | |||||
Table S13. Sensitivity to the NMS search range, star-convex head on BBBC038: held-out count error and at thresholds cross-validated with NMS IoU in (the range we report) or in . The lower range raises the count error of several models, because on a few large images (up to pixels) the selected thresholds produce hundreds of objects; the difference between MatchDown and strided at factor 8 stays positive, .
| f | Target | Count err. ↓ | Acc50 ↑ | ||
|---|---|---|---|---|---|
| ≥ 0.3 | ≥ 0.1 | ≥ 0.3 | ≥ 0.1 | ||
| 8 | Strided (StarDist) | 4.84 | 4.02 | 0.728 | 0.751 |
| Nearest (cell center) | 5.78 | 7.01 | 0.770 | 0.772 | |
| Majority pooling | 6.50 | 6.45 | 0.750 | 0.755 | |
| Greedy rescue | 4.77 | 4.27 | 0.772 | 0.775 | |
| Dilated | 10.47 | 11.70 | 0.767 | 0.774 | |
| MatchDown (ours) | 4.10 | 5.13 | 0.770 | 0.770 | |
| 4 | Strided | 4.20 | 3.61 | 0.781 | 0.788 |
| MatchDown (ours) | 3.80 | 4.49 | 0.795 | 0.792 | |
| 2 | Strided | 4.30 | 13.92 | 0.786 | 0.785 |
Table S14. Trained models on BBBC039 (197 images, 23,615 nuclei; 9 seeds × 3 folds, held-out predictions). Count error and at the default and cross-validated thresholds; Acc, detected and matched at the default thresholds. Detected: share of the nuclei missing from the majority target (2,382 at factor 16, 1,363 at factor 8) that the model detects (Appendix B); matched: share of the nuclei missing from the strided target (1,852 and 1,147) that the model matches at IoU > 0.5. Differences with intervals: Tab. S15. Best in bold, second best underlined, within each head and factor.
| Target | Count err. ↓ | Acc ↑ | Acc50 ↑ | Detected ↑ | Matched ↑ | ||
|---|---|---|---|---|---|---|---|
| default | cross-val. | default | cross-val. | ||||
| Affinity head, factor 16 | |||||||
| Majority pooling | 15.86 | 13.05 | 0.105 | 0.472 | 0.497 | 0.034 | 0.037 |
| Nearest (cell center) | 14.23 | 10.43 | 0.116 | 0.523 | 0.539 | 0.133 | 0.038 |
| MatchDown-P (ours) | 3.95 | 3.77 | 0.094 | 0.418 | 0.425 | 0.300 | 0.104 |
| Star-convex head, factor 16 | |||||||
| Strided (StarDist) | 7.79 | 5.62 | 0.594 | 0.816 | 0.799 | 0.234 | 0.022 |
| Nearest (cell center) | 13.64 | 11.57 | 0.678 | 0.854 | 0.855 | 0.117 | 0.081 |
| MatchDown-P (ours) | 3.74 | 3.35 | 0.636 | 0.831 | 0.827 | 0.495 | 0.303 |
| Star-convex head, factor 8 | |||||||
| Strided (StarDist) | 4.81 | 4.29 | 0.669 | 0.844 | 0.847 | 0.128 | 0.019 |
| Nearest (cell center) | 5.54 | 5.51 | 0.704 | 0.883 | 0.871 | 0.216 | 0.220 |
| MatchDown-P (ours) | 3.15 | 2.90 | 0.683 | 0.865 | 0.873 | 0.550 | 0.339 |
Table S15. Differences between targets on BBBC039 (197 images; 9 seeds × 3 folds, held-out predictions), at the default and the cross-validated thresholds, with 95% confidence intervals from a bootstrap over seeds and images. Each row is MatchDown-P minus the named target; negative count-error differences favor MatchDown-P.
| Head | Target | count error | Acc50 | ||
|---|---|---|---|---|---|
| default | cross-val. | default | cross-val. | ||
| Affinity, f=16 | minus majority | -11.90 [-12.96, -10.89] | -9.27 [-10.36, -8.24] | -0.054 [-0.058, -0.050] | -0.072 [-0.077, -0.067] |
| minus nearest | -10.28 [-11.20, -9.40] | -6.66 [-7.53, -5.80] | -0.105 [-0.110, -0.100] | -0.115 [-0.121, -0.108] | |
| Star-convex, f=16 | minus strided | -4.05 [-4.99, -3.22] | -2.27 [-3.01, -1.58] | +0.014 [+0.008, +0.022] | +0.027 [+0.019, +0.037] |
| minus nearest | -9.90 [-10.74, -9.11] | -8.22 [-9.16, -7.32] | -0.023 [-0.027, -0.018] | -0.028 [-0.034, -0.023] | |
| Star-convex, f=8 | minus strided | -1.66 [-2.24, -1.11] | -1.38 [-1.85, -0.92] | +0.021 [+0.016, +0.025] | +0.026 [+0.021, +0.031] |
| minus nearest | -2.39 [-6.60, -0.70] | -2.61 [-7.44, -0.12] | -0.019 [-0.023, -0.013] | +0.003 [-0.005, +0.010] | |

Image
67 nuclei
b

Labels

Majority target
39 lost

MatchDown-P target
1 lost

Trained on majority
22 missed

Trained on nearest
21 missed

Trained on MatchDown-P
4 missed
b

Strided target
22 lost

MatchDown-P target
1 lost

Trained on strided
35 missed at IoU > 0.5

Trained on nearest
34 missed at IoU > 0.5

Trained on MatchDown-P
27 missed at IoU > 0.5
c

Image
85 nuclei

Majority target
21 lost

MatchDown-P target
2 lost

Trained on majority
16 missed

Trained on nearest
15 missed

Trained on MatchDown-P
6 missed
d

Labels

Strided target
15 lost

MatchDown-P target
2 lost

Trained on strided
26 missed at IoU > 0.5

Trained on nearest
20 missed at IoU > 0.5

Trained on MatchDown-P
22 missed at IoU > 0.5
Figure S10. Two more held-out BBBC039 images at factor 16 (320×448-pixel windows holding 67 and 85 of the images' 101 and 185 nuclei), as in Fig. 3, with the models trained on nearest targets added: (a, c) the affinity head, (b, d) the star-convex head. On the first image the affinity models trained on majority, nearest and MatchDown-P targets predict 52, 60 and 99 objects for 101 nuclei.
Table S16. Greedy rescue and soft labels against MatchDown-P on BBBC039 at factor 16 (197 images; 9 seeds × 3 folds, held-out predictions, default thresholds; a separate set of runs with the BBBC039 protocol, in which the MatchDown-P models were trained again so that every difference is paired). Top: means; signed: mean predicted minus true count per image; FP50: false positives per image at IoU > 0.5; detected: share of the nuclei missing from the majority target (2,382) or from the rescue target (209) that the model detects; matched: share of the 1,852 nuclei missing from the strided target matched at IoU > 0.5. Bottom: differences, the named target minus MatchDown-P, with 95% confidence intervals, and the difference between the targets themselves under oracle decoding. Best in bold within each head. One MatchDown-P star-convex run over-counts by 22.7 nuclei per image and widens that interval; because of it, the retrained MatchDown-P models' means differ from Tab. S14 (star-convex count error 4.76 here, 3.74 there; affinity 3.85 and 3.95).
| Head | Target | Count err. ↓ | Signed | Acc ↑ | Acc50 ↑ | FP50 ↓ | Detected ↑ | Matched ↑strided-missing | |
|---|---|---|---|---|---|---|---|---|---|
| majority-missing | rescue-missing | ||||||||
| Affinity | MatchDown-P (ours) | 3.85 | -2.7 | 0.094 | 0.418 | 48.1 | 0.300 | 0.308 | 0.104 |
| Greedy rescue | 4.45 | -3.9 | 0.101 | 0.449 | 43.4 | 0.289 | 0.262 | 0.104 | |
| Soft labels [1] | 15.36 | -15.4 | 0.105 | 0.472 | 33.0 | 0.051 | 0.065 | 0.042 | |
| Star-convex | MatchDown-P (ours) | 4.76 | -1.7 | 0.634 | 0.827 | 10.7 | 0.491 | 0.350 | 0.301 |
| Greedy rescue | 4.39 | -3.6 | 0.648 | 0.841 | 8.4 | 0.482 | 0.281 | 0.316 | |
| Target | count err. | Acc | FP50 | detected | Oracle | |
|---|---|---|---|---|---|---|
| majority | rescue | |||||
| Affinity, rescue | +0.60 [+0.26, +0.97] | +0.031 [+0.027, +0.035] | -4.7 [-5.3, -4.1] | -0.01 [-0.02, +0.00] | -0.05 [-0.08, -0.02] | +0.71 |
| Affinity, soft | +11.51 [+10.62, +12.47] | +0.055 [+0.050, +0.059] | -15.1 [-16.2, -14.0] | -0.25 [-0.26, -0.23] | -0.24 [-0.30, -0.19] | - |
| Star-convex, rescue | -0.36 [-2.95, +1.09] | +0.014 [+0.007, +0.022] | -2.3 [-5.2, -0.8] | -0.01 [-0.02, +0.01] | -0.07 [-0.11, -0.02] | +0.74 |