Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -87,8 +87,9 @@ def inference(text, style, inference_step, guidance_scale, seed, guidance_method
|
|
87 |
|
88 |
return image_pipeline, image_guide
|
89 |
|
90 |
-
#
|
91 |
-
|
|
|
92 |
<style>
|
93 |
body {
|
94 |
background: linear-gradient(135deg, #1a1c2c, #4a4e69, #9a8c98);
|
@@ -219,6 +220,7 @@ css = """
|
|
219 |
background-color: transparent !important;
|
220 |
}
|
221 |
</style>
|
|
|
222 |
<div id="app-header">
|
223 |
<div class="artifact large"></div>
|
224 |
<div class="artifact medium"></div>
|
@@ -245,9 +247,8 @@ css = """
|
|
245 |
</div>
|
246 |
</div>
|
247 |
"""
|
248 |
-
|
249 |
-
|
250 |
-
gr.HTML(css + open("path/to/your/html_structure.html").read())
|
251 |
|
252 |
with gr.Row():
|
253 |
text = gr.Textbox(label="Prompt", placeholder="Describe your dreamscape...")
|
@@ -289,4 +290,7 @@ with gr.Blocks(css=css) as demo:
|
|
289 |
fn=inference,
|
290 |
cache_examples=True,
|
291 |
examples_per_page=5
|
292 |
-
)
|
|
|
|
|
|
|
|
87 |
|
88 |
return image_pipeline, image_guide
|
89 |
|
90 |
+
# Your existing imports and model setup code here...
|
91 |
+
|
92 |
+
css_and_html = """
|
93 |
<style>
|
94 |
body {
|
95 |
background: linear-gradient(135deg, #1a1c2c, #4a4e69, #9a8c98);
|
|
|
220 |
background-color: transparent !important;
|
221 |
}
|
222 |
</style>
|
223 |
+
|
224 |
<div id="app-header">
|
225 |
<div class="artifact large"></div>
|
226 |
<div class="artifact medium"></div>
|
|
|
247 |
</div>
|
248 |
</div>
|
249 |
"""
|
250 |
+
with gr.Blocks(css=css_and_html) as demo:
|
251 |
+
gr.HTML(css_and_html)
|
|
|
252 |
|
253 |
with gr.Row():
|
254 |
text = gr.Textbox(label="Prompt", placeholder="Describe your dreamscape...")
|
|
|
290 |
fn=inference,
|
291 |
cache_examples=True,
|
292 |
examples_per_page=5
|
293 |
+
)
|
294 |
+
|
295 |
+
if __name__ == "__main__":
|
296 |
+
demo.launch()
|