-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
[ntuple] Refactor RNTupleJoinProcessor::LoadEntry
#17270
[ntuple] Refactor RNTupleJoinProcessor::LoadEntry
#17270
Conversation
Test Results 18 files 18 suites 3d 22h 56m 12s ⏱️ Results for commit 8fa6570. ♻️ This comment has been updated with latest results. |
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.
LGTM. Just minor suggestions.
} | ||
|
||
// For each auxiliary field, load its value according to the entry number we just found of the ntuple it belongs to. | ||
for (auto &[fieldName, fieldContext] : fFieldContexts) { |
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.
for (auto &[fieldName, fieldContext] : fFieldContexts) { | |
for (const auto &[_, fieldContext] : fFieldContexts) { |
@@ -403,32 +403,42 @@ ROOT::Experimental::NTupleSize_t ROOT::Experimental::RNTupleJoinProcessor::Advan | |||
|
|||
void ROOT::Experimental::RNTupleJoinProcessor::LoadEntry() | |||
{ | |||
// Read the values of the primary ntuple. If no index is used (i.e., the join is aligned), also read the values of | |||
// auxiliary ntuples. | |||
for (auto &[fieldName, fieldContext] : fFieldContexts) { |
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.
for (auto &[fieldName, fieldContext] : fFieldContexts) { | |
for (const auto &[_, fieldContext] : fFieldContexts) { |
This refactor (along with more documentation) makes it easier to follow the entry loading logic.
396441f
to
8fa6570
Compare
Refactoring
RNTupleJoinProcessor::LoadEntry
, along with the added documentation should make it easier to follow the entry loading logic (in particular between the primary ntuple and the auxiliary one, and the different code paths for aligned and unaligned joins) and more robust to other (future) code changes.Related to #17132.