import gradio as gr def predict(*args): print(args) return {"inputs": list[args]} with gr.Blocks() as demo: s = gr.CheckboxGroup(choices=['Text-to-Image', 'Image-to-Image'], interactive=True) #value='Text-to-Image', @gr.render(inputs=s, triggers=[s.input]) def render(value): #texts = [] for Mode in value: with gr.Tab(label=Mode): if value=='Text-to-Image': #gr.Markdown(value=Mode) demo_t2i = gr.load('stabilityai/stable-diffusion-xl-base-1.0', src='models') #gr.load('minimaxir/sdxl-wrong-lora', src='models') #.launch(debug=True, quiet=True) #minimaxir/sdxl-wrong-lora stabilityai/sdxl-turbo ByteDance/SDXL-Lightning else: #gr.Markdown(value=Mode) demo_t2i = gr.load('stabilityai/stable-diffusion-xl-refiner-1.0', src='models') #.launch(height=1000, quiet=True) demo.launch(debug=True, quiet=True)