torchoutil.pyoutil.csv module

dump_csv(
data: Iterable[Mapping[str, Any]] | Mapping[str, Iterable[Any]] | Iterable,
fpath: str | Path | None = None,
*,
overwrite: bool = True,
make_parents: bool = True,
header: bool | Literal['auto'] = 'auto',
align_content: bool = False,
**csv_writer_kwds,
) str[source]

Dump content to CSV format.

load_csv(
fpath: str | Path,
/,
*,
orient: Literal['dict'],
header: bool = True,
comment_start: str | None = None,
strip_content: bool = False,
delimiter: str | None = None,
**csv_reader_kwds,
) Dict[str, List[Any]][source]
load_csv(
fpath: str | Path,
/,
*,
orient: Literal['list'] = 'list',
header: bool = True,
comment_start: str | None = None,
strip_content: bool = False,
delimiter: str | None = None,
**csv_reader_kwds,
) List[Dict[str, Any]]

Load content from csv filepath.