Shortcuts

mmcv.ops.convex_giou

mmcv.ops.convex_giou(pointsets: torch.Tensor, polygons: torch.Tensor)Tuple[torch.Tensor, torch.Tensor][源代码]

Return generalized intersection-over-union (Jaccard index) between point sets and polygons.

参数
  • pointsets (torch.Tensor) – It has shape (N, 18), indicating (x1, y1, x2, y2, …, x9, y9) for each row.

  • polygons (torch.Tensor) – It has shape (N, 8), indicating (x1, y1, x2, y2, x3, y3, x4, y4) for each row.

返回

The first element is the gious between point sets and polygons with the shape (N,). The second element is the gradient of point sets with the shape (N, 18).

返回类型

tuple[torch.Tensor, torch.Tensor]