Spaces:
Runtime error
Runtime error
Fixed np latent when not editing
Browse files
app.py
CHANGED
|
@@ -190,7 +190,7 @@ class ImageEditor(object):
|
|
| 190 |
|
| 191 |
# if edit type is none or if all slides were set to 0
|
| 192 |
if not target_latents:
|
| 193 |
-
target_latents = [
|
| 194 |
|
| 195 |
return target_latents
|
| 196 |
|
|
@@ -332,7 +332,8 @@ with blocks:
|
|
| 332 |
with gr.TabItem("Edit Images"):
|
| 333 |
with gr.Row():
|
| 334 |
with gr.Column():
|
| 335 |
-
|
|
|
|
| 336 |
with gr.Column():
|
| 337 |
img_output = gr.Gallery(label="Output Images")
|
| 338 |
|
|
|
|
| 190 |
|
| 191 |
# if edit type is none or if all slides were set to 0
|
| 192 |
if not target_latents:
|
| 193 |
+
target_latents = [np_source_latent, ] * (len(generators) - 1)
|
| 194 |
|
| 195 |
return target_latents
|
| 196 |
|
|
|
|
| 332 |
with gr.TabItem("Edit Images"):
|
| 333 |
with gr.Row():
|
| 334 |
with gr.Column():
|
| 335 |
+
with gr.Row():
|
| 336 |
+
img_button = gr.Button("Edit Image")
|
| 337 |
with gr.Column():
|
| 338 |
img_output = gr.Gallery(label="Output Images")
|
| 339 |
|