Skip to content

Commit bd74dc3

Browse files
f3schBenedikt Volkel
authored andcommitted
Data: Change default compression mode to recommended settings (#13120)
* Data: Change default compression mode to recommended settings As described [here](https://root.cern/doc/master/structROOT_1_1RCompressionSetting.html) for ZSTD recommended is 505 not 501. After measuring it, throughput/compression/peak memory usage stay stay almost unchanged but measured aod size reduces by 5%. Signed-off-by: Felix Schlepper <felix.schlepper@cern.ch> * AOD: Merger, Thinner use recommended compression settings This propagates the changes from the AO2D producer also to the merger and thinner. Signed-off-by: Felix Schlepper <felix.schlepper@cern.ch> * DPL: Set file compression to global settings Signed-off-by: Felix Schlepper <felix.schlepper@cern.ch> --------- Signed-off-by: Felix Schlepper <felix.schlepper@cern.ch>
1 parent c9bb022 commit bd74dc3

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

Framework/AODMerger/src/aodMerger.cxx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ int main(int argc, char* argv[])
9595
std::map<std::string, int> offsets;
9696
std::map<std::string, int> unassignedIndexOffset;
9797

98-
auto outputFile = TFile::Open(outputFileName.c_str(), "RECREATE", "", 501);
98+
auto outputFile = TFile::Open(outputFileName.c_str(), "RECREATE", "", 505);
9999
TDirectory* outputDir = nullptr;
100100
long currentDirSize = 0;
101101

Framework/AODMerger/src/aodThinner.cxx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ int main(int argc, char* argv[])
8989
TStopwatch clock;
9090
clock.Start(kTRUE);
9191

92-
auto outputFile = TFile::Open(outputFileName.c_str(), (bOverwrite) ? "RECREATE" : "CREATE", "", 501);
92+
auto outputFile = TFile::Open(outputFileName.c_str(), (bOverwrite) ? "RECREATE" : "CREATE", "", 505);
9393
if (outputFile == nullptr) {
9494
printf("Error: File %s exists or cannot be created!\n", outputFileName.c_str());
9595
return 1;

Framework/Core/src/DataOutputDirector.cxx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -501,7 +501,7 @@ FileAndFolder DataOutputDirector::getFileFolder(DataOutputDescriptor* dodesc, ui
501501
auto fn = resdirname + "/" + mfilenameBases[ind] + ".root";
502502
delete mfilePtrs[ind];
503503
mParentMaps[ind]->Clear();
504-
mfilePtrs[ind] = TFile::Open(fn.c_str(), mfileMode.c_str(), "", 501);
504+
mfilePtrs[ind] = TFile::Open(fn.c_str(), mfileMode.c_str(), "", 505);
505505
}
506506
fileAndFolder.file = mfilePtrs[ind];
507507

Framework/Utils/include/DPLUtils/RootTreeWriter.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -309,7 +309,7 @@ class RootTreeWriter
309309
/// branch definition provided to the constructor.
310310
void init(const char* filename, const char* treename, const char* treetitle = nullptr)
311311
{
312-
mFile = std::make_unique<TFile>(filename, "RECREATE");
312+
mFile = std::make_unique<TFile>(filename, "RECREATE", "", 505);
313313
mTree = std::make_unique<TTree>(treename, treetitle != nullptr ? treetitle : treename);
314314
mTree->SetDirectory(mFile.get());
315315
mTreeStructure->setup(mBranchSpecs, mTree.get());

0 commit comments

Comments
 (0)