odc.stac.bench.run_bench

odc.stac.bench.run_bench(xx, client, ntimes=1, col_width=12, restart_sleep=0, results_file=None)[source]

Run same configuration multiple times and resport timing.

Parameters
  • xx (Union[DataArray, Dataset]) – Dask graph to persist to ram

  • client (Client) – Dask client to test on (will be restarted between runs)

  • ntimes (int) – How many rounds to run (default: 1)

  • col_width (int) – First column width in characters

  • restart_sleep (float) – Number of seconds to sleep after client.restart()

  • results_file (Optional[str]) – If set pickle results to this file, it will be overwritten after every run.

Return type

Tuple[BenchmarkContext, List[Tuple[float, float, float]]]

Returns

odc.stac.bench.BenchmarkContext and timing info per run.

Reported timing info is a triple of (t0, t_finished_submit, t_finished_persist)