Spaces:
Running
on
Zero
Running
on
Zero
zhiweili
commited on
Commit
•
21ef723
1
Parent(s):
87f06d9
fix ui params
Browse files- app_haircolor.py +2 -1
app_haircolor.py
CHANGED
@@ -98,6 +98,7 @@ def create_demo() -> gr.Blocks:
|
|
98 |
with gr.Column():
|
99 |
edit_prompt = gr.Textbox(lines=1, label="Edit Prompt", value=DEFAULT_EDIT_PROMPT)
|
100 |
generate_size = gr.Number(label="Generate Size", value=1024)
|
|
|
101 |
category = gr.Textbox(label="Category", value=DEFAULT_CATEGORY, visible=False)
|
102 |
with gr.Column():
|
103 |
num_steps = gr.Slider(minimum=1, maximum=100, value=30, step=1, label="Num Steps")
|
@@ -124,7 +125,7 @@ def create_demo() -> gr.Blocks:
|
|
124 |
outputs=[origin_area_image, croper],
|
125 |
).success(
|
126 |
fn=image_to_image,
|
127 |
-
inputs=[origin_area_image, edit_prompt,seed, num_steps, guidance_scale],
|
128 |
outputs=[generated_image, generated_cost],
|
129 |
).success(
|
130 |
fn=restore_result,
|
|
|
98 |
with gr.Column():
|
99 |
edit_prompt = gr.Textbox(lines=1, label="Edit Prompt", value=DEFAULT_EDIT_PROMPT)
|
100 |
generate_size = gr.Number(label="Generate Size", value=1024)
|
101 |
+
adapter_weight = gr.Slider(minimum=0, maximum=2, value=1, step=0.1, label="Adapter Weight")
|
102 |
category = gr.Textbox(label="Category", value=DEFAULT_CATEGORY, visible=False)
|
103 |
with gr.Column():
|
104 |
num_steps = gr.Slider(minimum=1, maximum=100, value=30, step=1, label="Num Steps")
|
|
|
125 |
outputs=[origin_area_image, croper],
|
126 |
).success(
|
127 |
fn=image_to_image,
|
128 |
+
inputs=[origin_area_image, edit_prompt,seed, num_steps, guidance_scale, generate_size, adapter_weight],
|
129 |
outputs=[generated_image, generated_cost],
|
130 |
).success(
|
131 |
fn=restore_result,
|