The torch.Tensor elements in the docs are methods on Tensors.
So they should be called on a tensor: x.scatter(xxx).
If you want to use the version in torch., then you need to provide the tensor as first argument: torch.scatter(x, foo).