AliPhysics  6cf2591 (6cf2591)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
AliAnalysisTaskEmcalTriggerBase.cxx
Go to the documentation of this file.
1 /**************************************************************************
2  * Copyright(c) 1998-2016, 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 <functional>
17 #include <iostream>
18 
19 #include <TClonesArray.h>
20 #include <TGrid.h>
21 #include <THistManager.h>
22 #include <TParameter.h>
23 
25 #include "AliAnalysisUtils.h"
26 #include "AliAODEvent.h"
27 #include "AliAODInputHandler.h"
29 #include "AliEMCALGeometry.h"
30 #include "AliEMCALTriggerPatchInfo.h"
31 #include "AliEMCALTriggerMapping.h"
32 #include "AliESDEvent.h"
33 #include "AliInputEventHandler.h"
34 #include "AliLog.h"
35 #include "AliOADBContainer.h"
36 #include "AliVVertex.h"
37 
41 
42 namespace EMCalTriggerPtAnalysis {
43 
44 AliAnalysisTaskEmcalTriggerBase::AliAnalysisTaskEmcalTriggerBase():
46  fTriggerSelection(nullptr),
47  fUseTriggerBits(kTRUE),
48  fRequireBunchCrossing(kTRUE),
49  fHistos(nullptr),
50  fTriggerStringFromPatches(kFALSE),
51  fSelectedTriggers(),
52  fNameClusterContainer(""),
53  fRequireAnalysisUtils(kTRUE),
54  fVertexCut(-10., 10.),
55  fNameDownscaleOADB(""),
56  fDownscaleOADB(nullptr),
57  fDownscaleFactors(nullptr),
58  fNameMaskedFastorOADB(),
59  fMaskedFastorOADB(nullptr),
60  fMaskedFastors(),
61  fOnlineTriggerThresholds(),
62  fNameAcceptanceOADB(),
63  fSelectNoiseEvents(false),
64  fRejectNoiseEvents(false),
65  fEnableDCALTriggers(true),
66  fExclusiveMinBias(false)
67 {
68  SetNeedEmcalGeom(true);
70  SetCaloTriggerPatchInfoName("EmcalTriggers");
71 }
72 
74  AliAnalysisTaskEmcal(name, true),
75  fTriggerSelection(nullptr),
76  fUseTriggerBits(kTRUE),
77  fRequireBunchCrossing(kTRUE),
78  fHistos(nullptr),
79  fTriggerStringFromPatches(kFALSE),
80  fSelectedTriggers(),
81  fNameClusterContainer(""),
82  fRequireAnalysisUtils(kTRUE),
83  fVertexCut(-10., 10.),
84  fNameDownscaleOADB(""),
85  fDownscaleOADB(nullptr),
86  fDownscaleFactors(nullptr),
87  fNameMaskedFastorOADB(),
88  fMaskedFastorOADB(nullptr),
89  fMaskedFastors(),
90  fOnlineTriggerThresholds(),
91  fNameAcceptanceOADB(),
92  fSelectNoiseEvents(false),
93  fRejectNoiseEvents(false),
94  fEnableDCALTriggers(true),
95  fExclusiveMinBias(false)
96 {
97  SetNeedEmcalGeom(true);
99  SetCaloTriggerPatchInfoName("EmcalTriggers");
100 }
101 
104  if(fHistos) delete fHistos;
105  if(fDownscaleOADB) delete fDownscaleOADB;
106 }
107 
110  if(fRequireAnalysisUtils && !fAliAnalysisUtils) fAliAnalysisUtils = new AliAnalysisUtils;
111 
112  if(!fNameClusterContainer.Length()) fNameClusterContainer = AliEmcalAnalysisFactory::ClusterContainerNameFactory(fInputHandler->IsA() == AliAODInputHandler::Class());
115  }
116 
117  fHistos = new THistManager(Form("Histos_%s", GetName()));
118 
121 
122  for(auto h : *(fHistos->GetListOfHistograms())) fOutput->Add(h);
123 
124  PostData(1, fOutput);
125 }
126 
128  // Apply trigger selection
130  if(!fSelectedTriggers.size()) return false;
131 
133 
134  const AliVVertex *vtx = fInputEvent->GetPrimaryVertex();
135  //if(!fInputEvent->IsPileupFromSPD(3, 0.8, 3., 2., 5.)) return; // reject pileup event
136  if(vtx->GetNContributors() < 1) return false;
137 
139  if(fInputEvent->IsA() == AliESDEvent::Class() && fAliAnalysisUtils->IsFirstEventInChunk(fInputEvent)) return false;
140  if(fAliAnalysisUtils->IsPileUpEvent(fInputEvent)) return false; // Apply new vertex cut
141  if(!fAliAnalysisUtils->IsVertexSelected2013pA(fInputEvent))return false; // Apply new vertex cut
142  }
143 
144  if(!fVertexCut.IsInRange(fVertex[2])) return false;
145  if(!IsUserEventSelected()) return false;
146 
147  // Do MC outlier cut
148  if(fIsPythia){
149  if(!CheckMCOutliers()){
150  AliDebugStream(1) << GetName() << ": Reject MC outliers" << std::endl;
151  return false;
152  }
153  }
154 
156  return true;
157 }
158 
159 
161  fSelectedTriggers.clear();
162  Bool_t isMC = MCEvent() != nullptr;
163 
164  TString triggerstring = "";
167  } else {
168  triggerstring = fInputEvent->GetFiredTriggerClasses();
169  }
170 
171 
172  UInt_t selectionstatus = fInputHandler->IsEventSelected();
173  Bool_t isMinBias = selectionstatus & AliVEvent::kINT7,
175 
176  if(fExclusiveMinBias){
177  // do not perform EMCAL trigger selection in case only
178  // min. bias trigger is requested:w
179  if(isMinBias) fSelectedTriggers.push_back("MB");
180  return;
181  }
182 
183  for(int itrg = 0; itrg < AliEmcalTriggerOfflineSelection::kTrgn; itrg++) emcalTriggers[itrg] = true;
184  if(!isMC){
185  // In case of data select events as bunch-bunch (-B-) events.
186  // Cut not applied in simulations
187  if(fRequireBunchCrossing && ! triggerstring.Contains("-B-")) return;
188 
189  // In case of data use information from the physics selection and event record
190  // Further cleanup of trigger events can be performed depending on the presence
191  // of recalc patches (after masking hot fastors in the trigger maker) above
192  // threshold
193  if(fUseTriggerBits){
194  const std::array<ULong_t, AliEmcalTriggerOfflineSelection::kTrgn> kSelectTriggerBits = {
195  AliVEvent::kEMC7, AliVEvent::kEMCEGA, AliVEvent::kEMCEGA, AliVEvent::kEMCEJE, AliVEvent::kEMCEJE,
196  AliVEvent::kEMC7, AliVEvent::kEMCEGA, AliVEvent::kEMCEGA, AliVEvent::kEMCEJE, AliVEvent::kEMCEJE,
197  };
198  for(int iclass = 0; iclass < AliEmcalTriggerOfflineSelection::kTrgn; iclass++)
199  emcalTriggers[iclass] &= bool(selectionstatus & kSelectTriggerBits[iclass]);
200  }
201 
202  // Apply cut on the trigger string - this basically discriminates high- and low-threshold
203  // triggers
204  const std::array<TString, AliEmcalTriggerOfflineSelection::kTrgn> kSelectTriggerStrings = {
205  "CEMC7", "EG1", "EG2", "EJ1", "EJ2", "CDMC7", "DG1", "DG2", "DJ1", "DJ2"
206  };
207  if(triggerstring.Contains("EMC")) AliDebugStream(1) << GetName() << ": Trigger string " << triggerstring << std::endl;
208  for(int iclass = 0; iclass < AliEmcalTriggerOfflineSelection::kTrgn; iclass++){
209  emcalTriggers[iclass] &= triggerstring.Contains(kSelectTriggerStrings[iclass]);
210  if(emcalTriggers[iclass])
211  AliDebugStream(1) << GetName() << ": Event selected as trigger " << kSelectTriggerStrings[iclass] << std::endl;
212  }
213 
214  // Online selection / rejection
216  if(fRejectNoiseEvents){
217  for(int itrg = 0; itrg < AliEmcalTriggerOfflineSelection::kTrgn; itrg++){
218  if(emcalTriggers[itrg])
220  }
221  } else {
222  for(int itrg = 0; itrg < AliEmcalTriggerOfflineSelection::kTrgn; itrg++){
223  if(emcalTriggers[itrg])
225  }
226  }
227  }
228  }
229  // Apply offline trigger selection: In this case cuts are performed on the
230  // patch energy from EMCAL cells after calibration. This method is most relevant
231  // for simulations. It can have a special use case in data in case a stronger
232  // offline selection is applied in addition to the online selection.
234  for(int itrg = 0; itrg < AliEmcalTriggerOfflineSelection::kTrgn; itrg++)
236  }
237  if(isMinBias) fSelectedTriggers.push_back("MB");
238  if(emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgEL0]){
239  fSelectedTriggers.push_back("EMC7");
240  if(!isMinBias) fSelectedTriggers.push_back("EMC7excl");
241  }
242  if(emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgEJ2]){
243  fSelectedTriggers.push_back("EJ2");
244  if(!(isMinBias || emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgEL0])) fSelectedTriggers.push_back("EJ2excl");
245  }
246  if(emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgEJ1]){
247  fSelectedTriggers.push_back("EJ1");
248  if(!(isMinBias || emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgEL0] || emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgEJ2])) fSelectedTriggers.push_back("EJ1excl");
249  }
250  if(emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgEG2]){
251  fSelectedTriggers.push_back("EG2");
252  if(!(isMinBias || emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgEL0])) fSelectedTriggers.push_back("EG2excl");
253  }
254  if(emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgEG1]){
255  fSelectedTriggers.push_back("EG1");
256  if(!(isMinBias || emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgEL0] || emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgEG2])) fSelectedTriggers.push_back("EG1excl");
257  }
258 
260  // Handle DCAL triggers only in case DCAL triggers are enabled,
261  // otherwise ignore results of the online/offline trigger selection
262  if(emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgDL0]){
263  fSelectedTriggers.push_back("DMC7");
264  if(!isMinBias) fSelectedTriggers.push_back("DMC7excl");
265  }
266  if(emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgDJ2]){
267  fSelectedTriggers.push_back("DJ2");
268  if(!(isMinBias || emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgDL0])) fSelectedTriggers.push_back("DJ2excl");
269  }
270  if(emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgDJ1]){
271  fSelectedTriggers.push_back("DJ1");
272  if(!(isMinBias || emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgDL0] || emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgDJ2])) fSelectedTriggers.push_back("DJ1excl");
273  }
274  if(emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgDG2]){
275  fSelectedTriggers.push_back("DG2");
276  if(!(isMinBias || emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgDL0])) fSelectedTriggers.push_back("DG2excl");
277  }
278  if(emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgDG1]){
279  fSelectedTriggers.push_back("DG1");
280  if(!(isMinBias || emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgDL0] || emcalTriggers[AliEmcalTriggerOfflineSelection::kTrgDG2])) fSelectedTriggers.push_back("DG1excl");
281  }
282  }
283 }
284 
287 
288  if(!fLocalInitialized){
289  return;
290  }
291 
292  // Handle OADB container with downscaling factors
293  if(fNameDownscaleOADB.Length()){
294  if(fNameDownscaleOADB.Contains("alien://") && ! gGrid) TGrid::Connect("alien://");
295  fDownscaleOADB = new AliOADBContainer("AliEmcalDownscaleFactors");
296  fDownscaleOADB->InitFromFile(fNameDownscaleOADB.Data(), "AliEmcalDownscaleFactors");
297  }
298 
299  if(!fExclusiveMinBias){
300  // Load EMCAL trigger OADB in case EMCAL triggers
301  // are enabled
302 
303  // Load OADB container with masked fastors (in case fastor masking is switched on)
305  if(fNameMaskedFastorOADB.Contains("alien://") && ! gGrid) TGrid::Connect("alien://");
306  fMaskedFastorOADB = new AliOADBContainer("AliEmcalMaskedFastors");
307  fMaskedFastorOADB->InitFromFile(fNameMaskedFastorOADB.Data(), "AliEmcalMaskedFastors");
308  }
309 
310  // Setting online threshold for trigger
312  if(fInputEvent->GetRunNumber() >= 15344 && fInputEvent->GetRunNumber() <= 197388){
317  SetOnlineTriggerThreshold("DG1", 0);
318  SetOnlineTriggerThreshold("DG2", 0);
319  SetOnlineTriggerThreshold("DJ1", 0);
320  SetOnlineTriggerThreshold("DJ2", 0);
321  SetOnlineTriggerThreshold("EMC7", 0);
322  SetOnlineTriggerThreshold("DMC7", 0);
323  }
324  }
325 
326  // Load acceptance OADB
327  if(fNameAcceptanceOADB.Length() && fTriggerSelection){
328  AliDebugStream(1) << GetName() << ": Loading acceptance map from OADB file " << fNameAcceptanceOADB << std::endl;
329  AliOADBContainer acceptanceCont("AliEmcalTriggerAcceptance");
330  acceptanceCont.InitFromFile(fNameAcceptanceOADB.Data(), "AliEmcalTriggerAcceptance");
331  TObjArray *acceptanceMaps = dynamic_cast<TObjArray *>(acceptanceCont.GetObject(fInputEvent->GetRunNumber()));
332  TH2 *map(nullptr);
333  if((map = dynamic_cast<TH2 *>(acceptanceMaps->FindObject("EG1")))){
334  AliDebugStream(1) << GetName() << ": Found acceptance map for trigger EG1" << std::endl;
335  map->SetDirectory(nullptr);
337  }
338  if((map = dynamic_cast<TH2 *>(acceptanceMaps->FindObject("EG2")))){
339  AliDebugStream(1) << GetName() << ": Found acceptance map for trigger EG2" << std::endl;
340  map->SetDirectory(nullptr);
342  }
343  if((map = dynamic_cast<TH2 *>(acceptanceMaps->FindObject("DG1")))){
344  AliDebugStream(1) << GetName() << ": Found acceptance map for trigger DG1" << std::endl;
345  map->SetDirectory(nullptr);
347  }
348  if((map = dynamic_cast<TH2 *>(acceptanceMaps->FindObject("DG2")))){
349  AliDebugStream(1) << GetName() << ": Found acceptance map for trigger DG2" << std::endl;
350  map->SetDirectory(nullptr);
352  }
353  if((map = dynamic_cast<TH2 *>(acceptanceMaps->FindObject("EJ1")))){
354  AliDebugStream(1) << GetName() << ": Found acceptance map for trigger EJ1" << std::endl;
355  map->SetDirectory(nullptr);
357  }
358  if((map = dynamic_cast<TH2 *>(acceptanceMaps->FindObject("EJ2")))){
359  AliDebugStream(1) << GetName() << ": Found acceptance map for trigger EJ2" << std::endl;
360  map->SetDirectory(nullptr);
362  }
363  if((map = dynamic_cast<TH2 *>(acceptanceMaps->FindObject("DJ1")))){
364  AliDebugStream(1) << GetName() << ": Found acceptance map for trigger DJ1" << std::endl;
365  map->SetDirectory(nullptr);
367  }
368  if((map = dynamic_cast<TH2 *>(acceptanceMaps->FindObject("DJ2")))){
369  AliDebugStream(1) << GetName() << ": Found acceptance map for trigger DJ2" << std::endl;
370  map->SetDirectory(nullptr);
372  }
373  }
374  }
375 }
376 
378  if(fDownscaleOADB){
379  fDownscaleFactors = static_cast<TObjArray *>(fDownscaleOADB->GetObject(runnumber));
380  }
381  if(!fExclusiveMinBias){
382  if(fMaskedFastorOADB){
383  fMaskedFastors.clear();
384  TObjArray *ids = static_cast<TObjArray *>(fMaskedFastorOADB->GetObject(runnumber));
385  for(auto m : *ids){
386  TParameter<int> *id = static_cast<TParameter<int> *>(m);
387  fMaskedFastors.push_back(id->GetVal());
388  }
389  }
390  }
391 }
392 
394  // Exclusive means classes without lower trigger classes (which are downscaled) -
395  // in order to make samples statistically independent: MBExcl means MinBias && !EMCAL trigger
396  std::vector<TString> triggers = {"MB"}; // Min. Bias always enabled
397  const std::array<TString, 10> emcaltriggers = {"EMC7", "EJ1", "EJ2", "EG1", "EG2", "EMC7excl", "EG2excl", "EJ2excl", "EJ1excl", "EG1excl"},
398  dcaltriggers = {"DMC7", "DJ1", "DJ2", "DG1", "DG2", "DMC7excl", "DG2excl", "DJ2excl", "DJ1excl", "DG1excl"};
399  if(!fExclusiveMinBias){
400  for(const auto &t : emcaltriggers) triggers.push_back(t);
401  }
403  for(const auto &t : dcaltriggers) triggers.push_back(t);
404  }
405  return triggers;
406 }
407 
409  AliDebugStream(1) << "Using V1 online trigger selector" << std::endl;
411  int ngood(0);
412  for(auto p : *fTriggerPatchInfo){
413  AliEMCALTriggerPatchInfo *patch = static_cast<AliEMCALTriggerPatchInfo *>(p);
414  if((AliEmcalTriggerOfflineSelection::IsSingleShower(trigger) && patch->IsGammaLowRecalc()) ||
415  (!AliEmcalTriggerOfflineSelection::IsSingleShower(trigger) && patch->IsJetLowRecalc())){
416  if(patch->GetADCAmp() >= GetOnlineTriggerThresholdByIndex(trigger)) ngood++;
417  }
418  }
419  return ngood > 0;
420 }
421 
423  if(fDownscaleFactors){
424  TParameter<double> *result(nullptr);
425  // Downscaling only done on MB, L0 and the low threshold triggers
426  if(triggerclass.Contains("MB")) result = static_cast<TParameter<double> *>(fDownscaleFactors->FindObject("INT7"));
427  else if(triggerclass.Contains("EMC7")) result = static_cast<TParameter<double> *>(fDownscaleFactors->FindObject("EMC7"));
428  else if(triggerclass.Contains("EJ2")) result = static_cast<TParameter<double> *>(fDownscaleFactors->FindObject("EJ2"));
429  else if(triggerclass.Contains("EG2")) result = static_cast<TParameter<double> *>(fDownscaleFactors->FindObject("EG2"));
430  if(result) return 1./result->GetVal();
431  }
432  return 1.;
433 }
434 
436  TParameter<int> *threshpar(nullptr);
437  if((threshpar = static_cast<TParameter<int> *>(fOnlineTriggerThresholds.FindObject(triggerclass.Data())))){
438  threshpar->SetVal(threshold);
439  } else {
440  fOnlineTriggerThresholds.Add(new TParameter<int>(triggerclass.Data(), threshold));
441  }
442 }
443 
445  Int_t threshold(0);
446  TParameter<int> *val(nullptr);
447  if((val = static_cast<TParameter<int> *>(fOnlineTriggerThresholds.FindObject(name))))
448  threshold = val->GetVal();
449  return threshold;
450 }
451 
453  const TString triggernames[AliEmcalTriggerOfflineSelection::kTrgn] = {"EMC7", "EG1", "EG2", "EJ1", "EJ2", "DMC7",
454  "DG1", "DG2", "DJ1", "DJ2"};
455  return GetOnlineTriggerThresholdByName(triggernames[trigger]);
456 }
457 
459  const TString triggernames[AliEmcalTriggerOfflineSelection::kTrgn] = {"EMC7", "EG1", "EG2", "EJ1", "EJ2", "DMC7",
460  "DG1", "DG2", "DJ1", "DJ2"};
461  bool isInitialized = true;
462  for(int itrg = 0; itrg < AliEmcalTriggerOfflineSelection::kTrgn; itrg++){
463  if(!fOnlineTriggerThresholds.FindObject(triggernames[itrg].Data())) {
464  isInitialized = false;
465  break;
466  }
467  }
468  return isInitialized;
469 }
470 
472  return adc > GetOnlineTriggerThresholdByName(triggerclass);
473 }
474 
476  TString triggerstring = "";
477  Int_t nEJ1 = 0, nEJ2 = 0, nEG1 = 0, nEG2 = 0, nDJ1 = 0, nDJ2 = 0, nDG1 = 0, nDG2 = 0;
478  for(auto patchIter : *triggerpatches){
479  AliEMCALTriggerPatchInfo *patch = dynamic_cast<AliEMCALTriggerPatchInfo *>(patchIter);
480  if(!patch->IsRecalc()) continue;
481  if(patch->IsEMCal()){
482  if(patch->IsGammaLowRecalc() && SelectFiredPatch("EG1", patch->GetADCAmp())) nEG1++;
483  if(patch->IsGammaLowRecalc() && SelectFiredPatch("EG2", patch->GetADCAmp())) nEG2++;
484  if(patch->IsJetLowRecalc() && SelectFiredPatch("EJ1", patch->GetADCAmp())) nEJ1++;
485  if(patch->IsJetLowRecalc() && SelectFiredPatch("EJ2", patch->GetADCAmp())) nEJ2++;
486  } else {
487  if(patch->IsGammaLowRecalc() && SelectFiredPatch("DG1", patch->GetADCAmp())) nDG1++;
488  if(patch->IsGammaLowRecalc() && SelectFiredPatch("DG2", patch->GetADCAmp())) nDG2++;
489  if(patch->IsJetLowRecalc() && SelectFiredPatch("DJ1", patch->GetADCAmp())) nDJ1++;
490  if(patch->IsJetLowRecalc() && SelectFiredPatch("DJ2", patch->GetADCAmp())) nDJ2++;
491  }
492  }
493  if(nEJ1) triggerstring += "EJ1";
494  if(nEJ2){
495  if(triggerstring.Length()) triggerstring += ",";
496  triggerstring += "EJ2";
497  }
498  if(nEG1){
499  if(triggerstring.Length()) triggerstring += ",";
500  triggerstring += "EG1";
501  }
502  if(nEG2){
503  if(triggerstring.Length()) triggerstring += ",";
504  triggerstring += "EG2";
505  }
506  if(nDJ1){
507  if(triggerstring.Length()) triggerstring += ",";
508  triggerstring += "DJ2";
509  }
510  if(nDJ2){
511  if(triggerstring.Length()) triggerstring += ",";
512  triggerstring += "DJ2";
513  }
514  if(nDG1){
515  if(triggerstring.Length()) triggerstring += ",";
516  triggerstring += "DG1";
517  }
518  if(nDG2){
519  if(triggerstring.Length()) triggerstring += ",";
520  triggerstring += "DG2";
521  }
522  return triggerstring;
523 }
524 
525 } /* namespace EMCalTriggerPtAnalysis */
std::vector< TString > fSelectedTriggers
! Triggers selected for given event
Bool_t IsOfflineSelected(EmcalTriggerClass trgcls, const AliVEvent *const data) const
Select event as triggered event.
Bool_t fIsPythia
trigger, if it is a PYTHIA production
double Double_t
Definition: External.C:58
Int_t GetOnlineTriggerThresholdByIndex(AliEmcalTriggerOfflineSelection::EmcalTriggerClass trg) const
Bool_t fRejectNoiseEvents
Reject events triggered by noisy fastors.
Base task in the EMCAL framework.
void SetOnlineTriggerThreshold(const TString &triggerclass, Int_t threshold)
Bool_t fLocalInitialized
whether or not the task has been already initialized
TString GetFiredTriggerClassesFromPatches(const TClonesArray *triggerpatches) const
AliEmcalTriggerOfflineSelection * fTriggerSelection
Offline trigger selection.
TObjArray fOnlineTriggerThresholds
Trigger thresholds applied at online level.
Bool_t fEnableDCALTriggers
Enable / Disable event selection for DCAL trigger classes.
void SetCaloTriggerPatchInfoName(const char *n)
TString fNameMaskedFastorOADB
Name of the masked fastor OADB container.
Bool_t fRequireAnalysisUtils
Switch whether to require event selection in AliAnalysisUtils.
bool SelectOnlineTrigger(AliEmcalTriggerOfflineSelection::EmcalTriggerClass trigger) const
Bool_t fRequireBunchCrossing
Require bunch-bunch events (tag -B- in trigger string)
void SetAcceptanceMap(EmcalTriggerClass trgcls, const TH2 *accmap)
Set acceptance map for a given trigger class.
int Int_t
Definition: External.C:63
TString fNameClusterContainer
Name of the cluster container in the event.
unsigned int UInt_t
Definition: External.C:33
THashList * GetListOfHistograms() const
Definition: THistManager.h:504
EmcalTriggerClass
Definition of the various supported trigger types.
AliAnalysisUtils * fAliAnalysisUtils
!vertex selection (optional)
TString fNameDownscaleOADB
Name of the downscale OADB container.
static Bool_t IsSingleShower(EmcalTriggerClass cls)
Checks if the trigger class is a single shower patch trigger class.
TString fNameAcceptanceOADB
Name of the OADB container with the trigger acceptance.
const TString & GetNameClusterContainer() const
Get the name of the cluster container.
AliOADBContainer * fMaskedFastorOADB
! Container with masked fastors
Bool_t fSelectNoiseEvents
Explicitly select events triggered only by noisy fastors.
Bool_t fUseTriggerBits
Switch whether using trigger bits (relies on physics selection)
Bool_t fTriggerStringFromPatches
Do rebuild the trigger string from trigger patches.
Bool_t isMC
AliEmcalList * fOutput
!output list
Definition: External.C:220
AliOADBContainer * fDownscaleOADB
! Container with downscale factors for different triggers
ClassImp(AliAnalysisTaskCRC) AliAnalysisTaskCRC
Double_t fVertex[3]
!event vertex
void SetMakeGeneralHistograms(Bool_t g)
TClonesArray * fTriggerPatchInfo
!trigger patch info array
void SetNeedEmcalGeom(Bool_t n)
Container class for histograms.
Definition: THistManager.h:43
AliCutValueRange< double > fVertexCut
Cut on the z-position of the primary vertex.
bool Bool_t
Definition: External.C:53
Bool_t SelectFiredPatch(const TString &triggerclass, Int_t adc) const
static TString ClusterContainerNameFactory(Bool_t isAOD)
Get name of the default cluster container.