Solved by ptrblck in post #3 
              
              
                If the output_size argument is fixed for each layer, you could create a custom module and set this argument during its initialization: 
class MyConvTranspose3d(nn.Module):
    def __init__(self, conv, output_size=None):
        super().__init__()
        self.conv = conv
        self.output_size = o…