From cdb216d3b5b0c5ed174153a3a665427022572227 Mon Sep 17 00:00:00 2001 From: cvetan Date: Tue, 30 Jun 2009 16:05:06 +0000 Subject: [PATCH] New OCDB entry containing the list of cosmic triggers defined by the trigger coordinator. Used in the reconstruction in order to set properly the cosmic event specie. A macro and a text file in order to populate the existing OCDB. --- GRP/CosmicTriggers.txt | 15 +++++ GRP/MakeCosmicTriggersEntry.C | 62 ++++++++++++++++++ .../CosmicTriggers/Run0_999999999_v0_s0.root | Bin 0 -> 2509 bytes 3 files changed, 77 insertions(+) create mode 100644 GRP/CosmicTriggers.txt create mode 100644 GRP/MakeCosmicTriggersEntry.C create mode 100644 OCDB/GRP/Calib/CosmicTriggers/Run0_999999999_v0_s0.root diff --git a/GRP/CosmicTriggers.txt b/GRP/CosmicTriggers.txt new file mode 100644 index 00000000000..b427b5f91a6 --- /dev/null +++ b/GRP/CosmicTriggers.txt @@ -0,0 +1,15 @@ +# ttriggers used in 2008 +# even if they didn't follow the naming convention +# one still wants to be able to reconstruction these +# data correctly +D0SCO +C0SCO +D0ASL +C0ASL +DEMPTY +CEMPTY +TRDBYTOF +TOFTRD + +# Here is trigger classes list following the trigger +# naming conventions diff --git a/GRP/MakeCosmicTriggersEntry.C b/GRP/MakeCosmicTriggersEntry.C new file mode 100644 index 00000000000..d0981b5a077 --- /dev/null +++ b/GRP/MakeCosmicTriggersEntry.C @@ -0,0 +1,62 @@ +Bool_t MakeCosmicTriggersEntry(const char *fileName) +{ + const char* macroname = "MakeCosmicTriggersEntry.C"; + + if (gSystem->AccessPathName(fileName)) { + Error(macroname,Form("file (%s) not found", fileName)); + return kFALSE; + } + + ifstream *file = new ifstream(fileName); + if (!*file) { + Error(macroname,Form("Error opening file (%s) !",fileName)); + file->close(); + delete file; + return kFALSE; + } + + THashTable *table = new THashTable(); + table->SetName("List of defined cosmic triggers"); + + TString strLine; + while (strLine.ReadLine(*file)) { + + if (strLine.BeginsWith("#")) continue; + + strLine.ReplaceAll(" ",""); + strLine.ReplaceAll("\t",""); + if (strLine.IsNull()) continue; + + TObjString *obj = new TObjString(strLine.Data()); + table->Add(obj); + } + + file->close(); + delete file; + + + // save in CDB storage + TString Storage = gSystem->Getenv("STORAGE"); + if(!Storage.BeginsWith("local://") && !Storage.BeginsWith("alien://")) { + Error(macroname,"STORAGE variable set to %s is not valid. Exiting\n",Storage.Data()); + return; + } + Info(macroname,"Saving alignment objects in CDB storage %s",Storage.Data()); + AliCDBManager* cdb = AliCDBManager::Instance(); + AliCDBStorage* storage = cdb->GetStorage(Storage.Data()); + if(!storage){ + Error(macroname,"Unable to open storage %s\n",Storage.Data()); + return; + } + AliCDBMetaData* md = new AliCDBMetaData(); + md->SetResponsible("Federico Antinori"); + md->SetComment("List of the defined cosmic triggers. It is used in order to steer the reconstruction, namely in the selection of the proper event specie. It is maintained and updated by the trigger coordinator."); + md->SetAliRootVersion(gSystem->Getenv("ARVERSION")); + AliCDBId id("GRP/Calib/CosmicTriggers",0,AliCDBRunRange::Infinity()); + storage->Put(table,id,md); + + table->Delete(); + delete table; + + return kTRUE; +} diff --git a/OCDB/GRP/Calib/CosmicTriggers/Run0_999999999_v0_s0.root b/OCDB/GRP/Calib/CosmicTriggers/Run0_999999999_v0_s0.root new file mode 100644 index 0000000000000000000000000000000000000000..6942cf349488a52e6ee6afe6248a54a0434e25b8 GIT binary patch literal 2509 zcmcImc{r5q8h=M4+kB)`MwBI6C^MN)DTEjr$2y5ji)Ch-nHW=cjy0;08Ebs@Y$eN( zXz(#3MP-?aQkZOo$T-;|)HpBaI@dY>opb)^xvt;!+}HbD&;9=H`+n}lk46gsfNncB%+@`0vqUybU*g59as|gV?eK z0K^Oan}Z--n|=^k+42Kw(+?1z&HGZIv7nh~-vGbR|C9lot#}dySP=n2AQ4!e&9=ik z?9b^GseBhJqMOfYvhz7UO*6{QxIxZR=1?BHhx$;xtT!iVbl~~?5aD0^#!Hy34cK8tfcXZdk%d5`9~wQO}Jihiy$x%cx77fjD@m>{d5^7jzK+ zcg9}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