DeepNAPSI / app.py
lfolle's picture
Added application
42fa7ec
raw
history blame
451 Bytes
import torch
import os
import gradio as gr
from huggingface_hub import hf_hub_download
file_path = hf_hub_download("lfolle/DeepNAPSIModel", " dummy_model.pt",
use_auth_token=os.environ['TOKEN'])
model = torch.load(file_path)
def predict(data):
return model(data)
iface = gr.Interface(
predict,
title="DeepNAPSI Application",
inputs=gr.Image(),
outputs="numpy",
description=""
)
iface.launch()