CLIPer: Hierarchically Improving Spatial Representation of CLIP for Open-Vocabulary Semantic Segmentation

Lin Sun, Jiale Cao, Jin Xie, Xiaoheng Jiang, Yanwei Pang
11/21/2024
cs.CV

No official code found. Best implementation: linsun449/cliper.code (42 stars, last commit 2025-09-10).

Abstract

Contrastive Language-Image Pre-training (CLIP) exhibits strong zero-shot classification ability on various image-level tasks, leading to the research to adapt CLIP for pixel-level open-vocabulary semantic segmentation without additional training. The key is to improve spatial representation of image-level CLIP, such as replacing self-attention map at last layer with self-self attention map or vision foundation model based attention map. In this paper, we present a novel hierarchical framework, named CLIPer, that hierarchically improves spatial representation of CLIP. The proposed CLIPer includes an early-layer fusion module and a fine-grained compensation module. We observe that, the embeddings and attention maps at early layers can preserve spatial structural information. Inspired by this, we design the early-layer fusion module to generate segmentation map with better spatial coherence. Afterwards, we employ a fine-grained compensation module to compensate the local details using the self-attention maps of diffusion model. We conduct the experiments on seven segmentation datasets. Our proposed CLIPer achieves the state-of-the-art performance on these datasets. For instance, using ViT-L, CLIPer has the mIoU of 69.8% and 43.3% on VOC and COCO Object, outperforming ProxyCLIP by 9.2% and 4.1% respectively.

View on arXivView PDF

Code Implementations(1)

This repo is the official pytorch implementation of the paper: CLIPer: Hierarchically Improving Spatial Representation of CLIP for Open-Vocabulary Semantic Segmentation

420Shell, PythonNov 20, 20241 years ago
clipopen-vocabulary-semantic-segmentationstable-diffusion

Similar Papers

Cite this paper

@article{sun2024cliper,
  title  = {CLIPer: Hierarchically Improving Spatial Representation of CLIP for Open-Vocabulary Semantic Segmentation},
  author = {Lin Sun and Jiale Cao and Jin Xie and Xiaoheng Jiang and Yanwei Pang},
  year   = {2024},
  eprint = {2411.13836},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2411.13836v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2411.13836.svg)](https://codeofpaper.com/paper/2411.13836)

Discussion