Allow migrating factory methods to c10 (#28183)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/28183
-
ghstack-source-id: 92436986
Test Plan: waitforsandcastle
Differential Revision: D17969015
fbshipit-source-id: 0e2eac09c9622fc6c6e90bb80d2a250f37bbd148