AliPhysics  d497547 (d497547)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
AliAnalysisTaskEmcalJetSubstructureTree.cxx
Go to the documentation of this file.
1 /************************************************************************************
2  * Copyright (C) 2017, Copyright Holders of the ALICE Collaboration *
3  * All rights reserved. *
4  * *
5  * Redistribution and use in source and binary forms, with or without *
6  * modification, are permitted provided that the following conditions are met: *
7  * * Redistributions of source code must retain the above copyright *
8  * notice, this list of conditions and the following disclaimer. *
9  * * Redistributions in binary form must reproduce the above copyright *
10  * notice, this list of conditions and the following disclaimer in the *
11  * documentation and/or other materials provided with the distribution. *
12  * * Neither the name of the <organization> nor the *
13  * names of its contributors may be used to endorse or promote products *
14  * derived from this software without specific prior written permission. *
15  * *
16  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND *
17  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED *
18  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE *
19  * DISCLAIMED. IN NO EVENT SHALL ALICE COLLABORATION BE LIABLE FOR ANY *
20  * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES *
21  * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; *
22  * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND *
23  * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT *
24  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS *
25  * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. *
26  ************************************************************************************/
27 #include <iostream>
28 #include <string>
29 #include <sstream>
30 #include <vector>
31 
32 #include <fastjet/ClusterSequence.hh>
33 #include <fastjet/contrib/Nsubjettiness.hh>
34 #include <fastjet/contrib/SoftDrop.hh>
35 
36 #include <TLorentzVector.h>
37 #include <TMath.h>
38 #include <TString.h>
39 #include <TVector3.h>
40 
41 #include "AliAODInputHandler.h"
42 #include "AliAnalysisManager.h"
44 #include "AliClusterContainer.h"
45 #include "AliJetContainer.h"
47 #include "AliEmcalJet.h"
48 #include "AliEmcalList.h"
49 #include "AliLog.h"
50 #include "AliParticleContainer.h"
51 #include "AliTrackContainer.h"
52 #include "AliRhoParameter.h"
53 #include "AliVCluster.h"
54 #include "AliVParticle.h"
55 
59 
60 namespace EmcalTriggerJets {
61 
64  fJetSubstructureTree(nullptr),
65  fSDZCut(0.1),
66  fSDBetaCut(0),
67  fReclusterizer(kCAAlgo),
68  fTriggerSelectionBits(AliVEvent::kAny),
69  fTriggerSelectionString(""),
70  fRhoNamePtRec("RhoSparse_Full_R04"),
71  fRhoNameMassRec("RhoMassSparse_Full_R04"),
72  fRhoNamePtSim("RhoSparse_Part_R04"),
73  fRhoNameMassSim("RhoMassSparse_Part_R04")
74 {
75  memset(fJetTreeData, 0, sizeof(Double_t) * kTNVar);
76 }
77 
79  AliAnalysisTaskEmcalJet(name, kTRUE),
80  fJetSubstructureTree(nullptr),
81  fSDZCut(0.1),
82  fSDBetaCut(0),
83  fReclusterizer(kCAAlgo),
84  fTriggerSelectionBits(AliVEvent::kAny),
85  fTriggerSelectionString(""),
86  fRhoNamePtRec("RhoSparse_Full_R04"),
87  fRhoNameMassRec("RhoMassSparse_Full_R04"),
88  fRhoNamePtSim("RhoSparse_Part_R04"),
89  fRhoNameMassSim("RhoMassSparse_Part_R04")
90 {
91  memset(fJetTreeData, 0, sizeof(Double_t) * kTNVar);
92  DefineOutput(2, TTree::Class());
93 }
94 
96 
97 }
98 
101 
102  OpenFile(2);
103  fJetSubstructureTree = new TTree("jetSubstructure", "Tree with jet substructure information");
104  TString varnames[kTNVar];
105  varnames[0] = "Radius";
106  varnames[1] = "EventWeight";
107  varnames[2] = "PtJetRec";
108  varnames[3] = "PtJetSim";
109  varnames[4] = "RhoPtRec";
110  varnames[5] = "RhoPtSim";
111  varnames[6] = "RhoMassRec";
112  varnames[7] = "RhoMassSim";
113  varnames[8] = "AreaRec";
114  varnames[9] = "AreaSim";
115  varnames[10] = "NEFRec";
116  varnames[11] = "NEFSim";
117  varnames[12] = "MassRec";
118  varnames[13] = "MassSim";
119  varnames[14] = "ZgMeasured";
120  varnames[15] = "ZgTrue";
121  varnames[16] = "RgMeasured";
122  varnames[17] = "RgTrue";
123  varnames[18] = "MgMeasured";
124  varnames[19] = "MgTrue";
125  varnames[20] = "PtgMeasured";
126  varnames[21] = "PtgTrue";
127  varnames[22] = "OneSubjettinessMeasured";
128  varnames[23] = "OneSubjettinessTrue";
129  varnames[24] = "TwoSubjettinessMeasured";
130  varnames[25] = "TwoSubjettinessTrue";
131  varnames[26] = "AngularityMeasured";
132  varnames[27] = "AngularityTrue";
133  varnames[28] = "PtDMeasured";
134  varnames[29] = "PtDTrue";
135  varnames[30] = "NCharged";
136  varnames[31] = "NNeutral";
137  varnames[32] = "NConstTrue";
138  varnames[33] = "NDroppedMeasured";
139  varnames[34] = "NDroppedTrue";
140 
141  for(int ib = 0; ib < kTNVar; ib++){
142  fJetSubstructureTree->Branch(varnames[ib], fJetTreeData + ib, Form("%s/D", varnames[ib].Data()));
143  }
144  PostData(1, fOutput);
145  PostData(2, fJetSubstructureTree);
146 }
147 
149  AliClusterContainer *clusters = GetClusterContainer("caloClusters");
150  AliTrackContainer *tracks = GetTrackContainer("tracks");
151  AliParticleContainer *particles = GetParticleContainer("mcparticles");
152 
153  AliJetContainer *mcjets = GetJetContainer("mcjets");
154  AliJetContainer *datajets = GetJetContainer("datajets");
155 
157  *rhoMassRec = GetRhoFromEvent(fRhoNameMassRec),
158  *rhoPtSim = GetRhoFromEvent(fRhoNamePtSim),
159  *rhoMassSim = GetRhoFromEvent(fRhoNameMassSim);
160 
161  // Run trigger selection (not on pure MCgen train)
162  if(datajets){
163  if(!(fInputHandler->IsEventSelected() & fTriggerSelectionBits)) return false;
164  if(fTriggerSelectionString.Length()) {
165  if(!fInputEvent->GetFiredTriggerClasses().Contains(fTriggerSelectionString)) return false;
166  }
167  }
168 
169  Double_t weight = 1;
170  Double_t rhoparameters[4]; memset(rhoparameters, 0, sizeof(Double_t) * 4);
171  if(rhoPtRec) rhoparameters[0] = rhoPtRec->GetVal();
172  if(rhoPtSim) rhoparameters[1] = rhoPtSim->GetVal();
173  if(rhoMassRec) rhoparameters[2] = rhoMassRec->GetVal();
174  if(rhoMassSim) rhoparameters[3] = rhoMassSim->GetVal();
175 
176  AliSoftdropDefinition softdropSettings;
177  softdropSettings.fBeta = fSDBetaCut;
178  softdropSettings.fZ = fSDZCut;
179  switch(fReclusterizer) {
180  case kCAAlgo: softdropSettings.fRecluserAlgo = fastjet::cambridge_aachen_algorithm; break;
181  case kKTAlgo: softdropSettings.fRecluserAlgo = fastjet::kt_algorithm; break;
182  case kAKTAlgo: softdropSettings.fRecluserAlgo = fastjet::antikt_algorithm; break;
183  };
184 
185  AliNSubjettinessDefinition nsubjettinessSettings;
186  nsubjettinessSettings.fBeta = 1.;
187  nsubjettinessSettings.fRadius = 0.4;
188 
189  if(mcjets && !datajets) {
190  // pure MC (gen) train - run over MC jets
191  AliDebugStream(1) << "In MC pure jet branch: found " << mcjets->GetNJets() << " jets, " << mcjets->GetNAcceptedJets() << " were accepted\n";
192  for(auto jet : mcjets->accepted()) {
193  try {
194  AliJetSubstructureData structure = MakeJetSubstructure(*jet, mcjets->GetJetRadius() * 2., particles, nullptr,{softdropSettings, nsubjettinessSettings});
195  Double_t angularity[2] = {0., MakeAngularity(*jet, particles, nullptr)},
196  ptd[2] = {0., MakePtD(*jet, particles, nullptr)};
197  FillTree(mcjets->GetJetRadius(), weight, nullptr, jet, nullptr, &(structure.fSoftDrop), nullptr, &(structure.fNsubjettiness), angularity, ptd, rhoparameters);
198  } catch (ReclusterizerException &e) {
199  AliErrorStream() << "Error in reclusterization - skipping jet" << std::endl;
200  }
201  }
202  }
203 
204  if(datajets) {
205  for(auto jet : datajets->accepted()) {
206  AliEmcalJet *associatedJet = jet->MatchedJet();
207  if(mcjets) {
208  if(!associatedJet) continue;
209  try {
210  AliJetSubstructureData structureData = MakeJetSubstructure(*jet, datajets->GetJetRadius() * 2., tracks, clusters, {softdropSettings, nsubjettinessSettings}),
211  structureMC = MakeJetSubstructure(*associatedJet, mcjets->GetJetRadius() * 2, particles, nullptr, {softdropSettings, nsubjettinessSettings});
212  Double_t angularity[2] = {MakeAngularity(*jet, tracks, clusters), MakeAngularity(*associatedJet, particles, nullptr)},
213  ptd[2] = {MakePtD(*jet, tracks, clusters), MakePtD(*associatedJet, particles, nullptr)};
214  FillTree(datajets->GetJetRadius(), weight, jet, associatedJet, &(structureData.fSoftDrop), &(structureMC.fSoftDrop), &(structureData.fNsubjettiness), &(structureMC.fNsubjettiness), angularity, ptd, rhoparameters);
215  } catch(ReclusterizerException &e) {
216  AliErrorStream() << "Error in reclusterization - skipping jet" << std::endl;
217  }
218  } else {
219  try {
220  AliJetSubstructureData structure = MakeJetSubstructure(*jet, 0.4, tracks, clusters, {softdropSettings, nsubjettinessSettings});
221  Double_t angularity[2] = {MakeAngularity(*jet, tracks, clusters), 0.},
222  ptd[2] = {MakePtD(*jet, tracks, clusters), 0.};
223  FillTree(datajets->GetJetRadius(), weight, jet, nullptr, &(structure.fSoftDrop), nullptr, &(structure.fNsubjettiness), nullptr, angularity, ptd, rhoparameters);
224  } catch(ReclusterizerException &e) {
225  AliErrorStream() << "Error in reclusterization - skipping jet" << std::endl;
226  }
227  }
228  }
229  }
230 
231  return true;
232 }
233 
235  const AliEmcalJet *datajet, const AliEmcalJet *mcjet,
236  AliSoftDropParameters *dataSoftdrop, AliSoftDropParameters *mcSoftdrop,
237  AliNSubjettinessParameters *dataSubjettiness, AliNSubjettinessParameters *mcSubjettiness,
238  Double_t *angularity, Double_t *ptd, Double_t *rhoparameters){
239  fJetTreeData[kTRadius] = r;
240  fJetTreeData[kTWeight] = weight;
241  fJetTreeData[kTRhoPtRec] = rhoparameters[0];
242  fJetTreeData[kTRhoPtSim] = rhoparameters[1];
243  fJetTreeData[kTRhoMassRec] = rhoparameters[2];
244  fJetTreeData[kTRhoMassSim] = rhoparameters[3];
245  if(datajet) {
246  fJetTreeData[kTPtJetRec] = TMath::Abs(datajet->Pt());
248  fJetTreeData[kTNNeutral] = datajet->GetNumberOfClusters();
249  fJetTreeData[kTAreaRec] = datajet->Area();
250  fJetTreeData[kTNEFRec] = datajet->NEF();
251  fJetTreeData[kTMassRec] = datajet->M();
252  } else {
253  fJetTreeData[kTPtJetRec] = 0.;
256  fJetTreeData[kTAreaRec] = 0.;
257  fJetTreeData[kTNEFRec] = 0.;
258  fJetTreeData[kTMassRec] = 0.;
259  }
260 
261  if(mcjet) {
262  fJetTreeData[kTPtJetSim] = TMath::Abs(mcjet->Pt());
264  fJetTreeData[kTAreaSim] = mcjet->Area();
265  fJetTreeData[kTNEFSim] = mcjet->NEF();
266  fJetTreeData[kTMassSim] = mcjet->M();
267  } else {
268  fJetTreeData[kTPtJetSim] = 0.;
270  fJetTreeData[kTAreaSim] = 0.;
271  fJetTreeData[kTNEFSim] = 0.;
272  fJetTreeData[kTMassSim] = 0;
273  }
274 
275  if(dataSoftdrop) {
276  fJetTreeData[kTZgMeasured] = dataSoftdrop->fZg;
277  fJetTreeData[kTRgMeasured] = dataSoftdrop->fRg;
278  fJetTreeData[kTMgMeasured] = dataSoftdrop->fMg;
279  fJetTreeData[kTPtgMeasured] = dataSoftdrop->fPtg;
280  fJetTreeData[kTNDroppedMeasured] = dataSoftdrop->fNDropped;
281  } else {
287  }
288 
289  if(mcSoftdrop) {
290  fJetTreeData[kTZgTrue] = mcSoftdrop->fZg;
291  fJetTreeData[kTRgTrue] = mcSoftdrop->fRg;
292  fJetTreeData[kTMgTrue] = mcSoftdrop->fMg;
293  fJetTreeData[kTPtgTrue] = mcSoftdrop->fPtg;
294  fJetTreeData[kTNDroppedTrue] = mcSoftdrop->fNDropped;
295  } else {
296  fJetTreeData[kTZgTrue] = 0.;
297  fJetTreeData[kTRgTrue] = 0.;
298  fJetTreeData[kTMgTrue] = 0.;
299  fJetTreeData[kTPtgTrue] = 0.;
301  }
302 
303  if(dataSubjettiness) {
306  } else {
309  }
310 
311  if(mcSubjettiness) {
314  } else {
317  }
318 
319  fJetTreeData[kTAngularityMeasured] = angularity[0];
320  fJetTreeData[kTAngularityTrue] = angularity[1];
321  fJetTreeData[kTPtDMeasured] = ptd[0];
322  fJetTreeData[kTPtDTrue] = ptd[1];
323 
324  fJetSubstructureTree->Fill();
325 }
326 
327 
329  const int kClusterOffset = 30000; // In order to handle tracks and clusters in the same index space the cluster index needs and offset, large enough so that there is no overlap with track indices
330  std::vector<fastjet::PseudoJet> constituents;
331  for(int itrk = 0; itrk < jet.GetNumberOfTracks(); itrk++){
332  AliVTrack *track = static_cast<AliVTrack *>(jet.TrackAt(itrk, tracks->GetArray()));
333  fastjet::PseudoJet constituentTrack(track->Px(), track->Py(), track->Pz(), track->E());
334  constituentTrack.set_user_index(jet.TrackAt(itrk));
335  constituents.push_back(constituentTrack);
336  }
337 
338  for(int icl = 0; icl < jet.GetNumberOfClusters(); icl++) {
339  AliVCluster *cluster = jet.ClusterAt(icl, clusters->GetArray());
340  TLorentzVector clustervec;
341  cluster->GetMomentum(clustervec, fVertex);
342  fastjet::PseudoJet constituentCluster(clustervec.Px(), clustervec.Py(), clustervec.Pz(), cluster->GetHadCorrEnergy());
343  constituentCluster.set_user_index(jet.ClusterAt(icl) + kClusterOffset);
344  constituents.push_back(constituentCluster);
345  }
346 
347  // Redo jet finding on constituents with a
348  fastjet::JetDefinition jetdef(fastjet::antikt_algorithm, jetradius*2, static_cast<fastjet::RecombinationScheme>(0), fastjet::BestFJ30 );
349  std::vector<fastjet::PseudoJet> outputjets;
350  try {
351  fastjet::ClusterSequence jetfinder(constituents, jetdef);
352  outputjets = jetfinder.inclusive_jets(0);
353  AliJetSubstructureData result({MakeSoftDropParameters(outputjets[0], settings.fSoftdropSettings), MakeNsubjettinessParameters(outputjets[0], settings.fSubjettinessSettings)});
354  return result;
355  } catch (fastjet::Error &e) {
356  AliErrorStream() << " FJ Exception caught: " << e.message() << std::endl;
357  throw ReclusterizerException();
358  }
359 }
360 
362  fastjet::contrib::SoftDrop softdropAlgorithm(cutparameters.fBeta, cutparameters.fZ);
363  softdropAlgorithm.set_verbose_structure(kTRUE);
364  std::unique_ptr<fastjet::contrib::Recluster> reclusterizer(new fastjet::contrib::Recluster(cutparameters.fRecluserAlgo, 1, true));
365  softdropAlgorithm.set_reclustering(kTRUE, reclusterizer.get());
366  fastjet::PseudoJet groomed = softdropAlgorithm(jet);
367 
368  AliSoftDropParameters result({groomed.structure_of<fastjet::contrib::SoftDrop>().symmetry(),
369  groomed.structure_of<fastjet::contrib::SoftDrop>().delta_R(),
370  groomed.structure_of<fastjet::contrib::SoftDrop>().mu(),
371  groomed.perp(),
372  groomed.structure_of<fastjet::contrib::SoftDrop>().dropped_count()});
373  return result;
374 }
375 
378  fastjet::contrib::Nsubjettiness (1,fastjet::contrib::KT_Axes(),fastjet::contrib::NormalizedCutoffMeasure(cut.fBeta, cut.fRadius, 1e100)).result(jet),
379  fastjet::contrib::Nsubjettiness (2,fastjet::contrib::KT_Axes(),fastjet::contrib::NormalizedCutoffMeasure(cut.fBeta, cut.fRadius, 1e100)).result(jet)
380  });
381  return result;
382 }
383 
385  if(!jet.GetNumberOfTracks()) return 0;
386  TVector3 jetvec(jet.Px(), jet.Py(), jet.Pz());
387  Double_t den(0.), num(0.);
388  if(tracks){
389  for(UInt_t itrk = 0; itrk < jet.GetNumberOfTracks(); itrk++) {
390  AliVParticle *track = jet.TrackAt(itrk, tracks->GetArray());
391  if(!track){
392  AliErrorStream() << "Associated constituent particle / track not found\n";
393  continue;
394  }
395  TVector3 trackvec(track->Px(), track->Py(), track->Pz());
396 
397  num += track->Pt() * trackvec.DrEtaPhi(jetvec);
398  den += +track->Pt();
399  }
400  }
401  if(clusters) {
402  for(UInt_t icl = 0; icl < jet.GetNumberOfClusters(); icl++){
403  AliVCluster *clust = jet.ClusterAt(icl, clusters->GetArray());
404  if(!clust) {
405  AliErrorStream() << "Associated constituent cluster not found\n";
406  continue;
407  }
408  TLorentzVector clusterp;
409  clust->GetMomentum(clusterp, fVertex);
410 
411  num += clusterp.Pt() * clusterp.Vect().DrEtaPhi(jetvec);
412  den += clusterp.Pt();
413  }
414  }
415  return num/den;
416 }
417 
419  if (!jet.GetNumberOfTracks()) return 0;
420  Double_t den(0.), num(0.);
421  if(particles){
422  for(UInt_t itrk = 0; itrk < jet.GetNumberOfTracks(); itrk++) {
423  AliVParticle *trk = jet.TrackAt(itrk, particles->GetArray());
424  if(!trk){
425  AliErrorStream() << "Associated constituent particle / track not found\n";
426  continue;
427  }
428  num += trk->Pt() * trk->Pt();
429  den += trk->Pt();
430  }
431  }
432  if(clusters){
433  for(UInt_t icl = 0; icl < jet.GetNumberOfClusters(); icl++){
434  AliVCluster *clust = jet.ClusterAt(icl, clusters->GetArray());
435  if(!clust) {
436  AliErrorStream() << "Associated constituent cluster not found\n";
437  continue;
438  }
439  TLorentzVector clusterp;
440  clust->GetMomentum(clusterp, fVertex);
441  num += clusterp.Pt() * clusterp.Pt();
442  den += clusterp.Pt();
443  }
444  }
445  return TMath::Sqrt(num)/den;
446 }
447 
449  AliAnalysisManager *mgr = AliAnalysisManager::GetAnalysisManager();
450 
451  Bool_t isAOD(kFALSE);
452  AliInputEventHandler *inputhandler = static_cast<AliInputEventHandler *>(mgr->GetInputEventHandler());
453  if(inputhandler) {
454  if(inputhandler->IsA() == AliAODInputHandler::Class()) isAOD = kTRUE;
455  }
456 
457  AliAnalysisTaskEmcalJetSubstructureTree *treemaker = new AliAnalysisTaskEmcalJetSubstructureTree("JetSubstructureTreemaker_" + TString::Format("R%02d_", int(jetradius * 10.)) + trigger);
458  mgr->AddTask(treemaker);
459  treemaker->SetMakeGeneralHistograms(kTRUE);
460 
461  // Adding containers
462  if(isMC) {
463  AliParticleContainer *particles = treemaker->AddMCParticleContainer("mcparticles");
464  particles->SetMinPt(0.);
465 
466  AliJetContainer *mcjets = treemaker->AddJetContainer(
470  jetradius,
472  particles, nullptr);
473  mcjets->SetName("mcjets");
474  mcjets->SetJetPtCut(20.);
475  }
476 
477  if(isData) {
479  tracks->SetMinPt(0.15);
481  clusters->SetMinE(0.3); // 300 MeV E-cut
482 
483  AliJetContainer *datajets = treemaker->AddJetContainer(
487  jetradius,
489  tracks, clusters);
490  datajets->SetName("datajets");
491  datajets->SetJetPtCut(20.);
492 
493  treemaker->SetUseAliAnaUtils(true, true);
494  treemaker->SetVzRange(-10., 10);
495 
496  // configure trigger selection
497  TString triggerstring(trigger);
498  if(triggerstring.Contains("INT7")) {
499  treemaker->SetTriggerBits(AliVEvent::kINT7);
500  } else if(triggerstring.Contains("EJ1")) {
501  treemaker->SetTriggerBits(AliVEvent::kEMCEJE);
502  treemaker->SetTriggerString("EJ1");
503  } else if(triggerstring.Contains("EJ2")) {
504  treemaker->SetTriggerBits(AliVEvent::kEMCEJE);
505  treemaker->SetTriggerString("EJ2");
506  }
507  }
508 
509  // Connecting containers
510  TString outputfile = mgr->GetCommonFileName();
511  outputfile += TString::Format(":JetSubstructure_R%02d_%s", int(jetradius * 10.), trigger);
512  mgr->ConnectInput(treemaker, 0, mgr->GetCommonInputContainer());
513  mgr->ConnectOutput(treemaker, 1, mgr->CreateContainer("JetSubstructureHistos_" + TString::Format("R%0d_", int(jetradius * 10.)) + trigger, AliEmcalList::Class(), AliAnalysisManager::kOutputContainer, outputfile));
514  mgr->ConnectOutput(treemaker, 2, mgr->CreateContainer("JetSubstuctureTree_" + TString::Format("R%0d_", int(jetradius * 10.)) + trigger, TTree::Class(), AliAnalysisManager::kOutputContainer, Form("JetSubstructureTree_%s.root", trigger)));
515 
516  return treemaker;
517 }
518 
519 } /* namespace EmcalTriggerJets */
TString fRhoNameMassSim
Name of the rho parameter coming from the rho task for mc-level jet (mass)
Double_t Area() const
Definition: AliEmcalJet.h:123
double Double_t
Definition: External.C:58
Double_t MakePtD(const AliEmcalJet &jet, const AliParticleContainer *const particles, const AliClusterContainer *const clusters) const
AliJetContainer * GetJetContainer(Int_t i=0) const
Double_t Py() const
Definition: AliEmcalJet.h:100
Container with name, TClonesArray and cuts for particles.
void SetUseAliAnaUtils(Bool_t b, Bool_t bRejPilup=kTRUE)
AliJetSubstructureData MakeJetSubstructure(const AliEmcalJet &jet, double jetradius, const AliParticleContainer *tracks, const AliClusterContainer *clusters, const AliJetSubstructureSettings &settings) const
AliEmcalJet * MatchedJet() const
Definition: AliEmcalJet.h:226
Int_t ClusterAt(Int_t idx) const
Definition: AliEmcalJet.h:130
AliJetContainer * AddJetContainer(const char *n, TString defaultCutType, Float_t jetRadius=0.4)
TString fRhoNamePtSim
Name of the rho parameter coming from the rho task for mc-level jet (pt)
Structure for results from the soft drop algorithm.
virtual bool Run()
Run function. This is the core function of the analysis and contains the user code. Therefore users have to implement this function.
void SetVzRange(Double_t min, Double_t max)
AliClusterContainer * AddClusterContainer(const char *n)
Create new cluster container and attach it to the task.
fastjet::JetAlgorithm fRecluserAlgo
Reclusterization algorithm.
UShort_t GetNumberOfConstituents() const
Definition: AliEmcalJet.h:133
Container for particles within the EMCAL framework.
Int_t TrackAt(Int_t idx) const
Definition: AliEmcalJet.h:153
UShort_t GetNumberOfTracks() const
Definition: AliEmcalJet.h:132
Double_t Px() const
Definition: AliEmcalJet.h:99
AliParticleContainer * GetParticleContainer(Int_t i=0) const
Get particle container attached to this task.
AliRhoParameter * GetRhoFromEvent(const char *name)
UShort_t GetNumberOfClusters() const
Definition: AliEmcalJet.h:131
void SetJetPtCut(Float_t cut)
TPC acceptance.
Definition: AliEmcalJet.h:60
unsigned int UInt_t
Definition: External.C:33
Int_t GetNJets() const
AliNSubjettinessParameters MakeNsubjettinessParameters(const fastjet::PseudoJet &jet, const AliNSubjettinessDefinition &cut) const
Definition for the algorithm obtaining the softdrop parameters.
AliClusterContainer * GetClusterContainer(Int_t i=0) const
Get cluster container attached to this task.
AliMCParticleContainer * AddMCParticleContainer(const char *n)
Create new container for MC particles and attach it to the task.
Double_t MakeAngularity(const AliEmcalJet &jet, const AliParticleContainer *tracks, const AliClusterContainer *clusters) const
TString fRhoNamePtRec
Name of the rho parameter coming from the rho task for rec jet (pt)
Bool_t Data(TH1F *h, Double_t *rangefit, Bool_t writefit, Double_t &sgn, Double_t &errsgn, Double_t &bkg, Double_t &errbkg, Double_t &sgnf, Double_t &errsgnf, Double_t &sigmafit, Int_t &status)
Double_t Pt() const
Definition: AliEmcalJet.h:102
Bool_t isMC
Float_t GetJetRadius() const
AliEmcalList * fOutput
!output list
Double_t fVertex[3]
!event vertex
AliTrackContainer * AddTrackContainer(const char *n)
Create new track container and attach it to the task.
AliTrackContainer * GetTrackContainer(Int_t i=0) const
void SetMakeGeneralHistograms(Bool_t g)
Base task in the EMCAL jet framework.
void FillTree(double r, double weight, const AliEmcalJet *datajet, const AliEmcalJet *mcjet, AliSoftDropParameters *dataSoftdrop, AliSoftDropParameters *mcsoftdrop, AliNSubjettinessParameters *dataSubjettiness, AliNSubjettinessParameters *mcSubjettiness, Double_t *angularity, Double_t *ptd, Double_t *rhoparameters)
static AliAnalysisTaskEmcalJetSubstructureTree * AddEmcalJetSubstructureTreeMaker(Bool_t isMC, Bool_t isData, Double_t jetradius, const char *name)
Represent a jet reconstructed using the EMCal jet framework.
Definition: AliEmcalJet.h:44
Double_t Pz() const
Definition: AliEmcalJet.h:101
AliSoftDropParameters MakeSoftDropParameters(const fastjet::PseudoJet &jet, const AliSoftdropDefinition &cut) const
void UserCreateOutputObjects()
Main initialization function on the worker.
const AliJetIterableContainer accepted() const
bool Bool_t
Definition: External.C:53
Double_t NEF() const
Definition: AliEmcalJet.h:141
TString fRhoNameMassRec
Name of the rho parameter coming from the rho task for rec jet (mass)
Container structure for EMCAL clusters.
Double_t M() const
Definition: AliEmcalJet.h:113
EMCal fiducial acceptance (each eta, phi edge narrowed by jet R)
Definition: AliEmcalJet.h:63
Container for jet within the EMCAL jet framework.
TList * OpenFile(const char *fname)
Definition: DrawAnaELoss.C:65
static TString ClusterContainerNameFactory(Bool_t isAOD)
Get name of the default cluster container.
static TString TrackContainerNameFactory(Bool_t isAOD)
Get name of the default track container.