Unverified Commit ba94133f authored by Mantas's avatar Mantas Committed by GitHub
Browse files

Add expected shapes in tvtensors docs (#8262)


Co-authored-by: default avatarNicolas Hug <contact@nicolas-hug.com>
parent 2ae6a6d5
...@@ -25,7 +25,7 @@ class BoundingBoxFormat(Enum): ...@@ -25,7 +25,7 @@ class BoundingBoxFormat(Enum):
class BoundingBoxes(TVTensor): class BoundingBoxes(TVTensor):
""":class:`torch.Tensor` subclass for bounding boxes. """:class:`torch.Tensor` subclass for bounding boxes with shape ``[N, 4]``.
.. note:: .. note::
There should be only one :class:`~torchvision.tv_tensors.BoundingBoxes` There should be only one :class:`~torchvision.tv_tensors.BoundingBoxes`
......
...@@ -9,7 +9,7 @@ from ._tv_tensor import TVTensor ...@@ -9,7 +9,7 @@ from ._tv_tensor import TVTensor
class Image(TVTensor): class Image(TVTensor):
""":class:`torch.Tensor` subclass for images. """:class:`torch.Tensor` subclass for images with shape ``[..., C, H, W]``.
.. note:: .. note::
......
...@@ -9,7 +9,7 @@ from ._tv_tensor import TVTensor ...@@ -9,7 +9,7 @@ from ._tv_tensor import TVTensor
class Mask(TVTensor): class Mask(TVTensor):
""":class:`torch.Tensor` subclass for segmentation and detection masks. """:class:`torch.Tensor` subclass for segmentation and detection masks with shape ``[..., H, W]``.
Args: Args:
data (tensor-like, PIL.Image.Image): Any data that can be turned into a tensor with :func:`torch.as_tensor` as data (tensor-like, PIL.Image.Image): Any data that can be turned into a tensor with :func:`torch.as_tensor` as
......
...@@ -8,7 +8,7 @@ from ._tv_tensor import TVTensor ...@@ -8,7 +8,7 @@ from ._tv_tensor import TVTensor
class Video(TVTensor): class Video(TVTensor):
""":class:`torch.Tensor` subclass for videos. """:class:`torch.Tensor` subclass for videos with shape ``[..., T, C, H, W]``.
Args: Args:
data (tensor-like): Any data that can be turned into a tensor with :func:`torch.as_tensor`. data (tensor-like): Any data that can be turned into a tensor with :func:`torch.as_tensor`.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment