I also have the same error message. BTW, I use the torch.pdist either, which seems the same problem as @Naruto-Sasuke.
The CPU works fine, but GPU will have this error.
torch version: 1.4.0
CUDA: 10.1