fix variable shadowing issus (#19567)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/19567
fix variable shadowing
Reviewed By: bddppq, wx1988
Differential Revision: D15032114
fbshipit-source-id: 895ea21f22b87db8c7c8684f54fa186d22f24d10