How to use from the
Use from the
Keras library
# !pip install -U keras tensorflow huggingface_hub
# Keras needs TensorFlow installed to read "hf://" paths, so the tensorflow backend is selected here;
# "jax" and "torch" also work for computation once TensorFlow is installed.
import os
os.environ["KERAS_BACKEND"] = "tensorflow"

import keras

model = keras.saving.load_model("hf://sharktide/FV-FloodTrustNet")

This model requires the following custom objects:

import tensorflow as tf
from tensorflow.keras.saving import register_keras_serializable
from tensorflow.keras import layers, models, backend as K
import numpy as np

@register_keras_serializable()
def floodtrust_activation(x):
    return 0.5 + tf.sigmoid(x)  # output in range [0.5, 1.5]
Downloads last month
-
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Spaces using sharktide/FV-FloodTrustNet 2

Collection including sharktide/FV-FloodTrustNet