Instructions to use zeromodels/dfine-small with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- KerasFormers
How to use zeromodels/dfine-small 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/dfine-small 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/dfine-small") - Notebooks
- Google Colab
- Kaggle
docs: load image processor via from_weights
Browse files
README.md
CHANGED
|
@@ -44,7 +44,7 @@ from PIL import Image
|
|
| 44 |
from kerasformers.models.dfine import DFineDetect, DFineImageProcessor
|
| 45 |
|
| 46 |
model = DFineDetect.from_weights("kerasformers/dfine-small")
|
| 47 |
-
processor = DFineImageProcessor()
|
| 48 |
|
| 49 |
image = Image.open("your_image.jpg").convert("RGB")
|
| 50 |
inputs = processor(image)
|
|
|
|
| 44 |
from kerasformers.models.dfine import DFineDetect, DFineImageProcessor
|
| 45 |
|
| 46 |
model = DFineDetect.from_weights("kerasformers/dfine-small")
|
| 47 |
+
processor = DFineImageProcessor.from_weights("kerasformers/dfine-small")
|
| 48 |
|
| 49 |
image = Image.open("your_image.jpg").convert("RGB")
|
| 50 |
inputs = processor(image)
|