Adding 'Valid' and 'Same' padding option in Transposed Convolution layer.

This commit is contained in:
kartikdutt18
2020-01-18 08:38:33 +05:30
parent 352fcb2734
commit 42e5c1f728
@@ -455,6 +455,7 @@ void TransposedConvolution<
padWidth = (kernelWidth-strideWidth)/2 + kernelWidth-strideWidth%2==1;
padHeight = (kernelHeight-strideHeight)/2 + kernelHeight-strideHeight%2==1;
// If Padding is negative set it to 0.
if(padWidth<0){
padWidth = 0;
}