Instructions to use hf-internal-testing/tiny-random-clip-zero-shot-image-classification with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use hf-internal-testing/tiny-random-clip-zero-shot-image-classification with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("zero-shot-image-classification", model="hf-internal-testing/tiny-random-clip-zero-shot-image-classification") pipe( "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png", candidate_labels=["animals", "humans", "landscape"], )# Load model directly from transformers import AutoProcessor, AutoModelForZeroShotImageClassification processor = AutoProcessor.from_pretrained("hf-internal-testing/tiny-random-clip-zero-shot-image-classification") model = AutoModelForZeroShotImageClassification.from_pretrained("hf-internal-testing/tiny-random-clip-zero-shot-image-classification") - Notebooks
- Google Colab
- Kaggle
crop_size is after resize ??
Browse files- preprocessor_config.json +1 -1
preprocessor_config.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
| 1 |
{
|
| 2 |
-
"crop_size":
|
| 3 |
"do_center_crop": true,
|
| 4 |
"do_normalize": true,
|
| 5 |
"do_resize": true,
|
|
|
|
| 1 |
{
|
| 2 |
+
"crop_size": 30,
|
| 3 |
"do_center_crop": true,
|
| 4 |
"do_normalize": true,
|
| 5 |
"do_resize": true,
|