ATLAS Offline Software
Public Member Functions | Private Member Functions | Private Attributes | List of all members
LVL1::RecEmTauRoI Class Reference

This class defines the reconstructed em/tau hadron ROI. More...

#include <RecEmTauRoI.h>

Inheritance diagram for LVL1::RecEmTauRoI:
Collaboration diagram for LVL1::RecEmTauRoI:

Public Member Functions

 RecEmTauRoI ()
 
 RecEmTauRoI (unsigned int RoIWord, const std::vector< TrigConf::TriggerThreshold * > *caloThresholds)
 constructor using Run 1+2 configuration More...
 
 RecEmTauRoI (unsigned int RoIWord, const TrigConf::L1Menu *const l1menu)
 constructor using Run 3 configuration More...
 
 RecEmTauRoI (const RecEmTauRoI &obj)
 
RecEmTauRoIoperator= (const RecEmTauRoI &obj)
 
 ~RecEmTauRoI ()
 
virtual unsigned int roiWord () const
 returns roi word More...
 
virtual double phi () const
 returns phi coord of ROI More...
 
virtual double eta () const
 returns eta coord of ROI More...
 
virtual unsigned int crate () const
 returns CP crate number More...
 
virtual unsigned int module () const
 returns CPM number More...
 
virtual unsigned int fpga () const
 returns FPGA number More...
 
virtual unsigned int localcoord () const
 returns local coordinate within FPGA More...
 
virtual unsigned int et () const
 returns roi ET (Run 2 only) More...
 
virtual unsigned int isolation () const
 returns roi isolation results (Run 2 only) More...
 
virtual TrigT1CaloDefs::RoIType roiType () const
 returns roi type (EM = TrigT1CaloDefs::EMRoIWordType, Tau = TrigT1CaloDefs::TauRoIWordType, Run 1 = TrigT1CaloDefs::CpRoIWordType) More...
 
bool passedThreshold (unsigned int threshold_number) const
 returns TRUE if threshold number threshold_number has been passed by this ROI. More...
 
CoordinateRange coord () const
 returns the CoordinateRange. More...
 
std::vector< unsigned int > * thresholdsPassed () const
 returns a vector of thresholds passed. More...
 
unsigned int thresholdPattern () const
 returns bitmask of passed thresholds More...
 
unsigned int triggerThreshold (unsigned int thresh) const
 returns the value of the trigger threshold for the threshold passed. More...
 
unsigned int emIsolation (unsigned int thresh) const
 returns the value of the em isolation ring for the threshold passed. More...
 
unsigned int hadIsolation (unsigned int thresh) const
 returns the value of the hadronic layer isolation ring for the threshold passed. More...
 
unsigned int hadCoreIsolation (unsigned int thresh) const
 returns the value of the hadronic layer core isolation for the threshold passed. More...
 
unsigned int isolationMask (unsigned int thresh) const
 returns the isolation bits required for the threshold passed (Run 2) More...
 
bool isValidThreshold (unsigned int thresh) const
 returns true if thresh is a valid threshold number More...
 
TrigT1CaloDefs::ClusterAlgorithm thresholdType (unsigned int thresh) const
 returns the type of the threshold, which is either EMAlg or TauAlg. More...
 

Private Member Functions

void constructRun1 (const std::vector< TrigConf::TriggerThreshold * > *caloThresholds)
 The "construct" call unpacks the RoIWord and copies information about the passed thresholds from the vector of TriggerThresholds into maps for later retrieval. More...
 
void constructRun2 (const std::vector< TrigConf::TriggerThreshold * > *caloThresholds)
 Content of RoI word different in Run 2. More...
 
void constructRun3 (const TrigConf::L1Menu *const l1menu)
 

Private Attributes

unsigned long int m_roiWord { 0 }
 this is the actual format of the data sent from the LVL1 hardware. More...
 
CPRoIDecoderm_decoder {nullptr}
 Used for decoding RoI word. More...
 
TrigT1CaloDefs::RoIType m_type {TrigT1CaloDefs::RoIWordTypeError}
 Stored properties of the RoI: More...
 
CoordinateRange m_coordRange
 this contains the coordinate range worked out from the RoIWord hardware coord (i.e. More...
 
unsigned long int m_thresholdMask { 0 }
 
std::map< int, unsigned int > m_triggerThresholdValue
 
std::map< int, unsigned int > m_isolationMask
 
std::map< int, unsigned int > m_emIsolation
 
std::map< int, unsigned int > m_hadIsolation
 
std::map< int, unsigned int > m_hadCoreIsolation
 
std::map< int, TrigT1CaloDefs::ClusterAlgorithmm_thresholdType
 

Detailed Description

This class defines the reconstructed em/tau hadron ROI.

It is generated from the Slink output of TrigT1Calo

Author
Edward Moyse

Definition at line 44 of file RecEmTauRoI.h.

Constructor & Destructor Documentation

◆ RecEmTauRoI() [1/4]

LVL1::RecEmTauRoI::RecEmTauRoI ( )
inline

Definition at line 48 of file RecEmTauRoI.h.

48 {}

◆ RecEmTauRoI() [2/4]

LVL1::RecEmTauRoI::RecEmTauRoI ( unsigned int  RoIWord,
const std::vector< TrigConf::TriggerThreshold * > *  caloThresholds 
)

constructor using Run 1+2 configuration

The constructor doesn't do much - all the work is in the "construct" method.

Definition at line 33 of file RecEmTauRoI.cxx.

35  : m_roiWord(RoIWord),
36  m_decoder(new CPRoIDecoder()),
39 {
41  this->constructRun1(caloThresholds);
42  }
45  {
46  this->constructRun2(caloThresholds);
47  }
48  else
49  {
50  m_thresholdMask = 0;
52  m_isolationMask.clear();
53  m_emIsolation.clear();
54  m_hadIsolation.clear();
55  m_hadCoreIsolation.clear();
56  m_thresholdType.clear();
57  }
58 }

◆ RecEmTauRoI() [3/4]

LVL1::RecEmTauRoI::RecEmTauRoI ( unsigned int  RoIWord,
const TrigConf::L1Menu *const  l1menu 
)

constructor using Run 3 configuration

Definition at line 60 of file RecEmTauRoI.cxx.

61  :
62  m_roiWord(RoIWord),
63  m_decoder(new CPRoIDecoder()),
66 {
68 }

◆ RecEmTauRoI() [4/4]

LVL1::RecEmTauRoI::RecEmTauRoI ( const RecEmTauRoI obj)

Definition at line 71 of file RecEmTauRoI.cxx.

71  :
72  m_roiWord{obj.m_roiWord},
73  m_decoder{new CPRoIDecoder()},
74  m_type{obj.m_type},
75  m_coordRange{obj.m_coordRange},
76  m_thresholdMask{obj.m_thresholdMask},
77  m_triggerThresholdValue{obj.m_triggerThresholdValue},
78  m_isolationMask{obj.m_isolationMask},
79  m_emIsolation{obj.m_emIsolation},
80  m_hadIsolation{obj.m_hadIsolation},
81  m_hadCoreIsolation{obj.m_hadCoreIsolation},
82  m_thresholdType{obj.m_thresholdType}
83 {}

◆ ~RecEmTauRoI()

LVL1::RecEmTauRoI::~RecEmTauRoI ( )

Definition at line 106 of file RecEmTauRoI.cxx.

106  {
107  delete m_decoder;
108 }

Member Function Documentation

◆ constructRun1()

void LVL1::RecEmTauRoI::constructRun1 ( const std::vector< TrigConf::TriggerThreshold * > *  caloThresholds)
private

The "construct" call unpacks the RoIWord and copies information about the passed thresholds from the vector of TriggerThresholds into maps for later retrieval.

One warning here: the methods of the RecRoI classes assume threshold numbering starts at 1, rather than 0 in the calorimeter trigger simulation and Lvl1ConfigSvc. Hence the odd "-1" in a couple of places in this class

Definition at line 120 of file RecEmTauRoI.cxx.

122 {
123 
124  m_thresholdMask = m_roiWord & 0xffff;
125 
126  m_triggerThresholdValue.clear();
127  m_isolationMask.clear();
128  m_emIsolation.clear();
129  m_hadIsolation.clear();
130  m_hadCoreIsolation.clear();
131  m_thresholdType.clear();
132 
133  const vector<unsigned int> passed_thresholds =
135 
136  // Copy the thresholds into a map - makes matching up the passed ones very easy
137  std::map<int, TriggerThreshold *> thrMap;
138 
139  for (std::vector<TriggerThreshold *>::const_iterator it =
140  caloThresholds->begin();
141  it != caloThresholds->end(); ++it)
142  {
143  if ((*it)->type() == L1DataDef::emType() ||
144  (*it)->type() == L1DataDef::tauType())
145  {
146  int num = (*it)->thresholdNumber();
147  thrMap.insert(std::map<int, TriggerThreshold *>::value_type(num, (*it)));
148  }
149  }
150 
151  //
152  // Extract the properties of the passed thresholds:
153  //
154 
155  int ieta = int((m_coordRange.etaRange().min() + 0.025) / 0.1) +
156  ((m_coordRange.etaRange().min() + 0.025 > 0) ? 0 : -1);
157  int iphi = int((m_coordRange.phiRange().min() + 0.025) * 32 / M_PI);
158 
159  for (vector<unsigned int>::const_iterator itp = passed_thresholds.begin();
160  itp != passed_thresholds.end(); ++itp)
161  {
162  std::map<int, TriggerThreshold *>::const_iterator thr =
163  thrMap.find(*itp - 1);
164  if (thr != thrMap.end())
165  {
166  TriggerThresholdValue *ttv =
167  thr->second->triggerThresholdValue(ieta, iphi);
168  ClusterThresholdValue *ctv = dynamic_cast<ClusterThresholdValue *>(ttv);
169  if (ctv)
170  {
171  m_triggerThresholdValue.insert(std::map<int, unsigned int>::value_type(
172  *itp, ctv->thresholdValueCount()));
173  m_emIsolation.insert(std::map<int, unsigned int>::value_type(
174  *itp, ctv->emIsolationCount()));
175  m_hadIsolation.insert(std::map<int, unsigned int>::value_type(
176  *itp, ctv->hadIsolationCount()));
177  m_hadCoreIsolation.insert(
178  std::map<int, unsigned int>::value_type(*itp, ctv->hadVetoCount()));
180  ((ctv->type() == L1DataDef::emType()) ? TrigT1CaloDefs::EMAlg
182  m_thresholdType.insert(
183  std::map<int, TrigT1CaloDefs::ClusterAlgorithm>::value_type(*itp,
184  type));
185  }
186  } // end "found threshold in map"
187  } // end loop through passed thresholds
188 
189  return;
190 }

◆ constructRun2()

void LVL1::RecEmTauRoI::constructRun2 ( const std::vector< TrigConf::TriggerThreshold * > *  caloThresholds)
private

Content of RoI word different in Run 2.

To obtain thresholds passed need to simulate thresholding. Hence have an alternate constructor here

Definition at line 196 of file RecEmTauRoI.cxx.

197 {
198 
199  m_thresholdMask = 0;
200  m_triggerThresholdValue.clear();
201  m_isolationMask.clear();
202  m_emIsolation.clear();
203  m_hadIsolation.clear();
204  m_hadCoreIsolation.clear();
205  m_thresholdType.clear();
206 
207  std::string triggerType =
208  (m_type == TrigT1CaloDefs::EMRoIWordType ? L1DataDef::emType()
209  : L1DataDef::tauType());
210 
211  int ieta = int((m_coordRange.etaRange().min() + 0.025) / 0.1) +
212  ((m_coordRange.etaRange().min() + 0.025 > 0) ? 0 : -1);
213  int iphi = int((m_coordRange.phiRange().min() + 0.025) * 32 / M_PI);
214 
215  unsigned int isolWord = isolation();
216 
217  // Iterate through vector of thresholds and see which ones this RoI satisfies
218  for (std::vector<TriggerThreshold *>::const_iterator it =
219  caloThresholds->begin();
220  it != caloThresholds->end(); ++it) {
221  if ((*it)->type() == triggerType) {
222  // Does it satisfy this one?
223  // Start by extracting threshold values
224  TriggerThresholdValue *ttv = (*it)->triggerThresholdValue(ieta, iphi);
225  ClusterThresholdValue *ctv = dynamic_cast<ClusterThresholdValue *>(ttv);
226  if (ctv) {
227  float scale = ctv->caloInfo().globalEmScale();
228  unsigned int etCut = ctv->ptcut();
229  unsigned int threshold = etCut * scale;
230  unsigned int isolMask = ctv->isolationMask();
231 
232  bool isolationPassed = true;
233  for (unsigned int bit = 0; bit < TrigT1CaloDefs::numOfIsolationBits;
234  ++bit)
235  if ((isolMask & (1 << bit)) && !(isolWord & (1 << bit)))
236  isolationPassed = false;
237 
238  if (et() > threshold && isolationPassed) {
239  int num = (*it)->thresholdNumber();
241  std::map<int, unsigned int>::value_type(num, etCut));
242  m_isolationMask.insert(
243  std::map<int, unsigned int>::value_type(num, isolMask));
245  ((ctv->type() == L1DataDef::emType()) ? TrigT1CaloDefs::EMAlg
247  m_thresholdType.insert(
248  std::map<int, TrigT1CaloDefs::ClusterAlgorithm>::value_type(
249  num, type));
250  m_thresholdMask |= (1 << num);
251  } // passes cuts
252  } // ClusterThresholdValue pointer valid
253  } // correct threshold type
254  } // Loop over thresholds
255 }

◆ constructRun3()

void LVL1::RecEmTauRoI::constructRun3 ( const TrigConf::L1Menu *const  l1menu)
private

Definition at line 257 of file RecEmTauRoI.cxx.

258 {
259  m_thresholdMask = 0;
260  m_triggerThresholdValue.clear();
261  m_isolationMask.clear();
262  m_emIsolation.clear();
263  m_hadIsolation.clear();
264  m_hadCoreIsolation.clear();
265  m_thresholdType.clear();
266 
267  std::string triggerType = (m_type == TrigT1CaloDefs::EMRoIWordType ? "EM" : "TAU");
268 
269  // get the integer eta value
270  // eta value of ROIs goes in steps of 0.1 and on the negative side 1 is subtracted to avoid overlap at 0
271  // (copied from constructRun2)
272  int ieta = int((m_coordRange.etaRange().min() + 0.025) / 0.1) +
273  ((m_coordRange.etaRange().min() + 0.025 > 0) ? 0 : -1);
274 
275  unsigned int isolWord = RecEmTauRoI::isolation();
276 
277  // Iterate through the configured thresholds and see which ones this RoI satisfies
278  for (const shared_ptr<TrigConf::L1Threshold> &thr : l1menu->thresholds(triggerType))
279  {
280  // Start by extracting threshold values
281  auto caloThr = dynamic_cast<TrigConf::L1Threshold_Calo*>(thr.get());
282  if (!caloThr)
283  {
284  continue;
285  }
286 
287  // test eT
288  unsigned int etCut = std::round(caloThr->thrValue(ieta)); // threshold value in GeV (integer for legacy thr)
289  unsigned int etCounts = caloThr->thrValueCounts(ieta); // threshold counts (threshold value * emscale)
290  bool eTPassed = (RecEmTauRoI::et() > etCounts);
291 
292  // test isolation
293  unsigned int isolMask = 0;
294  if (triggerType == "EM")
295  {
296  auto emThr = dynamic_cast<TrigConf::L1Threshold_EM*>(thr.get());
297  if (emThr)
298  {
299  isolMask = emThr->isolationMask(ieta);
300  }
301  }
302  else if (triggerType == "TAU")
303  {
304  auto tauThr = dynamic_cast<TrigConf::L1Threshold_TAU*>(thr.get());
305  if (tauThr)
306  {
307  isolMask = tauThr->isolationMask();
308  }
309  }
310  bool isolationPassed = true;
311  for (unsigned int bit = 0; bit < TrigT1CaloDefs::numOfIsolationBits; ++bit)
312  {
313  if ((isolMask & (1 << bit)) && !(isolWord & (1 << bit)))
314  {
315  isolationPassed = false;
316  }
317  }
318 
319  if (eTPassed && isolationPassed)
320  {
321  int num = thr->mapping();
322  m_triggerThresholdValue[num] = etCut;
323  m_isolationMask[num] = isolMask;
325  m_thresholdMask |= (1 << num);
326  } // passes cuts
327  } // Loop over thresholds
328 }

◆ coord()

LVL1::CoordinateRange LVL1::RecEmTauRoI::coord ( ) const

returns the CoordinateRange.

This is worked out from the RoIWord's hardware coords (i.e. crate number, CPM number etc.) by the RoIDecoder class.

Definition at line 393 of file RecEmTauRoI.cxx.

393 { return m_coordRange; }

◆ crate()

unsigned int LVL1::RecEmTauRoI::crate ( ) const
virtual

returns CP crate number

returns crate number of ROI

Definition at line 346 of file RecEmTauRoI.cxx.

346 { return m_decoder->crate(m_roiWord); }

◆ emIsolation()

unsigned int LVL1::RecEmTauRoI::emIsolation ( unsigned int  thresh) const

returns the value of the em isolation ring for the threshold passed.

(Run 1)

(Run 1 only)

Definition at line 449 of file RecEmTauRoI.cxx.

450 {
451 
453  return 0;
454 
455  std::map<int, unsigned int>::const_iterator it = m_emIsolation.find(thresh);
456  if (it != m_emIsolation.end())
457  {
458  return (it->second);
459  }
460  return TrigT1CaloDefs::Error;
461 }

◆ et()

unsigned int LVL1::RecEmTauRoI::et ( ) const
virtual

returns roi ET (Run 2 only)

returns cluster ET of Run 2 RoI

Definition at line 364 of file RecEmTauRoI.cxx.

364 { return m_decoder->et(m_roiWord); }

◆ eta()

double LVL1::RecEmTauRoI::eta ( ) const
virtual

returns eta coord of ROI

Implements iRecCoordRoI.

Definition at line 343 of file RecEmTauRoI.cxx.

343 { return m_coordRange.eta(); }

◆ fpga()

unsigned int LVL1::RecEmTauRoI::fpga ( ) const
virtual

returns FPGA number

returns FPGA number of ROI

Definition at line 355 of file RecEmTauRoI.cxx.

355 { return m_decoder->chip(m_roiWord); }

◆ hadCoreIsolation()

unsigned int LVL1::RecEmTauRoI::hadCoreIsolation ( unsigned int  thresh) const

returns the value of the hadronic layer core isolation for the threshold passed.

(Run 1)

(Run 1 only)

Definition at line 480 of file RecEmTauRoI.cxx.

481 {
482 
484  return 0;
485 
486  map<int, unsigned int>::const_iterator it = m_hadCoreIsolation.find(thresh);
487  if (it != m_hadCoreIsolation.end())
488  {
489  return (it->second);
490  }
491  return TrigT1CaloDefs::Error;
492 }

◆ hadIsolation()

unsigned int LVL1::RecEmTauRoI::hadIsolation ( unsigned int  thresh) const

returns the value of the hadronic layer isolation ring for the threshold passed.

(Run 1)

(Run 1 only)

Definition at line 465 of file RecEmTauRoI.cxx.

466 {
468  return 0;
469 
470  map<int, unsigned int>::const_iterator it = m_hadIsolation.find(thresh);
471  if (it != m_hadIsolation.end())
472  {
473  return (it->second);
474  }
475  return TrigT1CaloDefs::Error;
476 }

◆ isolation()

unsigned int LVL1::RecEmTauRoI::isolation ( ) const
virtual

returns roi isolation results (Run 2 only)

returns isolation word of Run 2 RoI

Definition at line 367 of file RecEmTauRoI.cxx.

368 {
369 
371 }

◆ isolationMask()

unsigned int LVL1::RecEmTauRoI::isolationMask ( unsigned int  thresh) const

returns the isolation bits required for the threshold passed (Run 2)

returns the value of the isolation mask for the threshold passed.

(Run 2 only)

Definition at line 433 of file RecEmTauRoI.cxx.

434 {
435 
437  return 0;
438 
439  std::map<int, unsigned int>::const_iterator it = m_isolationMask.find(thresh);
440  if (it != m_isolationMask.end())
441  {
442  return (it->second);
443  }
444  return TrigT1CaloDefs::Error;
445 }

◆ isValidThreshold()

bool LVL1::RecEmTauRoI::isValidThreshold ( unsigned int  thresh) const

returns true if thresh is a valid threshold number

Definition at line 495 of file RecEmTauRoI.cxx.

496 {
498  {
500  }
502  {
504  }
506  {
508  }
509  return false;
510 }

◆ localcoord()

unsigned int LVL1::RecEmTauRoI::localcoord ( ) const
virtual

returns local coordinate within FPGA

returns local coordinate of ROI

Definition at line 358 of file RecEmTauRoI.cxx.

359 {
360  return m_decoder->localcoord(m_roiWord);
361 }

◆ module()

unsigned int LVL1::RecEmTauRoI::module ( ) const
virtual

returns CPM number

returns module number of ROI

Definition at line 349 of file RecEmTauRoI.cxx.

350 {
351  return m_decoder->module(m_roiWord);
352 }

◆ operator=()

LVL1::RecEmTauRoI & LVL1::RecEmTauRoI::operator= ( const RecEmTauRoI obj)

Definition at line 87 of file RecEmTauRoI.cxx.

88 {
89  if(this != &rhs) {
90  m_roiWord = rhs.m_roiWord;
91  delete m_decoder;
92  m_decoder = new CPRoIDecoder();
93  m_type = rhs.m_type;
94  m_coordRange = rhs.m_coordRange;
95  m_thresholdMask = rhs.m_thresholdMask;
96  m_triggerThresholdValue = rhs.m_triggerThresholdValue;
97  m_isolationMask = rhs.m_isolationMask;
98  m_emIsolation = rhs.m_emIsolation;
99  m_hadIsolation = rhs.m_hadIsolation;
100  m_hadCoreIsolation = rhs.m_hadCoreIsolation;
101  m_thresholdType = rhs.m_thresholdType;
102  }
103  return *this;
104 }

◆ passedThreshold()

bool LVL1::RecEmTauRoI::passedThreshold ( unsigned int  threshold_number) const

returns TRUE if threshold number threshold_number has been passed by this ROI.

Definition at line 382 of file RecEmTauRoI.cxx.

383 {
384  if (this->isValidThreshold(threshold_number)) {
385  return ((1 << threshold_number) & m_thresholdMask) != 0;
386  }
387  return false;
388 }

◆ phi()

double LVL1::RecEmTauRoI::phi ( ) const
virtual

returns phi coord of ROI

Implements iRecCoordRoI.

Definition at line 333 of file RecEmTauRoI.cxx.

334 {
335 
336  double roiPhi = m_coordRange.phi();
337  if (roiPhi > M_PI)
338  roiPhi -= 2 * M_PI;
339  return roiPhi;
340 }

◆ roiType()

LVL1::TrigT1CaloDefs::RoIType LVL1::RecEmTauRoI::roiType ( ) const
virtual

returns roi type (EM = TrigT1CaloDefs::EMRoIWordType, Tau = TrigT1CaloDefs::TauRoIWordType, Run 1 = TrigT1CaloDefs::CpRoIWordType)

returns type of RoI

Definition at line 378 of file RecEmTauRoI.cxx.

378 { return m_type; }

◆ roiWord()

unsigned int LVL1::RecEmTauRoI::roiWord ( ) const
virtual

returns roi word

Implements iRecCoordRoI.

Definition at line 330 of file RecEmTauRoI.cxx.

330 { return m_roiWord; }

◆ thresholdPattern()

unsigned int LVL1::RecEmTauRoI::thresholdPattern ( ) const

returns bitmask of passed thresholds

returns bitmask of thresholds passed by RoI

Definition at line 374 of file RecEmTauRoI.cxx.

374 { return m_thresholdMask; }

◆ thresholdsPassed()

std::vector< unsigned int > * LVL1::RecEmTauRoI::thresholdsPassed ( ) const

returns a vector of thresholds passed.

Definition at line 397 of file RecEmTauRoI.cxx.

398 {
399  std::vector<unsigned int> *newVec = new std::vector<unsigned int>;
400 
401  unsigned int nThresh = TrigT1CaloDefs::numOfCPThresholds;
406 
407  for (unsigned int iTh = 0; iTh <= nThresh; ++iTh) {
408  std::map<int, unsigned int>::const_iterator it =
409  m_triggerThresholdValue.find(iTh);
410  if (it != m_triggerThresholdValue.end())
411  newVec->push_back(iTh);
412  }
413 
414  return newVec;
415 }

◆ thresholdType()

LVL1::TrigT1CaloDefs::ClusterAlgorithm LVL1::RecEmTauRoI::thresholdType ( unsigned int  thresh) const

returns the type of the threshold, which is either EMAlg or TauAlg.

If there is a problem, ClustAlgError is returned

Definition at line 515 of file RecEmTauRoI.cxx.

516 {
517 
518  map<int, TrigT1CaloDefs::ClusterAlgorithm>::const_iterator it =
519  m_thresholdType.find(thresh);
520  if (it != m_thresholdType.end())
521  {
522  return it->second;
523  }
525 }

◆ triggerThreshold()

unsigned int LVL1::RecEmTauRoI::triggerThreshold ( unsigned int  thresh) const

returns the value of the trigger threshold for the threshold passed.

The trigger threshold is also sometimes called the cluster threshold.

Todo:
Thresholds can vary by coordinate. Return value which matches coord of RecRoI

The trigger threshold is also sometimes called the cluster threshold.

Definition at line 419 of file RecEmTauRoI.cxx.

420 {
421 
422  std::map<int, unsigned int>::const_iterator it =
424  if (it != m_triggerThresholdValue.end())
425  {
426  return (it->second);
427  }
428  return TrigT1CaloDefs::Error;
429 }

Member Data Documentation

◆ m_coordRange

CoordinateRange LVL1::RecEmTauRoI::m_coordRange
private

this contains the coordinate range worked out from the RoIWord hardware coord (i.e.

crate number, CPM number etc.)

Definition at line 148 of file RecEmTauRoI.h.

◆ m_decoder

CPRoIDecoder* LVL1::RecEmTauRoI::m_decoder {nullptr}
private

Used for decoding RoI word.

Definition at line 141 of file RecEmTauRoI.h.

◆ m_emIsolation

std::map< int, unsigned int > LVL1::RecEmTauRoI::m_emIsolation
private

Definition at line 153 of file RecEmTauRoI.h.

◆ m_hadCoreIsolation

std::map< int, unsigned int > LVL1::RecEmTauRoI::m_hadCoreIsolation
private

Definition at line 155 of file RecEmTauRoI.h.

◆ m_hadIsolation

std::map< int, unsigned int > LVL1::RecEmTauRoI::m_hadIsolation
private

Definition at line 154 of file RecEmTauRoI.h.

◆ m_isolationMask

std::map< int, unsigned int > LVL1::RecEmTauRoI::m_isolationMask
private

Definition at line 152 of file RecEmTauRoI.h.

◆ m_roiWord

unsigned long int LVL1::RecEmTauRoI::m_roiWord { 0 }
private

this is the actual format of the data sent from the LVL1 hardware.

See ATL-DAQ-99-015 for further explanation.

Definition at line 138 of file RecEmTauRoI.h.

◆ m_thresholdMask

unsigned long int LVL1::RecEmTauRoI::m_thresholdMask { 0 }
private

Definition at line 150 of file RecEmTauRoI.h.

◆ m_thresholdType

std::map< int, TrigT1CaloDefs::ClusterAlgorithm > LVL1::RecEmTauRoI::m_thresholdType
private

Definition at line 156 of file RecEmTauRoI.h.

◆ m_triggerThresholdValue

std::map< int, unsigned int > LVL1::RecEmTauRoI::m_triggerThresholdValue
private

Definition at line 151 of file RecEmTauRoI.h.

◆ m_type

TrigT1CaloDefs::RoIType LVL1::RecEmTauRoI::m_type {TrigT1CaloDefs::RoIWordTypeError}
private

Stored properties of the RoI:

Definition at line 144 of file RecEmTauRoI.h.


The documentation for this class was generated from the following files:
TrigConf::TriggerThresholdValue
Definition: TriggerThresholdValue.h:22
TrigConf::ClusterThresholdValue::thresholdValueCount
virtual int thresholdValueCount() const override
Definition: ClusterThresholdValue.cxx:58
LVL1::CPRoIDecoder::isolationWord
unsigned int isolationWord(const unsigned int roiWord) const
Extract isolation results from Run 2 RoI word.
Definition: CPRoIDecoder.cxx:142
LVL1::CPRoIDecoder::crate
unsigned int crate(const unsigned int roiWord) const
Decode crate number from RoI word.
Definition: CPRoIDecoder.cxx:104
TruthTest.itp
itp
Definition: TruthTest.py:46
LVL1::Coordinate::phi
double phi() const
return phi
Definition: Coordinate.cxx:50
LVL1::CoordinateRange::phiRange
PhiRange phiRange() const
Definition: CoordinateRange.cxx:40
HLTSeedingRoIToolDefs::roiPhi
constexpr float roiPhi(const AnyRoIPointer &roi)
Definition: HLTSeedingRoIToolDefs.h:167
LVL1::RecEmTauRoI::m_thresholdType
std::map< int, TrigT1CaloDefs::ClusterAlgorithm > m_thresholdType
Definition: RecEmTauRoI.h:156
LVL1::TrigT1CaloDefs::ClustAlgError
@ ClustAlgError
Definition: TrigT1CaloDefs.h:212
CaloCellPos2Ntuple.int
int
Definition: CaloCellPos2Ntuple.py:24
LVL1::TrigT1CaloDefs::TauRoIWordType
@ TauRoIWordType
Definition: TrigT1CaloDefs.h:174
physval_make_web_display.thresh
thresh
Definition: physval_make_web_display.py:36
LVL1::Range::min
double min() const
Definition: Trigger/TrigT1/TrigT1Interfaces/src/Range.cxx:31
LVL1::RecEmTauRoI::isolation
virtual unsigned int isolation() const
returns roi isolation results (Run 2 only)
Definition: RecEmTauRoI.cxx:367
LVL1::RecEmTauRoI::m_decoder
CPRoIDecoder * m_decoder
Used for decoding RoI word.
Definition: RecEmTauRoI.h:141
MuonGM::round
float round(const float toRound, const unsigned int decimals)
Definition: Mdt.cxx:27
skel.it
it
Definition: skel.GENtoEVGEN.py:396
TrigConf::TriggerThresholdValue::ptcut
float ptcut() const
Definition: TriggerThresholdValue.h:45
M_PI
#define M_PI
Definition: ActiveFraction.h:11
LVL1::TrigT1CaloDefs::ClusterAlgorithm
ClusterAlgorithm
Definition: TrigT1CaloDefs.h:208
LVL1::RecEmTauRoI::m_emIsolation
std::map< int, unsigned int > m_emIsolation
Definition: RecEmTauRoI.h:153
LVL1::TrigT1CaloDefs::EMAlg
@ EMAlg
Definition: TrigT1CaloDefs.h:209
yodamerge_tmp.scale
scale
Definition: yodamerge_tmp.py:138
TrigConf::L1Threshold_EM::isolationMask
uint16_t isolationMask(int eta) const
Definition: L1Threshold.h:28
TrigConf::ClusterThresholdValue
Definition: ClusterThresholdValue.h:13
TrigConf::ClusterThresholdValue::isolationMask
uint16_t isolationMask() const
Definition: ClusterThresholdValue.h:33
LVL1::RecEmTauRoI::constructRun2
void constructRun2(const std::vector< TrigConf::TriggerThreshold * > *caloThresholds)
Content of RoI word different in Run 2.
Definition: RecEmTauRoI.cxx:196
TrigConf::L1Threshold_Calo
Definition: L1ThresholdBase.h:188
LVL1::RecEmTauRoI::m_hadCoreIsolation
std::map< int, unsigned int > m_hadCoreIsolation
Definition: RecEmTauRoI.h:155
LVL1::TrigT1CaloDefs::numOfIsolationBits
static const unsigned int numOfIsolationBits
Definition: TrigT1CaloDefs.h:135
LVL1::CPRoIDecoder::et
unsigned int et(const unsigned int roiWord) const
ET and Isolation information (Run 2 RoIs)
Definition: CPRoIDecoder.cxx:132
TrigConf::ClusterThresholdValue::emIsolationCount
int emIsolationCount() const
Definition: ClusterThresholdValue.cxx:28
LVL1::RecEmTauRoI::isValidThreshold
bool isValidThreshold(unsigned int thresh) const
returns true if thresh is a valid threshold number
Definition: RecEmTauRoI.cxx:495
TrigConf::L1DataDef
Definition: L1DataDef.h:27
LVL1::CPRoIDecoder::thresholdsPassed
const std::vector< unsigned int > thresholdsPassed(const unsigned int word) const
Thresholds passed (Run 1 RoIs)
Definition: CPRoIDecoder.cxx:153
LVL1::RecEmTauRoI::constructRun3
void constructRun3(const TrigConf::L1Menu *const l1menu)
Definition: RecEmTauRoI.cxx:257
LVL1::TrigT1CaloDefs::TauAlg
@ TauAlg
Definition: TrigT1CaloDefs.h:210
TrigConf::TriggerThresholdValue::type
const std::string & type() const
Definition: TriggerThresholdValue.h:44
TrigConf::L1Threshold_TAU::isolationMask
uint16_t isolationMask() const
Definition: L1Threshold.h:44
LVL1::CoordinateRange::etaRange
Range etaRange() const
Definition: CoordinateRange.cxx:42
LVL1::TrigT1CaloDefs::numOfTauCMXThresholds
static const unsigned int numOfTauCMXThresholds
Definition: TrigT1CaloDefs.h:133
trigbs_pickEvents.num
num
Definition: trigbs_pickEvents.py:76
LVL1::RecEmTauRoI::m_thresholdMask
unsigned long int m_thresholdMask
Definition: RecEmTauRoI.h:150
threshold
Definition: chainparser.cxx:74
LVL1::RecEmTauRoI::constructRun1
void constructRun1(const std::vector< TrigConf::TriggerThreshold * > *caloThresholds)
The "construct" call unpacks the RoIWord and copies information about the passed thresholds from the ...
Definition: RecEmTauRoI.cxx:120
LVL1::Coordinate::eta
double eta() const
return eta
Definition: Coordinate.cxx:45
LVL1::CPRoIDecoder::localcoord
unsigned int localcoord(const unsigned int roiWord) const
Decode local coordinate from RoI word.
Definition: CPRoIDecoder.cxx:125
TrigConf::ClusterThresholdValue::hadIsolationCount
int hadIsolationCount() const
Definition: ClusterThresholdValue.cxx:40
LVL1::RecEmTauRoI::m_isolationMask
std::map< int, unsigned int > m_isolationMask
Definition: RecEmTauRoI.h:152
LVL1::PhiRange::min
double min() const
Definition: PhiRange.cxx:35
LVL1::CPRoIDecoder::coordinate
virtual CoordinateRange coordinate(const unsigned int roiWord) const override
RoI coordinate information.
Definition: CPRoIDecoder.cxx:50
LVL1::CPRoIDecoder::module
unsigned int module(const unsigned int roiWord) const
Decode module number from RoI word.
Definition: CPRoIDecoder.cxx:111
LVL1::CPRoIDecoder::chip
unsigned int chip(const unsigned int roiWord) const
Decode CP chip number from RoI word.
Definition: CPRoIDecoder.cxx:118
LVL1::TrigT1CaloDefs::numOfCPThresholds
static const unsigned int numOfCPThresholds
Definition: TrigT1CaloDefs.h:125
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
LVL1::TrigT1CaloDefs::numOfEMCMXThresholds
static const unsigned int numOfEMCMXThresholds
Definition: TrigT1CaloDefs.h:132
LVL1::RecEmTauRoI::m_hadIsolation
std::map< int, unsigned int > m_hadIsolation
Definition: RecEmTauRoI.h:154
TrigConf::TriggerThresholdValue::caloInfo
const CaloInfo & caloInfo() const
Definition: TriggerThresholdValue.cxx:35
python.XMLReader.l1menu
l1menu
Definition: XMLReader.py:73
RunTileMonitoring.triggerType
triggerType
Definition: RunTileMonitoring.py:162
LVL1::RecEmTauRoI::m_coordRange
CoordinateRange m_coordRange
this contains the coordinate range worked out from the RoIWord hardware coord (i.e.
Definition: RecEmTauRoI.h:148
LVL1::TrigT1CaloDefs::EMRoIWordType
@ EMRoIWordType
Definition: TrigT1CaloDefs.h:173
TrigConf::ClusterThresholdValue::hadVetoCount
int hadVetoCount() const
Definition: ClusterThresholdValue.cxx:49
LVL1::RecEmTauRoI::m_type
TrigT1CaloDefs::RoIType m_type
Stored properties of the RoI:
Definition: RecEmTauRoI.h:144
LVL1::RecEmTauRoI::m_roiWord
unsigned long int m_roiWord
this is the actual format of the data sent from the LVL1 hardware.
Definition: RecEmTauRoI.h:138
LVL1::RecEmTauRoI::m_triggerThresholdValue
std::map< int, unsigned int > m_triggerThresholdValue
Definition: RecEmTauRoI.h:151
TrigConf::L1Threshold_TAU
Definition: L1Threshold.h:37
TrigConf::CaloInfo::globalEmScale
float globalEmScale() const
Definition: CaloInfo.h:43
python.PyAthena.obj
obj
Definition: PyAthena.py:132
LVL1::TrigT1CaloDefs::CpRoIWordType
@ CpRoIWordType
Definition: TrigT1CaloDefs.h:167
LVL1::RecEmTauRoI::et
virtual unsigned int et() const
returns roi ET (Run 2 only)
Definition: RecEmTauRoI.cxx:364
TrigConf::L1Threshold_EM
Definition: L1Threshold.h:17
LVL1::CPRoIDecoder::roiType
TrigT1CaloDefs::RoIType roiType(unsigned int word) const
CP-RoI specific, but can distinguish Run 1/Run 2.
Definition: CPRoIDecoder.cxx:31
LVL1::TrigT1CaloDefs::Error
static const unsigned int Error
Definition: TrigT1CaloDefs.h:122