NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Interpretable Image Classification with Adaptive Prototype-based Vision Transformers

Chiyu Ma, Jon Donnelly, Wenjun Liu, Soroush Vosoughi, Cynthia Rudin, Chaofan Chen

Introduction

Deep learning models, particularly in sensitive domains like healthcare or criminal justice, often suffer from a "black-box" problem where their decision-making processes are opaque. Prototype-based networks offer a promising solution through case-based reasoning—classifying images by comparing their parts to learned "prototypes" (representative patches) from the training set. However, traditional approaches based on Convolutional Neural Networks (CNNs) are limited by rigid, rectangular prototype geometries that fail to capture the natural variation of real-world objects. Furthermore, previous attempts to bring this reasoning to Vision Transformers (ViTs) often failed to maintain inherent interpretability.

The ProtoViT Architecture

ProtoViT addresses these limitations by integrating a ViT backbone with a novel prototypical reasoning layer. This architecture ensures that the model's internal logic is grounded in actual training examples that a human can verify, bridging the gap between high-performance transformers and interpretable case-based reasoning.

The ProtoViT architecture, featuring a Transformer Encoder followed by a Greedy Matching and Prototype Layer.

Key Methodological Innovations

  • Deformable Prototypes & Greedy Matching: Instead of rigid boxes, prototypes consist of $K$ sub-prototypes. A greedy matching algorithm allows these parts to adapt to the irregular geometry of objects in test images, such as a bird's neck bending.
  • Adjacency Masking: To maintain semantic coherence, an adjacency mask ensures that matched parts remain spatially contiguous, preventing the model from associating unrelated features (e.g., explaining a bird's head using a patch of its tail).
  • Adaptive Slots: The model automatically prunes unnecessary sub-prototypes using a sigmoid-based mechanism, learning the optimal complexity for each feature.
  • Focal Similarity: By subtracting the ViT's global "class token" from patch tokens, the model acts as a high-pass filter for semantics, forcing prototypes to focus on unique, salient features rather than common background elements.

Experimental Results and Interpretability

The model was evaluated on the CUB-200-2011 (fine-grained bird species) and Stanford Cars datasets. ProtoViT achieved state-of-the-art accuracy for interpretable models, reaching 85.37% on CUB-200-2011 (DeiT-Small) and 92.40% on Stanford Cars (CaiT). Remarkably, ProtoViT often outperformed the standard "black-box" ViT backbones it was built upon, proving that interpretability can enhance rather than hinder performance.

Visual comparison of classification explanations across different prototype-based models, highlighting ProtoViT's semantic coherence.

Beyond raw metrics, ProtoViT provides significantly clearer explanations. As illustrated in the visual comparison, while previous methods like ProtoPNet use broad, ambiguous boxes, ProtoViT's deformable prototypes adapt to the object's shape. This flexibility results in semantically coherent "this looks like that" evidence that humans find much easier to understand.

Conclusion and Future Directions

ProtoViT demonstrates that the global attention mechanism of ViTs can be effectively harnessed for interpretable reasoning. By allowing prototypes to deform and adapt, the model provides a robust framework for transparent AI without sacrificing accuracy. Future research will explore integrating Vision-Language Models (VLMs) to provide natural language justifications and further refining location alignment to eliminate information leakage in deep transformer layers.

Summary updated

BibTeX
@inproceedings{ma2024interpretable,
  author = {Chiyu Ma and Jon Donnelly and Wenjun Liu and Soroush Vosoughi and Cynthia Rudin and Chaofan Chen},
  title = {{Interpretable Image Classification with Adaptive Prototype-based Vision Transformers}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2024},
  url = {https://openreview.net/forum?id=hjhpCJfbFG},
}
Figure