Skip to main content
QUICK REVIEW

[Paper Review] Improving Zero-Shot Models with Label Distribution Priors

Jonathan Kahana, Niv Cohen|arXiv (Cornell University)|Dec 1, 2022
Domain Adaptation and Few-Shot LearningComputer Science5 citations
TL;DR

This paper proposes CLIPPR, a method to improve zero-shot vision-and-language models like CLIP without using any labeled data by leveraging a prior distribution over labels. It trains an adapter network that balances preserving CLIP’s original zero-shot predictions and aligning predicted label distributions with the assumed prior, achieving a 28% relative reduction in mean absolute error on UTK age regression and a 2.83% accuracy gain on ImageNet classification.

ABSTRACT

Labeling large image datasets with attributes such as facial age or object type is tedious and sometimes infeasible. Supervised machine learning methods provide a highly accurate solution, but require manual labels which are often unavailable. Zero-shot models (e.g., CLIP) do not require manual labels but are not as accurate as supervised ones, particularly when the attribute is numeric. We propose a new approach, CLIPPR (CLIP with Priors), which adapts zero-shot models for regression and classification on unlabelled datasets. Our method does not use any annotated images. Instead, we assume a prior over the label distribution in the dataset. We then train an adapter network on top of CLIP under two competing objectives: i) minimal change of predictions from the original CLIP model ii) minimal distance between predicted and prior distribution of labels. Additionally, we present a novel approach for selecting prompts for Vision & Language models using a distributional prior. Our method is effective and presents a significant improvement over the original model. We demonstrate an improvement of 28% in mean absolute error on the UTK age regression task. We also present promising results for classification benchmarks, improving the classification accuracy on the ImageNet dataset by 2.83%, without using any labels.

Motivation & Objective

  • Address the poor performance of zero-shot models like CLIP on regression tasks due to mismatched label distributions.
  • Overcome the lack of labeled data for training, especially for long-tail attributes or numeric attributes like age.
  • Improve zero-shot classification and regression by incorporating prior knowledge of label distributions without requiring annotated examples.
  • Develop a method that adapts pre-trained V&L models using only unlabelled data and a distributional prior on labels.
  • Enable robust adaptation across diverse datasets by minimizing reliance on hyperparameters and maintaining fidelity to original model predictions.

Proposed method

  • Train an adapter module on top of a frozen vision-and-language (V&L) model encoder, such as CLIP, using only unlabelled images and a prior on label distribution.
  • Optimize the adapter with two competing objectives: (1) minimizing deviation from the original CLIP zero-shot predictions (via L2 loss on logits), and (2) minimizing the distributional distance between predicted and prior label distributions (via Wasserstein distance).
  • Use a weighted combination of the two objectives, with hyperparameter α balancing the trade-off between preserving original predictions and fitting the prior.
  • Select task-specific textual prompts based on the label prior, improving prompt engineering for zero-shot tasks without labeled data.
  • Apply distribution matching using the sliced Wasserstein distance for multivariate regression extensions, though this is left for future work.
  • Estimate the label prior from external sources or domain knowledge, such as demographic statistics or known data distributions.

Experimental results

Research questions

  • RQ1Can a prior distribution over labels significantly improve zero-shot regression performance in the absence of any annotated data?
  • RQ2How can a vision-and-language model be adapted to better reflect the true label distribution of a target dataset without access to labels?
  • RQ3To what extent does preserving the original zero-shot predictions while aligning with a label prior improve model accuracy across diverse tasks?
  • RQ4Can the proposed method generalize to both regression and classification tasks with minimal hyperparameter tuning?
  • RQ5How robust is the method to inaccuracies in the estimated label prior or failure cases in the base V&L model’s zero-shot predictions?

Key findings

  • CLIPPR reduces the mean absolute error (MAE) on the UTK age regression benchmark from 7.99 to 5.73, representing a 28% relative improvement over CLIP’s zero-shot performance.
  • The method improves ImageNet top-1 classification accuracy by 2.83% over CLIP’s zero-shot baseline, without using any labeled examples.
  • The method achieves consistent improvements across multiple datasets, with optimal performance at α = 1, and remains robust across different α values (0.3, 1, 3).
  • CLIPPR outperforms state-of-the-art few-shot methods like Tip-Adapter even with 32 shots per class on the UTK dataset, demonstrating strong zero-shot generalization.
  • The method is effective for both regression and classification, showing that distributional priors can be leveraged to enhance zero-shot performance across modalities.
  • Failure cases occur when CLIP’s zero-shot predictions are fundamentally incorrect (e.g., random-like), as the method relies on the base model’s outputs as a starting point.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.