Spaces:
Runtime error
Runtime error
ahmetyaylalioglu
commited on
Commit
•
d25512a
1
Parent(s):
80a267a
Update app.py
Browse files
app.py
CHANGED
@@ -24,7 +24,7 @@ def get_processed_inputs(image, points_str):
|
|
24 |
# Parse the input string into a list of points
|
25 |
points = list(map(int, points_str.split(',')))
|
26 |
# Reshape the points into pairs
|
27 |
-
input_points = [[
|
28 |
|
29 |
inputs = processor(image, input_points=input_points, return_tensors="pt").to(device)
|
30 |
with torch.no_grad():
|
|
|
24 |
# Parse the input string into a list of points
|
25 |
points = list(map(int, points_str.split(',')))
|
26 |
# Reshape the points into pairs
|
27 |
+
input_points = [[[x, y] for x, y in zip(points[::2], points[1::2])]]
|
28 |
|
29 |
inputs = processor(image, input_points=input_points, return_tensors="pt").to(device)
|
30 |
with torch.no_grad():
|