Thanks for your kind reply.
I have tried both torch.float32 and torch.float64 for weights and input in my own implementation. And both of them demonstrate some differences compared with the official conv2d API. As for the results, double precision will even introduce more difference compared with the official implementation of Conv2d in Pytorch.
Might I ask whether there are other reasons except the precision issue to cause such a difference? And whether there is a custom implementation to match the custom implementation to the official Conv2d?
Thanks again for your help!
Best
Jianming