// This macro is used to profile the HLT::TRD code // usage: aliroot aliHLTTRDrun.cxx("/data/sim/") reconstruct raw ddls, /data/run/ must contain subfolders rawX #if !defined (__CINT__) || defined (__MAKECINT__) #include #include #include #include #include "TString.h" #include "TMath.h" #include "AliHLTSystem.h" #include "AliLog.h" #include "AliHLTDataTypes.h" #include "AliHLTConfiguration.h" #include #include #endif #include "initGRP.h" #include "readCDBentry.h" void aliHLTTRDrun(const TString inDir = gSystem->pwd()); int main(int argc, char** argv) { if(argc==2) aliHLTTRDrun(argv[1]); else aliHLTTRDrun(); } void aliHLTTRDrun(const TString inDir) { // Is the TRD full? Bool_t fullTRD=kFALSE; // If not use these SMs: Int_t TRDmodules[18] = {0,1,7,8,9,10,17,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1}; // Use custom arguments for components? i.e.: not reading OCDB arguments Bool_t customArgs=kFALSE; // Disable HLT flag? Bool_t disableHLTflag=kFALSE; ///////////////////////////////////// Int_t usedModules=0; if(fullTRD){ usedModules = 18; for(int i=0; i<18; i++) TRDmodules[i]=i; }else{ #if !defined (__CINT__) || defined (__MAKECINT__) std::sort((UInt_t*)TRDmodules, ((UInt_t*)TRDmodules) + 18); #endif for(int i=0; i<18; i++) if(TRDmodules[i]>-1)usedModules++; } AliHLTSystem gHLT; AliLog::SetGlobalDebugLevel(1); //AliLog::SetClassDebugLevel("AliTRDrawStream", 11); /* enum ETpye {kFatal=0, kError, kWarning, kInfo, kDebug, kMaxType}; */ gHLT.SetGlobalLoggingLevel((AliHLTComponentLogSeverity)0x7f); /* enum AliHLTComponentLogSeverity { kHLTLogNone = 0, kHLTLogBenchmark = 0x1, kHLTLogDebug = 0x2, kHLTLogInfo = 0x4, kHLTLogWarning = 0x8, kHLTLogError = 0x10, kHLTLogFatal = 0x20, few important messages not to be filtered out. redirected to kHLTLogInfo in AliRoot kHLTLogImportant = 0x40, special value to enable all messages kHLTLogAll = 0x7f, the default logging filter kHLTLogDefault = 0x79 useful = 0x45 */ gHLT.LoadComponentLibraries("libAliHLTUtil.so libAliHLTTRD.so libAliHLTMUON.so libAliHLTGlobal.so libAliHLTTrigger.so"); InitGRP("local://$ALICE_ROOT/OCDB",Form("local://%s",inDir.Data())); //TString sGeomPath = " -geometry "+inDir+"/geometry.root"; TString inFolder = inDir+"/raw", inFile = "/TRD_", inExt = ".ddl"; TString sinput = " -datatype 'DDL_RAW ' 'TRD '"; TString temp1, temp2; Int_t spec, startEvent=0, nEvents=240, ddl; //KR: start=10, nEvents=30; for(Int_t Event=startEvent; Event<(nEvents+startEvent); Event++){ temp1=inFolder; temp1+=Event; temp1+=inFile; for(int module=0; module