Spaces:
Runtime error
Runtime error
Commit
·
f659f8d
1
Parent(s):
5bc1be6
update
Browse files
app.py
CHANGED
@@ -131,7 +131,7 @@ def visual_grounding(Image, Text):
|
|
131 |
sample = utils.apply_to_sample(apply_half, sample) if use_fp16 else sample
|
132 |
with torch.no_grad():
|
133 |
result, scores = eval_step(task, generator, models, sample)
|
134 |
-
img =
|
135 |
cv2.rectangle(
|
136 |
img,
|
137 |
(int(result[0]["box"][0]), int(result[0]["box"][1])),
|
|
|
131 |
sample = utils.apply_to_sample(apply_half, sample) if use_fp16 else sample
|
132 |
with torch.no_grad():
|
133 |
result, scores = eval_step(task, generator, models, sample)
|
134 |
+
img = np.asarray(Image)
|
135 |
cv2.rectangle(
|
136 |
img,
|
137 |
(int(result[0]["box"][0]), int(result[0]["box"][1])),
|