]>
Commit | Line | Data |
---|---|---|
aa191e39 | 1 | void JetAnalysisManagerCAF() |
2 | { | |
3 | // | |
4 | if (gApplication) gApplication->InitializeGraphics(); | |
aa191e39 | 5 | // |
6 | // Connect to proof | |
312525d3 | 7 | |
e6d0d7ed | 8 | // TProof::Reset("proof://morsch@lxb6046.cern.ch"); |
9 | TProof::Open("proof://morsch@lxb6046.cern.ch"); | |
10 | // gProof->SetParallel(1); | |
11 | // gProof->ClearPackage("STEERBase"); | |
312525d3 | 12 | // gProof->ClearPackage("ESD"); |
13 | // gProof->ClearPackage("AOD"); | |
e6d0d7ed | 14 | // gProof->ClearPackage("JETAN"); |
15 | // gProof->ClearPackage("ANALYSIS"); | |
16 | // gProof->ClearPackage("ANALYSISalice"); | |
aa191e39 | 17 | |
18 | gProof->ShowEnabledPackages(); | |
e6d0d7ed | 19 | |
20 | // Enable the STEERBase Package | |
21 | gProof->UploadPackage("STEERBase.par"); | |
22 | gProof->EnablePackage("STEERBase"); | |
aa191e39 | 23 | // Enable the ESD Package |
24 | gProof->UploadPackage("ESD.par"); | |
25 | gProof->EnablePackage("ESD"); | |
312525d3 | 26 | // Enable the AOD Package |
27 | gProof->UploadPackage("AOD.par"); | |
28 | gProof->EnablePackage("AOD"); | |
aa191e39 | 29 | // Enable the Analysis Package |
30 | gProof->UploadPackage("ANALYSIS.par"); | |
31 | gProof->EnablePackage("ANALYSIS"); | |
312525d3 | 32 | |
e6d0d7ed | 33 | gProof->UploadPackage("ANALYSISalice.par"); |
34 | gProof->EnablePackage("ANALYSISalice"); | |
35 | ||
aa191e39 | 36 | // Enable the JETAN Package |
37 | gProof->UploadPackage("JETAN.par"); | |
38 | gProof->EnablePackage("JETAN"); | |
312525d3 | 39 | |
aa191e39 | 40 | // |
41 | gProof->ShowEnabledPackages(); | |
42 | ||
43 | // | |
44 | // | |
45 | // Create the chain | |
46 | // | |
e6d0d7ed | 47 | // TChain* chain = CreateESDChain("test.txt", 200); |
48 | // Input | |
49 | AliESDInputHandler* inpHandler = new AliESDInputHandler(); | |
aa191e39 | 50 | // |
312525d3 | 51 | // Create the analysis manager |
aa191e39 | 52 | // |
a0255da7 | 53 | AliAODHandler* aodHandler = new AliAODHandler(); |
e6d0d7ed | 54 | aodHandler->SetOutputFileName("jets.root"); |
312525d3 | 55 | |
56 | AliAnalysisManager *mgr = new AliAnalysisManager("Jet Manager", "Jet Manager"); | |
e6d0d7ed | 57 | mgr->SetOutputEventHandler(aodHandler); |
58 | mgr->SetInputEventHandler(inpHandler); | |
aa191e39 | 59 | mgr-> SetDebugLevel(10); |
312525d3 | 60 | |
312525d3 | 61 | |
e6d0d7ed | 62 | // |
63 | // ESD Filter Task | |
64 | // | |
312525d3 | 65 | // |
66 | // Set of cuts | |
67 | // | |
68 | // standard | |
69 | AliESDtrackCuts* esdTrackCutsL = new AliESDtrackCuts("AliESDtrackCuts", "Loose"); | |
70 | esdTrackCutsL->SetMinNClustersTPC(50); | |
71 | esdTrackCutsL->SetMaxChi2PerClusterTPC(3.5); | |
312525d3 | 72 | esdTrackCutsL->SetRequireTPCRefit(kTRUE); |
a0f4238b | 73 | esdTrackCutsL->SetMaxDCAToVertexXY(2.4); |
74 | esdTrackCutsL->SetMaxDCAToVertexZ(3.2); | |
75 | esdTrackCutsL->SetDCAToVertex2D(kTRUE); | |
76 | esdTrackCutsL->SetRequireSigmaToVertex(kFALSE); | |
d3fae473 | 77 | esdTrackCutsL->SetAcceptKinkDaughters(kFALSE); |
312525d3 | 78 | // |
312525d3 | 79 | // |
80 | AliAnalysisFilter* trackFilter = new AliAnalysisFilter("trackFilter"); | |
81 | trackFilter->AddCuts(esdTrackCutsL); | |
312525d3 | 82 | // |
83 | AliAnalysisTaskESDfilter *esdfilter = new AliAnalysisTaskESDfilter("ESD Filter"); | |
84 | esdfilter->SetTrackFilter(trackFilter); | |
85 | esdfilter->SetDebugLevel(10); | |
86 | mgr->AddTask(esdfilter); | |
e6d0d7ed | 87 | |
88 | // | |
89 | // Jet Finder Task | |
90 | // | |
91 | ||
92 | AliAnalysisTaskJets *jetana = new AliAnalysisTaskJets("JetAnalysis"); | |
93 | jetana->SetDebugLevel(10); | |
94 | jetana->SetConfigFile("ConfigJetAnalysisAOD.C"); | |
95 | mgr->AddTask(jetana); | |
aa191e39 | 96 | // |
97 | // Create containers for input/output | |
861795a8 | 98 | AliAnalysisDataContainer *cinput1 = mgr->GetCommonInputContainer(); |
aa191e39 | 99 | |
861795a8 | 100 | AliAnalysisDataContainer *coutput1 = mgr->GetCommonOutputContainer(); |
e6d0d7ed | 101 | coutput1->SetSpecialOutput(); |
102 | ||
103 | AliAnalysisDataContainer *coutput2 = mgr->CreateContainer("histos", TList::Class(), | |
312525d3 | 104 | AliAnalysisManager::kOutputContainer, "histos.root"); |
aa191e39 | 105 | |
e6d0d7ed | 106 | mgr->ConnectInput (esdfilter, 0, cinput1 ); |
107 | mgr->ConnectOutput (esdfilter, 0, coutput1); | |
108 | ||
aa191e39 | 109 | mgr->ConnectInput (jetana, 0, cinput1); |
110 | mgr->ConnectOutput(jetana, 0, coutput1); | |
312525d3 | 111 | mgr->ConnectOutput(jetana, 1, coutput2); |
112 | ||
e6d0d7ed | 113 | |
aa191e39 | 114 | // |
115 | // Run the analysis | |
116 | // | |
117 | mgr->InitAnalysis(); | |
118 | mgr->PrintStatus(); | |
e6d0d7ed | 119 | mgr->StartAnalysis("proof","/PWG4/arian/jetjetAbove_50_real"); |
aa191e39 | 120 | } |