-
Notifications
You must be signed in to change notification settings - Fork 22
test: add benchmark for awkward #327
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #327 +/- ##
=======================================
Coverage 97.36% 97.36%
=======================================
Files 2 2
Lines 493 493
Branches 61 61
=======================================
Hits 480 480
Misses 8 8
Partials 5 5
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds a benchmarking infrastructure to measure and compare the performance of awkward array conversion operations across pull requests.
- Adds
pytest-benchmarkas a test dependency - Creates benchmark tests for
LHEFile.fromfileandto_awkwardconversion using multiple test files - Implements a GitHub Actions workflow to automatically run benchmarks on PRs and post comparison results
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| pyproject.toml | Adds pytest-benchmark dependency to test extras (reordered alphabetically) |
| benchmarks/test_awkward_bench.py | New benchmark test measuring performance of file loading and awkward array conversion across all test LHE files |
| .github/workflows/bench.yml | New workflow that runs benchmarks on both main and PR branches, compares results, and posts findings to the PR |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
eduardo-rodrigues
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks very good! Looking forward to seeing this in action for nice and useful comparisons.
|
One question I meant to ask for my own knowledge - does the benchmark need to go to a benchmarks directory rather than tests? Just curious. Advance thanks. |
|
Yes. Most distributions don't want to run benchmarks, but only tests. Often that means patching out the benchmark code if it is in |
See-also: #300