_get_device_index supports parsing device strings
authorSsnL <tongzhou.wang.1994@gmail.com>
Mon, 10 Dec 2018 05:10:39 +0000 (21:10 -0800)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Mon, 10 Dec 2018 05:12:46 +0000 (21:12 -0800)
commitfab80851111ffe7c090f05a051f49f1c54342815
tree998271465c356aca6e9cb528c40621efc4cf7a87
parent5fd69e75516326c2cdb3af9ffa702068adc6fbf6
_get_device_index supports parsing device strings

Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/14929

Reviewed By: weiyangfb

Differential Revision: D13394498

Pulled By: soumith

fbshipit-source-id: 948c6118abdf6c1e1a8a17709333954cafb2345e
test/test_cuda.py
torch/cuda/_utils.py