JeffLiang commited on
Commit
ba09e2c
1 Parent(s): 304ea95

memory saver

Browse files
Files changed (1) hide show
  1. open_vocab_seg/utils/predictor.py +1 -1
open_vocab_seg/utils/predictor.py CHANGED
@@ -151,7 +151,7 @@ class SAMVisualizationDemo(object):
151
  self.parallel = parallel
152
  self.granularity = granularity
153
  sam = sam_model_registry["vit_h"](checkpoint=sam_path).cuda()
154
- self.predictor = SamAutomaticMaskGenerator(sam)
155
  self.clip_model, _, _ = open_clip.create_model_and_transforms('ViT-L-14', pretrained=ovsegclip_path)
156
  self.clip_model.cuda()
157
 
 
151
  self.parallel = parallel
152
  self.granularity = granularity
153
  sam = sam_model_registry["vit_h"](checkpoint=sam_path).cuda()
154
+ self.predictor = SamAutomaticMaskGenerator(sam, points_per_batch=16)
155
  self.clip_model, _, _ = open_clip.create_model_and_transforms('ViT-L-14', pretrained=ovsegclip_path)
156
  self.clip_model.cuda()
157