torch.nn.functional.pixel_unshuffle¶
- torch.nn.functional.pixel_unshuffle(input, downscale_factor) Tensor ¶
Reverses the
PixelShuffle
operation by rearranging elements in a tensor of shape to a tensor of shape , where r is thedownscale_factor
.See
PixelUnshuffle
for details.- Parameters:
Examples:
>>> input = torch.randn(1, 1, 12, 12) >>> output = torch.nn.functional.pixel_unshuffle(input, 3) >>> print(output.size()) torch.Size([1, 9, 4, 4])