>>> torch.tensor(1.)[()]
tensor(1.)
>>> torch.tensor(1.)[[]]
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
IndexError: too many indices for tensor of dimension 0
>>> torch.tensor([1.])[(0,)]
tensor(1.)
>>> torch.tensor([1.])[[0]]
tensor([1.])
Closes #7.
This turned out to be a bug in PyTorch:
This PR just works around that bug.