Spaces:
Runtime error
Runtime error
Linoy Tsaban
commited on
Commit
•
2419d25
1
Parent(s):
8f7289c
Update app.py
Browse files
app.py
CHANGED
@@ -141,7 +141,7 @@ def edit(input_image,
|
|
141 |
src_prompt,
|
142 |
src_cfg_scale):
|
143 |
|
144 |
-
|
145 |
x0 = load_512(input_image, device=device)
|
146 |
# invert and retrieve noise maps and latent
|
147 |
zs_tensor, wts_tensor = invert(x0 =x0 , prompt_src=src_prompt, num_diffusion_steps=steps, cfg_scale_src=src_cfg_scale)
|
|
|
141 |
src_prompt,
|
142 |
src_cfg_scale):
|
143 |
|
144 |
+
if do_inversion or randomize_seed:
|
145 |
x0 = load_512(input_image, device=device)
|
146 |
# invert and retrieve noise maps and latent
|
147 |
zs_tensor, wts_tensor = invert(x0 =x0 , prompt_src=src_prompt, num_diffusion_steps=steps, cfg_scale_src=src_cfg_scale)
|