Spaces:
Running
on
Zero
Running
on
Zero
Commit
·
965ea29
1
Parent(s):
cc664f5
Update app.py
Browse files
app.py
CHANGED
@@ -127,14 +127,14 @@ def shuffle_images():
|
|
127 |
description_1, trigger_word_1 = get_description(two_shuffled_items[0])
|
128 |
description_2, trigger_word_2 = get_description(two_shuffled_items[1])
|
129 |
|
130 |
-
lora_1_link = f"[{
|
131 |
-
lora_2_link = f"[{
|
132 |
prompt_description_1 = gr.update(value=description_1, visible=True)
|
133 |
prompt_description_2 = gr.update(value=description_2, visible=True)
|
134 |
prompt = gr.update(value=f"{trigger_word_1} {trigger_word_2}")
|
135 |
scale = gr.update(value=0.7)
|
136 |
|
137 |
-
return
|
138 |
|
139 |
def save_preferences(lora_1_id, lora_1_scale, lora_2_id, lora_2_scale, prompt, generated_image, thumbs_direction, seed):
|
140 |
image_path = IMAGE_DATASET_DIR / f"{uuid4()}.png"
|
|
|
127 |
description_1, trigger_word_1 = get_description(two_shuffled_items[0])
|
128 |
description_2, trigger_word_2 = get_description(two_shuffled_items[1])
|
129 |
|
130 |
+
lora_1_link = f"[{two_shuffled_items[0]['repo']}](https://huggingface.co/{two_shuffled_items[0]['repo']}) ✨"
|
131 |
+
lora_2_link = f"[{two_shuffled_items[1]['repo']}](https://huggingface.co/{two_shuffled_items[1]['repo']}) ✨"
|
132 |
prompt_description_1 = gr.update(value=description_1, visible=True)
|
133 |
prompt_description_2 = gr.update(value=description_2, visible=True)
|
134 |
prompt = gr.update(value=f"{trigger_word_1} {trigger_word_2}")
|
135 |
scale = gr.update(value=0.7)
|
136 |
|
137 |
+
return lora_1_link, title_1, prompt_description_1, repo_id_1, lora_2_link, title_2, prompt_description_2, repo_id_2, prompt, two_shuffled_items, scale, scale
|
138 |
|
139 |
def save_preferences(lora_1_id, lora_1_scale, lora_2_id, lora_2_scale, prompt, generated_image, thumbs_direction, seed):
|
140 |
image_path = IMAGE_DATASET_DIR / f"{uuid4()}.png"
|