save(obj: Any, path: Union[str, pathlib.Path], global_dst_rank: Optional[int] = None) → None¶
Save an object to a directory.
obj – The object to be saved
path (str) – The directory in which the object is saved
global_dst_rank (int, optional) – The destination rank for saving global tensors. When specified, whole tensors will be saved by the process whose rank == global_src_rank, while other processes will not do any disk I/O.