It’s a little complicated. Here is the entry point for convolution:

  
      github.com
  
  
    pytorch/pytorch/blob/master/aten/src/ATen/native/Convolution.cpp#L289-L297 77

at::Tensor convolution(
  const Tensor& input, const Tensor& weight, const Tensor& bias,
  IntList stride, IntList padding, IntList dilation,
  bool transposed, IntList output_padding, int64_t groups) {
auto& ctx = at::globalContext();
return at::_convolution(input, weight, bias, stride, padding, dilation,
                        transposed, output_padding, groups,
                        ctx.benchmarkCuDNN(), ctx.deterministicCuDNN(), ctx.userEnabledCuDNN());
}