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

#include <MuonInputProvider.h>

Inheritance diagram for LVL1::MuonInputProvider:
Collaboration diagram for LVL1::MuonInputProvider:

Public Member Functions

 MuonInputProvider (const std::string &type, const std::string &name, const IInterface *parent)
 
virtual StatusCode initialize () override
 
virtual StatusCode fillTopoInputEvent (TCS::TopoInputEvent &) const override
 

Private Member Functions

TCS::MuonTOB createMuonTOB (const xAOD::MuonRoI &muonRoI, const std::vector< unsigned int > &rpcPtValues, const std::vector< unsigned int > &tgcPtValues) const
 
TCS::MuonTOB createMuonTOB (const MuCTPIL1TopoCandidate &roi) const
 
TCS::LateMuonTOB createLateMuonTOB (const xAOD::MuonRoI &muonRoI, const std::vector< unsigned int > &rpcPtValues, const std::vector< unsigned int > &tgcPtValues) const
 
TCS::LateMuonTOB createLateMuonTOB (const MuCTPIL1TopoCandidate &roi) const
 
int topoFlag (bool flag) const
 

Private Attributes

ToolHandle< LVL1::ITrigT1MuonRecRoiToolm_recRPCRoiTool {this, "RecRpcRoiTool", "LVL1::TrigT1RPCRecRoiTool/TrigT1RPCRecRoiTool", "RPC RoI reconstruction tool"}
 
ToolHandle< LVL1::ITrigT1MuonRecRoiToolm_recTGCRoiTool {this, "RecTgcRoiTool", "LVL1::TrigT1TGCRecRoiTool/TrigT1TGCRecRoiTool", "TGC RoI reconstruction tool"}
 
ToolHandle< GenericMonitoringToolm_monTool {this, "MonTool", "", "Monitoring tool to create online histograms"}
 
SG::ReadHandleKey< LVL1::MuCTPIL1Topom_MuCTPItoL1TopoLocation { this, "locationMuCTPItoL1Topo", LVL1MUCTPI::DEFAULT_MuonL1TopoLocation, "Storegate key for MuCTPItoL1Topo "}
 
SG::ReadHandleKey< LVL1::MuCTPIL1Topom_MuCTPItoL1TopoLocationPlusOne { this, "locationMuCTPItoL1Topo1", LVL1MUCTPI::DEFAULT_MuonL1TopoLocation, "Storegate key for MuCTPItoL1TopoPlusOne"}
 
SG::ReadHandleKey< xAOD::MuonRoIContainerm_MuonL1RoILocation {this, "locationMuonRoI", LVL1MUCTPI::DEFAULT_MuonL1TopoLocation, "Empty=Use Muctpi, LVL1MuonRoIs=Use reading from xAOD L1 RoI"}
 
SG::ReadHandleKey< xAOD::MuonRoIContainerm_MuonL1RoILocationPlusOne {this, "locationMuonRoI1", LVL1MUCTPI::DEFAULT_MuonL1TopoLocation, "Empty=Use Muctpi, LVL1MuonRoIs=Use reading from xAOD L1 RoI"}
 

Detailed Description

Definition at line 37 of file MuonInputProvider.h.

Constructor & Destructor Documentation

◆ MuonInputProvider()

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

Definition at line 28 of file MuonInputProvider.cxx.

29  :
30  base_class(type, name, parent)
31 {
32  declareInterface<LVL1::IInputTOBConverter>( this );
33 }

Member Function Documentation

◆ createLateMuonTOB() [1/2]

TCS::LateMuonTOB MuonInputProvider::createLateMuonTOB ( const MuCTPIL1TopoCandidate roi) const
private

Definition at line 271 of file MuonInputProvider.cxx.

271  {
272 
273 
274  ATH_MSG_DEBUG("Late Muon ROI (MuCTPiToTopo):bcid=1 thr pt = " << roi.getptThresholdID() << " eta = " << roi.geteta() << " phi = " << roi.getphi() << ", w = " << MSG::hex << std::setw( 8 ) << roi.getRoiID() << MSG::dec);
275 
276  float fEta = roi.geteta();
277  float fPhi = roi.getphi();
278 
279  int etaTopo = TSU::toTopoEta(fEta);
280  unsigned int phiTopo = TSU::toTopoPhi(fPhi);
281 
282  unsigned int EtTopo = roi.getptValue()*10;
283 
284 
285  TCS::LateMuonTOB muon( EtTopo, 0, etaTopo, phiTopo, roi.getRoiID() );
286 
287  muon.setEtDouble(static_cast<double>(EtTopo/10.));
288  muon.setEtaDouble(static_cast<double>(etaTopo/40.));
289  muon.setPhiDouble(static_cast<double>(phiTopo/20.));
290 
291  // Muon flags
292  if ( roi.getSectorName().at(0) != 'B' ) { // TGC ( endcap (E) + forward (F) )
293  muon.setBW2or3( topoFlag(roi.getbw2or3()) );
294  muon.setInnerCoin( topoFlag(roi.getinnerCoin()) );
295  muon.setGoodMF( topoFlag(roi.getgoodMF()) );
296  muon.setCharge( topoFlag(roi.getcharge()) );
297  muon.setIs2cand( 0 );
298  muon.setIsTGC( 1 );
299  }
300  else { // RPC ( barrel (B) )
301  muon.setBW2or3( 0 );
302  muon.setInnerCoin( 0 );
303  muon.setGoodMF( 0 );
304  muon.setCharge( 0 );
305  muon.setIs2cand( topoFlag(roi.getis2cand()) );
306  muon.setIsTGC( 0 );
307  }
308 
309  auto mon_hLateMuonPt = Monitored::Scalar("LateMuonTOBPt", muon.EtDouble());
310  auto mon_hLateMuonPtTGC = Monitored::Scalar("LateMuonTOBPtTGC", muon.EtDouble());
311  auto mon_hLateMuonPtRPC = Monitored::Scalar("LateMuonTOBPtRPC", muon.EtDouble());
312  auto mon_hLateMuonEta = Monitored::Scalar("LateMuonTOBEta",muon.eta());
313  auto mon_hLateMuonPhi = Monitored::Scalar("LateMuonTOBPhi",muon.phi());
314  auto mon_hLateMuonBW2or3 = Monitored::Scalar("LateMuonTOBBW2or3",muon.bw2or3());
315  auto mon_hLateMuonInnerCoin = Monitored::Scalar("LateMuonTOBInnerCoin",muon.innerCoin());
316  auto mon_hLateMuonGoodMF = Monitored::Scalar("LateMuonTOBGoodMF",muon.goodMF());
317  auto mon_hLateMuonCharge = Monitored::Scalar("LateMuonTOBCharge",muon.charge());
318  auto mon_hLateMuonIs2cand = Monitored::Scalar("LateMuonTOBIs2cand",muon.is2cand());
319  auto mon_hLateMuonIsTGC = Monitored::Scalar("LateMuonTOBIsTGC",muon.isTGC());
320  Monitored::Group(m_monTool, mon_hLateMuonPt, mon_hLateMuonEta, mon_hLateMuonPhi, mon_hLateMuonBW2or3, mon_hLateMuonInnerCoin, mon_hLateMuonGoodMF, mon_hLateMuonCharge, mon_hLateMuonIs2cand, mon_hLateMuonIsTGC);
321  if ( muon.isTGC() ) { Monitored::Group(m_monTool, mon_hLateMuonPtTGC); }
322  else { Monitored::Group(m_monTool, mon_hLateMuonPtRPC); }
323 
324  ATH_MSG_DEBUG("LateMuon created");
325  return muon;
326 }

◆ createLateMuonTOB() [2/2]

TCS::LateMuonTOB MuonInputProvider::createLateMuonTOB ( const xAOD::MuonRoI muonRoI,
const std::vector< unsigned int > &  rpcPtValues,
const std::vector< unsigned int > &  tgcPtValues 
) const
private

Definition at line 202 of file MuonInputProvider.cxx.

202  {
203 
204 
205  float et;
206  float eta = muonRoI.eta();
207  float phi = muonRoI.phi();
208 
209  int etaTopo = TSU::toTopoEta(eta);
210  unsigned int phiTopo = TSU::toTopoPhi(phi);
211 
212  // WARNING::
213  // Also uses mapping for thrNumber : thrValue , see above.
214  int thrNumber = muonRoI.getThrNumber();
215 
216  if (muonRoI.getSource() == xAOD::MuonRoI::RoISource::Barrel) { //RPC
217  et = rpcPtValues[thrNumber]; //map is in GeV
218  } else {
219  et = tgcPtValues[thrNumber]; //map is in GeV
220  }
221 
222  unsigned int EtTopo = et*10;
223 
224  ATH_MSG_DEBUG("LateMuon ROI: " << muonRoI.getSource() << " thrvalue = " << thrNumber << " eta = " << etaTopo << " phi = " << phiTopo << " BW2or3 " << muonRoI.getBW3Coincidence() << " Good MF " << muonRoI.getGoodMF() << " Inner Coincidence " << muonRoI.getInnerCoincidence() << " Charge " << muonRoI.getCharge() << ", w = " << MSG::hex << std::setw( 8 ) << muonRoI.getRoI() << MSG::dec);
225 
226  TCS::LateMuonTOB muon( EtTopo, 0, etaTopo, static_cast<unsigned int>(phiTopo), muonRoI.getRoI() );
227  muon.setEtDouble(static_cast<double>(EtTopo/10.));
228  muon.setEtaDouble(static_cast<double>(etaTopo/40.));
229  muon.setPhiDouble(static_cast<double>(phiTopo/20.));
230 
231  // Muon flags
232  if ( muonRoI.getSource() != xAOD::MuonRoI::RoISource::Barrel) { // TGC ( endcap (E) + forward (F) )
233  muon.setBW2or3( topoFlag(muonRoI.getBW3Coincidence()) ); //Needs checking if this is the right flag
234  muon.setInnerCoin( topoFlag(muonRoI.getInnerCoincidence()) );
235  muon.setGoodMF( topoFlag(muonRoI.getGoodMF()) );
236  muon.setCharge( topoFlag(muonRoI.getCharge()) );
237  muon.setIs2cand( 0 );
238  muon.setIsTGC( 1 );
239  }
240  else { // RPC ( barrel (B) )
241  muon.setBW2or3( 0 );
242  muon.setInnerCoin( 0 );
243  muon.setGoodMF( 0 );
244  muon.setCharge( 0 );
245  muon.setIs2cand( topoFlag(muonRoI.isMoreCandInRoI()) ); //Needs checking if this is the right flag
246  muon.setIsTGC( 0 );
247  }
248 
249  auto mon_hLateMuonPt = Monitored::Scalar("LateMuonTOBPt", muon.EtDouble());
250  auto mon_hLateMuonPtTGC = Monitored::Scalar("LateMuonTOBPtTGC", muon.EtDouble());
251  auto mon_hLateMuonPtRPC = Monitored::Scalar("LateMuonTOBPtRPC", muon.EtDouble());
252  auto mon_hLateMuonEta = Monitored::Scalar("LateMuonTOBEta",muon.eta());
253  auto mon_hLateMuonPhi = Monitored::Scalar("LateMuonTOBPhi",muon.phi());
254  auto mon_hLateMuonBW2or3 = Monitored::Scalar("LateMuonTOBBW2or3",muon.bw2or3());
255  auto mon_hLateMuonInnerCoin = Monitored::Scalar("LateMuonTOBInnerCoin",muon.innerCoin());
256  auto mon_hLateMuonGoodMF = Monitored::Scalar("LateMuonTOBGoodMF",muon.goodMF());
257  auto mon_hLateMuonCharge = Monitored::Scalar("LateMuonTOBCharge",muon.charge());
258  auto mon_hLateMuonIs2cand = Monitored::Scalar("LateMuonTOBIs2cand",muon.is2cand());
259  auto mon_hLateMuonIsTGC = Monitored::Scalar("LateMuonTOBIsTGC",muon.isTGC());
260  Monitored::Group(m_monTool, mon_hLateMuonPt, mon_hLateMuonEta, mon_hLateMuonPhi, mon_hLateMuonBW2or3, mon_hLateMuonInnerCoin, mon_hLateMuonGoodMF, mon_hLateMuonCharge, mon_hLateMuonIs2cand, mon_hLateMuonIsTGC);
261  if ( muon.isTGC() ) { Monitored::Group(m_monTool, mon_hLateMuonPtTGC); }
262  else { Monitored::Group(m_monTool, mon_hLateMuonPtRPC); }
263 
264  ATH_MSG_DEBUG("LateMuon created");
265  return muon;
266 
267 }

◆ createMuonTOB() [1/2]

TCS::MuonTOB MuonInputProvider::createMuonTOB ( const MuCTPIL1TopoCandidate roi) const
private

Definition at line 141 of file MuonInputProvider.cxx.

141  {
142  ATH_MSG_DEBUG("Muon ROI (MuCTPiToTopo): thr ID = " << roi.getptThresholdID() << " eta = " << roi.geteta() << " phi = " << roi.getphi()
143  << ", w = " << MSG::hex << std::setw( 8 ) << roi.getRoiID() << MSG::dec );
144  ATH_MSG_DEBUG(" Oct = " << roi.getMioctID() << " etacode=" << roi.getetacode() << " phicode= " <<
145  roi.getphicode()<< ", Sector="<< roi.getSectorName() );
146 
147  // roi.geteta() and roi.getphi() return the the exact geometrical coordinates of the trigger chambers
148  // L1Topo granularities are 0.025 for eta (=> inverse = 40) and 0.05 for phi (=> inverse = 20)
149  // L1Topo simulation uses positive phi (from 0 to 2pi) => transform phiTopo
150  float fEta = roi.geteta();
151  float fPhi = roi.getphi();
152 
153  int etaTopo = TSU::toTopoEta(fEta);
154  unsigned int phiTopo = TSU::toTopoPhi(fPhi);
155 
156  unsigned int EtTopo = roi.getptValue()*10;
157 
158 
159 
160  TCS::MuonTOB muon( EtTopo, 0, etaTopo, phiTopo, roi.getRoiID() );
161  muon.setEtDouble(static_cast<double>(EtTopo/10.));
162  muon.setEtaDouble(static_cast<double>(etaTopo/40.));
163  muon.setPhiDouble(static_cast<double>(phiTopo/20.));
164 
165  // Muon flags
166  if ( roi.getSectorName().at(0) != 'B' ) { // TGC ( endcap (E) + forward (F) )
167  muon.setBW2or3( topoFlag(roi.getbw2or3()) );
168  muon.setInnerCoin( topoFlag(roi.getinnerCoin()) );
169  muon.setGoodMF( topoFlag(roi.getgoodMF()) );
170  muon.setCharge( topoFlag(roi.getcharge()) );
171  muon.setIs2cand( 0 );
172  muon.setIsTGC( 1 );
173  }
174  else { // RPC ( barrel (B) )
175  muon.setBW2or3( 0 );
176  muon.setInnerCoin( 0 );
177  muon.setGoodMF( 0 );
178  muon.setCharge( 0 );
179  muon.setIs2cand( topoFlag(roi.getis2cand()) );
180  muon.setIsTGC( 0 );
181  }
182 
183  auto mon_hPt = Monitored::Scalar("MuonTOBPt", muon.EtDouble());
184  auto mon_hPtTGC = Monitored::Scalar("MuonTOBPtTGC", muon.EtDouble());
185  auto mon_hPtRPC = Monitored::Scalar("MuonTOBPtRPC", muon.EtDouble());
186  auto mon_hEta = Monitored::Scalar("MuonTOBEta",muon.eta());
187  auto mon_hPhi = Monitored::Scalar("MuonTOBPhi",muon.phi());
188  auto mon_hBW2or3 = Monitored::Scalar("MuonTOBBW2or3",muon.bw2or3());
189  auto mon_hInnerCoin = Monitored::Scalar("MuonTOBInnerCoin",muon.innerCoin());
190  auto mon_hGoodMF = Monitored::Scalar("MuonTOBGoodMF",muon.goodMF());
191  auto mon_hCharge = Monitored::Scalar("MuonTOBCharge",muon.charge());
192  auto mon_hIs2cand = Monitored::Scalar("MuonTOBIs2cand",muon.is2cand());
193  auto mon_hIsTGC = Monitored::Scalar("MuonTOBIsTGC",muon.isTGC());
194  Monitored::Group(m_monTool, mon_hPt, mon_hEta, mon_hPhi, mon_hBW2or3, mon_hInnerCoin, mon_hGoodMF, mon_hCharge, mon_hIs2cand, mon_hIsTGC);
195  if ( muon.isTGC() ) { Monitored::Group(m_monTool, mon_hPtTGC); }
196  else { Monitored::Group(m_monTool, mon_hPtRPC); }
197 
198  return muon;
199 }

◆ createMuonTOB() [2/2]

TCS::MuonTOB MuonInputProvider::createMuonTOB ( const xAOD::MuonRoI muonRoI,
const std::vector< unsigned int > &  rpcPtValues,
const std::vector< unsigned int > &  tgcPtValues 
) const
private

Definition at line 69 of file MuonInputProvider.cxx.

69  {
70 
71 
72  float et;
73  float fEta = muonRoI.eta();
74  float fPhi = muonRoI.phi();
75 
76  int etaTopo = TSU::toTopoEta(fEta);
77  unsigned int phiTopo = TSU::toTopoPhi(fPhi);
78 
79  // WARNING::
80  // This uses a mapping for thrNumber : thrValue , where the thresholds
81  // can change per run, and so the menu used might be different.
82  // This should be changed to read from threshold value as soon
83  // as it is available.
84  // See: https://its.cern.ch/jira/browse/ATR-26165
85 
86  int thrNumber = muonRoI.getThrNumber();
87 
88  if (muonRoI.getSource() == xAOD::MuonRoI::RoISource::Barrel) { //RPC
89  et = rpcPtValues[thrNumber]; //map is in GeV
90  } else {
91  et = tgcPtValues[thrNumber]; //map is in GeV
92  }
93 
94  unsigned int EtTopo = et*10;
95 
96 
97  ATH_MSG_DEBUG("Muon ROI: " << muonRoI.getSource() << " thrvalue = " << thrNumber << " eta = " << etaTopo << " phi = " << phiTopo << " BW2or3 " << muonRoI.getBW3Coincidence() << " Good MF " << muonRoI.getGoodMF() << " Inner Coincidence " << muonRoI.getInnerCoincidence() << " Charge " << muonRoI.getCharge() << ", w = " << MSG::hex << std::setw( 8 ) << muonRoI.getRoI() << MSG::dec);
98 
99  TCS::MuonTOB muon( EtTopo, 0, etaTopo, phiTopo, muonRoI.getRoI() );
100  muon.setEtDouble(static_cast<double>(EtTopo/10.));
101  muon.setEtaDouble(static_cast<double>(etaTopo/40.));
102  muon.setPhiDouble(static_cast<double>(phiTopo/20.));
103 
104  // Muon flags
105  if ( muonRoI.getSource() != xAOD::MuonRoI::RoISource::Barrel) { // TGC ( endcap (E) + forward (F) )
106  muon.setBW2or3( topoFlag(muonRoI.getBW3Coincidence()) ); //Needs checking if this is the right flag
107  muon.setInnerCoin( topoFlag(muonRoI.getInnerCoincidence()) );
108  muon.setGoodMF( topoFlag(muonRoI.getGoodMF()) );
109  muon.setCharge( topoFlag(muonRoI.getCharge()) );
110  muon.setIs2cand( 0 );
111  muon.setIsTGC( 1 );
112  }
113  else { // RPC ( barrel (B) )
114  muon.setBW2or3( 0 );
115  muon.setInnerCoin( 0 );
116  muon.setGoodMF( 0 );
117  muon.setCharge( 0 );
118  muon.setIs2cand( topoFlag(muonRoI.isMoreCandInRoI()) ); //Needs checking if this is the right flag
119  muon.setIsTGC( 0 );
120  }
121 
122  auto mon_hPt = Monitored::Scalar("MuonTOBPt", muon.EtDouble());
123  auto mon_hPtTGC = Monitored::Scalar("MuonTOBPtTGC", muon.EtDouble());
124  auto mon_hPtRPC = Monitored::Scalar("MuonTOBPtRPC", muon.EtDouble());
125  auto mon_hEta = Monitored::Scalar("MuonTOBEta",muon.eta());
126  auto mon_hPhi = Monitored::Scalar("MuonTOBPhi",muon.phi());
127  auto mon_hBW2or3 = Monitored::Scalar("MuonTOBBW2or3",muon.bw2or3());
128  auto mon_hInnerCoin = Monitored::Scalar("MuonTOBInnerCoin",muon.innerCoin());
129  auto mon_hGoodMF = Monitored::Scalar("MuonTOBGoodMF",muon.goodMF());
130  auto mon_hCharge = Monitored::Scalar("MuonTOBCharge",muon.charge());
131  auto mon_hIs2cand = Monitored::Scalar("MuonTOBIs2cand",muon.is2cand());
132  auto mon_hIsTGC = Monitored::Scalar("MuonTOBIsTGC",muon.isTGC());
133  Monitored::Group(m_monTool, mon_hPt, mon_hEta, mon_hPhi, mon_hBW2or3, mon_hInnerCoin, mon_hGoodMF, mon_hCharge, mon_hIs2cand, mon_hIsTGC);
134  if ( muon.isTGC() ) { Monitored::Group(m_monTool, mon_hPtTGC); }
135  else { Monitored::Group(m_monTool, mon_hPtRPC); }
136 
137  return muon;
138 }

◆ fillTopoInputEvent()

StatusCode MuonInputProvider::fillTopoInputEvent ( TCS::TopoInputEvent inputEvent) const
overridevirtual

Definition at line 335 of file MuonInputProvider.cxx.

335  {
336 
337  if (!m_MuonL1RoILocation.key().empty()) {
338 
339  ATH_MSG_DEBUG("Using muon inputs from L1 RoI");
340 
341  const TrigConf::L1Menu * l1menu = nullptr;
343 
344  //Read mapping from menu
345  const auto & exMU = l1menu->thrExtraInfo().MU();
346  auto rpcPtValues = exMU.knownRpcPtValues();
347  auto tgcPtValues = exMU.knownTgcPtValues();
348 
350  for (auto muonRoi : *muonROIs) {
351 
352  inputEvent.addMuon( MuonInputProvider::createMuonTOB( *muonRoi, rpcPtValues, tgcPtValues) );
353 
354  }
355 
356  // Also add LateMuons:
357  if(not m_MuonL1RoILocationPlusOne.key().empty()) {
358 
359  const EventContext& ctx = Gaudi::Hive::currentContext();
361 
362  if( latemuonROIs.isValid() ) {
363 
364  ATH_MSG_DEBUG( "Contains L1Topo LateMuons L1Muctpi object from StoreGate!" );
365 
366  for(const auto muonRoi : *latemuonROIs) {
367  inputEvent.addLateMuon( MuonInputProvider::createLateMuonTOB( *muonRoi, rpcPtValues, tgcPtValues) );
368  }
369  }
370  }
371  } else{
372 
373  ATH_MSG_DEBUG("Use MuCTPiToTopo granularity Muon ROIs.");
374 
375  // first see if L1Muctpi simulation already ran and object is in storegate, if not throw an error
376 
377  const LVL1::MuCTPIL1Topo* l1topo {nullptr};
378 
379  if(m_MuCTPItoL1TopoLocation.key().empty()==false){
381  if( l1topoh.isValid() ) l1topo = l1topoh.cptr();
382  }
383 
384  if( l1topo ) {
385  ATH_MSG_DEBUG("Use MuCTPiToTopo granularity Muon ROIs: retrieve from SG");
386 
387  const std::vector<MuCTPIL1TopoCandidate> & candList = l1topo->getCandidates();
388  for( const MuCTPIL1TopoCandidate & muCand : candList) {
389  inputEvent.addMuon( MuonInputProvider::createMuonTOB( muCand ) );
390  if(muCand.moreThan2CandidatesOverflow()){
391  inputEvent.setOverflowFromMuonInput(true);
392  ATH_MSG_DEBUG("setOverflowFromMuonInput : true (MuCTPIL1TopoCandidate from SG)");
393  }
394  }
395  } else {
396  ATH_MSG_ERROR("Couldn't retrieve L1Topo inputs from StoreGate");
397  return StatusCode::FAILURE;
398  }
399 
400  //BC+1 ... this can only come from simulation, in data taking this is collected by the L1Topo at its input
401  // so no need to do anything else here
402  if(m_MuCTPItoL1TopoLocationPlusOne.key().empty()==false) {
404  if( l1topoBC1.isValid() ) {
405  ATH_MSG_DEBUG( "Contains L1Topo LateMuons L1Muctpi object from StoreGate!" );
406  const std::vector<MuCTPIL1TopoCandidate> & candList = l1topoBC1->getCandidates();
407  for( const MuCTPIL1TopoCandidate& muCand : candList)
408  {
409  ATH_MSG_DEBUG("MuonInputProvider addLateMuon ");
410  inputEvent.addLateMuon( MuonInputProvider::createLateMuonTOB( muCand ) );
411  }
412  }
413  }
414  }
415  return StatusCode::SUCCESS;
416 }

◆ initialize()

StatusCode MuonInputProvider::initialize ( )
overridevirtual

Definition at line 36 of file MuonInputProvider.cxx.

36  {
37 
38  // Get the RPC and TGC RecRoI tool
39  ATH_CHECK( m_recRPCRoiTool.retrieve() );
40  ATH_CHECK( m_recTGCRoiTool.retrieve() );
41 
42  //This is a bit ugly but I've done it so the job options can be used to determine
43  //use of storegate
45 
48 
50 
51  // MuCTPIL1Topo from muon RoI
52  if (!m_MuonL1RoILocation.key().empty())
53  {m_MuonL1RoILocation = m_MuonL1RoILocation.key() + "FromMuonRoI";}
54  CHECK(m_MuonL1RoILocation.initialize(!m_MuonL1RoILocation.key().empty()));
55 
56 
57  //LateMuon from muonRoI
58  if(!m_MuonL1RoILocationPlusOne.key().empty()){
60  }
62 
63 
64  if (!m_monTool.empty()) ATH_CHECK(m_monTool.retrieve());
65 
66  return StatusCode::SUCCESS;
67 }

◆ topoFlag()

int MuonInputProvider::topoFlag ( bool  flag) const
private

Definition at line 329 of file MuonInputProvider.cxx.

329  {
330  if ( flag == true ) { return 1; }
331  else { return -1; }
332 }

Member Data Documentation

◆ m_monTool

ToolHandle<GenericMonitoringTool> LVL1::MuonInputProvider::m_monTool {this, "MonTool", "", "Monitoring tool to create online histograms"}
private

Definition at line 59 of file MuonInputProvider.h.

◆ m_MuCTPItoL1TopoLocation

SG::ReadHandleKey<LVL1::MuCTPIL1Topo> LVL1::MuonInputProvider::m_MuCTPItoL1TopoLocation { this, "locationMuCTPItoL1Topo", LVL1MUCTPI::DEFAULT_MuonL1TopoLocation, "Storegate key for MuCTPItoL1Topo "}
private

Definition at line 61 of file MuonInputProvider.h.

◆ m_MuCTPItoL1TopoLocationPlusOne

SG::ReadHandleKey<LVL1::MuCTPIL1Topo> LVL1::MuonInputProvider::m_MuCTPItoL1TopoLocationPlusOne { this, "locationMuCTPItoL1Topo1", LVL1MUCTPI::DEFAULT_MuonL1TopoLocation, "Storegate key for MuCTPItoL1TopoPlusOne"}
private

Definition at line 62 of file MuonInputProvider.h.

◆ m_MuonL1RoILocation

SG::ReadHandleKey<xAOD::MuonRoIContainer> LVL1::MuonInputProvider::m_MuonL1RoILocation {this, "locationMuonRoI", LVL1MUCTPI::DEFAULT_MuonL1TopoLocation, "Empty=Use Muctpi, LVL1MuonRoIs=Use reading from xAOD L1 RoI"}
private

Definition at line 63 of file MuonInputProvider.h.

◆ m_MuonL1RoILocationPlusOne

SG::ReadHandleKey<xAOD::MuonRoIContainer> LVL1::MuonInputProvider::m_MuonL1RoILocationPlusOne {this, "locationMuonRoI1", LVL1MUCTPI::DEFAULT_MuonL1TopoLocation, "Empty=Use Muctpi, LVL1MuonRoIs=Use reading from xAOD L1 RoI"}
private

Definition at line 64 of file MuonInputProvider.h.

◆ m_recRPCRoiTool

ToolHandle<LVL1::ITrigT1MuonRecRoiTool> LVL1::MuonInputProvider::m_recRPCRoiTool {this, "RecRpcRoiTool", "LVL1::TrigT1RPCRecRoiTool/TrigT1RPCRecRoiTool", "RPC RoI reconstruction tool"}
private

Definition at line 57 of file MuonInputProvider.h.

◆ m_recTGCRoiTool

ToolHandle<LVL1::ITrigT1MuonRecRoiTool> LVL1::MuonInputProvider::m_recTGCRoiTool {this, "RecTgcRoiTool", "LVL1::TrigT1TGCRecRoiTool/TrigT1TGCRecRoiTool", "TGC RoI reconstruction tool"}
private

Definition at line 58 of file MuonInputProvider.h.


The documentation for this class was generated from the following files:
LVL1::MuCTPIL1TopoCandidate::getphicode
unsigned int getphicode() const
Definition: MuCTPIL1TopoCandidate.h:77
python.PyKernel.retrieve
def retrieve(aClass, aKey=None)
Definition: PyKernel.py:110
TCS::LateMuonTOB
Definition: LateMuonTOB.h:13
TCS::TopoInputEvent::setOverflowFromMuonInput
void setOverflowFromMuonInput(bool v)
Definition: TopoInputEvent.cxx:338
TCS::TopoInputEvent::addLateMuon
StatusCode addLateMuon(const LateMuonTOB &muon)
Definition: TopoInputEvent.cxx:127
test_pyathena.eta
eta
Definition: test_pyathena.py:10
xAOD::muon
@ muon
Definition: TrackingPrimitives.h:195
et
Extra patterns decribing particle interation process.
LVL1::MuCTPIL1TopoCandidate::getcharge
int getcharge() const
Definition: MuCTPIL1TopoCandidate.h:88
TrigDefs::Group
Group
Properties of a chain group.
Definition: GroupProperties.h:13
LVL1::MuCTPIL1TopoCandidate::getptValue
unsigned int getptValue() const
Definition: MuCTPIL1TopoCandidate.h:73
LVL1::MuCTPIL1TopoCandidate::getRoiID
unsigned int getRoiID() const
Definition: MuCTPIL1TopoCandidate.h:69
TCS::MuonTOB
Definition: MuonTOB.h:14
LVL1::MuCTPIL1TopoCandidate::getis2cand
int getis2cand() const
Definition: MuCTPIL1TopoCandidate.h:87
xAOD::MuonRoI_v1::getInnerCoincidence
bool getInnerCoincidence() const
Returns whether or not there was an inner coincidence in the TGC.
Definition: MuonRoI_v1.cxx:299
LVL1::MuonInputProvider::m_recTGCRoiTool
ToolHandle< LVL1::ITrigT1MuonRecRoiTool > m_recTGCRoiTool
Definition: MuonInputProvider.h:58
xAOD::et
et
Definition: TrigEMCluster_v1.cxx:25
LVL1::MuCTPIL1TopoCandidate::geteta
float geteta() const
Definition: MuCTPIL1TopoCandidate.h:74
SG::ReadHandle
Definition: StoreGate/StoreGate/ReadHandle.h:70
TSU::toTopoEta
int toTopoEta(float eta)
Definition: Conversions.cxx:27
xAOD::MuonRoI_v1::getCharge
Charge getCharge() const
Returns the charge sign of the muon candidate.
Definition: MuonRoI_v1.cxx:264
xAOD::MuonRoI_v1::eta
float eta() const
The pseudorapidity ( ) of the muon candidate.
LVL1::MuCTPIL1Topo
MuCTPI input class to the L1Topo simulation.
Definition: MuCTPIL1Topo.h:24
LVL1::MuonInputProvider::m_MuCTPItoL1TopoLocation
SG::ReadHandleKey< LVL1::MuCTPIL1Topo > m_MuCTPItoL1TopoLocation
Definition: MuonInputProvider.h:61
TrigConf::L1Menu
L1 menu configuration.
Definition: L1Menu.h:28
LVL1::MuCTPIL1TopoCandidate::getbw2or3
bool getbw2or3() const
Definition: MuCTPIL1TopoCandidate.h:89
SG::VarHandleKey::key
const std::string & key() const
Return the StoreGate ID for the referenced object.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:141
LVL1::MuCTPIL1TopoCandidate::getinnerCoin
bool getinnerCoin() const
Definition: MuCTPIL1TopoCandidate.h:90
DetType::Barrel
@ Barrel
Definition: DetType.h:14
xAOD::phi
setEt phi
Definition: TrigEMCluster_v1.cxx:29
LVL1::MuonInputProvider::createLateMuonTOB
TCS::LateMuonTOB createLateMuonTOB(const xAOD::MuonRoI &muonRoI, const std::vector< unsigned int > &rpcPtValues, const std::vector< unsigned int > &tgcPtValues) const
Definition: MuonInputProvider.cxx:202
xAOD::MuonRoI_v1::isMoreCandInRoI
bool isMoreCandInRoI() const
Returns if there were other muons detected in the same RoI.
Definition: MuonRoI_v1.cxx:174
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
master.flag
bool flag
Definition: master.py:29
TCS::TopoInputEvent::addMuon
StatusCode addMuon(const MuonTOB &muon)
Definition: TopoInputEvent.cxx:122
test_pyathena.parent
parent
Definition: test_pyathena.py:15
xAOD::MuonRoI_v1::getSource
RoISource getSource() const
Returns the system that detected the muon candidate.
Definition: MuonRoI_v1.cxx:202
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
CHECK
#define CHECK(...)
Evaluate an expression and check for errors.
Definition: Control/AthenaKernel/AthenaKernel/errorcheck.h:422
SG::VarHandleKey::initialize
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:103
LVL1::MuonInputProvider::m_monTool
ToolHandle< GenericMonitoringTool > m_monTool
Definition: MuonInputProvider.h:59
xAOD::MuonRoI_v1::getRoI
int getRoI() const
Get the "RoI number" (position inside the sector)
Definition: MuonRoI_v1.cxx:89
LVL1::MuCTPIL1TopoCandidate::getetacode
unsigned int getetacode() const
Definition: MuCTPIL1TopoCandidate.h:76
LVL1::MuonInputProvider::m_MuCTPItoL1TopoLocationPlusOne
SG::ReadHandleKey< LVL1::MuCTPIL1Topo > m_MuCTPItoL1TopoLocationPlusOne
Definition: MuonInputProvider.h:62
TrigConf::name
Definition: HLTChainList.h:35
LVL1::MuCTPIL1TopoCandidate::getSectorName
const std::string & getSectorName() const
Definition: MuCTPIL1TopoCandidate.h:68
python.PyKernel.detStore
detStore
Definition: PyKernel.py:41
LVL1::MuCTPIL1TopoCandidate
MuCTPI input class to the L1Topo simulation.
Definition: MuCTPIL1TopoCandidate.h:23
ActsTrk::to_string
std::string to_string(const DetectorType &type)
Definition: GeometryDefs.h:34
LVL1::MuCTPIL1TopoCandidate::getptThresholdID
unsigned int getptThresholdID() const
Definition: MuCTPIL1TopoCandidate.h:71
LVL1::MuonInputProvider::createMuonTOB
TCS::MuonTOB createMuonTOB(const xAOD::MuonRoI &muonRoI, const std::vector< unsigned int > &rpcPtValues, const std::vector< unsigned int > &tgcPtValues) const
Definition: MuonInputProvider.cxx:69
LVL1::MuonInputProvider::topoFlag
int topoFlag(bool flag) const
Definition: MuonInputProvider.cxx:329
LVL1::MuonInputProvider::m_recRPCRoiTool
ToolHandle< LVL1::ITrigT1MuonRecRoiTool > m_recRPCRoiTool
Definition: MuonInputProvider.h:57
LVL1::MuCTPIL1TopoCandidate::getMioctID
unsigned int getMioctID() const
Definition: MuCTPIL1TopoCandidate.h:83
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
python.XMLReader.l1menu
l1menu
Definition: XMLReader.py:73
LVL1::MuCTPIL1TopoCandidate::getphi
float getphi() const
Definition: MuCTPIL1TopoCandidate.h:75
LVL1::MuCTPIL1TopoCandidate::getgoodMF
bool getgoodMF() const
Definition: MuCTPIL1TopoCandidate.h:91
xAOD::MuonRoI_v1::getBW3Coincidence
bool getBW3Coincidence() const
Returns whether or not there was a 3-station coincidence in the TGC.
Definition: MuonRoI_v1.cxx:289
LVL1::MuonInputProvider::m_MuonL1RoILocationPlusOne
SG::ReadHandleKey< xAOD::MuonRoIContainer > m_MuonL1RoILocationPlusOne
Definition: MuonInputProvider.h:64
Monitored::Scalar
Declare a monitored scalar variable.
Definition: MonitoredScalar.h:34
xAOD::MuonRoI_v1::getThrNumber
int getThrNumber() const
Get the logic number of the highest threshold this RoI passed.
Definition: MuonRoI_v1.cxx:76
xAOD::MuonRoI_v1::getGoodMF
bool getGoodMF() const
Returns whether or not there was a good magnetic field quality in the TGC.
Definition: MuonRoI_v1.cxx:309
LVL1::MuonInputProvider::m_MuonL1RoILocation
SG::ReadHandleKey< xAOD::MuonRoIContainer > m_MuonL1RoILocation
Definition: MuonInputProvider.h:63
TSU::toTopoPhi
unsigned int toTopoPhi(float phi)
Definition: Conversions.cxx:20
xAOD::MuonRoI_v1::phi
float phi() const
The azimuthal angle ( ) of the muon candidate.