model_dump: Use DumpUnpickler.load instead of .dump (#57659)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/57659
Faster since we don't do an automatic pprint, and shorter, simpler code.
Test Plan: Dumped some models.
Reviewed By: malfet
Differential Revision: D28531398
Pulled By: dreiss
fbshipit-source-id: 47f1f646d4576af9f7e680933e0512f616dab5c0