Spaces:
Runtime error
Runtime error
Commit
·
c58c4f8
1
Parent(s):
4374e49
Update app.py
Browse files
app.py
CHANGED
|
@@ -12,6 +12,9 @@ import os
|
|
| 12 |
from PIL import Image
|
| 13 |
from io import BytesIO
|
| 14 |
|
|
|
|
|
|
|
|
|
|
| 15 |
class Prodia:
|
| 16 |
def __init__(self, api_key, base=None):
|
| 17 |
self.base = base or "https://api.prodia.com/v1"
|
|
@@ -85,9 +88,9 @@ def flip_text(prompt, negative_prompt, model, steps, sampler, cfg_scale, width,
|
|
| 85 |
result = prodia_client.generate({
|
| 86 |
"prompt": prompt,
|
| 87 |
"negative_prompt": negative_prompt,
|
| 88 |
-
"model":
|
| 89 |
"steps": steps,
|
| 90 |
-
"sampler":
|
| 91 |
"cfg_scale": cfg_scale,
|
| 92 |
"width": width,
|
| 93 |
"height": height,
|
|
@@ -100,7 +103,7 @@ def flip_text(prompt, negative_prompt, model, steps, sampler, cfg_scale, width,
|
|
| 100 |
|
| 101 |
|
| 102 |
|
| 103 |
-
with gr.Blocks(
|
| 104 |
with gr.Row():
|
| 105 |
with gr.Column(scale=1):
|
| 106 |
gr.HTML(value=""""<h1><center>Fast SDXL-1.0 on <a href="https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0" target="_blank">stabilityai/stable-diffusion-xl-base-1.0</a>""")
|
|
|
|
| 12 |
from PIL import Image
|
| 13 |
from io import BytesIO
|
| 14 |
|
| 15 |
+
batch_size=1
|
| 16 |
+
batch_count=1
|
| 17 |
+
|
| 18 |
class Prodia:
|
| 19 |
def __init__(self, api_key, base=None):
|
| 20 |
self.base = base or "https://api.prodia.com/v1"
|
|
|
|
| 88 |
result = prodia_client.generate({
|
| 89 |
"prompt": prompt,
|
| 90 |
"negative_prompt": negative_prompt,
|
| 91 |
+
"model": "sd_xl_base_1.0.safetensors [be9edd61]",
|
| 92 |
"steps": steps,
|
| 93 |
+
"sampler": "DPM++ 2M Karras",
|
| 94 |
"cfg_scale": cfg_scale,
|
| 95 |
"width": width,
|
| 96 |
"height": height,
|
|
|
|
| 103 |
|
| 104 |
|
| 105 |
|
| 106 |
+
with gr.Blocks() as demo:
|
| 107 |
with gr.Row():
|
| 108 |
with gr.Column(scale=1):
|
| 109 |
gr.HTML(value=""""<h1><center>Fast SDXL-1.0 on <a href="https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0" target="_blank">stabilityai/stable-diffusion-xl-base-1.0</a>""")
|