HyperAIHyperAI

Command Palette

Search for a command to run...

5 months ago

OrdinalCLIP: Learning Rank Prompts for Language-Guided Ordinal Regression

Li Wanhua ; Huang Xiaoke ; Zhu Zheng ; Tang Yansong ; Li Xiu ; Zhou Jie ; Lu Jiwen

OrdinalCLIP: Learning Rank Prompts for Language-Guided Ordinal
  Regression

Abstract

This paper presents a language-powered paradigm for ordinal regression.Existing methods usually treat each rank as a category and employ a set ofweights to learn these concepts. These methods are easy to overfit and usuallyattain unsatisfactory performance as the learned concepts are mainly derivedfrom the training set. Recent large pre-trained vision-language models likeCLIP have shown impressive performance on various visual tasks. In this paper,we propose to learn the rank concepts from the rich semantic CLIP latent space.Specifically, we reformulate this task as an image-language matching problemwith a contrastive objective, which regards labels as text and obtains alanguage prototype from a text encoder for each rank. While prompt engineeringfor CLIP is extremely time-consuming, we propose OrdinalCLIP, a differentiableprompting method for adapting CLIP for ordinal regression. OrdinalCLIP consistsof learnable context tokens and learnable rank embeddings; The learnable rankembeddings are constructed by explicitly modeling numerical continuity,resulting in well-ordered, compact language prototypes in the CLIP space. Oncelearned, we can only save the language prototypes and discard the huge languagemodel, resulting in zero additional computational overhead compared with thelinear head counterpart. Experimental results show that our paradigm achievescompetitive performance in general ordinal regression tasks, and gainsimprovements in few-shot and distribution shift settings for age estimation.The code is available at https://github.com/xk-huang/OrdinalCLIP.

Code Repositories

xk-huang/OrdinalCLIP
Official
pytorch
Mentioned in GitHub

Benchmarks

BenchmarkMethodologyMetrics
aesthetics-quality-assessment-on-imageOrdinalCLIP
Accuracy: 73.05
MAE: 0.280
age-estimation-on-adience-1OrdinalCLIP
Accuracy: 61.2
MAE: 0.47
age-estimation-on-morph-album2-caucasianOrdinalCLIP
MAE: 2.32
few-shot-age-estimation-on-morph-album2OrdinalCLIP
MAE: 4.94
MAE (16 shot): 3.07
MAE (2 shot): 4.36
MAE (4 shot): 3.55
MAE (8 shot): 3.31
historical-color-image-dating-on-hciOrdinalCLIP
MAE: 0.67
accuracy: 56.44

Build AI with AI

From idea to launch — accelerate your AI development with free AI co-coding, out-of-the-box environment and best price of GPUs.

AI Co-coding
Ready-to-use GPUs
Best Pricing
Get Started

Hyper Newsletters

Subscribe to our latest updates
We will deliver the latest updates of the week to your inbox at nine o'clock every Monday morning
Powered by MailChimp
OrdinalCLIP: Learning Rank Prompts for Language-Guided Ordinal Regression | Papers | HyperAI