Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -169,8 +169,12 @@ def generate(
|
|
169 |
return generated_image, control_image, seed
|
170 |
|
171 |
# --- 5. UI Definition ---
|
172 |
-
|
173 |
-
|
|
|
|
|
|
|
|
|
174 |
gr.Markdown(
|
175 |
"Generate images using a curated set of stable preprocessors. "
|
176 |
"Choose a conditioning type, upload an image, and write a prompt."
|
@@ -178,7 +182,7 @@ with gr.Blocks(css="footer {display: none !important;}") as demo:
|
|
178 |
|
179 |
with gr.Row():
|
180 |
with gr.Column(scale=1):
|
181 |
-
input_image = gr.Image(type="pil", label="Input Image"
|
182 |
prompt = gr.Textbox(label="Prompt", placeholder="A detailed description of the desired image...")
|
183 |
conditioning = gr.Radio(
|
184 |
choices=["Canny", "Soft Edge", "Depth", "Pose"],
|
@@ -202,8 +206,8 @@ with gr.Blocks(css="footer {display: none !important;}") as demo:
|
|
202 |
randomize_seed = gr.Checkbox(label="Randomize seed", value=True)
|
203 |
|
204 |
with gr.Column(scale=1):
|
205 |
-
|
206 |
-
|
207 |
used_seed = gr.Number(label="Used Seed", interactive=False)
|
208 |
|
209 |
gr.Examples(
|
|
|
169 |
return generated_image, control_image, seed
|
170 |
|
171 |
# --- 5. UI Definition ---
|
172 |
+
css = '''
|
173 |
+
.fillable{max-width: 960px !important}
|
174 |
+
'''
|
175 |
+
|
176 |
+
with gr.Blocks(css=css, theme=gr.themes.Citrus()) as demo:
|
177 |
+
gr.Markdown("# Qwen-Image with Union ControlNet")
|
178 |
gr.Markdown(
|
179 |
"Generate images using a curated set of stable preprocessors. "
|
180 |
"Choose a conditioning type, upload an image, and write a prompt."
|
|
|
182 |
|
183 |
with gr.Row():
|
184 |
with gr.Column(scale=1):
|
185 |
+
input_image = gr.Image(type="pil", label="Input Image")
|
186 |
prompt = gr.Textbox(label="Prompt", placeholder="A detailed description of the desired image...")
|
187 |
conditioning = gr.Radio(
|
188 |
choices=["Canny", "Soft Edge", "Depth", "Pose"],
|
|
|
206 |
randomize_seed = gr.Checkbox(label="Randomize seed", value=True)
|
207 |
|
208 |
with gr.Column(scale=1):
|
209 |
+
generated_image_output = gr.Image(label="Generated Image", interactive=False)
|
210 |
+
control_image_output = gr.Image(label="Control Image (Preprocessor Output)", interactive=False)
|
211 |
used_seed = gr.Number(label="Used Seed", interactive=False)
|
212 |
|
213 |
gr.Examples(
|