Linoy Tsaban
commited on
Commit
·
908830c
1
Parent(s):
652f06c
Update app.py
Browse filesfixed example #3 path
app.py
CHANGED
|
@@ -52,7 +52,6 @@ sd_pipe = StableDiffusionPipeline.from_pretrained(sd_model_id).to(device)
|
|
| 52 |
sd_pipe.scheduler = DDIMScheduler.from_config(sd_model_id, subfolder = "scheduler")
|
| 53 |
sem_pipe = SemanticStableDiffusionPipeline.from_pretrained(sd_model_id).to(device)
|
| 54 |
|
| 55 |
-
cache_examples = True
|
| 56 |
|
| 57 |
def get_example():
|
| 58 |
case = [
|
|
@@ -73,7 +72,7 @@ def get_example():
|
|
| 73 |
'examples/ddpm_sega_plus_pink_drawings_of_muffins.png'
|
| 74 |
],
|
| 75 |
[
|
| 76 |
-
'examples/
|
| 77 |
'an empty room with concrete walls',
|
| 78 |
'glass walls',
|
| 79 |
'+giant elephant',
|
|
@@ -246,7 +245,8 @@ with gr.Blocks() as demo:
|
|
| 246 |
label='Examples',
|
| 247 |
examples=get_example(),
|
| 248 |
inputs=[input_image, src_prompt, tar_prompt, edit_concept, ddpm_edited_image, sega_edited_image],
|
| 249 |
-
outputs=[ddpm_edited_image, sega_edited_image]
|
|
|
|
| 250 |
|
| 251 |
|
| 252 |
|
|
|
|
| 52 |
sd_pipe.scheduler = DDIMScheduler.from_config(sd_model_id, subfolder = "scheduler")
|
| 53 |
sem_pipe = SemanticStableDiffusionPipeline.from_pretrained(sd_model_id).to(device)
|
| 54 |
|
|
|
|
| 55 |
|
| 56 |
def get_example():
|
| 57 |
case = [
|
|
|
|
| 72 |
'examples/ddpm_sega_plus_pink_drawings_of_muffins.png'
|
| 73 |
],
|
| 74 |
[
|
| 75 |
+
'examples/source_an_empty_room_with_concrete_walls.jpeg',
|
| 76 |
'an empty room with concrete walls',
|
| 77 |
'glass walls',
|
| 78 |
'+giant elephant',
|
|
|
|
| 245 |
label='Examples',
|
| 246 |
examples=get_example(),
|
| 247 |
inputs=[input_image, src_prompt, tar_prompt, edit_concept, ddpm_edited_image, sega_edited_image],
|
| 248 |
+
outputs=[ddpm_edited_image, sega_edited_image],
|
| 249 |
+
cache_examples=True)
|
| 250 |
|
| 251 |
|
| 252 |
|