Skip to content

Add jet parents retrieval #121

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

Merged
merged 7 commits into from
Feb 7, 2025
Merged

Add jet parents retrieval #121

merged 7 commits into from
Feb 7, 2025

Conversation

graeme-a-stewart
Copy link
Member

@graeme-a-stewart graeme-a-stewart commented Feb 5, 2025

Add parent_jets() accessor, that returns a jet's parents or nothing. Export this method.

"Promote" has_parents to ClusterSequence source file and ensure it works with both jet types (or any FourMomentum). Remove has_parents as unneeded

Add tests for parent jet retrieval, in case where a jet has parents and also when it doesn't.

Closes #100

Add parent_jets() accessor, that returns a jet's parents or nothing.
Export this method.

"Promote" has_parents() to ClusterSequence source file and
ensure it works with both jet types.

Add tests for parent jet retrieval, in case where a jet has parents and
also when it doesn't.
@graeme-a-stewart graeme-a-stewart added the enhancement New feature or request label Feb 5, 2025
@graeme-a-stewart graeme-a-stewart added this to the 0.4.4 Release milestone Feb 5, 2025
Copy link

codecov bot commented Feb 5, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 73.73%. Comparing base (164c6d2) to head (d782126).
Report is 6 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #121      +/-   ##
==========================================
+ Coverage   73.49%   73.73%   +0.23%     
==========================================
  Files          18       18              
  Lines        1249     1245       -4     
==========================================
  Hits          918      918              
+ Misses        331      327       -4     

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

Normally a jet has either two parents or none (initial particle).
However, for a beam merge step there is only one parent, so protect
mass_drop and soft_drop by checking both parents are valid.
Copy link
Member

@m-fila m-fila left a comment

Choose a reason for hiding this comment

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

LGTM

@graeme-a-stewart
Copy link
Member Author

Thanks for the useful review @m-fila !

@graeme-a-stewart graeme-a-stewart merged commit 59b2ff3 into main Feb 7, 2025
9 checks passed
@graeme-a-stewart graeme-a-stewart deleted the jet-parents branch February 7, 2025 16:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Public function to retrieve jet's parents
2 participants