Updates for train running (L. Cunqueiro)
[u/mrichter/AliRoot.git] / PWGJE / macros / AddTaskJetCore.C
CommitLineData
75bf77e3 1
2
a9e585a7 3AliAnalysisTaskJetCore* AddTaskJetCore(const char* bRec1,const char* bRec2, UInt_t filterMask = 272 , Float_t ptTrackMin = 0.15, Int_t kTriggerMask=0, Int_t eventClassMin = 0, Int_t eventClassMax = 4){
75bf77e3 4
ea693273 5 Printf("adding task jet response\n");
75bf77e3 6
7 AliAnalysisManager *mgr = AliAnalysisManager::GetAnalysisManager();
8 if(!mgr){
9 ::Error("AddTaskJetCore", "No analysis manager to connect to.");
10 return NULL;
11 }
12 if(!mgr->GetInputEventHandler()){
13 ::Error("AddTaskJetCore", "This task requires an input event handler.");
14 return NULL;
15 }
16
17
ea693273 18
75bf77e3 19
20 TString typeRec(bRec1);
21 TString typeGen(bRec2);
22
a9e585a7 23 AliAnalysisTaskJetCore *task = new AliAnalysisTaskJetCore(Form("JetCore_%s_%s_%d",bRec1,bRec2,kTriggerMask));
75bf77e3 24
25
26
27 task->SetBranchNames(bRec1,bRec2);
8b47ec90 28 task->SetOfflineTrgMask(kTriggerMask);
75bf77e3 29 task->SetEvtClassMin(eventClassMin);
30 task->SetEvtClassMax(eventClassMax);
31 task->SetCentMin(0.);
32 task->SetCentMax(100.);
8b47ec90 33 task->SetFilterMask(filterMask);
75bf77e3 34
35
36 task->SetJetPtMin(0.);
d3cc2b50 37 //task->SetAngStructCloseTracks(1);
75bf77e3 38
39
75bf77e3 40
41 mgr->AddTask(task);
42
43
a9e585a7 44 AliAnalysisDataContainer *coutputJetCore = mgr->CreateContainer(Form("pwgjejetcore_%s_%s_%d",bRec1,bRec2,kTriggerMask), TList::Class(),AliAnalysisManager::kOutputContainer,Form("%s:PWGJE_jetcore_%s_%s_%d",AliAnalysisManager::GetCommonFileName(),bRec1,bRec2,kTriggerMask));
75bf77e3 45
46
47
48
49
50 mgr->ConnectInput (task, 0, mgr->GetCommonInputContainer());
51 mgr->ConnectOutput(task, 0, mgr->GetCommonOutputContainer());
52 mgr->ConnectOutput(task, 1, coutputJetCore);
53
54 return task;
55}