Spaces:
Configuration error
Configuration error
Anonymous
commited on
Commit
·
b509c71
1
Parent(s):
bae6fd5
load in advance
Browse files
app.py
CHANGED
|
@@ -89,92 +89,13 @@ def infer(prompt, output_size, ddim_steps, guidance_scale, cosine_scale, seed, o
|
|
| 89 |
|
| 90 |
|
| 91 |
examples = [
|
| 92 |
-
["A Enchanted illustration of a Palatial Ghost Explosion with a Mystical Sky, in the style of Eric, viewed from CamProX, Bokeh. High resolution, 8k, insanely detailed.",],
|
| 93 |
-
["Brunette pilot girl in a snowstorm, full body, moody lighting, intricate details, depth of field, outdoors, Fujifilm XT3, RAW, 8K UHD, film grain, Unreal Engine 5, ray tracing.",],
|
| 94 |
["A cute and adorable fluffy puppy wearing a witch hat in a Halloween autumn evening forest, falling autumn leaves, brown acorns on the ground, Halloween pumpkins spiderwebs, bats, and a witch’s broom.",],
|
| 95 |
-
["
|
|
|
|
| 96 |
]
|
| 97 |
|
| 98 |
css = """
|
| 99 |
#col-container {max-width: 768px; margin-left: auto; margin-right: auto;}
|
| 100 |
-
a {text-decoration-line: underline; font-weight: 600;}
|
| 101 |
-
.animate-spin {
|
| 102 |
-
animation: spin 1s linear infinite;
|
| 103 |
-
}
|
| 104 |
-
@keyframes spin {
|
| 105 |
-
from {
|
| 106 |
-
transform: rotate(0deg);
|
| 107 |
-
}
|
| 108 |
-
to {
|
| 109 |
-
transform: rotate(360deg);
|
| 110 |
-
}
|
| 111 |
-
}
|
| 112 |
-
#share-btn-container {
|
| 113 |
-
display: flex;
|
| 114 |
-
padding-left: 0.5rem !important;
|
| 115 |
-
padding-right: 0.5rem !important;
|
| 116 |
-
background-color: #000000;
|
| 117 |
-
justify-content: center;
|
| 118 |
-
align-items: center;
|
| 119 |
-
border-radius: 9999px !important;
|
| 120 |
-
max-width: 15rem;
|
| 121 |
-
height: 36px;
|
| 122 |
-
}
|
| 123 |
-
div#share-btn-container > div {
|
| 124 |
-
flex-direction: row;
|
| 125 |
-
background: black;
|
| 126 |
-
align-items: center;
|
| 127 |
-
}
|
| 128 |
-
#share-btn-container:hover {
|
| 129 |
-
background-color: #060606;
|
| 130 |
-
}
|
| 131 |
-
#share-btn {
|
| 132 |
-
all: initial;
|
| 133 |
-
color: #ffffff;
|
| 134 |
-
font-weight: 600;
|
| 135 |
-
cursor:pointer;
|
| 136 |
-
font-family: 'IBM Plex Sans', sans-serif;
|
| 137 |
-
margin-left: 0.5rem !important;
|
| 138 |
-
padding-top: 0.5rem !important;
|
| 139 |
-
padding-bottom: 0.5rem !important;
|
| 140 |
-
right:0;
|
| 141 |
-
}
|
| 142 |
-
#share-btn * {
|
| 143 |
-
all: unset;
|
| 144 |
-
}
|
| 145 |
-
#share-btn-container div:nth-child(-n+2){
|
| 146 |
-
width: auto !important;
|
| 147 |
-
min-height: 0px !important;
|
| 148 |
-
}
|
| 149 |
-
#share-btn-container .wrap {
|
| 150 |
-
display: none !important;
|
| 151 |
-
}
|
| 152 |
-
#share-btn-container.hidden {
|
| 153 |
-
display: none!important;
|
| 154 |
-
}
|
| 155 |
-
img[src*='#center'] {
|
| 156 |
-
display: inline-block;
|
| 157 |
-
margin: unset;
|
| 158 |
-
}
|
| 159 |
-
.footer {
|
| 160 |
-
margin-bottom: 45px;
|
| 161 |
-
margin-top: 10px;
|
| 162 |
-
text-align: center;
|
| 163 |
-
border-bottom: 1px solid #e5e5e5;
|
| 164 |
-
}
|
| 165 |
-
.footer>p {
|
| 166 |
-
font-size: .8rem;
|
| 167 |
-
display: inline-block;
|
| 168 |
-
padding: 0 10px;
|
| 169 |
-
transform: translateY(10px);
|
| 170 |
-
background: white;
|
| 171 |
-
}
|
| 172 |
-
.dark .footer {
|
| 173 |
-
border-color: #303030;
|
| 174 |
-
}
|
| 175 |
-
.dark .footer>p {
|
| 176 |
-
background: #0b0f19;
|
| 177 |
-
}
|
| 178 |
"""
|
| 179 |
|
| 180 |
def mode_update(options):
|
|
@@ -237,7 +158,7 @@ with gr.Blocks(css=css) as demo:
|
|
| 237 |
minimum=0,
|
| 238 |
maximum=10000,
|
| 239 |
step=1,
|
| 240 |
-
value=
|
| 241 |
with gr.Row():
|
| 242 |
negative_prompt = gr.Textbox(label='Negative Prompt', value='blurry, ugly, duplicate, poorly drawn, deformed, mosaic')
|
| 243 |
|
|
|
|
| 89 |
|
| 90 |
|
| 91 |
examples = [
|
|
|
|
|
|
|
| 92 |
["A cute and adorable fluffy puppy wearing a witch hat in a Halloween autumn evening forest, falling autumn leaves, brown acorns on the ground, Halloween pumpkins spiderwebs, bats, and a witch’s broom.",],
|
| 93 |
+
["Brunette pilot girl in a snowstorm, full body, moody lighting, intricate details, depth of field, outdoors, Fujifilm XT3, RAW, 8K UHD, film grain, Unreal Engine 5, ray tracing.",],
|
| 94 |
+
["A Enchanted illustration of a Palatial Ghost Explosion with a Mystical Sky, in the style of Eric, viewed from CamProX, Bokeh. High resolution, 8k, insanely detailed.",],
|
| 95 |
]
|
| 96 |
|
| 97 |
css = """
|
| 98 |
#col-container {max-width: 768px; margin-left: auto; margin-right: auto;}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 99 |
"""
|
| 100 |
|
| 101 |
def mode_update(options):
|
|
|
|
| 158 |
minimum=0,
|
| 159 |
maximum=10000,
|
| 160 |
step=1,
|
| 161 |
+
value=111)
|
| 162 |
with gr.Row():
|
| 163 |
negative_prompt = gr.Textbox(label='Negative Prompt', value='blurry, ugly, duplicate, poorly drawn, deformed, mosaic')
|
| 164 |
|