Cross-domain few-shot segmentation (CD-FSS) aims to segment a target class in images from a previously unseen domain using only a few annotated support examples. Training-free CD-FSS methods, which typically leverage vision foundation models such as DINOv3, achieve competitive performance without parameter updates. However, the optimal DINOv3 layer for mask prediction varies across support--query episodes. Although several layer-selection criteria have been proposed, they do not explicitly evaluate whether the predicted query foreground and background labels agree with the corresponding support labels. To address this limitation, we propose a novel layer-selection criterion, Optimal-Transport-Based Backbone Layer Selection (OT-BLS). Our key insight is that an effective layer-selection criterion can be derived from the optimal-transport correspondence between query and support patch-token features. Based on this insight, we first estimate the transport plan using a well-established optimal transport algorithm and then compute a layer-selection score by aggregating the transported mass according to the foreground--background partition defined by each candidate query mask. The resulting score reflects how well the predicted foreground and background of the query correspond to those of the support. Experiments on eight benchmark datasets demonstrate the effectiveness of OT-BLS. It outperforms the conventional last-layer baseline in 12 of 16 dataset/shot settings. Furthermore, OT-BLS improves the average mIoU from 55.72 to 57.62 and achieves a 2.99-point improvement over the best-performing existing layer-selection criterion while running 3.7--14.6× faster.
Figures & tables
Fig. 1: Overview of OT-BLS for the case K=3 .
DeepGlobe
ISIC
SUIM
Chest X-ray
FSS-1000
SpaceNetv2
Kvasir-SEG
COCO-20i
Overall
Selection strategy
1-shot
5-shot
1-shot
5-shot
1-shot
5-shot
1-shot
5-shot
1-shot
5-shot
1-shot
5-shot
1-shot
5-shot
1-shot
5-shot
Avg.
Rank
Oracle (GT-guided upper bound)
57.55
67.02
67.19
74.34
61.60
69.41
76.57
76.72
86.79
88.14
39.59
42.78
54.99
61.87
54.55
62.92
65.13
–
Last-layer baseline
49.02
59.68
52.19
61.61
50.68
61.12
60.65
61.25
82.51
84.68
31.65
34.23
43.53
54.13
46.16
58.49
55.72
–
Layer selection
Entropy
38.33
44.10
35.68
38.59
25.57
30.24
32.45
29.74
37.50
42.92
29.39
32.99
22.05
23.39
11.70
14.43
30.57
7.63
Regularized Patch-Norm Ratio
36.84
47.06
42.32
50.43
29.91
36.02
49.31
51.37
44.61
52.84
26.86
27.81
23.99
23.51
13.53
18.21
35.91
6.56
Query Prediction Fisher Information
42.64
53.79
45.51
50.49
34.31
37.97
39.09
40.49
70.02
69.41
32.97
35.48
23.88
24.05
21.91
24.66
40.42
4.81
TABLE I: 1-shot and 5-shot performance of each method (mIoU, %). The best value among all methods except Oracle, including the last-layer baseline, is shaded light pink. The best value among the selection strategies, excluding Oracle and the last-layer baseline, is bold. Avg. denotes the mean mIoU over all 16 settings. Rank denotes the corresponding average rank over the same selection strategies. COCO-20i values are averaged over four folds. Oracle and the last-layer baseline are excluded from the rank computation.
Selection strategy
1-shot
5-shot
Rank
Entropy
2.0
2.0
2.00
Regularized Patch-Norm Ratio
0.2
0.4
1.00
Query Prediction Fisher Information
10.4
10.5
4.00
Support Prediction mIoU
17.6
75.9
6.00
Reverse mIoU Consistency
293.7
361.9
7.00
Gram Matrix Distance
14.3
15.7
5.00
TABLE II: Average runtime per episode (ms). The fastest value in each shot setting is bold. Rank is computed by sorting runtimes in ascending order among the selection strategies.
Fig. 2: Values of precisionfg , precisionbg , and s for ground-truth, under-segmented, and over-segmented masks.
Fig. 3: Effect of the foreground–background weighting parameter α in Eq. ( 2 ) on OT-BLS mIoU for 1-shot and 5-shot evaluation across the eight benchmarks.
Cross-domain Few-shot Segmentation (CD-FSS) aims to transfer knowledge learned from source domain to distinct target domains, segmenting unseen target classes with only a few annotated samples. Although existing methods have made significant progress, they still rely on training or fine-tuning processes, which incur high computational costs and risk overfitting. We observe that when powerful and general-purpose vision foundation models are incorporated into these methods, their performance shows only marginal improvement or even degrades due to overfitting. To address this, we eliminate trainable parameters and propose a training-free framework to avoid both training overhead and overfitting. Built upon the self-supervised vision encoder DINOv3, our framework addresses cross-domain challenges through three core modules. First, the Semantic-aware Feature Re-fusion (SAFR) module identifies and re-fuses features that emphasize semantic patterns, generating representations with enhanced semantic discriminability. Additionally, the Adaptive Support Enhancement (ASE) module narrows semantic gaps between support and query through robust query information aggregation. Finally, the Hybrid Prototype Matching (HPM) module integrates matching results from diverse prototypes to adapt to varying semantic complexity across domains. Extensive experiments on four target domain datasets demonstrate that our method achieves state-of-the-art performance in CD-FSS without any training.
Sujun Sun, Mingwu Ren, Haofeng Zhang
School of Computer Science and Engineering, Nanjing University of Science and Technology, China · State Key Laboratory of Intelligent Manufacturing of Advanced Construction Machinery, China
Cross-domain Few-shot Segmentation (CD-FSS) aims to learn generalizable segmentation capability from abundant annotated samples in the source domain, enabling accurate segmentation of novel classes in the target domain with only a few annotated samples. Existing CD-FSS methods mainly focus on mitigating feature distribution shifts caused by style gaps while ignoring significant differences in class semantic granularity and discriminative attributes across domains, leading to two key degradations in support-query matching: semantic over-alignment and attribute over-alignment. To this end, we propose the Dual Hierarchical Aggregation Network (DHANet), which comprises three key modules. First, the Hierarchical Spatial Aggregation (HSA) module performs multi-scale region aggregation of pixel features along the spatial dimension, generating hierarchical semantic-enhanced features to alleviate semantic over-alignment. Additionally, the HCA module conducts multi-scale attribute aggregation along the channel dimension, generating hierarchical attribute-enhanced features to mitigate attribute over-alignment. Finally, we propose the Online Probabilistic Semantic Bank (OPSB), which progressively constructs and updates class probability distributions from query predictions during inference, and samples multiple pseudo-prototypes as additional support information to mitigate insufficient support. Extensive experiments on four target-domain datasets demonstrate that our method achieves state-of-the-art performance.
Sujun Sun, Mingwu Ren, Haofeng Zhang
School of Computer Science and Engineering, Nanjing University of Science and Technology, China · State Key Laboratory of Intelligent Manufacturing of Advanced Construction Machinery, China
We present SCoRe (Support-Calibrated Role fusion), a framework to utilize two complementary vision foundation model-based (VFM) segmenters for training-free cross-domain few-shot segmentation (CD-FSS). Our approach is based on the observation that current VFMs for CD-FSS possess capabilities where one model locates the correct object, while another model computes the better contour. Our approach uses: 1. a method to identify a VFM segmenter to lead Few-Shot Segmentation (FSS) task for a given concept, 2. a novel deterministic boundary correction method using bands of near- and far-pixels at the lead segmenter's predicted boundary of an object, and 3. a region correction mechanism for the other segmenter to conservatively prune components, fill holes, and bridge short gaps on the lead segmenter's predicted masks to improve accuracy. We evaluate SCoRe using RSRM and FSS-SAM3 across 3,314 matched five-shot episodes from 10 datasets. SCoRe achieves 72.738% foreground mIoU averaged across datasets, a gain of 5.210 percentage points over RSRM (paired 95% CI [4.618, 5.972]), with per-dataset gains up to 8.461 points over the strongest standalone method and the best point estimate on 7 of 10 datasets.