Add alternative prettyprinting method to `Graph` (#50878)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/50878
Test Plan: Imported from OSS
Reviewed By: SplitInfinity, eellison
Differential Revision: D26009183
Pulled By: ansley
fbshipit-source-id: 300913ea634d9a0e5b00deb831154ef126ad4180