Skip to content
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

Fix significant performance regression #81

Merged
merged 6 commits into from
Oct 17, 2024
Merged

Conversation

graeme-a-stewart
Copy link
Member

When generalising ClusterSequence to also handle the EEJet type, the jets member was changed to be the abstract type FourMomentum. This is type unstable and has a very negative impact on performance!

Fix ClusterSequence to be parameterised, where the type T is taken from the type of the jets passed in to the constructor.

This improves performance for $pp$ and $e^+e^-$ significantly.

Further fixes are to factorise out some of the StructArray handling functions in EEAlgorithm.jl to make the code logic easier to follow.

Use EEjet for e+e-, PseudoJet for pp
Keep the main loop code cleaner by factorising
the compact array updates into functions
Resolve the actual jet indexes more explicitly
It is vital that ClusterSequence is a fully concrete type.
Change the constructor to be parametrised on the type of the jets
themselves.
Copy link

codecov bot commented Oct 17, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 70.18%. Comparing base (28d7f0d) to head (770b1f3).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #81      +/-   ##
==========================================
+ Coverage   69.98%   70.18%   +0.20%     
==========================================
  Files          17       17              
  Lines        1156     1164       +8     
==========================================
+ Hits          809      817       +8     
  Misses        347      347              

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

@graeme-a-stewart graeme-a-stewart merged commit f502397 into main Oct 17, 2024
9 checks passed
@graeme-a-stewart
Copy link
Member Author

Thanks for checking @Moelf 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants