Update app.py
Browse files
app.py
CHANGED
@@ -75,10 +75,10 @@ fe_nonrobust_model = FeatureExtractor(non_robust_model,layers = [args.NONROBUST.
|
|
75 |
|
76 |
# +
|
77 |
def retrieval_fn(image,radio):
|
78 |
-
try:
|
79 |
-
|
80 |
-
except:
|
81 |
-
|
82 |
image = TRANSFORMS(image).unsqueeze(0)
|
83 |
image = image.to(args.PARAMETERS.device)
|
84 |
|
|
|
75 |
|
76 |
# +
|
77 |
def retrieval_fn(image,radio):
|
78 |
+
#try:
|
79 |
+
image = Image.fromarray(image)
|
80 |
+
#except:
|
81 |
+
#pass
|
82 |
image = TRANSFORMS(image).unsqueeze(0)
|
83 |
image = image.to(args.PARAMETERS.device)
|
84 |
|