Apply the 2d convolution.

Set padding to VALID will use the value of pads.

  • inputs (Sequence[dragon.Tensor]) – The tensor x, weight and bias.
  • kernel_shape (Sequence[int], optional, default=3) – The shape of convolution kernel.
  • strides (Sequence[int], optional, default=1) – The stride(s) of sliding window.
  • pads (Sequence[int], optional, default=0) – The zero-padding size(s).
  • dilations (Sequence[int], optional, default=1) – The rate(s) of dilated kernel.
  • group (int, optional, default=1) – The number of groups to split input channels.
  • padding ({'VALID', 'SAME', 'SAME_UPPER', 'SAME_LOWER'}, optional) – The padding algorithm.
  • data_format ({'NCHW', 'NHWC'}, optional) – The optional data format.

dragon.Tensor – The output tensor.