Instructions to use Library-Mutsumi/clip_onnx with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Library-Mutsumi/clip_onnx with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("zero-shot-classification", model="Library-Mutsumi/clip_onnx")# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("Library-Mutsumi/clip_onnx", dtype="auto") - Notebooks
- Google Colab
- Kaggle
Migrasi final otomatis
Browse files- README.md +30 -0
- models.parquet +3 -0
- openai/clip-vit-base-patch16/image_encode.onnx +3 -0
- openai/clip-vit-base-patch16/meta.json +15 -0
- openai/clip-vit-base-patch16/preprocessor.json +38 -0
- openai/clip-vit-base-patch16/text_encode.onnx +3 -0
- openai/clip-vit-base-patch16/tokenizer.json +0 -0
- openai/clip-vit-base-patch32/image_encode.onnx +3 -0
- openai/clip-vit-base-patch32/meta.json +15 -0
- openai/clip-vit-base-patch32/preprocessor.json +38 -0
- openai/clip-vit-base-patch32/text_encode.onnx +3 -0
- openai/clip-vit-base-patch32/tokenizer.json +0 -0
- openai/clip-vit-large-patch14-336/image_encode.onnx +3 -0
- openai/clip-vit-large-patch14-336/meta.json +15 -0
- openai/clip-vit-large-patch14-336/preprocessor.json +38 -0
- openai/clip-vit-large-patch14-336/text_encode.onnx +3 -0
- openai/clip-vit-large-patch14-336/tokenizer.json +0 -0
- openai/clip-vit-large-patch14/image_encode.onnx +3 -0
- openai/clip-vit-large-patch14/meta.json +15 -0
- openai/clip-vit-large-patch14/preprocessor.json +38 -0
- openai/clip-vit-large-patch14/text_encode.onnx +3 -0
- openai/clip-vit-large-patch14/tokenizer.json +0 -0
README.md
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
pipeline_tag: zero-shot-classification
|
| 3 |
+
base_model:
|
| 4 |
+
- openai/clip-vit-base-patch16
|
| 5 |
+
- openai/clip-vit-base-patch32
|
| 6 |
+
- openai/clip-vit-large-patch14
|
| 7 |
+
- openai/clip-vit-large-patch14-336
|
| 8 |
+
language:
|
| 9 |
+
- en
|
| 10 |
+
tags:
|
| 11 |
+
- transformers
|
| 12 |
+
- clip
|
| 13 |
+
- image
|
| 14 |
+
- dghs-realutils
|
| 15 |
+
library_name: dghs-realutils
|
| 16 |
+
---
|
| 17 |
+
|
| 18 |
+
ONNX exported version of CLIP models.
|
| 19 |
+
|
| 20 |
+
# Models
|
| 21 |
+
|
| 22 |
+
4 models exported in total.
|
| 23 |
+
|
| 24 |
+
| Name | Image (Params/FLOPS) | Image Size | Image Width (Enc/Emb) | Text (Params/FLOPS) | Text Width (Enc/Emb) | Created At |
|
| 25 |
+
|:----------------------------------------------------------------------------------------------|:-----------------------|-------------:|:------------------------|:----------------------|:-----------------------|:-------------|
|
| 26 |
+
| [openai/clip-vit-large-patch14-336](https://huggingface.co/openai/clip-vit-large-patch14-336) | 302.9M / 174.7G | 336 | 1024 / 768 | 85.1M / 1.2G | 768 / 768 | 2022-04-22 |
|
| 27 |
+
| [openai/clip-vit-large-patch14](https://huggingface.co/openai/clip-vit-large-patch14) | 302.9M / 77.8G | 224 | 1024 / 768 | 85.1M / 1.2G | 768 / 768 | 2022-03-03 |
|
| 28 |
+
| [openai/clip-vit-base-patch16](https://huggingface.co/openai/clip-vit-base-patch16) | 85.6M / 16.9G | 224 | 768 / 512 | 37.8M / 529.2M | 512 / 512 | 2022-03-03 |
|
| 29 |
+
| [openai/clip-vit-base-patch32](https://huggingface.co/openai/clip-vit-base-patch32) | 87.4M / 4.4G | 224 | 768 / 512 | 37.8M / 529.2M | 512 / 512 | 2022-03-03 |
|
| 30 |
+
|
models.parquet
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:9150f4745be893a842e26063ef95cc47aed9155eb2d3de7b8830c5cc8bb9e9af
|
| 3 |
+
size 8637
|
openai/clip-vit-base-patch16/image_encode.onnx
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:c9546aaa4e94c5ac85cb64ca74729eca7343d0c690744d746a9a0dc25907c639
|
| 3 |
+
size 345024893
|
openai/clip-vit-base-patch16/meta.json
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"image_embedding_width": 512,
|
| 3 |
+
"image_encoding_width": 768,
|
| 4 |
+
"image_flops": 16862865408.0,
|
| 5 |
+
"image_params": 85647360.0,
|
| 6 |
+
"image_size": 224,
|
| 7 |
+
"logit_scale": 4.605170249938965,
|
| 8 |
+
"name": "clip-vit-base-patch16",
|
| 9 |
+
"repo_created_at": 1646263745.0,
|
| 10 |
+
"repo_id": "openai/clip-vit-base-patch16",
|
| 11 |
+
"text_embedding_width": 512,
|
| 12 |
+
"text_encoding_width": 512,
|
| 13 |
+
"text_flops": 529199104.0,
|
| 14 |
+
"text_params": 37829632.0
|
| 15 |
+
}
|
openai/clip-vit-base-patch16/preprocessor.json
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"stages": [
|
| 3 |
+
{
|
| 4 |
+
"force_background": "white",
|
| 5 |
+
"type": "convert_rgb"
|
| 6 |
+
},
|
| 7 |
+
{
|
| 8 |
+
"antialias": true,
|
| 9 |
+
"interpolation": "bicubic",
|
| 10 |
+
"max_size": null,
|
| 11 |
+
"size": 224,
|
| 12 |
+
"type": "resize"
|
| 13 |
+
},
|
| 14 |
+
{
|
| 15 |
+
"size": [
|
| 16 |
+
224,
|
| 17 |
+
224
|
| 18 |
+
],
|
| 19 |
+
"type": "center_crop"
|
| 20 |
+
},
|
| 21 |
+
{
|
| 22 |
+
"type": "to_tensor"
|
| 23 |
+
},
|
| 24 |
+
{
|
| 25 |
+
"mean": [
|
| 26 |
+
0.48145467042922974,
|
| 27 |
+
0.45782750844955444,
|
| 28 |
+
0.40821072459220886
|
| 29 |
+
],
|
| 30 |
+
"std": [
|
| 31 |
+
0.2686295509338379,
|
| 32 |
+
0.2613025903701782,
|
| 33 |
+
0.27577710151672363
|
| 34 |
+
],
|
| 35 |
+
"type": "normalize"
|
| 36 |
+
}
|
| 37 |
+
]
|
| 38 |
+
}
|
openai/clip-vit-base-patch16/text_encode.onnx
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:777bfe38c6ff9c5230fad08b9773a641f56403f4bc3d4bf639d17f3f9274536a
|
| 3 |
+
size 253990000
|
openai/clip-vit-base-patch16/tokenizer.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
openai/clip-vit-base-patch32/image_encode.onnx
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:58773462a749e7122def90d16eb159c20dff1f40b210f40ba834161ddd076f2e
|
| 3 |
+
size 351650753
|
openai/clip-vit-base-patch32/meta.json
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"image_embedding_width": 512,
|
| 3 |
+
"image_encoding_width": 768,
|
| 4 |
+
"image_flops": 4366181376.0,
|
| 5 |
+
"image_params": 87416832.0,
|
| 6 |
+
"image_size": 224,
|
| 7 |
+
"logit_scale": 4.605170249938965,
|
| 8 |
+
"name": "clip-vit-base-patch32",
|
| 9 |
+
"repo_created_at": 1646263745.0,
|
| 10 |
+
"repo_id": "openai/clip-vit-base-patch32",
|
| 11 |
+
"text_embedding_width": 512,
|
| 12 |
+
"text_encoding_width": 512,
|
| 13 |
+
"text_flops": 529199104.0,
|
| 14 |
+
"text_params": 37829632.0
|
| 15 |
+
}
|
openai/clip-vit-base-patch32/preprocessor.json
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"stages": [
|
| 3 |
+
{
|
| 4 |
+
"force_background": "white",
|
| 5 |
+
"type": "convert_rgb"
|
| 6 |
+
},
|
| 7 |
+
{
|
| 8 |
+
"antialias": true,
|
| 9 |
+
"interpolation": "bicubic",
|
| 10 |
+
"max_size": null,
|
| 11 |
+
"size": 224,
|
| 12 |
+
"type": "resize"
|
| 13 |
+
},
|
| 14 |
+
{
|
| 15 |
+
"size": [
|
| 16 |
+
224,
|
| 17 |
+
224
|
| 18 |
+
],
|
| 19 |
+
"type": "center_crop"
|
| 20 |
+
},
|
| 21 |
+
{
|
| 22 |
+
"type": "to_tensor"
|
| 23 |
+
},
|
| 24 |
+
{
|
| 25 |
+
"mean": [
|
| 26 |
+
0.48145467042922974,
|
| 27 |
+
0.45782750844955444,
|
| 28 |
+
0.40821072459220886
|
| 29 |
+
],
|
| 30 |
+
"std": [
|
| 31 |
+
0.2686295509338379,
|
| 32 |
+
0.2613025903701782,
|
| 33 |
+
0.27577710151672363
|
| 34 |
+
],
|
| 35 |
+
"type": "normalize"
|
| 36 |
+
}
|
| 37 |
+
]
|
| 38 |
+
}
|
openai/clip-vit-base-patch32/text_encode.onnx
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:2f07758ed6a9f05f8af341a80c486fcb547db499e8a5f5c79d8bc7e38d298156
|
| 3 |
+
size 253990000
|
openai/clip-vit-base-patch32/tokenizer.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
openai/clip-vit-large-patch14-336/image_encode.onnx
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:af2c86f35c06f13796d52c25ab3d3bc5903a5dfcdac758ac173657863971f907
|
| 3 |
+
size 1217674510
|
openai/clip-vit-large-patch14-336/meta.json
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"image_embedding_width": 768,
|
| 3 |
+
"image_encoding_width": 1024,
|
| 4 |
+
"image_flops": 174710792192.0,
|
| 5 |
+
"image_params": 302915584.0,
|
| 6 |
+
"image_size": 336,
|
| 7 |
+
"logit_scale": 4.605170249938965,
|
| 8 |
+
"name": "clip-vit-large-patch14-336",
|
| 9 |
+
"repo_created_at": 1650639463.0,
|
| 10 |
+
"repo_id": "openai/clip-vit-large-patch14-336",
|
| 11 |
+
"text_embedding_width": 768,
|
| 12 |
+
"text_encoding_width": 768,
|
| 13 |
+
"text_flops": 1190160384.0,
|
| 14 |
+
"text_params": 85056000.0
|
| 15 |
+
}
|
openai/clip-vit-large-patch14-336/preprocessor.json
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"stages": [
|
| 3 |
+
{
|
| 4 |
+
"force_background": "white",
|
| 5 |
+
"type": "convert_rgb"
|
| 6 |
+
},
|
| 7 |
+
{
|
| 8 |
+
"antialias": true,
|
| 9 |
+
"interpolation": "bicubic",
|
| 10 |
+
"max_size": null,
|
| 11 |
+
"size": 336,
|
| 12 |
+
"type": "resize"
|
| 13 |
+
},
|
| 14 |
+
{
|
| 15 |
+
"size": [
|
| 16 |
+
336,
|
| 17 |
+
336
|
| 18 |
+
],
|
| 19 |
+
"type": "center_crop"
|
| 20 |
+
},
|
| 21 |
+
{
|
| 22 |
+
"type": "to_tensor"
|
| 23 |
+
},
|
| 24 |
+
{
|
| 25 |
+
"mean": [
|
| 26 |
+
0.48145467042922974,
|
| 27 |
+
0.45782750844955444,
|
| 28 |
+
0.40821072459220886
|
| 29 |
+
],
|
| 30 |
+
"std": [
|
| 31 |
+
0.2686295509338379,
|
| 32 |
+
0.2613025903701782,
|
| 33 |
+
0.27577710151672363
|
| 34 |
+
],
|
| 35 |
+
"type": "normalize"
|
| 36 |
+
}
|
| 37 |
+
]
|
| 38 |
+
}
|
openai/clip-vit-large-patch14-336/text_encode.onnx
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:1c040a8a429bae34d99fa83a1f2dd48a0f6b21ccbe878eccb7c40c30291fda6e
|
| 3 |
+
size 494879632
|
openai/clip-vit-large-patch14-336/tokenizer.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
openai/clip-vit-large-patch14/image_encode.onnx
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:b15a7dbd19afefb67ee5cc299e10140193c959507a381d17fcbed31f345fdbef
|
| 3 |
+
size 1216363788
|
openai/clip-vit-large-patch14/meta.json
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"image_embedding_width": 768,
|
| 3 |
+
"image_encoding_width": 1024,
|
| 4 |
+
"image_flops": 77817126912.0,
|
| 5 |
+
"image_params": 302915584.0,
|
| 6 |
+
"image_size": 224,
|
| 7 |
+
"logit_scale": 4.605170249938965,
|
| 8 |
+
"name": "clip-vit-large-patch14",
|
| 9 |
+
"repo_created_at": 1646263745.0,
|
| 10 |
+
"repo_id": "openai/clip-vit-large-patch14",
|
| 11 |
+
"text_embedding_width": 768,
|
| 12 |
+
"text_encoding_width": 768,
|
| 13 |
+
"text_flops": 1190160384.0,
|
| 14 |
+
"text_params": 85056000.0
|
| 15 |
+
}
|
openai/clip-vit-large-patch14/preprocessor.json
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"stages": [
|
| 3 |
+
{
|
| 4 |
+
"force_background": "white",
|
| 5 |
+
"type": "convert_rgb"
|
| 6 |
+
},
|
| 7 |
+
{
|
| 8 |
+
"antialias": true,
|
| 9 |
+
"interpolation": "bicubic",
|
| 10 |
+
"max_size": null,
|
| 11 |
+
"size": 224,
|
| 12 |
+
"type": "resize"
|
| 13 |
+
},
|
| 14 |
+
{
|
| 15 |
+
"size": [
|
| 16 |
+
224,
|
| 17 |
+
224
|
| 18 |
+
],
|
| 19 |
+
"type": "center_crop"
|
| 20 |
+
},
|
| 21 |
+
{
|
| 22 |
+
"type": "to_tensor"
|
| 23 |
+
},
|
| 24 |
+
{
|
| 25 |
+
"mean": [
|
| 26 |
+
0.48145467042922974,
|
| 27 |
+
0.45782750844955444,
|
| 28 |
+
0.40821072459220886
|
| 29 |
+
],
|
| 30 |
+
"std": [
|
| 31 |
+
0.2686295509338379,
|
| 32 |
+
0.2613025903701782,
|
| 33 |
+
0.27577710151672363
|
| 34 |
+
],
|
| 35 |
+
"type": "normalize"
|
| 36 |
+
}
|
| 37 |
+
]
|
| 38 |
+
}
|
openai/clip-vit-large-patch14/text_encode.onnx
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:16a656e1f17390c75112babfeb3963077865d0c66d2916d7be87040db428ab1c
|
| 3 |
+
size 494879632
|
openai/clip-vit-large-patch14/tokenizer.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|