Skip to main content
QUICK REVIEW

[Paper Review] HiCLIP: Contrastive Language-Image Pretraining with Hierarchy-aware Attention

Shijie Geng, Jianbo Yuan|arXiv (Cornell University)|Mar 6, 2023
Multimodal Machine Learning ApplicationsComputer Science11 citations
TL;DR

HiCLIP adds hierarchy-aware attention to both image and text branches of CLIP, enabling unsupervised discovery of hierarchical structures and improving cross-modal alignment for vision and vision-language tasks.

ABSTRACT

The success of large-scale contrastive vision-language pretraining (CLIP) has benefited both visual recognition and multimodal content understanding. The concise design brings CLIP the advantage in inference efficiency against other vision-language models with heavier cross-attention fusion layers, making it a popular choice for a wide spectrum of downstream tasks. However, CLIP does not explicitly capture the hierarchical nature of high-level and fine-grained semantics conveyed in images and texts, which is arguably critical to vision-language understanding and reasoning. To this end, we equip both the visual and language branches in CLIP with hierarchy-aware attentions, namely Hierarchy-aware CLIP (HiCLIP), to progressively discover semantic hierarchies layer-by-layer from both images and texts in an unsupervised manner. As a result, such hierarchical aggregation significantly improves the cross-modal alignment. To demonstrate the advantages of HiCLIP, we conduct qualitative analysis on its unsupervised hierarchy induction during inference, as well as extensive quantitative experiments on both visual recognition and vision-language downstream tasks.

Motivation & Objective

  • Motivate explicit modeling of hierarchical (local-to-global) semantics in both vision and language for improved multimodal understanding.
  • Develop hierarchy-aware attention masks that progressively merge neighboring patches/tokens across layers.
  • Evaluate HiCLIP's impact on visual recognition, image-text retrieval, and vision-language reasoning, comparing to CLIP-family baselines.

Proposed method

  • Define hierarchy-aware attention by introducing a mask C that biases attention toward merging spatially/semantically similar patches or tokens.
  • For language, compute neighboring affinity scores between adjacent tokens, enforce non-splittable, increasing affinity across layers, and derive C from product of affinities along token paths.
  • For vision, extend to 2D grid graphs by computing neighboring affinities among four-connected patches and propagating scores via two 1-turn paths to form C, yielding a Group Transformer.
  • Pretrain HiCLIP with Group Transformer (images) and Tree Transformer (texts) using a CLIP-style contrastive loss across image-text pairs; option to combine with self-supervised objectives (HiDeCLIP).
  • During inference, perform unsupervised hierarchy induction by extracting neighboring affinity scores across layers to form hierarchical trees/groups.

Experimental results

Research questions

  • RQ1Can hierarchy-aware attention improve cross-modal alignment in CLIP for zero-shot visual recognition and downstream vision-language tasks?
  • RQ2How do hierarchical structures emerge in images and texts under HiCLIP, and can they be used for unsupervised hierarchy induction?
  • RQ3How does HiCLIP scale with data size and model capacity on vision-only versus vision-language tasks compared to CLIP and related baselines?

Key findings

  • HiCLIP achieves large gains over CLIP-style baselines on zero-shot visual recognition; for 15M data, average accuracy across 11 datasets improves from 31.8 (CLIP) to 41.8 (HiCLIP).
  • With 30M data, HiCLIP attains average 53.4 on vision-only benchmarks, vs CLIP 48.4, and 57.4 for HiDeCLIP, indicating scalable benefits with larger pretraining.
  • HiCLIP/HiDeCLIP significantly improve zero-shot image-text retrieval on MSCOCO across data scales; HiCLIP (15M) achieves Rsum 285.1 vs CLIP 211.5; HiCLIP (30M) achieves Rsum 333.5 vs CLIP 300.8.
  • Vision-language reasoning tasks (VQA, SNLI-VE) also benefit from HiCLIP, with higher accuracy and retrieval metrics over CLIP and DeCLIP baselines.
  • Unsupervised hierarchy induction is demonstrated: visual and textual hierarchies emerge across layers, enabling interpretable hierarchical representations.

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.