Created by: zycalice
Patch Description related to issue https://github.com/facebookresearch/metaseq/issues/516
- fixed distributed_main_mock by patching save_checkpoint in trainer
- replaced partial with partial method for patching on class method (the log_to_events mock now print out message instead of info due to the presence of self
- note that now loss matching is changed to matching to the 1st digit
Testing steps Ran python metaseq/gpu_tests/test_checkpoint_saving.py output: . Ran 1 test in 52.583s
OK