Spaces:
Runtime error
Runtime error
Update app.py
Browse files56 unmodified lines5758596061626364656667686970717273747576777879808182838485868756 unmodified linesreturn Nonecss = """#col-container {margin: 0 auto;max-width: 580px;}"""with gr.Blocks(css=css, theme='Nymbo/Nymbo_Theme') as app:with gr.Row():with gr.Column(elem_id="prompt-container"):with gr.Row():text_prompt = gr.Textbox(label="Prompt", placeholder="Enter a prompt here", lines=3, elem_id="prompt-text-input")with gr.Row():with gr.Accordion("Advanced Settings", open=False):negative_prompt = gr.Textbox(label="Negative Prompt", placeholder="What should not be in the image", value="[deformed | disfigured], poorly drawn, [bad : wrong] anatomy, [extra | missing | floating | disconnected] limb, (mutated hands and fingers), blurry, text, fuzziness", lines=3, elem_id="negative-prompt-text-input")steps = gr.Slider(label="Sampling steps", value=35, minimum=1, maximum=100, step=1)cfg = gr.Slider(label="CFG Scale", value=7, minimum=1, maximum=20, step=1)method = gr.Radio(label="Sampling method", value="DPM++ 2M Karras", choices=["DPM++ 2M Karras", "DPM++ SDE Karras", "Euler", "Euler a", "Heun", "DDIM"])strength = gr.Slider(label="Strength", value=0.7, minimum=0, maximum=1, step=0.001)seed = gr.Slider(label="Seed", value=-1, minimum=-1, maximum=1000000000, step=1)with gr.Row():text_button = gr.Button("Run", variant='primary', elem_id="gen-button")with gr.Row():image_output = gr.Image(type="pil", label="Image Output", elem_id="gallery")text_button.click(query, inputs=[text_prompt, negative_prompt, steps, cfg, method, seed, strength], outputs=image_output)app.launch(show_api=False, share=False)56 unmodified lines57585960616263646566676869707172737475767778798081828384858687888956 unmodified linesreturn Nonecss = """#app-container {max-width: 580px;margin-left: auto;margin-right: auto;}"""with gr.Blocks(theme='Nymbo/Nymbo_Theme', css=css) as app:with gr.Column(elem_id="app-container"):with gr.Row():with gr.Column(elem_id="prompt-container"):with gr.Row():text_prompt = gr.Textbox(label="Prompt", placeholder="Enter a prompt here", lines=3, elem_id="prompt-text-input")with gr.Row():with gr.Accordion("Advanced Settings", open=False):negative_prompt = gr.Textbox(label="Negative Prompt", placeholder="What should not be in the image", value="[deformed | disfigured], poorly drawn, [bad : wrong] anatomy, [extra | missing | floating | disconnected] limb, (mutated hands and fingers), blurry, text, fuzziness", lines=3, elem_id="negative-prompt-text-input")steps = gr.Slider(label="Sampling steps", value=35, minimum=1, maximum=100, step=1)cfg = gr.Slider(label="CFG Scale", value=7, minimum=1, maximum=20, step=1)method = gr.Radio(label="Sampling method", value="DPM++ 2M Karras", choices=["DPM++ 2M Karras", "DPM++ SDE Karras", "Euler", "Euler a", "Heun", "DDIM"])strength = gr.Slider(label="Strength", value=0.7, minimum=0, maximum=1, step=0.001)seed = gr.Slider(label="Seed", value=-1, minimum=-1, maximum=1000000000, step=1)with gr.Row():text_button = gr.Button("Run", variant='primary', elem_id="gen-button")with gr.Row():image_output = gr.Image(type="pil", label="Image Output", elem_id="gallery")text_button.click(query, inputs=[text_prompt, negative_prompt, steps, cfg, method, seed, strength], outputs=image_output)app.launch(show_api=False, share=False)
app.py+22-20