Skip to content

Commit

Permalink
imgviz.instances.mask_to_bbox -> masks_to_bboxes
Browse files Browse the repository at this point in the history
  • Loading branch information
wkentaro committed Aug 1, 2024
1 parent bdfa1b1 commit 53b37c7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion osam/_models/efficientsam/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ def generate(self, request: types.GenerateRequest) -> types.GenerateResponse:
mask = masks[0, 0, 0, :, :] # (1, 1, 3, H, W) -> (H, W)
mask = mask > 0.0

bbox = imgviz.instances.mask_to_bbox([mask])[0].astype(int)
bbox = imgviz.instances.masks_to_bboxes(masks=[mask])[0].astype(int)

return types.GenerateResponse(
model=self.name,
Expand Down

0 comments on commit 53b37c7

Please sign in to comment.