Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -76,7 +76,7 @@ def predict(radio, dict, word_mask, prompt=""):
|
|
76 |
with autocast(device): #"cuda"
|
77 |
init_image = dict["image"].convert("RGB").resize((512, 512))
|
78 |
mask = dict["mask"].convert("RGB").resize((512, 512))
|
79 |
-
|
80 |
img = transform(dict["image"]).squeeze(0)
|
81 |
word_masks = [word_mask]
|
82 |
with torch.no_grad():
|
|
|
76 |
with autocast(device): #"cuda"
|
77 |
init_image = dict["image"].convert("RGB").resize((512, 512))
|
78 |
mask = dict["mask"].convert("RGB").resize((512, 512))
|
79 |
+
elif(radio == "type what to keep"):
|
80 |
img = transform(dict["image"]).squeeze(0)
|
81 |
word_masks = [word_mask]
|
82 |
with torch.no_grad():
|