Instructions to use zeromodels/sam_vit_base with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- KerasFormers
How to use zeromodels/sam_vit_base with KerasFormers:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
- Keras
How to use zeromodels/sam_vit_base with Keras:
# Available backend options are: "jax", "torch", "tensorflow". import os os.environ["KERAS_BACKEND"] = "jax" import keras model = keras.saving.load_model("hf://zeromodels/sam_vit_base") - Notebooks
- Google Colab
- Kaggle
Upload kf_config.json with huggingface_hub
Browse files- kf_config.json +24 -0
kf_config.json
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"library_name": "kerasformers",
|
| 3 |
+
"kerasformers_version": "1.1.3",
|
| 4 |
+
"model_module": "kerasformers.models.sam",
|
| 5 |
+
"model_class": "SAMPromptableSegment",
|
| 6 |
+
"variant": "sam_vit_base",
|
| 7 |
+
"weights": "model.weights.h5",
|
| 8 |
+
"model_type": "sam",
|
| 9 |
+
"vision_hidden_size": 768,
|
| 10 |
+
"vision_num_hidden_layers": 12,
|
| 11 |
+
"vision_num_attention_heads": 12,
|
| 12 |
+
"vision_mlp_dim": 3072,
|
| 13 |
+
"vision_global_attn_indexes": [
|
| 14 |
+
2,
|
| 15 |
+
5,
|
| 16 |
+
8,
|
| 17 |
+
11
|
| 18 |
+
],
|
| 19 |
+
"num_multimask_outputs": 3,
|
| 20 |
+
"multimask_output": true,
|
| 21 |
+
"enable_boxes": false,
|
| 22 |
+
"enable_masks": false,
|
| 23 |
+
"image_size": 1024
|
| 24 |
+
}
|