aac_metrics.eval module¶
- load_csv_file(
- fpath: str | Path,
- cands_columns: str | Iterable[str] = ('caption_predicted',),
- mrefs_columns: str | Iterable[str] = ('caption_1', 'caption_2', 'caption_3', 'caption_4', 'caption_5'),
- load_mult_cands: bool = False,
- strict: bool = True,
Load candidates and mult_references from a CSV file.
- Parameters:
fpath – The filepath to the CSV file.
cands_columns – The columns of the candidates. defaults to (“captions_predicted”,).
mrefs_columns – The columns of the multiple references. defaults to (“caption_1”, “caption_2”, “caption_3”, “caption_4”, “caption_5”).
load_mult_cands – If True, load multiple candidates from file. defaults to False.
- Returns:
A tuple of (candidates, mult_references) loaded from file.