odunkel commited on
Commit
2f5372c
Β·
verified Β·
1 Parent(s): fd625c4

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
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=0)
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 = 30
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