Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -55,7 +55,7 @@ def resize(img, target_res=224, resize=True, to_pil=True, edge=False, sampling_f
|
|
55 |
return canvas
|
56 |
|
57 |
# βββ Feature extraction ββββββββββββββββββββββββββββββββββββββββββ
|
58 |
-
@spaces.GPU(duration=
|
59 |
def get_processed_features_dino(num_patches, img,use_dummy):
|
60 |
with torch.no_grad():
|
61 |
batch = extractor_vit.preprocess_pil(img)
|
@@ -177,7 +177,7 @@ def reload_img(
|
|
177 |
|
178 |
|
179 |
# βββ Configuration βββββββββββββββββββββββββββββββββββββββββββββββ
|
180 |
-
num_patches =
|
181 |
target_res = num_patches * 14
|
182 |
ckpt_file = "./ckpts/dino_spair_0300.pth"
|
183 |
|
|
|
55 |
return canvas
|
56 |
|
57 |
# βββ Feature extraction ββββββββββββββββββββββββββββββββββββββββββ
|
58 |
+
@spaces.GPU(duration=20)
|
59 |
def get_processed_features_dino(num_patches, img,use_dummy):
|
60 |
with torch.no_grad():
|
61 |
batch = extractor_vit.preprocess_pil(img)
|
|
|
177 |
|
178 |
|
179 |
# βββ Configuration βββββββββββββββββββββββββββββββββββββββββββββββ
|
180 |
+
num_patches = 45
|
181 |
target_res = num_patches * 14
|
182 |
ckpt_file = "./ckpts/dino_spair_0300.pth"
|
183 |
|