-
Notifications
You must be signed in to change notification settings - Fork 155
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Split TPC clusterization into 2 stages so that we can fit into 16GB for ~100PbPb. * Introduce additional cluster merging step to prepare one file for TPC reco * Add ROOT macro helper for the merge step (to be generalized later) * Adjust some memory/cpu resource estimates (based on ~100PbPb dataframes) * Don't use --rate 1 for TOF reco workflow. Now terminates much faster.
- Loading branch information
Showing
2 changed files
with
34 additions
and
8 deletions.
There are no files selected for viewing
This file contains 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 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 |
---|---|---|
@@ -0,0 +1,12 @@ | ||
// A helper to "vertically" merge the set of (distinct) branches of 2 trees | ||
// into a single common (non-friended) tree in a new file. | ||
// | ||
// This is using RDataFrame mechanics as suggested by the ROOT team. | ||
// TODO: generalize to abirtrary list of files. | ||
void merge_TTrees(std::string f1, std::string f2, std::string treename, std::string outname) { | ||
TFile file(f1.c_str(), "OPEN"); | ||
auto t1=(TTree*)file.Get(treename.c_str()); | ||
t1->AddFriend(treename.c_str(), f2.c_str()); | ||
ROOT::RDataFrame df(*t1); | ||
df.Snapshot(treename.c_str(), outname.c_str(), ".*"); | ||
} |