Organizations: School of Science and Engineering, The Chinese University of Hong Kong, Shenzhen · Shenzhen Future Network of Intelligence Institute (FNii-Shenzhen) · School of Computer Science, Beijing Jiaotong University, Weihai Campus · Guangdong Provincial Key Laboratory of Future Networks of Intelligence, CUHK(SZ)
Source-free cross-domain few-shot learning (SF-CDFSL) adapts a pre-trained vision-language model such as CLIP to a distant target domain from a handful of labeled images, without access to source data. Recent methods improve the fine-tuning of CLIP with token-level interventions and apply them in the same way to every target domain. In this paper, we find that whether an intervention helps depends on how well frozen CLIP already recognizes the target domain: in 5-way 1-shot tasks, intervening improves accuracy by 0.72 points where frozen CLIP misclassifies most support images, but lowers it by 1.31 points where frozen CLIP already classifies them well, and the support set of a single episode suffices to tell the two cases apart; a bias-variance analysis explains both. Based on this finding, we propose Competence-Gated Adaptation (CoGA), which measures frozen CLIP's accuracy and margin on the labeled support set and decides, before training, whether to intervene on the visual tokens or to trust CLIP by fusing the adapted prediction with the frozen one. CoGA adds no trainable parameters and uses no query labels. On the four BSCD-FSL target domains, CoGA achieves the best average accuracy, 59.56% (1-shot) and 68.96% (5-shot), outperforms ATHA and TIR by at least 2.82 and 1.39 points on the same episodes, and consistently improves three further backbones, three parameter-efficient fine-tuning frameworks and five further target domains.
Figures & tables
Figure 1: When to intervene on CLIP. (a) Frozen CLIP’s predictions on two real 1-shot episodes and its average support accuracy c per domain: it cannot read ISIC but reads EuroSAT. (b) Mean accuracy gains over CLIP-LoRA, computed from Tab. 1 . CoGA improves all eight domain–shot settings; TIR lowers 1-shot CropDiseases by 1.55 points.
Figure 2: Intervening improves accuracy at low frozen CLIP support accuracy in both shot settings. At high support accuracy, it reduces accuracy in 1-shot and has little effect in 5-shot. (a) Frozen CLIP’s support accuracy c separates the BSCD-FSL domains (all evaluation episodes; bar: interquartile range; dot: median; dashed: τ=0.5 ; labels: gate open rate). (b) TIR gain versus average c (diagnostic sets in of the supplement). (c) Open minus closed run, binned by c (200 episodes per BSCD-FSL domain); bottom: averages on each side of τ=0.5 . Error bars in (b,c): paired 95% intervals where available; the 5-shot panel in (b) shows means only.
Figure 3: Overview of CoGA. Top: Low frozen CLIP support accuracy c and negative mean margin m via description anchors open the gate for centred-anchor token reweighting. Otherwise, CLIP adapts without reweighting and its predictions are fused with frozen CLIP’s. Both branches share a trajectory ensemble. Bottom: Support-only gate example on five leaf classes. Red frames mark true-class scores.
Figure 4: The gate on the first 1-shot episode of each BSCD-FSL domain. Marks: frozen CLIP’s prediction on each plain support image; c and m use the five views of each image ( Eqs. 2 and 3 ).
Shot
Method
Venue
Backbone
Source
ISIC
EuroSAT
CropDiseases
ChestX
Avg.
1-shot
Other backbones
StyleAdv-FT [ 5 ]
CVPR-23
ViT/DINO
✓
33.99
74.93
84.11
22.92
53.99
FLoR [ 40 ]
CVPR-24
ViT/DINO
✓
35.49
73.09
83.55
23.26
53.85
DAMIM [ 15 ]
AAAI-25
ViT/DINO
✓
36.35
73.61
83.90
23.38
54.31
CD-CLS [ 42 ]
NeurIPS-24
ViT/DINO
✓
35.56
74.97
84.53
23.39
54.62
AttnTemp [ 41 ]
NeurIPS-24
ViT/DINO
✓
38.05
75.09
84.78
23.63
55.39
Table 1: Comparison on BSCD-FSL (5-way accuracy, %). ATHA, TIR and CoGA are evaluated on the same episodes. Source : source-data training. Red , green and blue mark the top three in each column.
Method
ISIC
EuroSAT
CropD
ChestX
Avg.
5-shot
CLIP-LoRA
51.10
92.52
96.21
24.13
65.99
gated adaptation
55.64
92.31
96.80
24.99
67.44
+ online crops
56.61
92.45
97.20
26.85
68.28
+ descriptions
57.69
92.92
97.41
26.48
68.63
+ anchor centring
57.66
92.99
97.41
26.58
68.66
Table 2: Component study of CoGA (accuracy, %). We evaluate the cumulative effects of the components in our adaptation framework.
1-shot
5-shot
Switch
BSCD
Others
All
BSCD
Others
All
Always closed
59.09
67.81
63.93
68.39
78.91
74.23
Always open
58.99
62.06
60.70
68.95
76.68
73.24
Random †
59.48
68.91
64.72
68.94
79.41
74.76
c<τ only
59.52
68.79
64.67
68.95
79.41
74.76
m<0 only
59.49
68.94
64.74
68.95
79.41
74.76
Table 3: Switches between the two branches, replayed from forced runs of each (average accuracy, %). Others: five further domains, 100 episodes each; All: unweighted average over nine domains. † At the gate’s per-domain rate. ‡ Uses query labels.
Open branch
ISIC
EuroSAT
CropD
ChestX
Avg.
5-shot
ATHA
54.18
92.72
96.39
25.14
67.11
Gate + ATHA rule
55.12
93.49
97.17
26.43
68.05
Gate + no rule
57.07
93.54
97.41
26.63
68.66
Full CoGA
58.01
93.56
97.42
26.86
68.96
1-shot
Table 4: The gate with other interventions in the open branch (accuracy, %). We compare different intervention rules under the same adaptation framework.
Figure 5: Gate minus always closing versus τ , BSCD-FSL average. Band: paired 95% confidence interval of the curve. Red star: gate at τ=0.5 ; dashed: always opening; diamond: random switch. Per domain: of the supplement.
Model
ISIC
EuroSAT
CropD
ChestX
Avg.
Δ
Backbones, 1-shot
SigLIP2
42.62
83.13
87.37
21.98
58.77
+ CoGA
45.87
85.91
92.55
22.39
61.68
+2.91
PE-Core
43.49
86.09
89.66
22.68
60.48
+ CoGA
46.27
90.50
93.04
23.19
63.25
+2.77
ViT-L/14
39.40
89.05
89.63
22.46
60.14
Table 5: CoGA on other backbones (LoRA, 1-shot, 200 episodes) and fine-tuning frameworks (ViT-B/16, 5-shot; LoRA rows: 400 episodes; DoRA/SSF: 200). Δ : change in average accuracy.
Method
7-way
10-way
DTD
Aircraft
APTOS
Kvasir
PlantDoc
frozen c
–
–
0.82
0.80
0.21
0.24
0.75
CLIP-LoRA
52.27
71.85
85.28
79.21
41.05
71.80
70.58
+ ATHA
51.05
68.74
83.48
74.45
40.44
70.97
67.53
+ TIR
51.89
70.55
83.39
77.01
42.64
72.21
68.40
+ CoGA
54.58
76.53
89.23
84.35
44.33
75.84
77.19
Table 6: Beyond 5-way BSCD-FSL (accuracy, %, 100 episodes per cell). 7-/10-way: 1-shot, averaged over BSCD-FSL / over EuroSAT, CropDiseases, DTD and FGVC-Aircraft; others: mean of 1- and 5-shot. c : frozen CLIP’s average support accuracy. All rows: our runs on the same episodes, TIR at 7/10 ways with its released rule for more than five classes. Details: of the supplement.
Institute of Artificial Intelligence, Huazhong University of Science and Technology, Wuhan, China · School of Computer Science and Technology, Huazhong University of Science and Technology, Wuhan, China.
School of Computer Science and Technology, Huazhong University of Science and Technology · National Key Laboratory for Multimedia Information Processing, Peking University