Spaces:
Running
Running
Commit
•
bc76095
1
Parent(s):
e8387c2
Update app.py
Browse files
app.py
CHANGED
@@ -384,9 +384,9 @@ def add_custom_lora(custom_lora, selected_indices):
|
|
384 |
except Exception as e:
|
385 |
print(e)
|
386 |
gr.Warning(str(e))
|
387 |
-
return gr.
|
388 |
else:
|
389 |
-
return gr.
|
390 |
|
391 |
def remove_custom_lora(selected_indices):
|
392 |
global loras
|
@@ -486,8 +486,8 @@ with gr.Blocks(theme=gr.themes.Soft(), css=css, delete_cache=(60, 3600)) as app:
|
|
486 |
remove_button_2 = gr.Button("Remove", size="sm")
|
487 |
with gr.Row():
|
488 |
with gr.Column():
|
489 |
-
with gr.Group(
|
490 |
-
with gr.Row():
|
491 |
custom_lora = gr.Textbox(label="Custom LoRA", info="LoRA Hugging Face path or *.safetensors public URL", placeholder="multimodalart/vintage-ads-flux", scale=3, min_width=150)
|
492 |
add_custom_lora_button = gr.Button("Add Custom LoRA", elem_id="custom_lora_btn", scale=2, min_width=150)
|
493 |
remove_custom_lora_button = gr.Button("Remove Custom LoRA", visible=False)
|
|
|
384 |
except Exception as e:
|
385 |
print(e)
|
386 |
gr.Warning(str(e))
|
387 |
+
return gr.update(), gr.update(), gr.update(), selected_indices, gr.update(), gr.update(), gr.update(), gr.update()
|
388 |
else:
|
389 |
+
return gr.update(), gr.update(), gr.update(), selected_indices, gr.update(), gr.update(), gr.update(), gr.update()
|
390 |
|
391 |
def remove_custom_lora(selected_indices):
|
392 |
global loras
|
|
|
486 |
remove_button_2 = gr.Button("Remove", size="sm")
|
487 |
with gr.Row():
|
488 |
with gr.Column():
|
489 |
+
with gr.Group():
|
490 |
+
with gr.Row(elem_id="custom_lora_structure"):
|
491 |
custom_lora = gr.Textbox(label="Custom LoRA", info="LoRA Hugging Face path or *.safetensors public URL", placeholder="multimodalart/vintage-ads-flux", scale=3, min_width=150)
|
492 |
add_custom_lora_button = gr.Button("Add Custom LoRA", elem_id="custom_lora_btn", scale=2, min_width=150)
|
493 |
remove_custom_lora_button = gr.Button("Remove Custom LoRA", visible=False)
|