ATLAS Offline Software
Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
NSWL1::PadTriggerLogicOfflineTool Class Reference

#include <PadTriggerLogicOfflineTool.h>

Inheritance diagram for NSWL1::PadTriggerLogicOfflineTool:
Collaboration diagram for NSWL1::PadTriggerLogicOfflineTool:

Public Member Functions

 PadTriggerLogicOfflineTool (const std::string &type, const std::string &name, const IInterface *parent)
 
virtual ~PadTriggerLogicOfflineTool ()=default
 
virtual StatusCode initialize ATLAS_NOT_THREAD_SAFE () override
 
virtual void handle (const Incident &inc) override
 
virtual StatusCode compute_pad_triggers (const std::vector< std::shared_ptr< PadData >> &pads, std::vector< std::unique_ptr< PadTrigger >> &triggers) const override
 Log a message using the Athena controlled logging system. More...
 
int ROI2BandId (const float EtaTrigAtCenter, const int SectorType) const
 
PadTrigger convert (const SectorTriggerCandidate &t) const
 from TDR-style SectorTriggerCandidate to PadTrigger More...
 
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & evtStore () const
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. More...
 
virtual StatusCode sysInitialize () override
 Perform system initialization for an algorithm. More...
 
virtual StatusCode sysStart () override
 Handle START transition. More...
 
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles. More...
 
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles. More...
 
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T > &t)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc="none")
 Declare a new Gaudi property. More...
 
void updateVHKA (Gaudi::Details::PropertyBase &)
 
MsgStream & msg () const
 
MsgStream & msg (const MSG::Level lvl) const
 
bool msgLvl (const MSG::Level lvl) const
 

Static Public Member Functions

static std::vector< std::unique_ptr< PadTrigger > > build4of4SingleWedgeTriggers (const std::vector< std::shared_ptr< PadData >> &pads)
 
static const InterfaceID & interfaceID ()
 

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution More...
 
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
 
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed. More...
 

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

void fillGeometricInformation (PadOfflineData &) const
 
void fillPhiTable ()
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Private Attributes

const std::vector< float > m_etaBandsLargeSector
 get the output tree from the athena histogram service More...
 
const std::vector< float > m_etaBandsSmallSector
 
std::map< IdentifierHash, std::pair< double, double > > m_phiTable
 
std::pair< double, double > m_Zratio
 
ServiceHandle< IIncidentSvc > m_incidentSvc {this, "IncidentSvc", "IncidentSvc"}
 Athena/Gaudi incident Service. More...
 
const MuonGM::MuonDetectorManagerm_detManager
 MuonDetectorManager. More...
 
Gaudi::Property< float > m_PadEfficiency {this, "PadEfficiency", 1.0, "Pad trigger efficiency"}
 
Gaudi::Property< int > m_phiIdBits {this, "PhiIdBits", 6, "Number of bit to compute Phi-Id of pad triggers"}
 
Gaudi::Property< bool > m_useSimple4of4 {this, "UseSimple4of4", false, "Use simplified logic requiring 4 hits on 4 gas gaps"}
 
Gaudi::Property< bool > m_doNtuple {this, "DoNtuple", false, "Save the trigger outputs in an analysis ntuple"}
 
std::unique_ptr< PadTriggerValidationTreem_validation_tree
 
L1TdrStgcTriggerLogic m_tdrLogic
 
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Detailed Description

Definition at line 70 of file PadTriggerLogicOfflineTool.h.

Member Typedef Documentation

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< AlgTool > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ PadTriggerLogicOfflineTool()

NSWL1::PadTriggerLogicOfflineTool::PadTriggerLogicOfflineTool ( const std::string &  type,
const std::string &  name,
const IInterface *  parent 
)

Definition at line 13 of file PadTriggerLogicOfflineTool.cxx.

13  :
17  m_detManager(nullptr),
18  m_tdrLogic()
19  {
20  declareInterface<NSWL1::IPadTriggerLogicTool>(this);
21  }

◆ ~PadTriggerLogicOfflineTool()

virtual NSWL1::PadTriggerLogicOfflineTool::~PadTriggerLogicOfflineTool ( )
virtualdefault

Member Function Documentation

◆ ATLAS_NOT_THREAD_SAFE()

virtual StatusCode initialize NSWL1::PadTriggerLogicOfflineTool::ATLAS_NOT_THREAD_SAFE ( )
overridevirtual

◆ build4of4SingleWedgeTriggers()

std::vector< std::unique_ptr< PadTrigger > > NSWL1::PadTriggerLogicOfflineTool::build4of4SingleWedgeTriggers ( const std::vector< std::shared_ptr< PadData >> &  pads)
static

Definition at line 100 of file PadTriggerLogicOfflineTool.cxx.

100  {
101  std::vector<std::unique_ptr<PadTrigger>> triggers;
102  for(const auto& p0 : filterByGasGap(pads, 1)){
103  int p0ieta = p0->padEtaId();
104  int p0iphi = p0->padPhiId();
105  for(const auto& p1 : filterByGasGap(pads, 2)){
106  int p1ieta = p1->padEtaId();
107  int p1iphi = p1->padPhiId();
108  bool p0_p1_match = ((p1ieta == p0ieta || p1ieta == p0ieta+1 ) &&
109  (p1iphi == p0iphi || p1iphi == p0iphi+1 ) );
110  if(not p0_p1_match) continue;
111  for(const auto& p2 :filterByGasGap(pads, 3) ){
112  int p2ieta = p2->padEtaId();
113  int p2iphi = p2->padPhiId();
114  bool p1_p2_match = ((p2ieta == p1ieta || p2ieta == p1ieta+1 ) &&
115  (p2iphi == p1iphi || p2iphi == p1iphi+1 ) );
116  if(not p1_p2_match) continue;
117  for(const auto& p3 : filterByGasGap(pads, 4)){
118  int p3ieta = p3->padEtaId();
119  int p3iphi = p3->padPhiId();
120  bool p2_p3_match = ((p3ieta == p2ieta || p3ieta == p2ieta+1 ) &&
121  (p3iphi == p2iphi || p3iphi == p2iphi+1 ) );
122  if(p2_p3_match){
123  auto trg=std::make_unique<PadTrigger>();
124  trg->m_pads.push_back(p0);
125  trg->m_pads.push_back(p1);
126  trg->m_pads.push_back(p2);
127  trg->m_pads.push_back(p3);
128  triggers.push_back(std::move(trg));
129  }
130  } // for(p3)
131  } // for(p2)
132  } // for(p1)
133  } // for(p0)
134  return triggers;
135 }

◆ compute_pad_triggers()

StatusCode NSWL1::PadTriggerLogicOfflineTool::compute_pad_triggers ( const std::vector< std::shared_ptr< PadData >> &  pads,
std::vector< std::unique_ptr< PadTrigger >> &  triggers 
) const
overridevirtual

Log a message using the Athena controlled logging system.

Implements NSWL1::IPadTriggerLogicTool.

Definition at line 138 of file PadTriggerLogicOfflineTool.cxx.

140 {
141  ATH_MSG_DEBUG(" <N> receiving "<<pads.size()<<" pad data");
142  ATH_MSG_DEBUG("calling compute_pad_triggers() (pads.size() "<<pads.size()<<")");
143  for(const auto& pad : pads){
144  ATH_MSG_DEBUG(" <N> building trig from pad "
145  <<" side "<<pad->sideId()<<""
146  <<", sector "<<pad->sectorId()
147  <<", sector type "<<pad->sectorType()
148  <<", module "<<pad->moduleId()
149  <<", multiplet "<<pad->multipletId()
150  <<", gas gap "<<pad->gasGapId()
151  <<", pad eta "<<pad->padEtaId()
152  <<", pad phi "<<pad->padPhiId());
153  }
154  for(const size_t side : SIDES){
155  for(const size_t sector : SECTORS){
156  std::vector<std::shared_ptr<PadData>> sector_pads;
157  std::copy_if(pads.begin(), pads.end(),
158  back_inserter(sector_pads),
159  [&](const std::shared_ptr<PadData>& p) { return (p->sideId()==static_cast<int>(side) &&
160  (2*p->sectorId()-1-p->sectorType())==static_cast<int>(sector));});
161 
162  if(!sector_pads.empty()){
163  const std::shared_ptr<PadData> firstPad = sector_pads[0];
164  ATH_MSG_DEBUG("<N> side "
165  <<(firstPad->sideId()==0?"A":"C")
166  <<" trigger sector "<< (2*firstPad->sectorId()-1-firstPad->sectorType())
167  <<" : "<<sector_pads.size()<<" pads");
168  if(m_useSimple4of4) {
169  const int innerMultiplet(1), outerMultiplet(2); // DG-2015-10-07 move to enum?
170  std::vector<std::shared_ptr<PadData>> padsInner(filterByMultiplet(sector_pads, innerMultiplet));
171  std::vector<std::shared_ptr<PadData>> padsOuter(filterByMultiplet(sector_pads, outerMultiplet));
172  std::vector<std::unique_ptr<PadTrigger>> triggersInner = build4of4SingleWedgeTriggers(padsInner);
173  std::vector<std::unique_ptr<PadTrigger>> triggersOuter = build4of4SingleWedgeTriggers(padsOuter);
174  ATH_MSG_DEBUG("found "
175  <<triggersInner.size()<<" inner triggers"
176  <<" and "
177  <<triggersOuter.size()<<" outer triggers");
178  triggers.reserve(triggers.size() + triggersInner.size()+triggersOuter.size());
179 
180  triggers.insert(triggers.end(),std::make_move_iterator(triggersInner.begin()),std::make_move_iterator(triggersInner.end()));
181  triggers.insert(triggers.end(),std::make_move_iterator(triggersOuter.begin()),std::make_move_iterator(triggersOuter.end()));
182  }
183  else {
184  std::vector<std::shared_ptr<PadOfflineData>> trgpads;
185  for(const auto& p : sector_pads){
186  auto pod=std::dynamic_pointer_cast<PadOfflineData> (p);
188  trgpads.emplace_back(std::move(pod));
189  }
190  const std::vector<SectorTriggerCandidate> candidates = m_tdrLogic.buildSectorTriggers(trgpads,m_Zratio);
191  int index=0;
192  for( const auto& st : candidates){
193  auto p=std::make_unique<PadTrigger>(convert(st));
194  p->m_triggerindex=index;
195  if (p->m_pads.empty()) continue;//don't record null triggers (rejected or empty)
196  triggers.push_back(std::move(p));
197  index++;
198  }
199  ATH_MSG_DEBUG("found " << candidates.size() << " triggers using the tdr logic");
200  }
201  } // if(sector_pads)
202  } // for(sector)
203  } // for(side)
204  // Fill Ntuple
205  if(m_doNtuple) {
206  // Ntuple can only be enabled in single-threaded mode (see initialize)
207  [[maybe_unused]] bool b1 ATLAS_THREAD_SAFE = m_validation_tree->fill_num_pad_triggers(triggers.size());
208  [[maybe_unused]] bool b2 ATLAS_THREAD_SAFE = m_validation_tree->fill_pad_trigger_basics(triggers);
209  }
210  return StatusCode::SUCCESS;
211 }

◆ convert()

NSWL1::PadTrigger NSWL1::PadTriggerLogicOfflineTool::convert ( const SectorTriggerCandidate t) const

from TDR-style SectorTriggerCandidate to PadTrigger

Definition at line 239 of file PadTriggerLogicOfflineTool.cxx.

239  {
240 
241  PadTrigger pt;
242  const Polygon roi=stc.triggerRegion3();
243  Vertex trgCntr=centroid(roi);
244  SingleWedgePadTrigger innertrg = stc.wedgeTrigs().at(0);
245 
246  //*********** assign central etaphi cordinates of the triggering region *****************
247  const float xcntr=coordinate<0>(trgCntr);
248  const float ycntr=coordinate<1>(trgCntr);
249  const float zcntr=innertrg.pads().at(0)->m_cornerXyz[1][2];
250  ROOT::Math::XYZVector trigVector(xcntr,ycntr,zcntr);
251  const float etaTrig=trigVector.Eta();
252  const float phiTrig=trigVector.Phi();
253  pt.m_eta = etaTrig;
254  pt.m_phi = phiTrig;
255 
256  /*
257  ===== Recipe for projecting eta of the trigger centroid to the axis of symmetry on a sector =======
258  */
259  //**************************************************************************************
260  auto pad0=innertrg.pads().at(0);
261  Identifier idt(pad0->id());
263  Amg::Vector3D global_trgCoordinates(xcntr,ycntr,zcntr);
264  Amg::Vector2D local_trgCoordinates;
265  surf.globalToLocal(global_trgCoordinates,Amg::Vector3D(),local_trgCoordinates);
266 
267  float yloc_trg=local_trgCoordinates.y();
268  Amg::Vector2D local_trgCoordinateOnAxis(0,yloc_trg);
269  Amg::Vector3D global_trgCoordinateProjectedOnAxis;
270  surf.localToGlobal(local_trgCoordinateOnAxis, Amg::Vector3D(),global_trgCoordinateProjectedOnAxis);
271  ROOT::Math::XYZVector trgVectorProjectedOnAxis(global_trgCoordinateProjectedOnAxis.x(),global_trgCoordinateProjectedOnAxis.y(),global_trgCoordinateProjectedOnAxis.z());
272  float etaProjected=trgVectorProjectedOnAxis.Eta();
273  int secType=pad0->sectorType();
274  int matchedBandId=ROI2BandId(std::abs(etaProjected),secType);
275  pt.m_bandid = (matchedBandId < 0) ? 0 : matchedBandId+2;// Y.R Bands start from 2
276  if(pt.m_bandid == 0) ATH_MSG_WARNING("PadTrigger out of current eta bands");
277 
278  /* ======== End of band Id matching and assignment ======================= */
279 
280  pt.m_multiplet_id = pad0->multipletId();
281  pt.m_eta_id = innertrg.halfPadCoordinates().ieta;//this is meaningless and shoiuld be removed
282  pt.m_isSmall= int(innertrg.isSmallSector());
283 
284  //************** assign extrema of the trigger region coordinates in eta-phi and some other variables for offline analysis **************
285  std::vector<std::pair<float,float>> trg_etaphis;
286  for(const auto& v : boost::geometry::exterior_ring(roi)){
287  const float xcurr=coordinate<0>(v);
288  const float ycurr=coordinate<1>(v);
289  const float zcurr=zcntr;
290  const float etacurr=eta(xcurr,ycurr,zcurr);
291  const float phicurr=phi(xcurr,ycurr,zcurr);
292  trg_etaphis.emplace_back(etacurr,phicurr);
293  }
294  const auto trg_phiminmax=std::minmax_element(trg_etaphis.begin(),trg_etaphis.end(),[](
295  const std::pair<float,float>& l,const std::pair<float,float>& r){return l.second<r.second;}
296  );
297  float trgEtaMin=0;
298  float trgEtaMax=0;
299 
300  if(pt.m_isSmall && matchedBandId > 0){
301  trgEtaMin=m_etaBandsSmallSector.at(matchedBandId+1);
302  trgEtaMax=m_etaBandsSmallSector.at(matchedBandId);
303  } else if(!pt.m_isSmall && matchedBandId > 0) {
304  trgEtaMin=m_etaBandsLargeSector.at(matchedBandId+1);
305  trgEtaMax=m_etaBandsLargeSector.at(matchedBandId);
306  }
307 
308  pt.m_etamin=trgEtaMin;
309  pt.m_etamax=trgEtaMax;
310  pt.m_phimin=(trg_phiminmax.first)->second;
311  pt.m_phimax=(trg_phiminmax.second)->second;
312  pt.m_moduleIdInner=-1;
313  pt.m_moduleIdOuter=-1;
314 
315  if(stc.wedgeTrigs().size()==2){//double wedge trigger
316  pt.m_moduleIdInner=stc.wedgeTrigs().at(0).pads().at(0)->moduleId();
317  pt.m_moduleIdOuter=stc.wedgeTrigs().at(1).pads().at(1)->moduleId();
318  }
319  else{
320  int multId0=stc.wedgeTrigs().at(0).pads().at(0)->multipletId();
321  if( multId0==1){
322  pt.m_moduleIdInner=stc.wedgeTrigs().at(0).pads().at(0)->moduleId();
323  }
324  else{
325  pt.m_moduleIdOuter=stc.wedgeTrigs().at(0).pads().at(0)->moduleId();
326  }
327  //one of the module Ids remain as -1 /single wedge trigger
328  }
329 
330  //****************************************************************************************
331 
332  for(const SingleWedgePadTrigger& swt : stc.wedgeTrigs()){
333  int currwedge=swt.pads().at(0)->multipletId();
334  std::vector<float> trglocalminY;
335  std::vector<float> trglocalmaxY;
336  std::vector<int> trgSelectedLayers;
337  std::vector<int> trgSelectedBands;
338  std::vector<int> trgPadPhiIndices;
339  std::vector<int> trgPadEtaIndices;
340  std::vector< std::shared_ptr<PadData>> trgPads;
341  for(const auto &p : swt.pads()){
342  const float padZ=p->m_cornerXyz[0][2];
343  Identifier Id( p->id());
344  const Trk::PlaneSurface &padsurface = m_detManager->getsTgcReadoutElement(Id)->surface(Id);
345  float Phi=p->stationPhiAngle();
346 
347  //Find the radial boundaries of the band within the sector axis
348  float Rmin=std::abs(padZ*std::tan(2*std::atan(-1*std::exp(pt.m_etamax))) );
349  float Rmax=std::abs(padZ*std::tan(2*std::atan(-1*std::exp(pt.m_etamin))) );
350  float xmin=Rmin*std::cos(Phi);
351  float ymin=Rmin*std::sin(Phi);
352  float xmax=Rmax*std::cos(Phi);
353  float ymax=Rmax*std::sin(Phi);
354 
355  Amg::Vector3D global_trgMinOnAxis(xmin,ymin,padZ);
356  Amg::Vector3D global_trgMaxOnAxis(xmax,ymax,padZ);
357 
358  Amg::Vector2D local_trgMinOnAxis;
359  Amg::Vector2D local_trgMaxOnAxis;
360  padsurface.globalToLocal(global_trgMinOnAxis,Amg::Vector3D(),local_trgMinOnAxis);
361  padsurface.globalToLocal(global_trgMaxOnAxis,Amg::Vector3D(),local_trgMaxOnAxis);
362 
363  float bandLocalMaxY=local_trgMaxOnAxis.y();
364  float bandLocalMinY=local_trgMinOnAxis.y();
365 
366  trglocalminY.push_back(bandLocalMinY);
367  trglocalmaxY.push_back(bandLocalMaxY);
368  trgSelectedLayers.push_back(p->gasGapId());
369  trgSelectedBands.push_back(matchedBandId+2);
370  trgPadPhiIndices.push_back(p->padPhiId());
371  trgPadEtaIndices.push_back(p->padEtaId());
372  trgPads.push_back(p);
373  pt.m_pads.push_back(p);
374  } // eof for(p) pads
375  //assign variables / wedgewise
376  if(currwedge==1){
377  pt.m_trglocalminYInner=trglocalminY;
378  pt.m_trglocalmaxYInner=trglocalmaxY;
379  pt.m_trgSelectedLayersInner=trgSelectedLayers;
380  pt.m_trgSelectedBandsInner=trgSelectedBands;
381  pt.m_trgPadPhiIndicesInner=trgPadPhiIndices;
382  pt.m_trgPadEtaIndicesInner=trgPadEtaIndices;
383  pt.m_padsInner=trgPads;
384  }
385  if(currwedge==2){
386  pt.m_trglocalminYOuter=trglocalminY;
387  pt.m_trglocalmaxYOuter=trglocalmaxY;
388  pt.m_trgSelectedLayersOuter=trgSelectedLayers;
389  pt.m_trgSelectedBandsOuter=trgSelectedBands;
390  pt.m_trgPadPhiIndicesOuter=trgPadPhiIndices;
391  pt.m_trgPadEtaIndicesOuter=trgPadEtaIndices;
392  pt.m_padsOuter=trgPads;
393  }
394 
395  trglocalminY.clear();
396  trglocalmaxY.clear();
397  trgSelectedLayers.clear();
398  trgSelectedBands.clear();
399  trgPadPhiIndices.clear();
400  trgPadEtaIndices.clear();
401  trgPads.clear();
402  } // eof for (swt) single wedge trigger
403 
404  //Assignment of Phi Id using 6 bits slicing
405  Identifier padIdentifier(pt.m_pads.at(0)->id() );
406  IdentifierHash moduleHashId;
407  const IdContext ModuleContext = m_detManager->stgcIdHelper()->module_context();
408 
409  //get the module Identifier using the pad's
410  m_detManager->stgcIdHelper()->get_hash( padIdentifier, moduleHashId, &ModuleContext );
411  float stationPhiMin=0.0;
412  float stationPhiMax=0.0;
413  std::map<IdentifierHash,std::pair<double,double>>::const_iterator itPhi = m_phiTable.find(moduleHashId);
414  if (itPhi != m_phiTable.end()) {
415  stationPhiMin=(*itPhi).second.first;
416  stationPhiMax=(*itPhi).second.second;
417  }
418  else {
419  ATH_MSG_WARNING("Could not find the hash Id: " << moduleHashId << " in the map");
420  }
421 
422  float trgPhiCntr=pt.m_phi;
423  int nPhiSlices=1<<m_phiIdBits;//6 bits for Phi Id; i.e interval of [0,....63]
424 
425  // special treatment for the last phi region
426  if ( stationPhiMax > M_PI && trgPhiCntr<0 ) {
427  trgPhiCntr=2*M_PI-fabs(trgPhiCntr);
428  }
429 
430  if ( trgPhiCntr<stationPhiMin || trgPhiCntr>stationPhiMax ) {
431  ATH_MSG_WARNING("Trigger phi: " << trgPhiCntr << " outside the station. Min, max: " << stationPhiMin << " " << stationPhiMax );
432  }
433 
434  float step=(stationPhiMax-stationPhiMin)/nPhiSlices;
435  for( int i=0;i<nPhiSlices;i++){
436  if(stationPhiMin+i*step>=trgPhiCntr){
437  pt.m_phi_id=i;
438  break;
439  }
440  }
441  return pt;
442 }

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyArrayType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKeyArray>

Definition at line 170 of file AthCommonDataStore.h.

172  {
173  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
174  hndl.value(),
175  hndl.documentation());
176 
177  }

◆ declareGaudiProperty() [2/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleBase>

Definition at line 184 of file AthCommonDataStore.h.

186  {
187  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
188  hndl.value(),
189  hndl.documentation());
190  }

◆ declareGaudiProperty() [4/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  t,
const SG::NotHandleType  
)
inlineprivateinherited

specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>

Definition at line 199 of file AthCommonDataStore.h.

200  {
201  return PBASE::declareProperty(t);
202  }

◆ declareProperty() [1/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleBase hndl,
const std::string &  doc,
const SG::VarHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleBase. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 245 of file AthCommonDataStore.h.

249  {
250  this->declare(hndl.vhKey());
251  hndl.vhKey().setOwner(this);
252 
253  return PBASE::declareProperty(name,hndl,doc);
254  }

◆ declareProperty() [2/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKey hndl,
const std::string &  doc,
const SG::VarHandleKeyType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleKey. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 221 of file AthCommonDataStore.h.

225  {
226  this->declare(hndl);
227  hndl.setOwner(this);
228 
229  return PBASE::declareProperty(name,hndl,doc);
230  }

◆ declareProperty() [3/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKeyArray hndArr,
const std::string &  doc,
const SG::VarHandleKeyArrayType  
)
inlineinherited

Definition at line 259 of file AthCommonDataStore.h.

263  {
264 
265  // std::ostringstream ost;
266  // ost << Algorithm::name() << " VHKA declareProp: " << name
267  // << " size: " << hndArr.keys().size()
268  // << " mode: " << hndArr.mode()
269  // << " vhka size: " << m_vhka.size()
270  // << "\n";
271  // debug() << ost.str() << endmsg;
272 
273  hndArr.setOwner(this);
274  m_vhka.push_back(&hndArr);
275 
276  Gaudi::Details::PropertyBase* p = PBASE::declareProperty(name, hndArr, doc);
277  if (p != 0) {
278  p->declareUpdateHandler(&AthCommonDataStore<PBASE>::updateVHKA, this);
279  } else {
280  ATH_MSG_ERROR("unable to call declareProperty on VarHandleKeyArray "
281  << name);
282  }
283 
284  return p;
285 
286  }

◆ declareProperty() [4/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc,
const SG::NotHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This is the generic version, for types that do not derive from SG::VarHandleKey. It just forwards to the base class version of declareProperty.

Definition at line 333 of file AthCommonDataStore.h.

337  {
338  return PBASE::declareProperty(name, property, doc);
339  }

◆ declareProperty() [5/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc = "none" 
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This dispatches to either the generic declareProperty or the one for VarHandle/Key/KeyArray.

Definition at line 352 of file AthCommonDataStore.h.

355  {
356  typedef typename SG::HandleClassifier<T>::type htype;
357  return declareProperty (name, property, doc, htype());
358  }

◆ declareProperty() [6/6]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( Gaudi::Property< T > &  t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145  {
146  typedef typename SG::HandleClassifier<T>::type htype;
148  }

◆ detStore()

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

95 { return m_detStore; }

◆ evtStore() [1/2]

ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

85 { return m_evtStore; }

◆ evtStore() [2/2]

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( ) const
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase &  ExtraDeps)
protectedinherited

Add StoreName to extra input/output deps as needed.

use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given

◆ fillGeometricInformation()

void NSWL1::PadTriggerLogicOfflineTool::fillGeometricInformation ( PadOfflineData pod) const
private

Definition at line 66 of file PadTriggerLogicOfflineTool.cxx.

66  {
67  const MuonGM::sTgcReadoutElement* rdoEl = m_detManager->getsTgcReadoutElement(pod.Identity());
68  const Trk::PlaneSurface &surface = rdoEl->surface(pod.Identity());
69  std::array<Amg::Vector2D, 4> local_pad_corners{make_array<Amg::Vector2D, 4>(Amg::Vector2D::Zero())};
70  //From MuonPadDesign... read pad local corners
71  rdoEl->padCorners(pod.Identity(),local_pad_corners);
72  Amg::Vector3D pad_corner_global;
73  for(unsigned int i=0; i<4; i++) {
74  surface.localToGlobal(local_pad_corners.at(i), pad_corner_global, pad_corner_global);
75  pod.m_cornerXyz[i][0] = pad_corner_global.x();
76  pod.m_cornerXyz[i][1] = pad_corner_global.y();
77  pod.m_cornerXyz[i][2] = pad_corner_global.z();
78  }
79 }

◆ fillPhiTable()

void NSWL1::PadTriggerLogicOfflineTool::fillPhiTable ( )
private

Definition at line 445 of file PadTriggerLogicOfflineTool.cxx.

445  {
446 
448 
449  std::vector<Identifier>::const_iterator idfirst = helper->module_begin();
450  std::vector<Identifier>::const_iterator idlast = helper->module_end();
451 
452  const IdContext ModuleContext = helper->module_context();
453 
454  for ( std::vector<Identifier>::const_iterator i=idfirst ; i!=idlast ; ++i ) {
455 
456  Identifier Id = *i;
457  IdentifierHash hashId;
458 
459  helper->get_hash( Id, hashId, &ModuleContext );
460 
462  if (!module) continue;
463  int multilayer = helper->multilayer(Id);
464 
465  char side = module->getStationEta() < 0 ? 'C' : 'A';
466  char sector_l = module->getStationName().substr(2,1)=="L" ? 'L' : 'S';
467 
468  sTGCDetectorHelper aHelper;
469  sTGCDetectorDescription* md = aHelper.Get_sTGCDetector( sector_l, std::abs(module->getStationEta()), module->getStationPhi(), multilayer, side );
470 
471  Amg::Vector3D pos = module->center();
472  double swidth = md->sWidth();
473  double lwidth = md->lWidth();
474  double ycutout = md->yCutout();
475  double length = md->Length();
476  double moduleR = std::sqrt( pos.mag()*pos.mag() - pos.z()*pos.z());
477  double dphi1 = std::atan( (0.5*lwidth)/(moduleR+0.5*length) );
478  double dphi2 = std::atan( (0.5*swidth)/(moduleR-0.5*length) );
479 
480  double dphi = ( dphi1 > dphi2 ? dphi1 : dphi2 );
481  if ( ycutout > 0 ) {
482  double rcutout = moduleR+0.5*length - ycutout;
483  double dphicutout = std::atan( (0.5*lwidth)/rcutout );
484  if ( dphi < dphicutout ) dphi = dphicutout;
485  }
486  double phimin = pos.phi()-dphi;
487  double phimax = pos.phi()+dphi;
488 
489  if ( phimin > M_PI ) phimin -= 2*M_PI;
490  if ( phimin < -M_PI ) phimin += 2*M_PI;
491 
492  std::pair<double,double> phiRange(phimin,phimax);
493  m_phiTable[hashId]=phiRange;
494 
495  if((sector_l=='L' && m_Zratio.first==0) || (sector_l=='S' && m_Zratio.second==0)) {
496  double ratio=1/pos.z();
497  Id=helper->multilayerID(Id,2);
499  Amg::Vector3D pos2 = module2->center();
500  ratio*=pos2.z();
501  if(sector_l=='L') m_Zratio.first=ratio;
502  else if(sector_l=='S') m_Zratio.second=ratio;
503  }
504  }
505 
506  }

◆ handle()

void NSWL1::PadTriggerLogicOfflineTool::handle ( const Incident &  inc)
overridevirtual

Definition at line 59 of file PadTriggerLogicOfflineTool.cxx.

59  {
60  if( inc.type()==IncidentType::BeginEvent && m_doNtuple ) {
61  // Ntuple can only be enabled in single-threaded mode (see initialize)
62  [[maybe_unused]] bool success ATLAS_THREAD_SAFE = m_validation_tree->reset_ntuple_variables();
63  }
64 }

◆ inputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::inputHandles ( ) const
overridevirtualinherited

Return this algorithm's input handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ interfaceID()

static const InterfaceID& NSWL1::IPadTriggerLogicTool::interfaceID ( )
inlinestaticinherited

Definition at line 39 of file IPadTriggerLogicTool.h.

39  {
40  static const InterfaceID IID_IPadTriggerLogicTool("NSWL1::IPadTriggerLogicTool", 1 ,0);
41  return IID_IPadTriggerLogicTool;
42  }

◆ msg() [1/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24  {
25  return this->msgStream();
26  }

◆ msg() [2/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( const MSG::Level  lvl) const
inlineinherited

Definition at line 27 of file AthCommonMsg.h.

27  {
28  return this->msgStream(lvl);
29  }

◆ msgLvl()

bool AthCommonMsg< AlgTool >::msgLvl ( const MSG::Level  lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30  {
31  return this->msgLevel(lvl);
32  }

◆ outputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::outputHandles ( ) const
overridevirtualinherited

Return this algorithm's output handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ renounce()

std::enable_if_t<std::is_void_v<std::result_of_t<decltype(&T::renounce)(T)> > && !std::is_base_of_v<SG::VarHandleKeyArray, T> && std::is_base_of_v<Gaudi::DataHandle, T>, void> AthCommonDataStore< AthCommonMsg< AlgTool > >::renounce ( T &  h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381  {
382  h.renounce();
383  PBASE::renounce (h);
384  }

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::renounceArray ( SG::VarHandleKeyArray handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364  {
365  handlesArray.renounce();
366  }

◆ ROI2BandId()

int NSWL1::PadTriggerLogicOfflineTool::ROI2BandId ( const float  EtaTrigAtCenter,
const int  SectorType 
) const

Definition at line 214 of file PadTriggerLogicOfflineTool.cxx.

214  {
215 
216  switch(SectorType){
217  case(1): //L
218  if(EtaTrigAtCenter < m_etaBandsLargeSector.back() || EtaTrigAtCenter > m_etaBandsLargeSector.front()) return -999;
219  for(unsigned int i=0;i<m_etaBandsLargeSector.size();i++){
220  if(EtaTrigAtCenter < m_etaBandsLargeSector.at(i) && EtaTrigAtCenter > m_etaBandsLargeSector.at(i+1) ) return i;
221  }
222  break;
223 
224  case(0): //S
225  if(EtaTrigAtCenter < m_etaBandsSmallSector.back() || EtaTrigAtCenter > m_etaBandsSmallSector.front()) return -999;
226  for(unsigned int i=0;i<m_etaBandsSmallSector.size();i++){
227  if(EtaTrigAtCenter < m_etaBandsSmallSector.at(i) && EtaTrigAtCenter > m_etaBandsSmallSector.at(i+1) ) return i;
228  }
229  break;
230 
231  default:
232  ATH_MSG_FATAL(" Unexpected SectorType="<<SectorType);
233  break;
234  }
235  return -999;
236 }

◆ sysInitialize()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysInitialize ( )
overridevirtualinherited

Perform system initialization for an algorithm.

We override this to declare all the elements of handle key arrays at the end of initialization. See comments on updateVHKA.

Reimplemented in DerivationFramework::CfAthAlgTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and asg::AsgMetadataTool.

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::updateVHKA ( Gaudi::Details::PropertyBase &  )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308  {
309  // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310  // << " size: " << m_vhka.size() << endmsg;
311  for (auto &a : m_vhka) {
312  std::vector<SG::VarHandleKey*> keys = a->keys();
313  for (auto k : keys) {
314  k->setOwner(this);
315  }
316  }
317  }

Member Data Documentation

◆ m_detManager

const MuonGM::MuonDetectorManager* NSWL1::PadTriggerLogicOfflineTool::m_detManager
private

MuonDetectorManager.

Definition at line 99 of file PadTriggerLogicOfflineTool.h.

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_doNtuple

Gaudi::Property<bool> NSWL1::PadTriggerLogicOfflineTool::m_doNtuple {this, "DoNtuple", false, "Save the trigger outputs in an analysis ntuple"}
private

Definition at line 104 of file PadTriggerLogicOfflineTool.h.

◆ m_etaBandsLargeSector

const std::vector<float> NSWL1::PadTriggerLogicOfflineTool::m_etaBandsLargeSector
private

get the output tree from the athena histogram service

Definition at line 92 of file PadTriggerLogicOfflineTool.h.

◆ m_etaBandsSmallSector

const std::vector<float> NSWL1::PadTriggerLogicOfflineTool::m_etaBandsSmallSector
private

Definition at line 93 of file PadTriggerLogicOfflineTool.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_incidentSvc

ServiceHandle<IIncidentSvc> NSWL1::PadTriggerLogicOfflineTool::m_incidentSvc {this, "IncidentSvc", "IncidentSvc"}
private

Athena/Gaudi incident Service.

Definition at line 98 of file PadTriggerLogicOfflineTool.h.

◆ m_PadEfficiency

Gaudi::Property<float> NSWL1::PadTriggerLogicOfflineTool::m_PadEfficiency {this, "PadEfficiency", 1.0, "Pad trigger efficiency"}
private

Definition at line 101 of file PadTriggerLogicOfflineTool.h.

◆ m_phiIdBits

Gaudi::Property<int> NSWL1::PadTriggerLogicOfflineTool::m_phiIdBits {this, "PhiIdBits", 6, "Number of bit to compute Phi-Id of pad triggers"}
private

Definition at line 102 of file PadTriggerLogicOfflineTool.h.

◆ m_phiTable

std::map<IdentifierHash, std::pair<double,double> > NSWL1::PadTriggerLogicOfflineTool::m_phiTable
private

Definition at line 95 of file PadTriggerLogicOfflineTool.h.

◆ m_tdrLogic

L1TdrStgcTriggerLogic NSWL1::PadTriggerLogicOfflineTool::m_tdrLogic
private

Definition at line 109 of file PadTriggerLogicOfflineTool.h.

◆ m_useSimple4of4

Gaudi::Property<bool> NSWL1::PadTriggerLogicOfflineTool::m_useSimple4of4 {this, "UseSimple4of4", false, "Use simplified logic requiring 4 hits on 4 gas gaps"}
private

Definition at line 103 of file PadTriggerLogicOfflineTool.h.

◆ m_validation_tree

std::unique_ptr<PadTriggerValidationTree> NSWL1::PadTriggerLogicOfflineTool::m_validation_tree
private

Definition at line 106 of file PadTriggerLogicOfflineTool.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< AlgTool > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.

◆ m_Zratio

std::pair<double,double> NSWL1::PadTriggerLogicOfflineTool::m_Zratio
private

Definition at line 96 of file PadTriggerLogicOfflineTool.h.


The documentation for this class was generated from the following files:
MuonGM::sTgcReadoutElement::padCorners
bool padCorners(const Identifier &id, std::array< Amg::Vector2D, 4 > &corners) const
pad corners
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/sTgcReadoutElement.h:358
NSWL1::PadTriggerLogicOfflineTool::m_tdrLogic
L1TdrStgcTriggerLogic m_tdrLogic
Definition: PadTriggerLogicOfflineTool.h:109
beamspotman.r
def r
Definition: beamspotman.py:676
Trk::PlaneSurface::globalToLocal
virtual bool globalToLocal(const Amg::Vector3D &glob, const Amg::Vector3D &mom, Amg::Vector2D &loc) const override final
Specified for PlaneSurface: GlobalToLocal method without dynamic memory allocation - boolean checks i...
Definition: PlaneSurface.cxx:213
python.SystemOfUnits.second
int second
Definition: SystemOfUnits.py:120
NSWL1::PadTriggerLogicOfflineTool::m_phiTable
std::map< IdentifierHash, std::pair< double, double > > m_phiTable
Definition: PadTriggerLogicOfflineTool.h:95
NSWL1::eta
float eta(float x, float y, float z)
Definition: GeoUtils.cxx:9
ymin
double ymin
Definition: listroot.cxx:63
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition: AthMsgStreamMacros.h:34
NSWL1::PadTriggerLogicOfflineTool::ROI2BandId
int ROI2BandId(const float EtaTrigAtCenter, const int SectorType) const
Definition: PadTriggerLogicOfflineTool.cxx:214
NSWL1::SIDES
const std::vector< size_t > SIDES
Definition: tdr_compat_enum.h:20
sTGCDetectorDescription::sWidth
double sWidth() const
Definition: sTGCDetectorDescription.h:70
NSWL1::filterByGasGap
std::vector< std::shared_ptr< PadData > > filterByGasGap(const std::vector< std::shared_ptr< PadData >> &pads_in, const int gasgap)
! helper function: copy pads with a given gas gap
Definition: PadTriggerLogicOfflineTool.cxx:91
NSWL1::filterByMultiplet
std::vector< std::shared_ptr< PadData > > filterByMultiplet(const std::vector< std::shared_ptr< PadData >> &pads_in, const int multiplet)
! helper function: copy pads with a given multiplet
Definition: PadTriggerLogicOfflineTool.cxx:82
CaloCellPos2Ntuple.int
int
Definition: CaloCellPos2Ntuple.py:24
MuonGM::MuonClusterReadoutElement::center
virtual const Amg::Vector3D & center() const override
Return the center of the element.
Definition: MuonClusterReadoutElement.h:125
Amg::Vector2D
Eigen::Matrix< double, 2, 1 > Vector2D
Definition: GeoPrimitives.h:48
index
Definition: index.py:1
drawFromPickle.candidates
candidates
Definition: drawFromPickle.py:271
AthCommonDataStore::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
NSWL1::Vertex
boost::geometry::model::d2::point_xy< double > Vertex
Definition: GeoUtils.h:17
NSWL1::BandsInEtaLargeSector
const std::vector< float > BandsInEtaLargeSector
Definition: sTGCTriggerBandsInEta.h:16
NSWL1::BandsInEtaSmallSector
const std::vector< float > BandsInEtaSmallSector
Definition: sTGCTriggerBandsInEta.h:111
NSWL1::Polygon
boost::geometry::model::polygon< Vertex > Polygon
Definition: GeoUtils.h:18
TRTCalib_cfilter.p1
p1
Definition: TRTCalib_cfilter.py:130
test_pyathena.pt
pt
Definition: test_pyathena.py:11
M_PI
#define M_PI
Definition: ActiveFraction.h:11
sTGCDetectorDescription::Length
double Length() const
Definition: sTGCDetectorDescription.h:72
NSWL1::PadTriggerLogicOfflineTool::m_Zratio
std::pair< double, double > m_Zratio
Definition: PadTriggerLogicOfflineTool.h:96
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
UploadAMITag.l
list l
Definition: UploadAMITag.larcaf.py:158
Phi
@ Phi
Definition: RPCdef.h:8
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
drawFromPickle.cos
cos
Definition: drawFromPickle.py:36
python.TrigTLAMonitorAlgorithm.triggers
triggers
Definition: TrigTLAMonitorAlgorithm.py:196
drawFromPickle.exp
exp
Definition: drawFromPickle.py:36
MuonGM::MuonClusterReadoutElement::surface
virtual const Trk::PlaneSurface & surface() const override
access to chamber surface (phi orientation), uses the first gas gap
Definition: MuonClusterReadoutElement.h:123
drawFromPickle.atan
atan
Definition: drawFromPickle.py:36
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
sTGCDetectorDescription
Definition: sTGCDetectorDescription.h:51
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
TRT::Hit::side
@ side
Definition: HitInfo.h:83
runBeamSpotCalibration.helper
helper
Definition: runBeamSpotCalibration.py:112
python.PyAthena.module
module
Definition: PyAthena.py:131
TRTCalib_cfilter.p2
p2
Definition: TRTCalib_cfilter.py:131
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
AthCommonDataStore
Definition: AthCommonDataStore.h:52
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
lumiFormat.i
int i
Definition: lumiFormat.py:85
xmin
double xmin
Definition: listroot.cxx:60
NSWL1::PadTriggerLogicOfflineTool::m_doNtuple
Gaudi::Property< bool > m_doNtuple
Definition: PadTriggerLogicOfflineTool.h:104
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
NSWL1::PadTriggerLogicOfflineTool::m_detManager
const MuonGM::MuonDetectorManager * m_detManager
MuonDetectorManager.
Definition: PadTriggerLogicOfflineTool.h:99
MuonGM::sTgcReadoutElement
An sTgcReadoutElement corresponds to a single STGC module; therefore typicaly a barrel muon station c...
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/sTgcReadoutElement.h:30
NSWL1::SECTORS
const std::vector< size_t > SECTORS
Definition: tdr_compat_enum.h:19
test_pyathena.parent
parent
Definition: test_pyathena.py:15
MuonGM::MuonDetectorManager::stgcIdHelper
const sTgcIdHelper * stgcIdHelper() const
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/MuonDetectorManager.h:241
AnalysisUtils::copy_if
Out copy_if(In first, const In &last, Out res, const Pred &p)
Definition: IFilterUtils.h:30
drawFromPickle.tan
tan
Definition: drawFromPickle.py:36
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
NSWL1::PadTriggerLogicOfflineTool::convert
PadTrigger convert(const SectorTriggerCandidate &t) const
from TDR-style SectorTriggerCandidate to PadTrigger
Definition: PadTriggerLogicOfflineTool.cxx:239
AthAlgTool::AthAlgTool
AthAlgTool()
Default constructor:
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
NSWL1::PadTriggerLogicOfflineTool::build4of4SingleWedgeTriggers
static std::vector< std::unique_ptr< PadTrigger > > build4of4SingleWedgeTriggers(const std::vector< std::shared_ptr< PadData >> &pads)
Definition: PadTriggerLogicOfflineTool.cxx:100
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
NSWL1::PadTriggerLogicOfflineTool::m_validation_tree
std::unique_ptr< PadTriggerValidationTree > m_validation_tree
Definition: PadTriggerLogicOfflineTool.h:106
sTgcIdHelper
Definition: sTgcIdHelper.h:55
sTGCDetectorDescription::yCutout
void yCutout(double y)
Definition: sTGCDetectorDescription.h:75
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
NSWL1::PadTriggerLogicOfflineTool::m_etaBandsLargeSector
const std::vector< float > m_etaBandsLargeSector
get the output tree from the athena histogram service
Definition: PadTriggerLogicOfflineTool.h:92
python.LumiBlobConversion.pos
pos
Definition: LumiBlobConversion.py:18
NSWL1::PadTriggerLogicOfflineTool::m_etaBandsSmallSector
const std::vector< float > m_etaBandsSmallSector
Definition: PadTriggerLogicOfflineTool.h:93
SectorType
SectorType
Definition: sTGCenumeration.h:39
python.PyAthena.v
v
Definition: PyAthena.py:154
DeMoScan.index
string index
Definition: DeMoScan.py:364
a
TList * a
Definition: liststreamerinfos.cxx:10
h
python.compareTCTs.ratio
ratio
Definition: compareTCTs.py:295
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
MuonIdHelper::get_hash
virtual int get_hash(const Identifier &id, IdentifierHash &hash_id, const IdContext *context=0) const override
Create hash id from compact id (return == 0 for OK)
Definition: MuonIdHelper.cxx:144
NSWL1::L1TdrStgcTriggerLogic::buildSectorTriggers
std::vector< SectorTriggerCandidate > buildSectorTriggers(const std::vector< std::shared_ptr< PadOfflineData >> &pads, const std::pair< double, double > &Zratio) const
main function to compute trigger candidates
Definition: L1TdrStgcTriggerLogic.cxx:342
Trk::PlaneSurface
Definition: PlaneSurface.h:64
sTGCDetectorDescription::lWidth
double lWidth() const
Definition: sTGCDetectorDescription.h:71
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
MuonIdHelper::module_context
IdContext module_context() const
id for module
Definition: MuonIdHelper.cxx:731
xmax
double xmax
Definition: listroot.cxx:61
NSWL1::PadTriggerLogicOfflineTool::fillGeometricInformation
void fillGeometricInformation(PadOfflineData &) const
Definition: PadTriggerLogicOfflineTool.cxx:66
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:623
NSWL1::PadTriggerLogicOfflineTool::m_phiIdBits
Gaudi::Property< int > m_phiIdBits
Definition: PadTriggerLogicOfflineTool.h:102
Rmin
double Rmin
Definition: LArDetectorConstructionTBEC.cxx:56
LArCellBinning.step
step
Definition: LArCellBinning.py:158
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
ATLAS_THREAD_SAFE
#define ATLAS_THREAD_SAFE
Definition: checker_macros.h:211
LArCellBinning.phiRange
phiRange
Filling Phi ranges.
Definition: LArCellBinning.py:107
MuonGM::MuonDetectorManager::getsTgcReadoutElement
const sTgcReadoutElement * getsTgcReadoutElement(const Identifier &id) const
access via extended identifier (requires unpacking)
Definition: MuonDetDescr/MuonReadoutGeometry/src/MuonDetectorManager.cxx:259
drawFromPickle.sin
sin
Definition: drawFromPickle.py:36
IdentifierHash
This is a "hash" representation of an Identifier. This encodes a 32 bit index which can be used to lo...
Definition: IdentifierHash.h:25
Trk::PlaneSurface::localToGlobal
virtual void localToGlobal(const Amg::Vector2D &locp, const Amg::Vector3D &mom, Amg::Vector3D &glob) const override final
Specified for PlaneSurface: LocalToGlobal method without dynamic memory allocation.
Definition: PlaneSurface.cxx:204
TRTCalib_cfilter.p3
p3
Definition: TRTCalib_cfilter.py:132
NSWL1::phi
float phi(float x, float y, float z)
Definition: GeoUtils.cxx:14
NSWL1::PadTriggerLogicOfflineTool::m_useSimple4of4
Gaudi::Property< bool > m_useSimple4of4
Definition: PadTriggerLogicOfflineTool.h:103
IdContext
This class saves the "context" of an expanded identifier (ExpandedIdentifier) for compact or hash ver...
Definition: IdContext.h:26
sTGCDetectorHelper
Definition: sTGCDetectorHelper.h:24
length
double length(const pvec &v)
Definition: FPGATrackSimLLPDoubletHoughTransformTool.cxx:26
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
NSWL1::centroid
Vertex centroid(const Polygon &p)
Definition: GeoUtils.cxx:59
sTGCDetectorHelper::Get_sTGCDetector
sTGCDetectorDescription * Get_sTGCDetector(char type, int ieta, int iphi, int layer=1, char side='A')
Definition: sTGCDetectorHelper.cxx:35
TRTCalib_cfilter.p0
p0
Definition: TRTCalib_cfilter.py:129
fitman.k
k
Definition: fitman.py:528
generate::Zero
void Zero(TH1D *hin)
Definition: generate.cxx:32
ymax
double ymax
Definition: listroot.cxx:64
Identifier
Definition: IdentifierFieldParser.cxx:14