Add image sampler. (#45037)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/45037
Test Plan: Imported from OSS
Reviewed By: IvanKobzarev
Differential Revision: D23820824
Pulled By: AshkanAliabadi
fbshipit-source-id: 2b71f24fb590ad87a963d00a4e380b4d990a11ef