use tensoriterator instead of th for fill_ implementation. (#20719)
Summary:
Moves fill_ to aten as suggested in:
https://github.com/pytorch/pytorch/pull/20336#issuecomment-493260729
borrows from cpuhrsch's PR: https://github.com/pytorch/pytorch/pull/18876/files#diff-0d1178f1a4ce15aeb760d251974e6924
Co-authored-by: cpuhrsch
Pull Request resolved: https://github.com/pytorch/pytorch/pull/20719
Differential Revision: D15439420
Pulled By: nairbv
fbshipit-source-id: cbcc313cda61a528cecc4a28d601871565e6110c