Spaces:
Build error
Build error
File size: 859 Bytes
aee59a3 5b395e2 5265a69 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 |
import evaluate
from evaluate.utils import launch_gradio_widget
module = evaluate.load("SEA-AI/horizon-metrics")
#launch_gradio_widget(module)
def launch_empty_interface():
"""Launches an empty Gradio interface."""
try:
import gradio as gr
except ImportError as error:
print(
"To create a metric widget with Gradio make sure gradio is installed."
)
raise error
def dummy_function():
return "This is an empty interface."
iface = gr.Interface(
fn=dummy_function,
inputs=[],
outputs=[],
description="This is a description of the empty interface.",
title="Empty Interface",
article="You can provide additional information or instructions here.")
iface.launch()
# Call the function to launch the interface
launch_empty_interface()
|