Skip to content

Commit

Permalink
modify explanation
Browse files Browse the repository at this point in the history
  • Loading branch information
venkatram-dev committed Aug 30, 2024
1 parent 2dc2dfe commit 844aec7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions notebooks/how-to-segment-images-with-sam-2.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -1085,8 +1085,8 @@
" multimask_output=False\n",
")\n",
"\n",
"# A single bounding box is already a 3D np.array\n",
"# multiple bounding boxes need to be squeezed\n",
"# With one box as input, predictor returns masks of shape (1, H, W);\n",
"# with N boxes, it returns (N, 1, H, W).\n",
"if boxes.shape[0] != 1:\n",
" masks = np.squeeze(masks)\n"
],
Expand Down

0 comments on commit 844aec7

Please sign in to comment.