Upload app.py
Browse files
app.py
CHANGED
|
@@ -7,7 +7,7 @@ from dc import (infer, _infer, pass_result, get_diffusers_model_list, get_sample
|
|
| 7 |
get_vaes, enable_model_recom_prompt, enable_diffusers_model_detail, extract_exif_data, esrgan_upscale, UPSCALER_KEYS,
|
| 8 |
preset_quality, preset_styles, process_style_prompt, get_all_lora_tupled_list, update_loras, apply_lora_prompt,
|
| 9 |
download_my_lora, search_civitai_lora, update_civitai_selection, select_civitai_lora, search_civitai_lora_json)
|
| 10 |
-
from modutils import get_t2i_model_info, get_civitai_tag, CIVITAI_SORT, CIVITAI_PERIOD,
|
| 11 |
# Translator
|
| 12 |
from llmdolphin import (dolphin_respond_auto, dolphin_parse_simple,
|
| 13 |
get_llm_formats, get_dolphin_model_format, get_dolphin_models,
|
|
@@ -141,7 +141,7 @@ with gr.Blocks(fill_width=True, elem_id="container", css=css, delete_cache=(60,
|
|
| 141 |
lora5_md = gr.Markdown(value="", visible=False)
|
| 142 |
with gr.Accordion("From URL", open=True, visible=True):
|
| 143 |
with gr.Row():
|
| 144 |
-
lora_search_civitai_basemodel = gr.CheckboxGroup(label="Search LoRA for", choices=
|
| 145 |
lora_search_civitai_sort = gr.Radio(label="Sort", choices=CIVITAI_SORT, value="Highest Rated")
|
| 146 |
lora_search_civitai_period = gr.Radio(label="Period", choices=CIVITAI_PERIOD, value="AllTime")
|
| 147 |
with gr.Row():
|
|
@@ -153,7 +153,7 @@ with gr.Blocks(fill_width=True, elem_id="container", css=css, delete_cache=(60,
|
|
| 153 |
lora_search_civitai_json = gr.JSON(value={}, visible=False)
|
| 154 |
lora_search_civitai_desc = gr.Markdown(value="", visible=False)
|
| 155 |
with gr.Accordion("Select from Gallery", open=False):
|
| 156 |
-
lora_search_civitai_gallery = gr.Gallery([], label="Results", allow_preview=False, columns=5,
|
| 157 |
lora_search_civitai_result = gr.Dropdown(label="Search Results", choices=[("", "")], value="", allow_custom_value=True, visible=False)
|
| 158 |
lora_download_url = gr.Textbox(label="LoRA URL", placeholder="https://civitai.com/api/download/models/28907", lines=1)
|
| 159 |
lora_download = gr.Button("Get and set LoRA and apply to prompt")
|
|
|
|
| 7 |
get_vaes, enable_model_recom_prompt, enable_diffusers_model_detail, extract_exif_data, esrgan_upscale, UPSCALER_KEYS,
|
| 8 |
preset_quality, preset_styles, process_style_prompt, get_all_lora_tupled_list, update_loras, apply_lora_prompt,
|
| 9 |
download_my_lora, search_civitai_lora, update_civitai_selection, select_civitai_lora, search_civitai_lora_json)
|
| 10 |
+
from modutils import get_t2i_model_info, get_civitai_tag, CIVITAI_SORT, CIVITAI_PERIOD, CIVITAI_BASEMODEL
|
| 11 |
# Translator
|
| 12 |
from llmdolphin import (dolphin_respond_auto, dolphin_parse_simple,
|
| 13 |
get_llm_formats, get_dolphin_model_format, get_dolphin_models,
|
|
|
|
| 141 |
lora5_md = gr.Markdown(value="", visible=False)
|
| 142 |
with gr.Accordion("From URL", open=True, visible=True):
|
| 143 |
with gr.Row():
|
| 144 |
+
lora_search_civitai_basemodel = gr.CheckboxGroup(label="Search LoRA for", choices=CIVITAI_BASEMODEL, value=["Pony", "SDXL 1.0"])
|
| 145 |
lora_search_civitai_sort = gr.Radio(label="Sort", choices=CIVITAI_SORT, value="Highest Rated")
|
| 146 |
lora_search_civitai_period = gr.Radio(label="Period", choices=CIVITAI_PERIOD, value="AllTime")
|
| 147 |
with gr.Row():
|
|
|
|
| 153 |
lora_search_civitai_json = gr.JSON(value={}, visible=False)
|
| 154 |
lora_search_civitai_desc = gr.Markdown(value="", visible=False)
|
| 155 |
with gr.Accordion("Select from Gallery", open=False):
|
| 156 |
+
lora_search_civitai_gallery = gr.Gallery([], label="Results", allow_preview=False, columns=5, show_share_button=False, interactive=False)
|
| 157 |
lora_search_civitai_result = gr.Dropdown(label="Search Results", choices=[("", "")], value="", allow_custom_value=True, visible=False)
|
| 158 |
lora_download_url = gr.Textbox(label="LoRA URL", placeholder="https://civitai.com/api/download/models/28907", lines=1)
|
| 159 |
lora_download = gr.Button("Get and set LoRA and apply to prompt")
|