Numba convolutions with Padding

This code (https://numba.discourse.group/t/numba-convolutions/33/2) which calculates convolutions with cuda.grid. But unfortunately padding is not possible. Is there an efficient way to extend this code so that padding is possible?