Instructions to use google/siglip2-so400m-patch16-naflex with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use google/siglip2-so400m-patch16-naflex with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("zero-shot-image-classification", model="google/siglip2-so400m-patch16-naflex") 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("google/siglip2-so400m-patch16-naflex") model = AutoModelForZeroShotImageClassification.from_pretrained("google/siglip2-so400m-patch16-naflex") - Notebooks
- Google Colab
- Kaggle
Inconsistent Results When Passing Batch vs Single
#6
by ysdk - opened
I am seeing inconsistent behavior in the output when I pass a batch of inputs vs if I pass a single input.
Notice the huge discrepancy between the vector outputs of the last vector in the batch call vs the vector in the single call. Am I missing something? This behavior isn't consistent with other VL-embedding models (e.g. CLIP, SigLip, etc.)

