MCPcopy Create free account
hub / github.com/OpenRaiser/PaperFlow / write_csv

Function write_csv

experiments/human_eval/aggregate_main_human_eval.py:22–28  ·  view source on GitHub ↗
(path: Path, rows: List[Dict[str, object]])

Source from the content-addressed store, hash-verified

20
21
22def write_csv(path: Path, rows: List[Dict[str, object]]) -> None:
23 path.parent.mkdir(parents=True, exist_ok=True)
24 fields = list(rows[0].keys()) if rows else []
25 with path.open("w", encoding="utf-8-sig", newline="") as handle:
26 writer = csv.DictWriter(handle, fieldnames=fields)
27 writer.writeheader()
28 writer.writerows(rows)
29
30
31def parse_score(value: str, field: str, sample_id: str) -> float:

Callers 1

mainFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected