Skip to content

Conversation

@APN-Pucky
Copy link
Member

See-also: #300

@codecov
Copy link

codecov bot commented Oct 30, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.36%. Comparing base (36c3cce) to head (18c3b33).
⚠️ Report is 1 commits behind head on main.

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           
Flag Coverage Δ
unittests-3.10 97.36% <ø> (ø)
unittests-3.11 97.36% <ø> (ø)
unittests-3.12 97.36% <ø> (ø)
unittests-3.13 97.36% <ø> (ø)
unittests-3.9 97.07% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@APN-Pucky APN-Pucky requested a review from Copilot October 30, 2025 09:23
Copy link
Contributor

Copilot AI left a 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-benchmark as a test dependency
  • Creates benchmark tests for LHEFile.fromfile and to_awkward conversion 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.

@APN-Pucky APN-Pucky changed the title ci: add benchmark ci for awkward ci: add benchmark for awkward Oct 30, 2025
@APN-Pucky APN-Pucky changed the title ci: add benchmark for awkward test: add benchmark for awkward Oct 30, 2025
@APN-Pucky APN-Pucky marked this pull request as ready for review October 30, 2025 11:32
Copy link
Member

@eduardo-rodrigues eduardo-rodrigues left a 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.

@APN-Pucky APN-Pucky merged commit d0503a0 into main Oct 30, 2025
16 checks passed
@APN-Pucky APN-Pucky deleted the pytest_benchmark branch October 30, 2025 15:08
@eduardo-rodrigues
Copy link
Member

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.

@APN-Pucky
Copy link
Member Author

APN-Pucky commented Oct 30, 2025

Yes. Most distributions don't want to run benchmarks, but only tests. Often that means patching out the benchmark code if it is in tests/ as well (e.g. https://github.com/search?q=repo%3Agentoo%2Fgentoo+pytest-benchmark&type=code).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants