clip-vit-base-patch32-onnx (vision tower, dynamic int8)
Mirror of the vision tower of OpenAI CLIP ViT-B/32 in ONNX, dynamically quantized to 8 bit. Used by the Ipsilon apps for on-device image similarity (512-d image embeddings). The text tower is not included.
Provenance
- Upstream: https://huggingface.co/Xenova/clip-vit-base-patch32 (converted from
openai/clip-vit-base-patch32), commit6b7c523703ae26e39be4b03774966f8571c7f523 - File copied unchanged:
onnx/vision_model_quantized.onnx - Upstream licence: MIT (OpenAI CLIP, https://github.com/openai/CLIP)
- This repository is a verbatim mirror created 2026-11-20; no re-export, no re-quantization.
File
| File | Size (bytes) | SHA-256 |
|---|---|---|
vision_model_quantized.onnx |
89,117,001 | 583fd1110a514667812fee7d684952aaf82a99b959760c8d7dca7e0ab9839299 |
Graph (checked with onnx.load, onnx 1.20.1)
- Opset 11 (default domain), IR version 6, producer
onnx.quantize - Quantization ops:
DynamicQuantizeLinearx50,MatMulIntegerx73,ConvIntegerx1 (CPU execution; NNAPI cannot run these ops) - Input:
pixel_values, float32, shape[batch_size, num_channels, height, width](dynamic batch; use[N, 3, 224, 224]) - Output:
image_embeds, float32, shape[batch_size, 512](not L2-normalised: normalise before cosine similarity)
Required preprocessing (OpenAI CLIP)
- Resize the shorter side to 224 (bicubic), centre crop 224 x 224, RGB.
- Scale to [0, 1].
- Normalise: mean
[0.48145466, 0.4578275, 0.40821073], std[0.26862954, 0.26130258, 0.27577711]. - Layout NCHW float32.
Usage (ONNX Runtime)
import onnxruntime as ort, numpy as np
s = ort.InferenceSession("vision_model_quantized.onnx")
emb = s.run(["image_embeds"], {"pixel_values": x.astype(np.float32)})[0] # x: [N,3,224,224]
emb /= np.linalg.norm(emb, axis=1, keepdims=True)
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐ Ask for provider support
Model tree for ipsilondev/clip-vit-base-patch32-onnx
Base model
openai/clip-vit-base-patch32