Instructions to use ashm/test-docs with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use ashm/test-docs with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("zero-shot-image-classification", model="ashm/test-docs") 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("ashm/test-docs") model = AutoModelForZeroShotImageClassification.from_pretrained("ashm/test-docs", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Download config.json from ashm/test-docs: direct link, hf CLI and curl.
- Browser
- Download file 762 Bytes
-
https://huggingface.co/ashm/test-docs/resolve/main/config.json
- Command line
-
hf download hf://ashm/test-docs/config.json
-
curl -L -o config.json https://huggingface.co/ashm/test-docs/resolve/main/config.json
762 Bytes
| { | |
| "architectures": [ | |
| "CLIPModel" | |
| ], | |
| "model_type": "clip", | |
| "model_cfg": { | |
| "embed_dim": 512, | |
| "vision_cfg": { | |
| "timm_model_name": "vit_base_patch16_224", | |
| "timm_model_pretrained": false, | |
| "timm_pool": "", | |
| "timm_proj": "linear", | |
| "image_size": 224 | |
| }, | |
| "text_cfg": { | |
| "hf_model_name": "microsoft/BiomedNLP-PubMedBERT-base-uncased-abstract", | |
| "hf_tokenizer_name": "microsoft/BiomedNLP-PubMedBERT-base-uncased-abstract", | |
| "proj": "mlp", | |
| "pooler_type": "cls_last_hidden_state_pooler", | |
| "context_length": 256 | |
| } | |
| }, | |
| "preprocess_cfg": { | |
| "mean": [ | |
| 0.48145466, | |
| 0.4578275, | |
| 0.40821073 | |
| ], | |
| "std": [ | |
| 0.26862954, | |
| 0.26130258, | |
| 0.27577711 | |
| ] | |
| } | |
| } |