Instructions to use google/siglip-base-patch16-224 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use google/siglip-base-patch16-224 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("zero-shot-image-classification", model="google/siglip-base-patch16-224") pipe( "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png", candidate_labels=["animals", "humans", "landscape"], )# pip install -U transformers accelerate # Load model directly from transformers import AutoProcessor, AutoModelForZeroShotImageClassification processor = AutoProcessor.from_pretrained("google/siglip-base-patch16-224") model = AutoModelForZeroShotImageClassification.from_pretrained("google/siglip-base-patch16-224", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Update tokenizer_config.json
Browse files- tokenizer_config.json +1 -2
tokenizer_config.json
CHANGED
|
@@ -22,8 +22,7 @@
|
|
| 22 |
"do_lower_case": true,
|
| 23 |
"eos_token": "</s>",
|
| 24 |
"model_input_names": [
|
| 25 |
-
"input_ids"
|
| 26 |
-
"attention_mask"
|
| 27 |
],
|
| 28 |
"model_max_length": 64,
|
| 29 |
"pad_token": "</s>",
|
|
|
|
| 22 |
"do_lower_case": true,
|
| 23 |
"eos_token": "</s>",
|
| 24 |
"model_input_names": [
|
| 25 |
+
"input_ids"
|
|
|
|
| 26 |
],
|
| 27 |
"model_max_length": 64,
|
| 28 |
"pad_token": "</s>",
|