Spaces:
Build error
Build error
edits
Browse files
app.py
CHANGED
|
@@ -95,15 +95,15 @@ def generate_matching_superfeatures(im1, im2, scale_id=6, threshold=50, sf_ids='
|
|
| 95 |
# feats2 = output2[0][0]
|
| 96 |
# attns2 = output2[1][0]
|
| 97 |
# strenghts2 = output2[2][0]
|
| 98 |
-
|
| 99 |
-
|
| 100 |
-
|
| 101 |
-
|
| 102 |
-
|
| 103 |
-
|
| 104 |
-
|
| 105 |
-
|
| 106 |
-
|
| 107 |
print(feats1.shape, feats2.shape)
|
| 108 |
print(attns1.shape, attns2.shape)
|
| 109 |
print(strenghts1.shape, strenghts2.shape)
|
|
|
|
| 95 |
# feats2 = output2[0][0]
|
| 96 |
# attns2 = output2[1][0]
|
| 97 |
# strenghts2 = output2[2][0]
|
| 98 |
+
outputs = []
|
| 99 |
+
for im_tensor in loader:
|
| 100 |
+
outputs.append(net.get_superfeatures(im_tensor.to(device), scales=[scales[scale_id]]))
|
| 101 |
+
feats1 = outputs[0][0][0]
|
| 102 |
+
attns1 = outputs[0][1][0]
|
| 103 |
+
strenghts1 = outputs[0][2][0]
|
| 104 |
+
feats2 = outputs[1][0][0]
|
| 105 |
+
attns2 = outputs[1][1][0]
|
| 106 |
+
strenghts2 = outputs[1][2][0]
|
| 107 |
print(feats1.shape, feats2.shape)
|
| 108 |
print(attns1.shape, attns2.shape)
|
| 109 |
print(strenghts1.shape, strenghts2.shape)
|