1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103
|
.. _ops:
Operators
=========
.. currentmodule:: torchvision.ops
:mod:`torchvision.ops` implements operators, losses and layers that are specific for Computer Vision.
.. note::
All operators have native support for TorchScript.
Detection and Segmentation Operators
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The below operators perform pre-processing as well as post-processing required in object detection and segmentation models.
.. autosummary::
:toctree: generated/
:template: function.rst
batched_nms
masks_to_boxes
nms
roi_align
roi_pool
ps_roi_align
ps_roi_pool
.. autosummary::
:toctree: generated/
:template: class.rst
FeaturePyramidNetwork
MultiScaleRoIAlign
RoIAlign
RoIPool
PSRoIAlign
PSRoIPool
Box Operators
~~~~~~~~~~~~~
These utility functions perform various operations on bounding boxes.
.. autosummary::
:toctree: generated/
:template: function.rst
box_area
box_convert
box_iou
clip_boxes_to_image
complete_box_iou
distance_box_iou
generalized_box_iou
remove_small_boxes
Losses
~~~~~~
The following vision-specific loss functions are implemented:
.. autosummary::
:toctree: generated/
:template: function.rst
complete_box_iou_loss
distance_box_iou_loss
generalized_box_iou_loss
sigmoid_focal_loss
Layers
~~~~~~
TorchVision provides commonly used building blocks as layers:
.. autosummary::
:toctree: generated/
:template: class.rst
Conv2dNormActivation
Conv3dNormActivation
DeformConv2d
DropBlock2d
DropBlock3d
FrozenBatchNorm2d
MLP
Permute
SqueezeExcitation
StochasticDepth
.. autosummary::
:toctree: generated/
:template: function.rst
deform_conv2d
drop_block2d
drop_block3d
stochastic_depth
|