Spaces:
Sleeping
Sleeping
lora item
Browse files
app.py
CHANGED
|
@@ -56,6 +56,9 @@ def infer(
|
|
| 56 |
return image, seed
|
| 57 |
|
| 58 |
|
|
|
|
|
|
|
|
|
|
| 59 |
examples = [
|
| 60 |
"cute_animal",
|
| 61 |
"Astronaut in a jungle, cold color palette, muted colors, detailed, 8k",
|
|
@@ -78,6 +81,18 @@ with gr.Blocks(css=css) as demo:
|
|
| 78 |
with gr.Row():
|
| 79 |
model_id = gr.Dropdown(
|
| 80 |
choices=["CompVis/stable-diffusion-v1-4", "stabilityai/sdxl-turbo"], info="Choose model")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 81 |
|
| 82 |
with gr.Row():
|
| 83 |
prompt = gr.Text(
|
|
|
|
| 56 |
return image, seed
|
| 57 |
|
| 58 |
|
| 59 |
+
|
| 60 |
+
|
| 61 |
+
|
| 62 |
examples = [
|
| 63 |
"cute_animal",
|
| 64 |
"Astronaut in a jungle, cold color palette, muted colors, detailed, 8k",
|
|
|
|
| 81 |
with gr.Row():
|
| 82 |
model_id = gr.Dropdown(
|
| 83 |
choices=["CompVis/stable-diffusion-v1-4", "stabilityai/sdxl-turbo"], info="Choose model")
|
| 84 |
+
|
| 85 |
+
with gr.Row():
|
| 86 |
+
lora = gr.Dropdown(
|
| 87 |
+
choices=["None", "pepe"], info="Choose lora", visible=False)
|
| 88 |
+
|
| 89 |
+
def setup_lora(model_id):
|
| 90 |
+
if selected_option == "CompVis/stable-diffusion-v1-4":
|
| 91 |
+
return lora.update(visible=True)
|
| 92 |
+
else:
|
| 93 |
+
return lora.update(visible=False)
|
| 94 |
+
model_id.change(setup_lora, model_id, lora)
|
| 95 |
+
|
| 96 |
|
| 97 |
with gr.Row():
|
| 98 |
prompt = gr.Text(
|