Hi, its my second day with PyTorch. I have ran into this problem:
a = Variable(torch.randn(5, 3))
b = Variable(torch.randn(3))
print(a/b)
It is throwing an error:
RuntimeError: inconsistent tensor size at /data/users/soumith/builder/wheel/pytorch-src/torch/lib/TH/generic/THTensorMath.c:869
What should I do now? In numpy, I would have done so through broadcasting:
x = np.random.randn(5,3)
y = np.random.randn(3)
print(x/y)