ATLAS Offline Software
MuFastDataPreparator.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef TRIGL2MUONSA_MUFASTDATAPREPARATOR_H
6 #define TRIGL2MUONSA_MUFASTDATAPREPARATOR_H
7 
9 #include "GaudiKernel/ToolHandle.h"
10 
14 #include "xAODTrigger/MuonRoI.h"
15 
17 #include "RpcDataPreparator.h"
18 #include "RpcRoadDefiner.h"
19 #include "RpcPatFinder.h"
20 #include "TgcDataPreparator.h"
21 #include "TgcRoadDefiner.h"
22 #include "MdtDataPreparator.h"
23 #include "MdtRegion.h"
24 #include "CscDataPreparator.h"
25 #include "CscData.h"
26 #include "StgcDataPreparator.h"
27 #include "StgcData.h"
28 #include "MmDataPreparator.h"
29 #include "MmData.h"
30 
32 
34 
35 #include "ClusterRoadDefiner.h"
36 #include "RpcClusterPreparator.h"
37 #include "ClusterPatFinder.h"
38 
39 namespace TrigL2MuonSA {
40 
42  public:
43 
44  MuFastDataPreparator(const std::string& type,
45  const std::string& name,
46  const IInterface* parent);
47 
48  virtual StatusCode initialize() override;
49 
50  public:
51 
53  const TrigRoiDescriptor* p_roids,
54  const bool insideOut,
55  TrigL2MuonSA::RpcHits& rpcHits,
56  TrigL2MuonSA::MuonRoad& muonRoad,
57  TrigL2MuonSA::MdtRegion& mdtRegion,
58  TrigL2MuonSA::RpcFitResult& rpcFitResult,
59  TrigL2MuonSA::MdtHits& mdtHits_normal,
60  TrigL2MuonSA::MdtHits& mdtHits_overlap,
61  const bool dynamicDeltaRpc) const;
62 
64  const TrigRoiDescriptor* p_roids,
65  const bool insideOut,
66  TrigL2MuonSA::RpcHits& rpcHits,
67  TrigL2MuonSA::MuonRoad& muonRoad,
68  TrigL2MuonSA::MdtRegion& mdtRegion,
69  TrigL2MuonSA::RpcFitResult& rpcFitResult,
70  TrigL2MuonSA::MdtHits& mdtHits_normal,
71  TrigL2MuonSA::MdtHits& mdtHits_overlap,
72  const bool dynamicDeltaRpc) const;
73 
75  const TrigRoiDescriptor* p_roids,
76  const bool insideOut,
77  TrigL2MuonSA::TgcHits& tgcHits,
78  TrigL2MuonSA::MuonRoad& muonRoad,
79  TrigL2MuonSA::MdtRegion& mdtRegion,
80  TrigL2MuonSA::TgcFitResult& tgcFitResult,
81  TrigL2MuonSA::MdtHits& mdtHits_normal,
82  TrigL2MuonSA::MdtHits& mdtHits_overlap,
83  TrigL2MuonSA::CscHits& cscHits,
84  TrigL2MuonSA::StgcHits& stgcHits,
85  TrigL2MuonSA::MmHits& mmHits) const;
86 
88  const TrigRoiDescriptor* p_roids,
89  const bool insideOut,
90  TrigL2MuonSA::TgcHits& tgcHits,
91  TrigL2MuonSA::MuonRoad& muonRoad,
92  TrigL2MuonSA::MdtRegion& mdtRegion,
93  TrigL2MuonSA::TgcFitResult& tgcFitResult,
94  TrigL2MuonSA::MdtHits& mdtHits_normal,
95  TrigL2MuonSA::MdtHits& mdtHits_overlap,
96  TrigL2MuonSA::CscHits& cscHits,
97  TrigL2MuonSA::StgcHits& stgcHits,
98  TrigL2MuonSA::MmHits& mmHits) const;
99 
100  //for multi-track mode
102  const TrigRoiDescriptor* p_roids,
103  std::vector<TrigL2MuonSA::MuonRoad>& clusterRoad,
104  std::vector<TrigL2MuonSA::RpcFitResult>& clusterFitResults,
105  TrigL2MuonSA::MdtHits& mdtHits_normal,
106  TrigL2MuonSA::MdtHits& mdtHits_overlap,
107  std::vector<TrigL2MuonSA::MdtHits>& mdtHits_cluster_normal,
108  const bool dynamicDeltaRpc) const;
109 
110  StatusCode prepareData(const xAOD::MuonRoI* p_roi,
111  const TrigRoiDescriptor* p_roids,
112  std::vector<TrigL2MuonSA::MuonRoad>& clusterRoad,
113  std::vector<TrigL2MuonSA::RpcFitResult>& clusterFitResults,
114  TrigL2MuonSA::MdtHits& mdtHits_normal,
115  TrigL2MuonSA::MdtHits& mdtHits_overlap,
116  std::vector<TrigL2MuonSA::MdtHits>& mdtHits_cluster_normal,
117  const bool dynamicDeltaRpc) const;
118 
120 
121  void setRoadWidthForFailure(double rWidth_RPC_Failed, double rWidth_TGC_Failed);
122 
123  StatusCode setGeometry(bool use_new_geometry);
124  void setRpcGeometry(bool use_rpc);
125 
126  void setStgcGeometry(bool use_stgc){ m_use_stgc = use_stgc; };
127  void setMmGeometry(bool use_mm){ m_use_mm = use_mm; };
128 
129  StatusCode setMCFlag(const BooleanProperty& use_mcLUT);
130  void setRoIBasedDataAccess(bool use_RoIBasedDataAccess_MDT,
131  bool use_RoIBasedDataAccess_RPC,
132  bool use_RoIBasedDataAccess_TGC,
133  bool use_RoIBasedDataAccess_CSC,
134  bool use_RoIBasedDataAccess_STGC,
135  bool use_RoIBasedDataAccess_MM);
136 
137  void setExtrapolatorTool(ToolHandle<ITrigMuonBackExtrapolator>* backExtrapolator);
138 
139  private:
141 
142  ToolHandle<LVL1::ITrigT1MuonRecRoiTool> m_recRPCRoiTool{this, "TrigT1RPCRecRoiTool", "LVL1::TrigT1RPCRecRoiTool/TrigT1RPCRecRoiTool"};
143  ToolHandle<RpcDataPreparator> m_rpcDataPreparator{this, "RPCDataPreparator", "TrigL2MuonSA::RpcDataPreparator"};
144  ToolHandle<TgcDataPreparator> m_tgcDataPreparator{this, "TGCDataPreparator", "TrigL2MuonSA::TgcDataPreparator"};
145  ToolHandle<MdtDataPreparator> m_mdtDataPreparator{this, "MDTDataPreparator", "TrigL2MuonSA::MdtDataPreparator"};
146  ToolHandle<CscDataPreparator> m_cscDataPreparator{this, "CSCDataPreparator", "TrigL2MuonSA::CscDataPreparator"};
147  ToolHandle<StgcDataPreparator> m_stgcDataPreparator{this,"STGCDataPreparator","TrigL2MuonSA::StgcDataPreparator"};
148  ToolHandle<MmDataPreparator> m_mmDataPreparator{this, "MMDataPreparator", "TrigL2MuonSA::MmDataPreparator"};
149 
150  ToolHandle<RpcRoadDefiner> m_rpcRoadDefiner{this, "RpcRoadDefiner", "TrigL2MuonSA::RpcRoadDefiner"};
151  ToolHandle<TgcRoadDefiner> m_tgcRoadDefiner{this, "TgcRoadDefiner", "TrigL2MuonSA::TgcRoadDefiner"};
152  ToolHandle<RpcPatFinder> m_rpcPatFinder{"TrigL2MuonSA::RpcPatFinder"};
153 
154  //for multimu-in-pad mode
155  ToolHandle<ClusterRoadDefiner> m_clusterRoadDefiner{this, "ClusterRoadDefiner", "TrigL2MuonSA::ClusterRoadDefiner"};
156  ToolHandle<ClusterPatFinder> m_clusterPatFinder{this, "ClusterPatFinder", "TrigL2MuonSA::ClusterPatFinder"};
157  //
158 
159  ToolHandle<ITrigMuonBackExtrapolator>* m_backExtrapolatorTool{nullptr};
160 
161  bool m_use_rpc{false};
162  bool m_use_stgc{false};
163  bool m_use_mm{false};
164  bool m_use_mcLUT{false};
165 
166 };
167 
168 } // namespace TrigL2MuonSA
169 
170 #endif // MUFASTDATAPREPARATOR_H
TrigL2MuonSA::MuFastDataPreparator::setStgcGeometry
void setStgcGeometry(bool use_stgc)
Definition: MuFastDataPreparator.h:126
MuFastDataPreparatorOptions.h
TrigL2MuonSA::MuFastDataPreparator::m_backExtrapolatorTool
ToolHandle< ITrigMuonBackExtrapolator > * m_backExtrapolatorTool
Definition: MuFastDataPreparator.h:159
RpcPatFinder.h
ITrigMuonBackExtrapolator.h
TrigL2MuonSA::MuFastDataPreparator::setMmGeometry
void setMmGeometry(bool use_mm)
Definition: MuFastDataPreparator.h:127
TrigL2MuonSA::MuFastDataPreparator::setRpcGeometry
void setRpcGeometry(bool use_rpc)
Definition: MuFastDataPreparator.cxx:118
TrigL2MuonSA::RpcHits
std::vector< RpcHitData > RpcHits
Definition: RpcData.h:57
TrigL2MuonSA::MuFastDataPreparator::m_clusterPatFinder
ToolHandle< ClusterPatFinder > m_clusterPatFinder
Definition: MuFastDataPreparator.h:156
TrigL2MuonSA::MuFastDataPreparator::m_recRPCRoiTool
ToolHandle< LVL1::ITrigT1MuonRecRoiTool > m_recRPCRoiTool
Definition: MuFastDataPreparator.h:142
TrigL2MuonSA::RpcFitResult
Definition: RpcFitResult.h:14
TrigL2MuonSA::MuFastDataPreparatorOptions
Definition: MuFastDataPreparatorOptions.h:17
TrigL2MuonSA::MuFastDataPreparator::m_mdtDataPreparator
ToolHandle< MdtDataPreparator > m_mdtDataPreparator
Definition: MuFastDataPreparator.h:145
TrigL2MuonSA::TgcFitResult
Definition: TgcFitResult.h:11
ClusterRoadDefiner.h
MmData.h
MdtDataPreparator.h
TrigL2MuonSA::MdtHits
std::vector< MdtHitData > MdtHits
Definition: MdtData.h:57
TrigL2MuonSA::TgcHits
std::vector< TgcHitData > TgcHits
Definition: TgcData.h:43
TrigL2MuonSA::MuFastDataPreparator::m_use_mcLUT
bool m_use_mcLUT
Definition: MuFastDataPreparator.h:164
RecMuonRoI.h
StgcDataPreparator.h
TrigRoiDescriptor
nope - should be used for standalone also, perhaps need to protect the class def bits #ifndef XAOD_AN...
Definition: TrigRoiDescriptor.h:56
TrigL2MuonSA::CscHits
std::vector< CscHitData > CscHits
Definition: CscData.h:40
TrigL2MuonSA::MuFastDataPreparator::setRoIBasedDataAccess
void setRoIBasedDataAccess(bool use_RoIBasedDataAccess_MDT, bool use_RoIBasedDataAccess_RPC, bool use_RoIBasedDataAccess_TGC, bool use_RoIBasedDataAccess_CSC, bool use_RoIBasedDataAccess_STGC, bool use_RoIBasedDataAccess_MM)
Definition: MuFastDataPreparator.cxx:128
TrigL2MuonSA::MdtRegion
Definition: MdtRegion.h:14
TrigL2MuonSA::MuFastDataPreparator::m_rpcRoadDefiner
ToolHandle< RpcRoadDefiner > m_rpcRoadDefiner
Definition: MuFastDataPreparator.h:150
TrigL2MuonSA::MuFastDataPreparator::m_options
TrigL2MuonSA::MuFastDataPreparatorOptions m_options
Definition: MuFastDataPreparator.h:140
TrigL2MuonSA::MuFastDataPreparator::setOptions
void setOptions(const TrigL2MuonSA::MuFastDataPreparatorOptions &options)
Definition: MuFastDataPreparator.cxx:71
LVL1::RecMuonRoI
This class defines the reconstructed Muon ROI.
Definition: RecMuonRoI.h:60
TrigL2MuonSA::MuonRoad
Definition: MuonRoad.h:20
CscData.h
TrigL2MuonSA::MuFastDataPreparator::m_mmDataPreparator
ToolHandle< MmDataPreparator > m_mmDataPreparator
Definition: MuFastDataPreparator.h:148
RpcClusterPreparator.h
TrigL2MuonSA::MuFastDataPreparator::MuFastDataPreparator
MuFastDataPreparator(const std::string &type, const std::string &name, const IInterface *parent)
Definition: MuFastDataPreparator.cxx:11
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
MmDataPreparator.h
AthAlgTool.h
xAOD::MuonRoI_v1
Class describing a LVL1 muon region of interest.
Definition: MuonRoI_v1.h:29
RpcDataPreparator.h
test_pyathena.parent
parent
Definition: test_pyathena.py:15
TrigL2MuonSA::MuFastDataPreparator::initialize
virtual StatusCode initialize() override
Definition: MuFastDataPreparator.cxx:22
TgcRoadDefiner.h
ClusterPatFinder.h
TrigL2MuonSA::MuFastDataPreparator::setExtrapolatorTool
void setExtrapolatorTool(ToolHandle< ITrigMuonBackExtrapolator > *backExtrapolator)
Definition: MuFastDataPreparator.cxx:147
TrigL2MuonSA::MuFastDataPreparator::m_rpcPatFinder
ToolHandle< RpcPatFinder > m_rpcPatFinder
Definition: MuFastDataPreparator.h:152
python.AtlRunQueryLib.options
options
Definition: AtlRunQueryLib.py:379
CscDataPreparator.h
ITrigT1MuonRecRoiTool.h
TrigL2MuonSA::MuFastDataPreparator::m_use_rpc
bool m_use_rpc
Definition: MuFastDataPreparator.h:161
MdtRegion.h
ReadCondHandleKey.h
TrigL2MuonSA::MuFastDataPreparator::m_rpcDataPreparator
ToolHandle< RpcDataPreparator > m_rpcDataPreparator
Definition: MuFastDataPreparator.h:143
TrigL2MuonSA::MuFastDataPreparator::m_stgcDataPreparator
ToolHandle< StgcDataPreparator > m_stgcDataPreparator
Definition: MuFastDataPreparator.h:147
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
TrigL2MuonSA::MuFastDataPreparator::m_use_stgc
bool m_use_stgc
Definition: MuFastDataPreparator.h:162
TrigL2MuonSA::MuFastDataPreparator::m_cscDataPreparator
ToolHandle< CscDataPreparator > m_cscDataPreparator
Definition: MuFastDataPreparator.h:146
TgcDataPreparator.h
TrigL2MuonSA::MuFastDataPreparator::setRoadWidthForFailure
void setRoadWidthForFailure(double rWidth_RPC_Failed, double rWidth_TGC_Failed)
Definition: MuFastDataPreparator.cxx:107
TrigL2MuonSA::MuFastDataPreparator::m_clusterRoadDefiner
ToolHandle< ClusterRoadDefiner > m_clusterRoadDefiner
Definition: MuFastDataPreparator.h:155
TrigL2MuonSA::MuFastDataPreparator::m_tgcRoadDefiner
ToolHandle< TgcRoadDefiner > m_tgcRoadDefiner
Definition: MuFastDataPreparator.h:151
TrigL2MuonSA::MmHits
std::vector< MmHitData > MmHits
Definition: MmData.h:47
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
TrigL2MuonSA::StgcHits
std::vector< StgcHitData > StgcHits
Definition: StgcData.h:49
MuonRoI.h
RpcRoadDefiner.h
TrigL2MuonSA::MuFastDataPreparator::setMCFlag
StatusCode setMCFlag(const BooleanProperty &use_mcLUT)
Definition: MuFastDataPreparator.cxx:81
TrigRoiDescriptor.h
TrigL2MuonSA::MuFastDataPreparator::setGeometry
StatusCode setGeometry(bool use_new_geometry)
TrigL2MuonSA::MuFastDataPreparator::m_tgcDataPreparator
ToolHandle< TgcDataPreparator > m_tgcDataPreparator
Definition: MuFastDataPreparator.h:144
TrigL2MuonSA::MuFastDataPreparator::prepareData
StatusCode prepareData(const LVL1::RecMuonRoI *p_roi, const TrigRoiDescriptor *p_roids, const bool insideOut, TrigL2MuonSA::RpcHits &rpcHits, TrigL2MuonSA::MuonRoad &muonRoad, TrigL2MuonSA::MdtRegion &mdtRegion, TrigL2MuonSA::RpcFitResult &rpcFitResult, TrigL2MuonSA::MdtHits &mdtHits_normal, TrigL2MuonSA::MdtHits &mdtHits_overlap, const bool dynamicDeltaRpc) const
Definition: MuFastDataPreparator.cxx:157
AthAlgTool
Definition: AthAlgTool.h:26
StgcData.h
TrigL2MuonSA::MuFastDataPreparator::m_use_mm
bool m_use_mm
Definition: MuFastDataPreparator.h:163
TrigL2MuonSA::MuFastDataPreparator
Definition: MuFastDataPreparator.h:41
TrigL2MuonSA
Definition: AlignmentBarrelLUT.h:13