-
Notifications
You must be signed in to change notification settings - Fork 444
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
Supporting also vector<pod> in the RootTreeWriter #2645
Supporting also vector<pod> in the RootTreeWriter #2645
Conversation
@matthiasrichter thanks! If you think the final implementation (including # #2525) will take more than a few days, let me know please, then I will use the trick with |
Require the buffer to be of serialization Method 'None' unless a char type is used which will allow to access the raw buffer in all cases.
Implementing a specialization for vector<messageable> retrieving the input opject as span and copying the data to the storage variable which is then stored in the branch. Implementation for Vectors of non messageable types with ROOT dictionary is unchanged. TODO: Need to investigate if the binary branch specialization can be extended to any POD pointer and realized without copy. Add read-back check for binary branch test.
2b17e50
to
872092e
Compare
With the latest update, the PR implements now the support for vectors of messageable types with and without ROOT dictionary. The latter need to be non serialized at the input. We can extend later to support both non and ROOT serialized messages as input for these types. Storage in a ROOT tree always involves a copy. While ROOT serialized objects are deserialized and the object pointer is used for writing data to branch, the data of the non serialized messages needs to be copied to a storage object for writing. Maybe this can be avoided, but this is a task for later investigation. |
Looks like this PR screws up the POD subbranches, the updated o2-test-dplutils-RootTreeWriter produces
|
@shahor02, yes, unfortunately I have been using the wrong pointer for the branch data. ROOT IO seems to be very flexible because it was handling this. Although not silently, I should have noticed the error message but it was hidden in the lengthy log. Please try with the fix in PR #2687. For the TPC reco workflow I have verified it. |
I can confirm that this is fixed. Thanks! |
… error, apply clang-format
* [WIP][EMCAL-505] Porting EMCAL clusterizer to O2 framework * [WIP][EMCAL-505] Requested improvements for pull request #2525 * [WIP][EMCAL-505] Implementation for clusterizer in workflow * Fixing typo in cmake file * Removed some orphans that accidentally CMakeLists * Added fixes in run_clus_emcal macro + implemented BranchDefinition in workflow that currently breaks * Applying workaround for related to PR #2645 * Removing workaround related to PR #2645, fix code checker error, apply clang-format
This is a first sketch for the functionality requested by @shahor02
A couple of things need to be polished and the unit test has to be completed.
It also depends on the correct implementation of `InputRecord::get, WIP in PR #2617
EDIT: