[FSDP2][DCP][DSD] Add FSDP2 model state dict unit test with distributed state dict (#120680)
This adds some initial unit tests for FSDP2 model state dict only.
This PR adds two tests:
1. Add a unit test for parity check for FSDP `model.state_dict()` with distributed_state_dict's `get_model_state_dict`.
2. Add a unit test to make sure`StateDictOptions(full_state_dict=True, cpu_offload=True)` in distributed_state_dict work for FSDP2 model state_dict.
Optimizer state dict will be in follow up PRs.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/120680
Approved by: https://github.com/awgu