Our new X account is live! Follow @wizwand_team for updates
WorkDL logo mark

Frustratingly Easy Test-Time Adaptation of Vision-Language Models

About

Vision-Language Models seamlessly discriminate among arbitrary semantic categories, yet they still suffer from poor generalization when presented with challenging examples. For this reason, Episodic Test-Time Adaptation (TTA) strategies have recently emerged as powerful techniques to adapt VLMs in the presence of a single unlabeled image. The recent literature on TTA is dominated by the paradigm of prompt tuning by Marginal Entropy Minimization, which, relying on online backpropagation, inevitably slows down inference while increasing memory. In this work, we theoretically investigate the properties of this approach and unveil that a surprisingly strong TTA method lies dormant and hidden within it. We term this approach ZERO (TTA with "zero" temperature), whose design is both incredibly effective and frustratingly simple: augment N times, predict, retain the most confident predictions, and marginalize after setting the Softmax temperature to zero. Remarkably, ZERO requires a single batched forward pass through the vision encoder only and no backward passes. We thoroughly evaluate our approach following the experimental protocol established in the literature and show that ZERO largely surpasses or compares favorably w.r.t. the state-of-the-art while being almost 10x faster and 13x more memory-friendly than standard Test-Time Prompt Tuning. Thanks to its simplicity and comparatively negligible computation, ZERO can serve as a strong baseline for future work in this field. The code is available at https://github.com/FarinaMatteo/zero.

Matteo Farina, Gianni Franchi, Giovanni Iacca, Massimiliano Mancini, Elisa Ricci• 2024

Related benchmarks

TaskDatasetResultRank
Image ClassificationCIFAR-100
Top-1 Accuracy71.56
622
Image ClassificationImageNet A
Top-1 Acc49.02
553
Image ClassificationFood-101
Accuracy87.11
494
Image ClassificationImageNet V2
Top-1 Acc64.32
487
Image ClassificationImageNet-R
Top-1 Acc82.42
474
Image ClassificationImageNet-Sketch
Top-1 Accuracy56.53
360
Image ClassificationImageNet-R (val)
Accuracy87.21
82
ClassificationCIFAR-10
Accuracy88.54
80
Image ClassificationCross-domain Benchmark (AIR, CAL, CAR, DTD, EUR, FLWR, FOOD, PETS, SUN, UCF) (test)
AIR Accuracy33.9
67
Image ClassificationImageNet original (val)
Top-1 Acc75.52
65
Showing 10 of 67 rows

Other info

Code

Follow for update