Spaces:
Runtime error
Runtime error
File size: 382 Bytes
98de6bd f24acd7 98de6bd 4073f79 98de6bd f24acd7 98de6bd 4073f79 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
import numpy as np
import time
from huggingface_hub import from_pretrained_keras
from tensorflow import keras
from tensorflow.keras import layers
app = FastAPI()
model = from_pretrained_keras("mat27/medmnsitPrueba")
model.compile(loss="categorical_crossentropy", optimizer="adam", metrics=["accuracy"])
@app.get("/generate")
def generate(x: np.array):
print(model.predict(x)) |