Transposed Convolution Configuration for FCN Upsampling
To restore the spatial dimensions of feature maps to the original input image size in a Fully Convolutional Network (FCN), a transposed convolutional layer is employed. If the spatial dimensions need to be increased by a factor of , the transposed convolution is configured with a stride of . To achieve the exact original dimensions, the padding is set to (assuming is an integer), and the height and width of the convolution kernel are set to . For instance, to upscale a feature map by 32 times, the stride is 32, the padding is 16, and the kernel size is 64.
# PyTorch net.add_module('transpose_conv', nn.ConvTranspose2d(num_classes, num_classes, kernel_size=64, padding=16, stride=32))
# MXNet net.add(nn.Conv2DTranspose(num_classes, kernel_size=64, padding=16, strides=32))
0
1
Tags
D2L
Dive into Deep Learning @ D2L
Related
Feature Extraction in Fully Convolutional Networks
Channel Transformation in Fully Convolutional Networks
Accuracy Calculation in Fully Convolutional Networks
Loss Calculation in Fully Convolutional Networks
Transposed Convolution Configuration for FCN Upsampling
Transposed Convolution Configuration for FCN Upsampling