I am trying to check the count of element-wise equality between two tensors. I have narrowed my issue down to the following short example. The last line results in an “Illegal instruction” message and crashing out of Python.
import torch

torch.manual_seed(1)
x = torch.randint(0, 5, (1000, ))

x.eq(x).sum()

I am using Python 3.6.4 in iPython 6.5.0 with torch 0.4.1 on Windows 10.