Update app.py
Browse files
app.py
CHANGED
@@ -26,8 +26,6 @@ def query(prompt, model, is_negative=False, steps=20, cfg_scale=7, seed=None):
|
|
26 |
API_URL = "https://api-inference.huggingface.co/models/stabilityai/stable-diffusion-xl-base-1.0"
|
27 |
if model == 'PixArt':
|
28 |
API_URL = "https://api-inference.huggingface.co/models/PixArt-alpha/PixArt-LCM-XL-2-1024-MS"
|
29 |
-
if model == 'Kandinsky 3':
|
30 |
-
API_URL = "https://api-inference.huggingface.co/models/kandinsky-community/kandinsky-3"
|
31 |
|
32 |
payload = {
|
33 |
"inputs": prompt,
|
@@ -51,7 +49,7 @@ with gr.Blocks(css=css) as dalle:
|
|
51 |
with gr.Row():
|
52 |
with gr.Column(elem_id="prompt-container"):
|
53 |
text_prompt = gr.Textbox(label="Prompt", placeholder="Описание изображения", lines=3, elem_id="prompt-text-input")
|
54 |
-
model = gr.Radio(label="Модель", value="DALL-E 3 XL", choices=["DALL-E 3 XL", "Playground v2", "D-XL 1.0", "PixArt"
|
55 |
|
56 |
|
57 |
with gr.Tab("Расширенные настройки"):
|
|
|
26 |
API_URL = "https://api-inference.huggingface.co/models/stabilityai/stable-diffusion-xl-base-1.0"
|
27 |
if model == 'PixArt':
|
28 |
API_URL = "https://api-inference.huggingface.co/models/PixArt-alpha/PixArt-LCM-XL-2-1024-MS"
|
|
|
|
|
29 |
|
30 |
payload = {
|
31 |
"inputs": prompt,
|
|
|
49 |
with gr.Row():
|
50 |
with gr.Column(elem_id="prompt-container"):
|
51 |
text_prompt = gr.Textbox(label="Prompt", placeholder="Описание изображения", lines=3, elem_id="prompt-text-input")
|
52 |
+
model = gr.Radio(label="Модель", value="DALL-E 3 XL", choices=["DALL-E 3 XL", "Playground v2", "D-XL 1.0", "PixArt"])
|
53 |
|
54 |
|
55 |
with gr.Tab("Расширенные настройки"):
|