Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
|
@@ -137,7 +137,8 @@ def edit(init_image, source_prompt, target_prompt, num_steps, inject_step, guida
|
|
| 137 |
idx = max(int(fn.split("_")[-1].split(".")[0]) for fn in fns) + 1
|
| 138 |
else:
|
| 139 |
idx = 0
|
| 140 |
-
|
|
|
|
| 141 |
with torch.autocast(device_type=device.type, dtype=torch.bfloat16):
|
| 142 |
x = ae.decode(x)
|
| 143 |
|
|
|
|
| 137 |
idx = max(int(fn.split("_")[-1].split(".")[0]) for fn in fns) + 1
|
| 138 |
else:
|
| 139 |
idx = 0
|
| 140 |
+
|
| 141 |
+
device = torch.device("cuda")
|
| 142 |
with torch.autocast(device_type=device.type, dtype=torch.bfloat16):
|
| 143 |
x = ae.decode(x)
|
| 144 |
|