nets.py
def _forward(self, x):
        """Forward application of the module.

        Args:
            x: Tensor with shape [batch, channels, height, width].

        Returns:
            out_x: Output tensor with shape
                [batch, self._out_channels, output_height, output_width].
        """
        if not self.space_evaluated():
            if not self._output_padding_evaluated():
                raise ValueError(
                    'Cannot compute the output padding before it is evaluated. '
                    'Check to make sure that the output_padding_evaluated '
                    'argument to the constructor of this instance is correct.')

            output_padding = (0, self._output_padding['width'],
                              0, self._output_padding['height'])
            self._output_padding_module = torch.nn.ZeroPad2d(output_padding)

        layer_x = self._layer(x)
        padded_layer_x = self._output_padding_module(layer_x)
        out_x = padded_layer_x[:, :, self._stripping[0]:-self._stripping[1],
                               self._stripping[2]:-self._stripping[3]]

        return out_x
Forward application of the module.

        Args:
            x: Tensor with shape [batch, channels, height, width].

        Returns:
            out_x: Output tensor with shape
                [batch, self._out_channels, output_height, output_width].
        
Forward application of the module.
Forward application of the module .
def _forward(self, x):
        if not self.space_evaluated():
            if not self._output_padding_evaluated():
                raise ValueError(
                    'Cannot compute the output padding before it is evaluated. '
                    'Check to make sure that the output_padding_evaluated '
                    'argument to the constructor of this instance is correct.')
            output_padding = (0, self._output_padding['width'],
                              0, self._output_padding['height'])
            self._output_padding_module = torch.nn.ZeroPad2d(output_padding)
        layer_x = self._layer(x)
        padded_layer_x = self._output_padding_module(layer_x)
        out_x = padded_layer_x[:, :, self._stripping[0]:-self._stripping[1],
                               self._stripping[2]:-self._stripping[3]]
        return out_x
def _forward ( self , x ) : if not self . space_evaluated ( ) : if not self . _output_padding_evaluated ( ) : raise ValueError ( 'Cannot compute the output padding before it is evaluated. ' 'Check to make sure that the output_padding_evaluated ' 'argument to the constructor of this instance is correct.' ) output_padding = ( 0 , self . _output_padding [ 'width' ] , 0 , self . _output_padding [ 'height' ] ) self . _output_padding_module = torch . nn . ZeroPad2d ( output_padding ) layer_x = self . _layer ( x ) padded_layer_x = self . _output_padding_module ( layer_x ) out_x = padded_layer_x [ : , : , self . _stripping [ 0 ] : - self . _stripping [ 1 ] , self . _stripping [ 2 ] : - self . _stripping [ 3 ] ] return out_x
Forward application of the module.
Forward application of the module .
"""Forward application of the module.

        Args:
            x: Tensor with shape [batch, channels, height, width].

        Returns:
            out_x: Output tensor with shape
                [batch, self._out_channels, output_height, output_width].
        """
Output tensor with shape
[batch, self._out_channels, output_height, output_width].
Output tensor with shape [ batch self . _out_channels output_height output_width ] .
out_x
self
x
Tensor with shape [batch, channels, height, width].
Tensor with shape [ batch channels height width ] .