Open ShreyasKhandekar opened 2 months ago
I thought about adding this, but the gradient kernel for the convolution operation with arbitrary kernel size, input channels, output channels, stride, and padding, is extremely difficult to implement. I think the forward kernel could be done trivially though. Let me know if this is a blocker for anything and I will write it.
Added the most basic level of support for this in https://github.com/Iainmon/ChAI/pull/14 . I will work on adding more
Currently
Conv2d
in ChAI does not support a parameter forpadding
. Although this can potentially be done withoutConv2d
having to support it as a parameter, it would be nice if we could support it to add it to all 4 sides of the input automatically within the layer.See pytorch for reference: https://pytorch.org/docs/stable/generated/torch.nn.Conv2d.html#torch.nn.Conv2d