torchoutil.serialization.load_fn module

load(
fpath: TextIO | BinaryIO,
*args,
saving_backend: Literal['csv', 'json', 'h5py', 'numpy', 'pickle', 'safetensors', 'torch', 'torchaudio', 'yaml'] = 'torch',
**kwargs,
) Any[source]
load(
fpath: str | Path | PathLike,
*args,
saving_backend: Literal['csv', 'json', 'h5py', 'numpy', 'pickle', 'safetensors', 'torch', 'torchaudio', 'yaml'] | None = 'torch',
**kwargs,
) Any

Load from file using the correct backend.