Unfortunately updating SpatialConvolutionMM.c in THNN does not resolve the error.
Do you know how to change the declaration of thnn_conv2d_forward_out() and  thnn_conv2d_forward() in the autogenerated Declarations.yaml file “build/aten/src/ATen/Declarations.yaml”?
Changing them in derivatives.yaml “/tools/autograd/derivatives.yaml” does not yield a result.