Optimize ConvTranspose2d stride description (#150819)

Fixes #150775

## Test Result

### Before

![image](https://github.com/user-attachments/assets/81cd932f-9447-4924-9553-a5cb88fc5d0e)

### After

![image](https://github.com/user-attachments/assets/6365c71c-7268-4226-b722-ee7446cb2467)

Pull Request resolved: https://github.com/pytorch/pytorch/pull/150819
Approved by: https://github.com/jbschlosser
This commit is contained in:
zeshengzong 2025-04-11 09:37:52 +00:00 committed by PyTorch MergeBot
parent 183bca41de
commit d94cc0e994

View File

@ -998,7 +998,10 @@ class ConvTranspose2d(_ConvTransposeNd):
On certain ROCm devices, when using float16 inputs this module will use :ref:`different precision<fp16_on_mi200>` for backward.
* :attr:`stride` controls the stride for the cross-correlation.
* :attr:`stride` controls the stride for the cross-correlation. When stride > 1, ConvTranspose2d inserts zeros between input
elements along the spatial dimensions before applying the convolution kernel. This zero-insertion operation is the standard
behavior of transposed convolutions, which can increase the spatial resolution and is equivalent to a learnable
upsampling operation.
* :attr:`padding` controls the amount of implicit zero padding on both
sides for ``dilation * (kernel_size - 1) - padding`` number of points. See note