-
Notifications
You must be signed in to change notification settings - Fork 1.5k
[ntuple] Support multiple column representations in the merger #22017
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
Open
silverweed
wants to merge
12
commits into
root-project:master
Choose a base branch
from
silverweed:ntuple_merge_colrep2
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
4e634de
[ntuple] Small improvement in RNTupleMerger
silverweed 1ee6153
[ntuple] Serializer: sort columns by ID before serializing them
silverweed 1e5a4e9
[ntuple] Add RClusterDescriptor::TryGetColumnRange
silverweed 3508b34
[ntuple] Add functionality to RPagePersistentSink for column extension
silverweed 18e3a51
[ntuple] Add multiple column representation support in the Merger
silverweed c737819
[ntuple] Merger: extract column repr matching into a separate function
silverweed 7423f97
[ntuple] Merger: accept different sizes for fields' logical column ids
silverweed 9f50b52
[ntuple] Add new merger test
silverweed 57cac89
[ntuple] support merging columns with metadata (with different types)
silverweed a5df89f
[ntuple] Support merging columns with same type and different metadata
silverweed af1744c
[ntuple][NFC] update Merging.md
silverweed 78e4e54
[ntuple] ensure valid descriptor in AddAliasColumn/AddColumnRepresent…
silverweed File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -543,6 +543,15 @@ public: | |
| [[nodiscard]] std::unique_ptr<RNTupleModel> | ||
| InitFromDescriptor(const ROOT::RNTupleDescriptor &descriptor, bool copyClusters); | ||
|
|
||
| /// Adds a new column representation to the given field. | ||
| /// \return The physical id of the first newly added column. | ||
| ROOT::DescriptorId_t AddColumnRepresentation(const ROOT::RFieldDescriptor &field, | ||
| std::span<const ROOT::Internal::RColumnFormat> newRepresentation); | ||
|
|
||
| /// Adds a new alias column pointing to an existing column with the given physical id to the given field. | ||
| void AddAliasColumn(const ROOT::RNTupleDescriptor &desc, const ROOT::RFieldDescriptor &field, | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Pass field id instead of descriptor
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. See comment above about this being an internal function (maybe an assert is good enough?)
silverweed marked this conversation as resolved.
|
||
| ROOT::DescriptorId_t physicalId); | ||
|
|
||
| void CommitSuppressedColumn(ColumnHandle_t columnHandle) final; | ||
| void CommitPage(ColumnHandle_t columnHandle, const ROOT::Internal::RPage &page) final; | ||
| void CommitSealedPage(ROOT::DescriptorId_t physicalColumnId, const RPageStorage::RSealedPage &sealedPage) final; | ||
|
|
||
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
I think this is only used once and can be replaed by
ContainsColumn()followed byGetColumnRange()(at the cost of a small performance penalty). I think it's not worth it at this point adding the public method.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.
On the other hand, is it really a problem to have the method? I imagine this could be useful for users in general and since we're hiding the underlying maps we should not force a suboptimal access pattern via the API imho.