I tried the code in docs. But it gives me a error.
RuntimeError: Input, output and indices must be on the current device