Unverified Commit 0e688ce0 authored by Nicolas Hug's avatar Nicolas Hug Committed by GitHub
Browse files

Add new `.. betastatus::` directive and document Beta APIs (#6115)

* Add new .. betastatus:: directive to document Beta APIs

* Also add it for the fine-grained video API

* Add directive for all builders and pages of Detection module

* Also segmentation and video models
parent 3c94a490
......@@ -412,6 +412,8 @@ def maskrcnn_resnet50_fpn(
"""Mask R-CNN model with a ResNet-50-FPN backbone from the `Mask R-CNN
<https://arxiv.org/abs/1703.06870>`_ paper.
.. betastatus:: detection module
The input to the model is expected to be a list of tensors, each of shape ``[C, H, W]``, one for each
image, and should be in ``0-1`` range. Different images can have different sizes.
......@@ -513,6 +515,8 @@ def maskrcnn_resnet50_fpn_v2(
"""Improved Mask R-CNN model with a ResNet-50-FPN backbone from the `Benchmarking Detection Transfer
Learning with Vision Transformers <https://arxiv.org/abs/2111.11429>`_ paper.
.. betastatus:: detection module
:func:`~torchvision.models.detection.maskrcnn_resnet50_fpn` for more details.
Args:
......
......@@ -733,6 +733,8 @@ def retinanet_resnet50_fpn(
"""
Constructs a RetinaNet model with a ResNet-50-FPN backbone.
.. betastatus:: detection module
Reference: `Focal Loss for Dense Object Detection <https://arxiv.org/abs/1708.02002>`_.
The input to the model is expected to be a list of tensors, each of shape ``[C, H, W]``, one for each
......@@ -829,6 +831,8 @@ def retinanet_resnet50_fpn_v2(
"""
Constructs an improved RetinaNet model with a ResNet-50-FPN backbone.
.. betastatus:: detection module
Reference: `Bridging the Gap Between Anchor-based and Anchor-free Detection via Adaptive Training Sample Selection
<https://arxiv.org/abs/1912.02424>`_.
......
......@@ -584,6 +584,8 @@ def ssd300_vgg16(
"""The SSD300 model is based on the `SSD: Single Shot MultiBox Detector
<https://arxiv.org/abs/1512.02325>`_ paper.
.. betastatus:: detection module
The input to the model is expected to be a list of tensors, each of shape [C, H, W], one for each
image, and should be in 0-1 range. Different images can have different sizes but they will be resized
to a fixed size before passing it to the backbone.
......
......@@ -222,6 +222,8 @@ def ssdlite320_mobilenet_v3_large(
described at `Searching for MobileNetV3 <https://arxiv.org/abs/1905.02244>`__ and
`MobileNetV2: Inverted Residuals and Linear Bottlenecks <https://arxiv.org/abs/1801.04381>`__.
.. betastatus:: detection module
See :func:`~torchvision.models.detection.ssd300_vgg16` for more details.
Example:
......
......@@ -233,6 +233,8 @@ def deeplabv3_resnet50(
) -> DeepLabV3:
"""Constructs a DeepLabV3 model with a ResNet-50 backbone.
.. betastatus:: segmentation module
Reference: `Rethinking Atrous Convolution for Semantic Image Segmentation <https://arxiv.org/abs/1706.05587>`__.
Args:
......@@ -286,6 +288,8 @@ def deeplabv3_resnet101(
) -> DeepLabV3:
"""Constructs a DeepLabV3 model with a ResNet-101 backbone.
.. betastatus:: segmentation module
Reference: `Rethinking Atrous Convolution for Semantic Image Segmentation <https://arxiv.org/abs/1706.05587>`__.
Args:
......
......@@ -126,6 +126,8 @@ def fcn_resnet50(
"""Fully-Convolutional Network model with a ResNet-50 backbone from the `Fully Convolutional
Networks for Semantic Segmentation <https://arxiv.org/abs/1411.4038>`_ paper.
.. betastatus:: segmentation module
Args:
weights (:class:`~torchvision.models.segmentation.FCN_ResNet50_Weights`, optional): The
pretrained weights to use. See
......@@ -182,6 +184,8 @@ def fcn_resnet101(
"""Fully-Convolutional Network model with a ResNet-101 backbone from the `Fully Convolutional
Networks for Semantic Segmentation <https://arxiv.org/abs/1411.4038>`_ paper.
.. betastatus:: segmentation module
Args:
weights (:class:`~torchvision.models.segmentation.FCN_ResNet101_Weights`, optional): The
pretrained weights to use. See
......
......@@ -132,6 +132,8 @@ def lraspp_mobilenet_v3_large(
"""Constructs a Lite R-ASPP Network model with a MobileNetV3-Large backbone from
`Searching for MobileNetV3 <https://arxiv.org/abs/1905.02244>`_ paper.
.. betastatus:: segmentation module
Args:
weights (:class:`~torchvision.models.segmentation.LRASPP_MobileNet_V3_Large_Weights`, optional): The
pretrained weights to use. See
......
......@@ -374,6 +374,8 @@ class R2Plus1D_18_Weights(WeightsEnum):
def r3d_18(*, weights: Optional[R3D_18_Weights] = None, progress: bool = True, **kwargs: Any) -> VideoResNet:
"""Construct 18 layer Resnet3D model.
.. betastatus:: video module
Reference: `A Closer Look at Spatiotemporal Convolutions for Action Recognition <https://arxiv.org/abs/1711.11248>`__.
Args:
......@@ -408,6 +410,8 @@ def r3d_18(*, weights: Optional[R3D_18_Weights] = None, progress: bool = True, *
def mc3_18(*, weights: Optional[MC3_18_Weights] = None, progress: bool = True, **kwargs: Any) -> VideoResNet:
"""Construct 18 layer Mixed Convolution network as in
.. betastatus:: video module
Reference: `A Closer Look at Spatiotemporal Convolutions for Action Recognition <https://arxiv.org/abs/1711.11248>`__.
Args:
......@@ -442,6 +446,8 @@ def mc3_18(*, weights: Optional[MC3_18_Weights] = None, progress: bool = True, *
def r2plus1d_18(*, weights: Optional[R2Plus1D_18_Weights] = None, progress: bool = True, **kwargs: Any) -> VideoResNet:
"""Construct 18 layer deep R(2+1)D network as in
.. betastatus:: video module
Reference: `A Closer Look at Spatiotemporal Convolutions for Action Recognition <https://arxiv.org/abs/1711.11248>`__.
Args:
......
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