IC-643Conditioning CLIP on correct contextual attributes in the text prompt improves zero-shot classification accuracy across 13 image transformations

Bang An, Sicheng Zhu, Michael-Andrei Panaitescu-Liess, Chaithanya Kumar Mummadi, Furong Huang

SourcePerceptionCLIP: Visual Classification by Inferring and Conditioning on Contexts

The authors apply 13 image transformations (vertical flip, rotation, blur, noise, fog, etc.) to ImageNet test images and compare four prompting strategies: no attribute, random attribute, wrong attribute, and correct attribute. Conditioning on the ground-truth attribute consistently improves accuracy over the no-attribute baseline, with an average gain of +1.16% across all transformations. Self-inferred attributes (CLIP's own estimate) yield a similar +1.17% gain. On the full ImageNet test set with ViT-B/16, using the top-4 attribute composition achieves 68.80% versus 66.72% for the single template and 68.32% for 80-template prompt ensembling.

Evidence
correlational
Key metric
average accuracy gain +1.16% (correct z) and +1.17% (self-inferred z) across 13 transformations on ImageNet; ViT-B/16 ImageNet: 68.80% (top-4 attributes) vs 66.72% (single template) vs 68.32% (80 templates)
Caveat
The paper notes sensitivity to text description wording: using different synonyms for the same attribute can have non-trivial effects. Ablation with random strings of equal length shows a smaller but non-zero gain, suggesting some benefit from added tokens.
Model
CLIP / CLIP-ViT (LC)
Datasets
ImageNet-1k / ImageNet / ImageNet-1k-val / ImageNet-Val [eval], ImageNet-V2 [eval], ImageNet-R / ImageNet-Rendition [eval], ImageNet-A [eval], ImageNet-Sketch [eval], CUB-200-2011 / CUB200 [eval], EuroSAT [eval], Places365 [eval], Flowers-102 [eval], Food-101 [eval], Oxford Pets [eval]
Methods
Prompt Ensembling [compared-to]
Related work
Prompt Ensembling [compared-to]
Related findings
IC-642, IC-644
Extraction
automatic-extraction