urbanlc.model.pipeline_transforms.rand_bbox#

urbanlc.model.pipeline_transforms.rand_bbox(size: Tuple[int], lam: float) Tuple[float, float, float, float]#

Generate a random bounding box.

Parameters:
  • size (Tuple[int]) – Size of the tensor (N, C, H, W).

  • lam (float) – Lambda value for beta distribution.

Returns:

Coordinates of the bounding box (bbx1, bby1, bbx2, bby2).

Return type:

Tuple[float, float, float, float]