Exemplo n.º 1
0
    def __init__(self,
                 in_channels,
                 out_channels,
                 kernel_size,
                 stride=1,
                 padding=0,
                 out_padding=0,
                 dilation=1,
                 groups=1,
                 bias=True,
                 weight_init=Kaiming_Normal(),
                 bias_init=Zeros()):
        """

        :param in_channels:
        :param out_channels:
        :param kernel_size:
        :param stride:
        :param padding:
        :param dilation:
        :param groups:
        :param bias:
        :param weight_init:
        :param bias_init:
        """
        super(ConvTranspose1d,
              self).__init__(in_channels, out_channels, _single(kernel_size),
                             _single(stride), _single(padding),
                             _single(dilation), groups, bias,
                             _single(out_padding), weight_init, bias_init)
Exemplo n.º 2
0
    def __init__(self,
                 in_channels,
                 kernel_size,
                 stride=1,
                 padding=0,
                 out_padding=0,
                 dilation=1,
                 bias=True,
                 multiplier=1,
                 weight_init=Kaiming_Normal(),
                 bias_init=Zeros()):
        """

        :param in_channels:
        :param kernel_size:
        :param stride:
        :param padding:
        :param dilation:
        :param bias:
        :param multiplier:
        :param weight_init:
        :param bias_init:
        """
        super(DepthwiseConvTranspose1d,
              self).__init__(in_channels, in_channels * multiplier,
                             _single(kernel_size), _single(stride),
                             _single(padding),
                             _single(dilation), in_channels, bias,
                             _single(out_padding), weight_init, bias_init)
 def __init__(self,
              in_channels: int,
              out_channels: int,
              kernel_size: _size_1_t,
              stride: _size_1_t = 1,
              padding: _size_1_t = 0,
              dilation: _size_1_t = 1,
              groups: int = 1,
              bias: bool = True,
              padding_mode: str = 'zeros'):
     kernel_size = _single(kernel_size)
     stride = _single(stride)
     padding = _single(padding)
     dilation = _single(dilation)
     super(Conv1d, self).__init__(in_channels, out_channels, kernel_size,
                                  stride, padding, dilation, False,
                                  _single(0), groups, bias, padding_mode)