PyTorch (and other ML frameworks that I know about) actually implement cross-correlation in the functions named convolution.
The difference is just the reversal of the filter.
filt = torch.from_numpy(np.ascontiguousarray(testFilt[::-1, ::-1])).type(torch.float32)
filt = filt.unsqueeze(0).unsqueeze(0)

Now it produces the same results.

  
      en.wikipedia.org
  
  
    

Cross-correlation 25

In signal processing, cross-correlation is a measure of similarity of two series as a function of the displacement of one relative to the other. This is also known as a sliding dot product or sliding inner-product. It is commonly used for searching a long signal for a shorter, known feature. It has applications in pattern recognition, single particle analysis, electron tomography, averaging, cryptanalysis, and neurophysiology. For continuous functions f and g, the cross-correlation is defined as:...