Skip to main content

Conv2d

Conv2d(in_channels, out_channels, kernel_size, stride=1, padding=0, dilation=1, groups=1, bias=True, padding_mode="zeros", device=None, dtype=None, *, activation=None)

A 2-d convolution over channels-last [batch, height, width, in_channels] input; weight [out_channels, kh, kw, in_channels // groups]. Every knob takes an int or a pair; padding also takes "valid" / "same".