Change one_hot from IndexTensor to Tensor. (#18073)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/18073
ghimport-source-id: f4dadebafa0423c4c5a0e46c15b38129402d830a
Stack:
* #18072 properly device_guard IndexTensor and BoolTensor.
* **#18073 Change one_hot from IndexTensor to Tensor.**
There is no codegen change.
Reviewed By: ezyang
Differential Revision: D14485248
fbshipit-source-id: ee2ba8e5dcbbbaf0214a026c8e7ed4e6712becb0