Spaces:
Runtime error
Runtime error
File size: 443 Bytes
4ec72e6 a7f8465 4ec72e6 a7f8465 4ec72e6 5b79a3b |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
import gradio as gr
from huggingface_hub import from_pretrained_keras
import numpy as np
reloaded_model = from_pretrained_keras('jmparejaz/Facial_Age-gender-eth_Recognition')
reloaded_model_eth = from_pretrained_keras('jmparejaz/Facial_eth_recognition')
def rgb2gray(rgb):
return np.dot(rgb[...,:3], [0.2989, 0.5870, 0.1140])
iface = gr.Interface(fn=rgb2gray, gr.inputs.Image(shape=(48, 48),), outputs="text")
iface.launch() |