Skip to content

Comments

Greatly simplify benchmarks#3420

Open
andrewfullard wants to merge 3 commits intotardis-sn:masterfrom
andrewfullard:benchmark-reduction
Open

Greatly simplify benchmarks#3420
andrewfullard wants to merge 3 commits intotardis-sn:masterfrom
andrewfullard:benchmark-reduction

Conversation

@andrewfullard
Copy link
Contributor

@andrewfullard andrewfullard commented Feb 9, 2026

📝 Description

Type: 🪲 bugfix | 🎢 infrastructure

Benchmarks have consistently been failing and causing problems. The only API we are consistently supporting right now is the classic run_tardis and the workflows. For now, the benchmarks are simplified to just run_tardis with and without packet tracking.

Running them locally has been prevented by the same bug that is affecting docstr-cov, #3419

🚦 Testing

How did you test these changes?

  • Testing pipeline
  • Other method (describe)
  • My changes can't be tested (explain why)

☑️ Checklist

  • I requested two reviewers for this pull request
  • I updated the documentation according to my changes
  • I built the documentation by applying the build_docs label

Note: If you are not allowed to perform any of these actions, ping (@) a contributor.

Copilot AI review requested due to automatic review settings February 9, 2026 21:15
@github-project-automation github-project-automation bot moved this to Todo in DevOps Feb 9, 2026
@tardis-bot
Copy link
Contributor

tardis-bot commented Feb 9, 2026

*beep* *bop*
Hi human,
I ran ruff on the latest commit (fb523b4).
Here are the outputs produced.
Results can also be downloaded as artifacts here.
Summarised output:

Details
643	      	[ ] syntax-error
12	E701  	[ ] multiple-statements-on-one-line-colon
9	E902  	[ ] io-error
7	W293  	[ ] blank-line-with-whitespace
5	E702  	[ ] multiple-statements-on-one-line-semicolon
1	B019  	[ ] cached-instance-method
1	RET506	[*] superfluous-else-raise
Found 678 errors.
[*] 1 fixable with the `--fix` option.

Complete output(might be large):

Details
benchmarks/benchmark_base.py:58:9: RET506 [*] Unnecessary `else` after `raise` statement
benchmarks/opacities_opacity.py:1:1: E902 No such file or directory (os error 2)
benchmarks/opacities_opacity_state.py:21:5: B019 Use of `functools.lru_cache` or `functools.cache` on methods can lead to memory leaks
benchmarks/transport_geometry_calculate_distances.py:1:1: E902 No such file or directory (os error 2)
benchmarks/transport_montecarlo_estimators_radfield_estimator_calcs.py:1:1: E902 No such file or directory (os error 2)
benchmarks/transport_montecarlo_interaction.py:1:1: E902 No such file or directory (os error 2)
benchmarks/transport_montecarlo_main_loop.py:1:1: E902 No such file or directory (os error 2)
benchmarks/transport_montecarlo_packet_trackers.py:1:1: E902 No such file or directory (os error 2)
benchmarks/transport_montecarlo_single_packet_loop.py:1:1: E902 No such file or directory (os error 2)
benchmarks/transport_montecarlo_vpacket.py:1:1: E902 No such file or directory (os error 2)
Found 10 errors.
[*] 1 fixable with the `--fix` option.

@andrewfullard andrewfullard linked an issue Feb 9, 2026 that may be closed by this pull request
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

Simplifies the ASV benchmark suite by removing unstable/unsupported benchmarks, keeping focus on the currently supported run_tardis workflow (with/without packet tracking).

Changes:

  • Removed multiple Monte Carlo / opacities / spectrum / geometry benchmark modules that have been failing.
  • Deleted an unused benchmark YAML config under benchmarks/data/.
  • Slimmed down BenchmarkBase to remove heavy simulation helpers and keep only config-loading utilities (including rpacket tracking config).

Reviewed changes

Copilot reviewed 12 out of 12 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
benchmarks/transport_montecarlo_vpacket.py Removed vpacket tracing benchmarks.
benchmarks/transport_montecarlo_single_packet_loop.py Removed single-packet-loop benchmark.
benchmarks/transport_montecarlo_packet_trackers.py Removed packet tracker benchmarks.
benchmarks/transport_montecarlo_main_loop.py Removed Monte Carlo main loop benchmark.
benchmarks/transport_montecarlo_interaction.py Removed interaction event benchmarks.
benchmarks/transport_montecarlo_estimators_radfield_estimator_calcs.py Removed radfield estimator calcs benchmark.
benchmarks/transport_geometry_calculate_distances.py Removed geometry distance calculation benchmarks.
benchmarks/spectrum_formal_integral.py Removed formal integral benchmarks.
benchmarks/opacities_opacity_state.py Removed opacity state initialization benchmark.
benchmarks/opacities_opacity.py Removed opacity calculation benchmarks.
benchmarks/data/tardis_configv1_benchmark.yml Removed benchmark-specific config YAML.
benchmarks/benchmark_base.py Removed simulation/packet helper machinery; kept config helpers and added a cached tracking-enabled config property.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@tardis-bot
Copy link
Contributor

*beep* *bop*

Hi, human.

The docs workflow has succeeded ✔️

Click here to see your results.

@codecov
Copy link

codecov bot commented Feb 9, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 70.54%. Comparing base (9200ec0) to head (fb523b4).
⚠️ Report is 2 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #3420      +/-   ##
==========================================
- Coverage   70.73%   70.54%   -0.20%     
==========================================
  Files         213      213              
  Lines       17259    17259              
==========================================
- Hits        12209    12175      -34     
- Misses       5050     5084      +34     

☔ 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.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will need to be modified to point to the correct file (once Atharva's PR is merged)

Copy link
Contributor

@connor-mcclellan connor-mcclellan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Leave opacities_opacity_state.py and spectrum_formal_integral.py as-is for now

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

Projects

Status: Todo

Development

Successfully merging this pull request may close these issues.

Investigate benchmarking in PRs

3 participants