MobileCLIP2: Improving Multi-Modal Reinforced Training
MobileCLIP2 was introduced in
MobileCLIP2: Improving Multi-Modal Reinforced Training
(TMLR August 2025
Featured
), by Fartash Faghri, Pavan Kumar Anasosalu Vasu, Cem Koc, Vaishaal Shankar, Alexander T Toshev, Oncel Tuzel, Hadi Pouransari.
This repository contains the
MobileCLIP-S3
checkpoint.
Highlights
MobileCLIP2-S4
matches the accuracy of SigLIP-SO400M/14 with 2x fewer parameters and surpasses DFN ViT-L/14 at 2.5x lower latency measured on iPhone12 Pro Max.
MobileCLIP-S3/S4
are our new architectures trained on MobileCLIP’s training dataset, DataCompDR-1B (dashed lines).
Our smallest variant
MobileCLIP-S0
obtains similar zero-shot performance as
OpenAI
's ViT-B/16 model while being 4.8x faster and 2.8x smaller.
MobileCLIP-S2
obtains better avg zero-shot performance than
SigLIP
's ViT-B/16 model while being 2.3x faster and 2.1x smaller, and trained with 3x less seen samples.
MobileCLIP-B (LT)
attains zero-shot ImageNet performance of
77.2%
which is significantly better than recent works like
DFN
and
SigLIP
with similar architectures or even
OpenAI's ViT-L/14@336
.
First, download the desired checkpoint visiting one of the links in the table above, then click the
Files and versions
tab, and download the PyTorch checkpoint.
For programmatic downloading, if you have
huggingface_hub
installed, you can also run:
hf download apple/MobileCLIP-S3
Then, install
ml-mobileclip
by following the instructions in the repo. It uses an API similar to
open_clip
's
.
You can run inference with a code snippet like the following:
import torch
import open_clip
from PIL import Image
from mobileclip.modules.common.mobileone import reparameterize_model
model, _, preprocess = open_clip.create_model_and_transforms('MobileCLIP2-S3', pretrained='/path/to/mobileclip_s3.pt')
tokenizer = open_clip.get_tokenizer('MobileCLIP2-S3')
# For inference/model exporting purposes, please reparameterize first
model = reparameterize_model(model.eval())
image = preprocess(Image.open("docs/fig_accuracy_latency.png").convert('RGB')).unsqueeze(0)
text = tokenizer(["a diagram", "a dog", "a cat"])
with torch.no_grad(), torch.cuda.amp.autocast():
image_features = model.encode_image(image)
text_features = model.encode_text(text)
image_features /= image_features.norm(dim=-1, keepdim=True)
text_features /= text_features.norm(dim=-1, keepdim=True)
text_probs = (100.0 * image_features @ text_features.T).softmax(dim=-1)
print("Label probs:", text_probs)
Runs of apple MobileCLIP-S3 on huggingface.co
70
Total runs
0
24-hour runs
1
3-day runs
10
7-day runs
65
30-day runs
More Information About MobileCLIP-S3 huggingface.co Model
MobileCLIP-S3 huggingface.co is an AI model on huggingface.co that provides MobileCLIP-S3's model effect (), which can be used instantly with this apple MobileCLIP-S3 model. huggingface.co supports a free trial of the MobileCLIP-S3 model, and also provides paid use of the MobileCLIP-S3. Support call MobileCLIP-S3 model through api, including Node.js, Python, http.
MobileCLIP-S3 huggingface.co is an online trial and call api platform, which integrates MobileCLIP-S3's modeling effects, including api services, and provides a free online trial of MobileCLIP-S3, you can try MobileCLIP-S3 online for free by clicking the link below.
apple MobileCLIP-S3 online free url in huggingface.co:
MobileCLIP-S3 is an open source model from GitHub that offers a free installation service, and any user can find MobileCLIP-S3 on GitHub to install. At the same time, huggingface.co provides the effect of MobileCLIP-S3 install, users can directly use MobileCLIP-S3 installed effect in huggingface.co for debugging and trial. It also supports api for free installation.