remove_small_boxes¶
- torchvision.ops.remove_small_boxes(boxes: Tensor, min_size: float) Tensor [source]¶
从
boxes
中移除至少有一个边长小于min_size
的所有框。注意
对于用于清理
BoundingBoxes
对象,请考虑使用转换SanitizeBoundingBoxes()
替代。- 参数:
boxes (Tensor[N, 4]) – 格式为
(x1, y1, x2, y2)
的框,其中0 <= x1 < x2
和0 <= y1 < y2
。min_size (float) – 最小尺寸
- 返回:
两个边都大于
min_size
的框的索引- 返回类型:
Tensor[K]