AliPhysics  6bc8652 (6bc8652)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
AliAnalysisTaskEmcalClustersRef.cxx
Go to the documentation of this file.
1 /**************************************************************************
2  * Copyright(c) 1998-2015, ALICE Experiment at CERN, All rights reserved. *
3  * *
4  * Author: The ALICE Off-line Project. *
5  * Contributors are mentioned in the code where appropriate. *
6  * *
7  * Permission to use, copy, modify and distribute this software and its *
8  * documentation strictly for non-commercial purposes is hereby granted *
9  * without fee, provided that the above copyright notice appears in all *
10  * copies and that both the copyright notice and this permission notice *
11  * appear in the supporting documentation. The authors make no claims *
12  * about the suitability of this software for any purpose. It is *
13  * provided "as is" without express or implied warranty. *
14  **************************************************************************/
15 #include <array>
16 #include <bitset>
17 #include <iostream>
18 #include <map>
19 #include <vector>
20 
21 #include <TArrayD.h>
22 #include <TClonesArray.h>
23 #include <TGrid.h>
24 #include <THashList.h>
25 #include <THistManager.h>
26 #include <TLinearBinning.h>
27 #include <TLorentzVector.h>
28 #include <TObjArray.h>
29 #include <TParameter.h>
30 #include <TMath.h>
31 
32 #include "AliAnalysisManager.h"
33 #include "AliAnalysisUtils.h"
34 #include "AliClusterContainer.h"
36 #include "AliEMCALGeometry.h"
37 #include "AliEmcalList.h"
38 #include "AliEMCALTriggerPatchInfo.h"
40 #include "AliESDEvent.h"
41 #include "AliInputEventHandler.h"
42 #include "AliLog.h"
43 #include "AliMultSelection.h"
44 #include "AliMultEstimator.h"
45 #include "AliVCluster.h"
46 #include "AliVEvent.h"
47 #include "AliVEventHandler.h"
48 #include "AliVVertex.h"
49 
51 
55 
56 namespace EMCalTriggerPtAnalysis {
57 
58 AliAnalysisTaskEmcalClustersRef::AliAnalysisTaskEmcalClustersRef() :
60  fCentralityRange(-999., 999.),
61  fRequestCentrality(false),
62  fEventCentrality(-1),
63  fCentralityEstimator("V0M"),
64  fBunchCrossingIndex(-1),
65  fEnergyDefinition(kDefaultEnergy),
66  fEnableSumw2(false),
67  fClusterTimeRange(-50e-6, 50e-6)
68 {
69 }
70 
73  fCentralityRange(-999., 999.),
74  fRequestCentrality(false),
75  fEventCentrality(-1),
76  fCentralityEstimator("V0M"),
77  fBunchCrossingIndex(-1),
78  fEnergyDefinition(kDefaultEnergy),
79  fEnableSumw2(false),
80  fClusterTimeRange(-50e-6, 50e-6)
81 {
82 }
83 
85 }
86 
87 
89 
90  EnergyBinning energybinning;
91  TLinearBinning smbinning(21, -0.5, 20.5), etabinning(100, -0.7, 0.7), timebinning(1000, -500e-9, 500e-9);
92  TString optionstring = fEnableSumw2 ? "s" : "";
93 
94  /*
95  * Exclusive classes are defined as triggered events
96  * in a class without lower threshold classes firing.
97  * This is needed to make the triggers statistically
98  * independent.
99  */
100  std::array<Double_t, 5> encuts = {1., 2., 5., 10., 20.};
101  Int_t sectorsWithEMCAL[10] = {4, 5, 6, 7, 8, 9, 13, 14, 15, 16};
102  for(auto trg : GetSupportedTriggers()){
103  fHistos->CreateTH1("hEventCount" + trg, "Event count for trigger class " + trg, 1, 0.5, 1.5, optionstring);
104  fHistos->CreateTH1("hEventCentrality" + trg, "Event centrality for trigger class " + trg, 103, -2., 101., optionstring);
105  fHistos->CreateTH1("hVertexZ" + trg, "z-position of the primary vertex for trigger class " + trg, 200, -40., 40., optionstring);
106  fHistos->CreateTH1("hClusterEnergy" + trg, "Cluster energy for trigger class " + trg, energybinning, optionstring);
107  fHistos->CreateTH1("hClusterET" + trg, "Cluster transverse energy for trigger class " + trg, energybinning, optionstring);
108  fHistos->CreateTH1("hClusterEnergyFired" + trg, "Cluster energy for trigger class " + trg + ", firing the trigger", energybinning, optionstring);
109  fHistos->CreateTH1("hClusterETFired" + trg, "Cluster transverse energy for trigger class " + trg + ", firing the trigger" , energybinning, optionstring);
110  fHistos->CreateTH2("hClusterEnergySM" + trg, "Cluster energy versus supermodule for trigger class " + trg, smbinning, energybinning, optionstring);
111  fHistos->CreateTH2("hClusterETSM" + trg, "Cluster transverse energy versus supermodule for trigger class " + trg, smbinning, energybinning, optionstring);
112  fHistos->CreateTH2("hClusterEnergyFiredSM" + trg, "Cluster energy versus supermodule for trigger class " + trg + ", firing the trigger" , smbinning, energybinning, optionstring);
113  fHistos->CreateTH2("hClusterETFiredSM" + trg, "Cluster transverse energy versus supermodule for trigger class " + trg + ", firing the trigger" , smbinning, energybinning, optionstring);
114  fHistos->CreateTH2("hEtaEnergy" + trg, "Cluster energy vs. eta for trigger class " + trg, etabinning, energybinning, optionstring);
115  fHistos->CreateTH2("hEtaET" + trg, "Cluster transverse energy vs. eta for trigger class " + trg, etabinning, energybinning, optionstring);
116  fHistos->CreateTH2("hTimeEnergy" + trg, "Cluster time vs. energy for trigger class " + trg, timebinning, energybinning, optionstring);
117  fHistos->CreateTH2("hEtaEnergyFired" + trg, "Cluster energy vs. eta for trigger class " + trg + ", firing the trigger", etabinning, energybinning, optionstring);
118  fHistos->CreateTH2("hEtaETFired" + trg, "Cluster transverse energy vs. eta for trigger class " + trg + ", firing the trigger", etabinning, energybinning, optionstring);
119  for(int ism = 0; ism < 20; ism++){
120  fHistos->CreateTH2(TString::Format("hEtaEnergySM%d", ism) + trg, TString::Format("Cluster energy vs. eta in Supermodule %d for trigger ", ism) + trg, etabinning, energybinning, optionstring);
121  fHistos->CreateTH2(TString::Format("hEtaETSM%d", ism) + trg, TString::Format("Cluster transverse energy vs. eta in Supermodule %d for trigger ", ism) + trg, etabinning, energybinning, optionstring);
122  fHistos->CreateTH2(TString::Format("hEtaEnergyFiredSM%d", ism) + trg, TString::Format("Cluster energy vs. eta in Supermodule %d for trigger ", ism) + trg + ", firing the trigger", etabinning, energybinning, optionstring);
123  fHistos->CreateTH2(TString::Format("hEtaETFiredSM%d", ism) + trg, TString::Format("Cluster transverse energy vs. eta in Supermodule %d for trigger ", ism) + trg +", firing the trigger", etabinning, energybinning, optionstring);
124  }
125  for(int isec = 0; isec < 10; isec++){
126  fHistos->CreateTH2(TString::Format("hEtaEnergySec%d", sectorsWithEMCAL[isec]) + trg, TString::Format("Cluster energy vs.eta in tracking sector %d for trigger ", sectorsWithEMCAL[isec]) + trg, etabinning, energybinning, optionstring);
127  fHistos->CreateTH2(TString::Format("hEtaETSec%d", sectorsWithEMCAL[isec]) + trg, TString::Format("Cluster transverse energy vs.eta in tracking sector %d for trigger ", sectorsWithEMCAL[isec]) + trg, etabinning, energybinning, optionstring);
128  fHistos->CreateTH2(TString::Format("hEtaEnergyFiredSec%d", sectorsWithEMCAL[isec]) + trg, TString::Format("Cluster energy vs.eta in tracking sector %d for trigger ", sectorsWithEMCAL[isec]) + trg + ", firing the trigger", etabinning, energybinning, optionstring);
129  fHistos->CreateTH2(TString::Format("hEtaETFiredSec%d", sectorsWithEMCAL[isec]) + trg, TString::Format("Cluster transverse energy vs.eta in tracking sector %d for trigger ", sectorsWithEMCAL[isec]) + trg + ", firing the trigger", etabinning, energybinning, optionstring);
130  }
131  for(auto ien : encuts){
132  fHistos->CreateTH2(TString::Format("hEtaPhi%dG", static_cast<int>(ien)) + trg, TString::Format("cluster #eta-#phi map for clusters with energy larger than %f GeV/c for trigger class ", ien) + trg, 100, -0.7, 0.7, 200, 0, 2*TMath::Pi(), optionstring);
133  fHistos->CreateTH2(TString::Format("hEtaPhiFired%dG", static_cast<int>(ien)) + trg, TString::Format("cluster #eta-#phi map for clusters fired the trigger with energy larger than %f GeV/c for trigger class", ien) + trg + ", firing the trigger", 200, -0.7, 0.7, 200, 0, 2*TMath::Pi(), optionstring);
134  }
135  }
136 }
137 
139  fEventCentrality = -1;
140  if(fRequestCentrality){
141  AliMultSelection *mult = dynamic_cast<AliMultSelection *>(InputEvent()->FindListObject("MultSelection"));
142  if(!mult){
143  AliErrorStream() << GetName() << ": Centrality selection enabled but no centrality estimator found" << std::endl;
144  return false;
145  }
146  if(mult->IsEventSelected()) return false;
147  fEventCentrality = mult->GetEstimator(fCentralityEstimator)->GetPercentile();
148  AliDebugStream(1) << GetName() << ": Centrality " << fEventCentrality << std::endl;
150  AliDebugStream(1) << GetName() << ": reject centrality: " << fEventCentrality << std::endl;
151  return false;
152  } else {
153  AliDebugStream(1) << GetName() << ": select centrality " << fEventCentrality << std::endl;
154  }
155  } else {
156  AliDebugStream(1) << GetName() << ": No centrality selection applied" << std::endl;
157  }
158 
159  if(fBunchCrossingIndex > -1){
160  int bcindex = fInputEvent->GetHeader()->GetBunchCrossNumber() % 4;
161  if(bcindex != fBunchCrossingIndex) return false;
162  }
163  return true;
164 }
165 
167  AliDebugStream(1) << GetName() << ": UserExec start" << std::endl;
168 
169  TList ej1patches, dj1patches, ej2patches, dj2patches, eg1patches, dg1patches, eg2patches, dg2patches;
170  FindPatchesForTrigger("EJ2", fTriggerPatchInfo, ej2patches);
171  FindPatchesForTrigger("DJ2", fTriggerPatchInfo, dj2patches);
172  FindPatchesForTrigger("EJ1", fTriggerPatchInfo, ej1patches);
173  FindPatchesForTrigger("DJ1", fTriggerPatchInfo, dj1patches);
174  FindPatchesForTrigger("EG2", fTriggerPatchInfo, eg2patches);
175  FindPatchesForTrigger("DG2", fTriggerPatchInfo, dg2patches);
176  FindPatchesForTrigger("EG1", fTriggerPatchInfo, eg1patches);
177  FindPatchesForTrigger("DG1", fTriggerPatchInfo, dg1patches);
178 
179  Double_t energy, et, eta, phi;
180  TList *selpatches(nullptr);
181  for(auto clust : GetClusterContainer(fNameClusterContainer.Data())->all()){
182  //AliVCluster *clust = static_cast<AliVCluster *>(*clustIter);
183  if(!clust->IsEMCAL()) continue;
184  if(clust->GetIsExotic()) continue;
185  if(!fClusterTimeRange.IsInRange(clust->GetTOF())) continue;
186 
187  // Distinguish energy definition
188  switch(fEnergyDefinition){
189  case kDefaultEnergy:
190  AliDebugStream(2) << GetName() << ": Using cluster energy definition: default" << std::endl;
191  energy = clust->E();
192  break;
193  case kNonLinCorrEnergy:
194  AliDebugStream(2) << GetName() << ": Using cluster energy definition: corrected for non-linearity" << std::endl;
195  energy = clust->GetNonLinCorrEnergy();
196  break;
197  case kHadCorrEnergy:
198  AliDebugStream(2) << GetName() << ": Using cluster energy definition: corrected for hadronic contribution" << std::endl;
199  energy = clust->GetHadCorrEnergy();
200  break;
201  };
202 
203  AliDebugStream(2) << GetName() << ": Using energy " << energy << " (def: " << clust->E()
204  << " | NL: " << clust->GetNonLinCorrEnergy()
205  << " | HD: " << clust->GetHadCorrEnergy()
206  << ")" << std::endl;
207 
208  TLorentzVector posvec;
209  clust->GetMomentum(posvec, fVertex);
210  posvec.SetE(energy); // use energy definition as selected in the task
211  et = posvec.Et();
212  eta = posvec.Eta();
213  phi = posvec.Phi();
214 
215  // fill histograms allEta
216  for(const auto & trg : fSelectedTriggers){
217  selpatches = nullptr;
218  if(trg.Contains("EJ2")) selpatches = &ej2patches;
219  if(trg.Contains("DJ2")) selpatches = &dj2patches;
220  if(trg.Contains("EJ1")) selpatches = &ej1patches;
221  if(trg.Contains("DJ1")) selpatches = &dj1patches;
222  if(trg.Contains("EG2")) selpatches = &eg2patches;
223  if(trg.Contains("DG2")) selpatches = &dg2patches;
224  if(trg.Contains("EG1")) selpatches = &eg1patches;
225  if(trg.Contains("DG1")) selpatches = &dg1patches;
226  FillClusterHistograms(trg.Data(), energy, et, eta, phi, clust->GetTOF(), nullptr);
227  }
228  }
229  return true;
230 }
231 
232 void AliAnalysisTaskEmcalClustersRef::FillClusterHistograms(const TString &triggerclass, double energy, double transverseenergy, double eta, double phi, double clustertime, TList *fTriggerPatches){
233  Bool_t hasTriggerPatch = fTriggerPatches ? CorrelateToTrigger(eta, phi, fTriggerPatches) : kFALSE;
234  Int_t supermoduleID = -1, sector = -1;
235  Double_t weight = GetTriggerWeight(triggerclass);
236  AliDebugStream(1) << GetName() << ": Using weight " << weight << " for trigger " << triggerclass << std::endl;
237 
238  fGeom->SuperModuleNumberFromEtaPhi(eta, phi, supermoduleID);
239  fHistos->FillTH1("hClusterEnergy" + triggerclass, energy, weight);
240  fHistos->FillTH1("hClusterET" + triggerclass, transverseenergy, weight);
241  fHistos->FillTH2("hEtaEnergy" + triggerclass, eta, energy, weight);
242  fHistos->FillTH2("hEtaET" + triggerclass, eta, transverseenergy, weight);
243  fHistos->FillTH2("hTimeEnergy" + triggerclass, clustertime, energy, weight);
244  if(supermoduleID >= 0){
245  fHistos->FillTH2("hClusterEnergySM" + triggerclass, supermoduleID, energy, weight);
246  fHistos->FillTH2("hClusterETSM" + triggerclass, supermoduleID, transverseenergy, weight);
247  fHistos->FillTH2(TString::Format("hEtaEnergySM%d", supermoduleID) + triggerclass, eta, energy, weight);
248  fHistos->FillTH2(TString::Format("hEtaETSM%d", supermoduleID) + triggerclass, eta, transverseenergy, weight);
249  if(supermoduleID < 12)
250  sector = 4 + int(supermoduleID/2); // EMCAL
251  else
252  sector = 13 + int((supermoduleID-12)/2); // DCAL
253  fHistos->FillTH2(TString::Format("hEtaEnergySec%d", sector) + triggerclass, eta, energy, weight);
254  fHistos->FillTH2(TString::Format("hEtaETSec%d", sector) + triggerclass, eta, transverseenergy, weight);
255  }
256  if(hasTriggerPatch){
257  fHistos->FillTH1("hClusterEnergyFired" + triggerclass, energy, weight);
258  fHistos->FillTH1("hClusterETFired" + triggerclass, energy, weight);
259  fHistos->FillTH2("hEtaEnergyFired" + triggerclass, eta, energy, weight);
260  fHistos->FillTH2("hEtaETFired" + triggerclass, eta, energy, weight);
261  if(supermoduleID >= 0){
262  fHistos->FillTH2("hClusterEnergyFiredSM" + triggerclass, supermoduleID, energy, weight);
263  fHistos->FillTH2("hClusterETFiredSM" + triggerclass, supermoduleID, transverseenergy, weight);
264  fHistos->FillTH2(TString::Format("hEtaEnergyFiredSM%d", supermoduleID) + triggerclass, eta, energy,weight);
265  fHistos->FillTH2(TString::Format("hEtaETFiredSM%d", supermoduleID) + triggerclass, eta, transverseenergy, weight);
266  fHistos->FillTH2(TString::Format("hEtaEnergyFiredSec%d", sector) + triggerclass, eta, energy, weight);
267  fHistos->FillTH2(TString::Format("hEtaETFiredSec%d", sector) + triggerclass, eta, transverseenergy, weight);
268  }
269  }
270  Double_t encuts[5] = {1., 2., 5., 10., 20.};
271  for(int ien = 0; ien < 5; ien++){
272  if(energy > encuts[ien]){
273  fHistos->FillTH2(TString::Format("hEtaPhi%dG", static_cast<int>(encuts[ien])) + triggerclass, eta, phi, weight);
274  if(hasTriggerPatch){
275  fHistos->FillTH2(TString::Format("hEtaPhiFired%dG", static_cast<int>(encuts[ien])) + triggerclass, eta, phi, weight);
276  }
277  }
278  }
279 }
280 
282  for(const auto &t : fSelectedTriggers){
283  Double_t weight = GetTriggerWeight(t);
284  fHistos->FillTH1("hEventCount" + t, 1, weight);
285  fHistos->FillTH1("hEventCentrality" + t, fEventCentrality, weight);
286  fHistos->FillTH1("hVertexZ" + t, fVertex[2], weight);
287  }
288 }
289 
291  Bool_t hasfound = kFALSE;
292  for(TIter patchIter = TIter(fTriggerPatches).Begin(); patchIter != TIter::End(); ++patchIter){
293  Double_t boundaries[4];
294  GetPatchBoundaries(*patchIter, boundaries);
295  Double_t etamin = TMath::Min(boundaries[0], boundaries[1]),
296  etamax = TMath::Max(boundaries[0], boundaries[1]),
297  phimin = TMath::Min(boundaries[2], boundaries[3]),
298  phimax = TMath::Max(boundaries[2], boundaries[3]);
299  if(etaclust > etamin && etaclust < etamax && phiclust > phimin && phiclust < phimax){
300  hasfound = kTRUE;
301  break;
302  }
303  }
304  return hasfound;
305 }
306 
307 void AliAnalysisTaskEmcalClustersRef::FindPatchesForTrigger(TString triggerclass, const TClonesArray * triggerPatches, TList &foundtriggers) const {
308  foundtriggers.Clear();
309  if(!triggerPatches) return;
311  if(triggerclass == "EG1") myclass = AliEmcalTriggerOfflineSelection::kTrgEG1;
312  if(triggerclass == "EG2") myclass = AliEmcalTriggerOfflineSelection::kTrgEG2;
313  if(triggerclass == "EJ1") myclass = AliEmcalTriggerOfflineSelection::kTrgEJ1;
314  if(triggerclass == "EJ2") myclass = AliEmcalTriggerOfflineSelection::kTrgEJ2;
315  if(triggerclass == "DMC7") myclass = AliEmcalTriggerOfflineSelection::kTrgDL0;
316  if(triggerclass == "DG1") myclass = AliEmcalTriggerOfflineSelection::kTrgDG1;
317  if(triggerclass == "DG2") myclass = AliEmcalTriggerOfflineSelection::kTrgDG2;
318  if(triggerclass == "DJ1") myclass = AliEmcalTriggerOfflineSelection::kTrgDJ1;
319  if(triggerclass == "DJ2") myclass = AliEmcalTriggerOfflineSelection::kTrgDJ2;
320  for(auto patchiter : *triggerPatches){
321  AliEMCALTriggerPatchInfo *mypatch = static_cast<AliEMCALTriggerPatchInfo *>(patchiter);
322  if(!mypatch->IsOfflineSimple()) continue;
324  if(!mypatch->IsDCalPHOS()) continue;
325  } else {
326  if(mypatch->IsDCalPHOS()) continue;
327  }
329  if(!mypatch->IsGammaLowSimple()) continue;
330  } else {
331  if(!mypatch->IsJetLowSimple()) continue;
332  }
333  double threshold = fTriggerSelection ? fTriggerSelection->GetThresholdForTrigger(myclass) : -1;
334  if(mypatch->GetPatchE() > threshold) foundtriggers.Add(patchiter);
335  }
336 }
337 
339  AliEMCALTriggerPatchInfo *patch= dynamic_cast<AliEMCALTriggerPatchInfo *>(o);
340  boundaries[0] = patch->GetEtaMin();
341  boundaries[1] = patch->GetEtaMax();
342  boundaries[2] = patch->GetPhiMin();
343  boundaries[3] = patch->GetPhiMax();
344 }
345 
347  AliAnalysisManager *mgr = AliAnalysisManager::GetAnalysisManager();
348 
349  //-------------------------------------------------------
350  // Init the task and do settings
351  //-------------------------------------------------------
352 
353  TString clusName(nclusters == "usedefault" ? AliEmcalAnalysisFactory::ClusterContainerNameFactory(mgr->GetInputEventHandler()->InheritsFrom("AliAODInputHandler")) : nclusters);
354 
355  TString taskname = "emcalClusterQA_" + suffix;
356 
358  task->AddClusterContainer(clusName);
359  task->SetClusterContainer(clusName);
360  mgr->AddTask(task);
361 
362  TString outfile(mgr->GetCommonFileName());
363  outfile += ":ClusterQA_" + TString(suffix);
364  TString containername = "ClusterResults_" + TString(suffix);
365  printf("Outfile: %s, container: %s\n", outfile.Data(), containername.Data());
366 
367  task->ConnectInput(0, mgr->GetCommonInputContainer());
368  mgr->ConnectOutput(task, 1, mgr->CreateContainer(containername.Data(), TList::Class(), AliAnalysisManager::kOutputContainer, outfile.Data()));
369 
370  return task;
371 }
372 
374  AliAnalysisManager *mgr = AliAnalysisManager::GetAnalysisManager();
375 
377  mgr->AddTask(task);
378 
379  // Adding cluster container
380  TString clusName(nClusters == "usedefault" ? AliEmcalAnalysisFactory::ClusterContainerNameFactory(mgr->GetInputEventHandler()->InheritsFrom("AliAODInputHandler")) : nClusters);
381  task->AddClusterContainer(clusName.Data());
382  task->SetClusterContainer(clusName);
383 
384  // Set Energy thresholds for additional patch selection:
385  // These are events with offline patches of a given type where the trigger reached already the plateau
386  // These numers are determined as:
387  // EMC7: 3.5 GeV
388  // EG1: 14 GeV
389  // EG2: 8 GeV
390  // EJ1: 22 GeV
391  // EJ2: 12 GeV
394  );
395 
396  TString outfile(mgr->GetCommonFileName());
397  outfile += ":ClusterQA";
398 
399  task->ConnectInput(0, mgr->GetCommonInputContainer());
400  mgr->ConnectOutput(task, 1, mgr->CreateContainer("ClusterResults", AliEmcalList::Class(), AliAnalysisManager::kOutputContainer, outfile.Data()));
401 
402  return task;
403 }
404 
405 
411 {
412  this->SetMinimum(0.);
413  this->AddStep(1, 0.05);
414  this->AddStep(2, 0.1);
415  this->AddStep(4, 0.2);
416  this->AddStep(7, 0.5);
417  this->AddStep(16, 1);
418  this->AddStep(32, 2);
419  this->AddStep(40, 4);
420  this->AddStep(50, 5);
421  this->AddStep(100, 10);
422  this->AddStep(200, 20);
423 }
424 
425 
426 } /* namespace EMCalTriggerPtAnalysis */
AliCutValueRange< double > fClusterTimeRange
Selected range on cluster time.
void GetPatchBoundaries(TObject *o, Double_t *boundaries) const
std::vector< TString > fSelectedTriggers
! Triggers selected for given event
double Double_t
Definition: External.C:58
Class creating a linear binning, used in the histogram manager.
Bool_t CorrelateToTrigger(Double_t etaclust, Double_t phiclust, TList *triggerpatches) const
static TString ClusterContainerNameFactory(Bool_t isAOD)
void FillTH2(const char *hname, double x, double y, double weight=1., Option_t *opt="")
Simple monitoring task for cluster-related quantities in EMCAL-triggered events.
AliEmcalTriggerOfflineSelection * fTriggerSelection
Offline trigger selection.
Bool_t fRequestCentrality
Switch on request for centrality range.
static AliEmcalTriggerOfflineSelection * TriggerSelectionFactory(Double_t el0, Double_t eg1, Double_t eg2, Double_t ej1, Double_t ej2, AliEmcalTriggerOfflineSelection::EmcalEnergyDefinition_t endef=AliEmcalTriggerOfflineSelection::kFEEEnergy)
void AddStep(Double_t max, Double_t binwidth)
void SetOfflineTriggerSelection(AliEmcalTriggerOfflineSelection *sel)
AliClusterContainer * AddClusterContainer(const char *n)
const Double_t etamin
TH2 * CreateTH2(const char *name, const char *title, int nbinsx, double xmin, double xmax, int nbinsy, double ymin, double ymax, Option_t *opt="")
TString fNameClusterContainer
Name of the cluster container in the event.
int Int_t
Definition: External.C:63
AliEMCALGeometry * fGeom
!emcal geometry
EmcalTriggerClass
Definition of the various supported trigger types.
TH1 * CreateTH1(const char *name, const char *title, int nbins, double xmin, double xmax, Option_t *opt="")
AliClusterContainer * GetClusterContainer(Int_t i=0) const
Helper class creating user defined custom binning.
static AliAnalysisTaskEmcalClustersRef * AddTaskEmcalClustersRef(const TString &nClusters="usedefault", const TString &suffix="")
void FillTH1(const char *hname, double x, double weight=1., Option_t *opt="")
TString fCentralityEstimator
Centrality estimator (default: V0M for PbPb)
energy
void FillClusterHistograms(const TString &triggerclass, double energy, double transversenergy, double eta, double phi, double clustertime, TList *triggerpatches)
static AliAnalysisTaskEmcalClustersRef * AddTaskEmcalClustersRefDefault(const TString &nClusters="usedefault")
ClassImp(AliAnalysisTaskCRC) AliAnalysisTaskCRC
Double_t fVertex[3]
!event vertex
AliCutValueRange< double > fCentralityRange
Selected centrality range.
const Double_t etamax
TClonesArray * fTriggerPatchInfo
!trigger patch info array
EnergyDefinition_t fEnergyDefinition
Energy definition used for a given cluster.
bool Bool_t
Definition: External.C:53
const Double_t phimin
void FindPatchesForTrigger(TString triggerclass, const TClonesArray *triggerpatches, TList &foundpatches) const
void SetMinimum(Double_t min)