Update app.py
Browse files
app.py
CHANGED
|
@@ -75,7 +75,7 @@ print("Loading new LoRA adapters...")
|
|
| 75 |
pipe.load_lora_weights(
|
| 76 |
"markury/flux2k9b-simpletuner-lora-loona",
|
| 77 |
weight_name="pytorch_lora_weights.safetensors",
|
| 78 |
-
adapter_name="
|
| 79 |
)
|
| 80 |
pipe.load_lora_weights(
|
| 81 |
"linoyts/Flux2-Klein-Delight-LoRA",
|
|
@@ -86,8 +86,8 @@ print("All LoRA adapters loaded.")
|
|
| 86 |
|
| 87 |
# Updated map for the new adapters
|
| 88 |
ADAPTER_MAP = {
|
| 89 |
-
"Simple
|
| 90 |
-
"Klein
|
| 91 |
}
|
| 92 |
|
| 93 |
@spaces.GPU
|
|
@@ -151,8 +151,8 @@ with gr.Blocks() as demo:
|
|
| 151 |
lora_adapter = gr.Dropdown(
|
| 152 |
label="Choose a Creative Style",
|
| 153 |
# Updated choices for the new adapters
|
| 154 |
-
choices=["Simple
|
| 155 |
-
value="
|
| 156 |
)
|
| 157 |
|
| 158 |
run_button = gr.Button("Apply Style", variant="primary")
|
|
@@ -171,7 +171,7 @@ with gr.Blocks() as demo:
|
|
| 171 |
# Updated examples for the new LoRAs
|
| 172 |
gr.Examples(
|
| 173 |
examples=[
|
| 174 |
-
["examples/animal.jpg", "a cute red panda, charming and delightful illustration, soft lighting", "Klein
|
| 175 |
],
|
| 176 |
inputs=[input_image, prompt, lora_adapter],
|
| 177 |
outputs=[output_image, used_seed],
|
|
|
|
| 75 |
pipe.load_lora_weights(
|
| 76 |
"markury/flux2k9b-simpletuner-lora-loona",
|
| 77 |
weight_name="pytorch_lora_weights.safetensors",
|
| 78 |
+
adapter_name="simple-tuner"
|
| 79 |
)
|
| 80 |
pipe.load_lora_weights(
|
| 81 |
"linoyts/Flux2-Klein-Delight-LoRA",
|
|
|
|
| 86 |
|
| 87 |
# Updated map for the new adapters
|
| 88 |
ADAPTER_MAP = {
|
| 89 |
+
"Simple-Tuner": "simple-tuner",
|
| 90 |
+
"Klein-Delight-Style": "klein-delight",
|
| 91 |
}
|
| 92 |
|
| 93 |
@spaces.GPU
|
|
|
|
| 151 |
lora_adapter = gr.Dropdown(
|
| 152 |
label="Choose a Creative Style",
|
| 153 |
# Updated choices for the new adapters
|
| 154 |
+
choices=["Simple-Tuner", "Klein-Delight-Style"],
|
| 155 |
+
value="Klein-Delight-Style"
|
| 156 |
)
|
| 157 |
|
| 158 |
run_button = gr.Button("Apply Style", variant="primary")
|
|
|
|
| 171 |
# Updated examples for the new LoRAs
|
| 172 |
gr.Examples(
|
| 173 |
examples=[
|
| 174 |
+
["examples/animal.jpg", "a cute red panda, charming and delightful illustration, soft lighting", "Klein-Delight-Style"],
|
| 175 |
],
|
| 176 |
inputs=[input_image, prompt, lora_adapter],
|
| 177 |
outputs=[output_image, used_seed],
|