Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -17,7 +17,7 @@ DESCRIPTION = """
|
|
| 17 |
"""
|
| 18 |
|
| 19 |
def save_image(img):
|
| 20 |
-
unique_name = str(uuid.uuid4()) + ".
|
| 21 |
img.save(unique_name)
|
| 22 |
return unique_name
|
| 23 |
|
|
@@ -189,15 +189,16 @@ with gr.Blocks(css=css, theme=gr.themes.Base()) as demo:
|
|
| 189 |
run_button = gr.Button("Run")
|
| 190 |
result = gr.Gallery(label="Result", columns=1, preview=True)
|
| 191 |
with gr.Accordion("Advanced options", open=False):
|
| 192 |
-
use_negative_prompt = gr.Checkbox(label="Use negative prompt", value=True)
|
| 193 |
-
|
|
|
|
| 194 |
label="Negative prompt",
|
| 195 |
lines=4,
|
| 196 |
max_lines=6,
|
| 197 |
value="""(deformed, distorted, disfigured:1.3), poorly drawn, bad anatomy, wrong anatomy, extra limb, missing limb, floating limbs, (mutated hands and fingers:1.4), disconnected limbs, mutation, mutated, ugly, disgusting, blurry, amputation, (NSFW:1.25)""",
|
| 198 |
placeholder="Enter a negative prompt",
|
| 199 |
visible=True,
|
| 200 |
-
)
|
| 201 |
with gr.Row():
|
| 202 |
num_inference_steps = gr.Slider(
|
| 203 |
label="Steps",
|
|
|
|
| 17 |
"""
|
| 18 |
|
| 19 |
def save_image(img):
|
| 20 |
+
unique_name = str(uuid.uuid4()) + ".png"
|
| 21 |
img.save(unique_name)
|
| 22 |
return unique_name
|
| 23 |
|
|
|
|
| 189 |
run_button = gr.Button("Run")
|
| 190 |
result = gr.Gallery(label="Result", columns=1, preview=True)
|
| 191 |
with gr.Accordion("Advanced options", open=False):
|
| 192 |
+
use_negative_prompt = gr.Checkbox(label="Use negative prompt", value=False, visible=True)
|
| 193 |
+
#use_negative_prompt = gr.Checkbox(label="Use negative prompt", value=True)
|
| 194 |
+
"""negative_prompt = gr.Text(
|
| 195 |
label="Negative prompt",
|
| 196 |
lines=4,
|
| 197 |
max_lines=6,
|
| 198 |
value="""(deformed, distorted, disfigured:1.3), poorly drawn, bad anatomy, wrong anatomy, extra limb, missing limb, floating limbs, (mutated hands and fingers:1.4), disconnected limbs, mutation, mutated, ugly, disgusting, blurry, amputation, (NSFW:1.25)""",
|
| 199 |
placeholder="Enter a negative prompt",
|
| 200 |
visible=True,
|
| 201 |
+
)"""
|
| 202 |
with gr.Row():
|
| 203 |
num_inference_steps = gr.Slider(
|
| 204 |
label="Steps",
|