Instructions to use google/paligemma2-3b-pt-448-keras with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- KerasHub
How to use google/paligemma2-3b-pt-448-keras with KerasHub:
import keras_hub # Create a Backbone model unspecialized for any task backbone = keras_hub.models.Backbone.from_preset("hf://google/paligemma2-3b-pt-448-keras") - Keras
How to use google/paligemma2-3b-pt-448-keras with Keras:
# Available backend options are: "jax", "torch", "tensorflow". import os os.environ["KERAS_BACKEND"] = "jax" import keras model = keras.saving.load_model("hf://google/paligemma2-3b-pt-448-keras") - Notebooks
- Google Colab
- Kaggle
| { | |
| "module": "keras_hub.src.models.pali_gemma.pali_gemma_image_converter", | |
| "class_name": "PaliGemmaImageConverter", | |
| "config": { | |
| "name": "pali_gemma_image_converter", | |
| "trainable": true, | |
| "dtype": { | |
| "module": "keras", | |
| "class_name": "DTypePolicy", | |
| "config": { | |
| "name": "bfloat16" | |
| }, | |
| "registered_name": null | |
| }, | |
| "image_size": [ | |
| 448, | |
| 448 | |
| ], | |
| "scale": 0.00784313725490196, | |
| "offset": -1, | |
| "interpolation": "bilinear", | |
| "crop_to_aspect_ratio": true | |
| }, | |
| "registered_name": "keras_hub>PaliGemmaImageConverter" | |
| } |