Interpretable Zero-Shot Learning with Locally-Aligned Vision-Language Model

Shiming Chen, Bowen Duan, Salman Khan, Fahad Shahbaz Khan

TL;DR

This paper introduces LaZSL, a novel method for interpretable zero-shot learning (ZSL) that aligns local visual features with semantic attributes using Optimal Transport. By focusing on fine-grained local interactions rather than global image-text similarity, LaZSL achieves improved accuracy and interpretability without requiring additional training data or model fine-tuning.

What Problem Does This Paper Address?

Large-scale Vision-Language Models (VLMs) like CLIP have revolutionized zero-shot learning by enabling models to classify images into categories they haven't been explicitly trained on. However, these models often lack interpretability; they tell you what they predict but not why. This is because they typically compute similarity between the entire image and category names, making it hard to pinpoint the visual cues responsible for the prediction. While some methods try to improve interpretability by using discrete attributes, they often still rely on global image-attribute alignment, which can miss crucial fine-grained details and limit generalization. This paper addresses the challenge of achieving both high performance and true interpretability in ZSL by enabling models to understand how local visual features correspond to specific attributes.

Methods

The core of LaZSL lies in its "locally-aligned vision-language model." The process involves three main steps:

  1. Construction of Semantic and Vision Sets:
    • Semantic Sets: For each category, a set of semantic attributes is generated using Large Language Models (LLMs) like GPT-3. This is done by prompting the LLM with questions like "What are useful features for distinguishing a {class name} in a photo?"
    • Vision Sets: To capture local visual information, images are divided into a set of "region vision sets" by performing random multi-scale cropping. This creates multiple local views of the image.
  2. Local Visual-Semantic Alignment Via Optimal Transport (OT):
    • Instead of a simple global similarity, LaZSL uses Optimal Transport (OT) to measure the distance and find the best alignment between the set of local visual features (from cropped regions) and the set of semantic attributes. OT is a powerful mathematical framework for finding the minimum cost to transform one probability distribution into another, making it ideal for matching sets of features.
  3. To further enhance robustness, LaZSL incorporates a "vision selection" mechanism to filter out noisy local features and a "region-global hybrid cost" approach that combines local visual information with global image features. This hybrid approach prevents knowledge forgetting in the pre-trained VLM and improves alignment.
  4. Zero-Shot Prediction:
    • The aligned visual-semantic information is used to compute a category score. The class with the highest score is then predicted. This process is designed to be interpretable, as the alignment explicitly links visual regions to specific attributes.

A key advantage is that LaZSL is training-free, meaning it leverages pre-trained VLMs like CLIP without requiring additional fine-tuning on downstream datasets.

Datasets

The paper evaluates LaZSL on nine widely-used image datasets for cross-dataset transfer learning and domain generalization. These include:

  • ImageNet: For recognizing daily objects.
  • CUB: For fine-grained bird classification.
  • Oxford Pets: For recognizing common animals.
  • Food101: For food classification.
  • Place365: For scene recognition.

Additionally, they use variants of ImageNet to test domain generalization:

  • ImageNet-V2
  • ImageNet-Sketch
  • ImageNet-A
  • ImageNet-R

Key Insights and Ideas

  • Local Alignment is Crucial for Interpretability: The paper strongly advocates for moving beyond global image-text similarity. By aligning local visual regions with specific attributes, LaZSL provides a more granular and understandable basis for classification.
  • Optimal Transport as a Powerful Matching Tool: OT proves effective in matching sets of local visual features to sets of semantic attributes, enabling a more nuanced and robust alignment than simple averaging.
  • Training-Free Interpretability: LaZSL's ability to achieve state-of-the-art performance and interpretability without additional training is a significant practical advantage, reducing computational costs and data requirements.
  • Attribute-Based Classification Mimics Human Perception: The method's success in aligning with human-understandable attributes suggests it's closer to how humans naturally perceive and classify objects.

Key Results

  • Improved Accuracy: LaZSL consistently outperforms baseline interpretable ZSL methods like DCLIP across various datasets and CLIP backbones. For example, on ImageNet, CUB, Oxford Pets, Food101, and Place365, LaZSL achieved average accuracy gains of +2.0% over DCLIP using the ViT-B/32 backbone.
  • Strong Domain Generalization: LaZSL demonstrates competitive performance on ImageNet variants with natural domain shifts, achieving an average accuracy of 60.9% without any additional training.
  • Enhanced Interpretability: Qualitative results (Figure 4) show LaZSL accurately predicting classes and providing attribute-based explanations, even for challenging fine-grained categories where DCLIP struggles.

Limitations and Future Work

  • Sensitivity to Hyperparameters: While LaZSL is shown to be relatively insensitive to the cropping scale ($\alpha$), the hybrid coefficient ($\theta$) requires careful tuning. The paper notes that excessively high $\theta$ can degrade performance, suggesting a trade-off between local and global information.
  • Reliance on LLM-Generated Attributes: The quality and comprehensiveness of the generated attributes from LLMs directly impact the model's performance. Future work could explore more sophisticated attribute generation or discovery methods.
  • Computational Cost of OT: While OT is powerful, its computation can be intensive. The paper uses the Sinkhorn algorithm for efficiency, but further optimizations might be explored.

The authors suggest that their approach of local visual-semantic alignment via OT is a promising direction for building more interpretable and accurate VLM-based ZSL systems.

Summary updated

BibTeX
@inproceedings{chen2025interpretable,
  author = {Shiming Chen and Bowen Duan and Salman Khan and Fahad Shahbaz Khan},
  title = {{Interpretable Zero-Shot Learning with Locally-Aligned Vision-Language Model}},
  booktitle = {IEEE/CVF International Conference on Computer Vision},
  year = {2025},
}
Figure