outlines icon indicating copy to clipboard operation
outlines copied to clipboard

Check benchmarks in CI

Open brandonwillard opened this issue 1 year ago • 2 comments

We need an Actions/CI step that automatically compares benchmark results against current main and notifies us when there is a significant regression before a PR is merged.

We've used github-actions-benchmark in the past, but it seemed overly complicated, was more about serving a website with benchmark results (which is complexity we don't need right now), and wasn't actually able to perform the desired checks on each PR—at least not without some undesirable trade-offs.

If anyone knows of an existing workflow we can adapt, or alternative Action, please tell us!

N.B. https://labs.quansight.org/blog/2021/08/github-actions-benchmarks

brandonwillard avatar May 09 '24 21:05 brandonwillard

Good reading materials @brandonwillard

Here are some examples I found of ASV in use:

  • dashboard of historical performance: https://asv-runner.github.io/asv-collection/pandas/
  • PR comment in a repo with asv configured for PR actions: https://github.com/lincc-frameworks/tape/pull/440#issuecomment-2083401324
    • Corresponding asv-pr.yml: https://github.com/lincc-frameworks/tape/blob/8f33ee8a2a7ab77cbc337ebc0c121b9fdb17dba1/.github/workflows/asv-pr.yml

ASV seems like a great solution, it can be run in GitHub Actions while minimizing comparison error, is widely used by major python libraries, and appears to have relatively easy setup.

Happy to get started on this if you agree!

lapp0 avatar May 17 '24 04:05 lapp0

Note that we should track both execution speed and memory usage.

rlouf avatar May 17 '24 09:05 rlouf