I have my model hosted in huggingface hub, and now i’m trying to create a demo for it using Gradio. The demo is supposed to be asking the user for the model mode, based on that it generates the output, so how can we access the model’s functions in aim to have a if-else flow while creating Gradio demo?
def model(mode, output):
if output==‘Generate Image Randomly’:
elif output==‘Generate Art Grid’:
imimga = model.generate_grid()