Spaces:
Running
Running
Download scripts/build_live_aggregate_results.py from ThinkcatLab/LiveHouse-TS: direct link, hf CLI and curl.
- Browser
- Download file 826 Bytes
-
https://huggingface.co/spaces/ThinkcatLab/LiveHouse-TS/resolve/main/scripts/build_live_aggregate_results.py
- Command line
-
hf download hf://spaces/ThinkcatLab/LiveHouse-TS/scripts/build_live_aggregate_results.py
-
curl -L -o build_live_aggregate_results.py https://huggingface.co/spaces/ThinkcatLab/LiveHouse-TS/resolve/main/scripts/build_live_aggregate_results.py
826 Bytes
| #!/usr/bin/env python3 | |
| """Build cumulative live metrics and rank tables from saved releases.""" | |
| from __future__ import annotations | |
| import argparse | |
| from pathlib import Path | |
| import sys | |
| REPO_ROOT = Path(__file__).resolve().parents[1] | |
| SRC_DIR = REPO_ROOT / "src" | |
| if str(SRC_DIR) not in sys.path: | |
| sys.path.insert(0, str(SRC_DIR)) | |
| from tsfm_bench.eval.live_aggregation import write_live_aggregates | |
| def parse_args() -> argparse.Namespace: | |
| parser = argparse.ArgumentParser(description=__doc__) | |
| parser.add_argument("--results", type=Path, default=Path("space/results")) | |
| return parser.parse_args() | |
| def main() -> int: | |
| args = parse_args() | |
| for name, path in write_live_aggregates(args.results).items(): | |
| print(f"{name}: {path}") | |
| return 0 | |
| if __name__ == "__main__": | |
| raise SystemExit(main()) | |