ATLAS Offline Software
Loading...
Searching...
No Matches
TgcCablingMap.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
3*/
4
5/***************************************************************************
6 TgcCablingMap.h
7 Description : online-offline ID mapper for TGC
8***************************************************************************/
9
10#ifndef MUONTGC_CABLING_MUONTGC_CABLINGMAP_H
11#define MUONTGC_CABLING_MUONTGC_CABLINGMAP_H
12
17
18class Identifier;
19namespace Muon {
22 public:
29 TgcCablingMap(const Config& cfg);
30
32
33 // give max value of the ROD ID
34 static constexpr int getMaxRodId() {
36 }
37
38 // give max value of ReadoutID parameters
40 void getReadoutIDRanges(int& maxRodId, int& maxSRodId, int& maxSswId,
41 int& maxSbloc, int& minChannelId,
42 int& maxChannelId) const;
43
44 bool getCoveragefromSRodID(const int srodID, int& startEndcapSector,
45 int& coverageOfEndcapSector,
46 int& startForwardSector,
47 int& coverageOfForwardSector) const;
48
49 // Readout ID is ored
51 bool isOredChannel(const int subDetectorID, const int rodID,
52 const int sswID, const int sbLoc,
53 const int channelID) const;
54
55 // Offline ID has adjacent Readout ID
56 bool hasAdjacentChannel(const Identifier& offlineID) const;
57 // readout IDs -> offline IDs
60 const int subDetectorID, const int rodID,
61 const int sswID, const int sbLoc,
62 const int channelID,
63 bool orChannel = false) const;
64
65 // offline IDs -> readout IDs
66 bool getReadoutIDfromOfflineID(const Identifier& offlineID,
67 int& subDetectorID, int& rodID, int& sswID,
68 int& sbLoc, int& channelID,
69 bool adChannel = false) const;
70
71 // offline ID -> online IDs
72 bool getOnlineIDfromOfflineID(const Identifier& offlineID,
73 int& subsystemNumber, int& octantNumber,
74 int& moduleNumber, int& layerNumber,
75 int& rNumber, int& wireOrStrip,
76 int& channelNumber) const;
77
78 // online IDs -> offline ID
80 const int subsystemNumber,
81 const int octantNumber,
82 const int moduleNumber, const int layerNumber,
83 const int rNumber, const int wireOrStrip,
84 const int channelNumber) const;
85
86 // readout IDs -> online IDs
87 bool getOnlineIDfromReadoutID(const int subDetectorID, const int rodID,
88 const int sswID, const int sbLoc,
89 const int channelID, int& subsystemNumber,
90 int& octantNumber, int& moduleNumber,
91 int& layerNumber, int& rNumber,
92 int& wireOrStrip, int& channelNumber,
93 bool orChannel = false) const;
94
95 // online IDs -> readout IDs
96 bool getReadoutIDfromOnlineID(int& subDetectorID, int& rodID, int& sswID,
97 int& sbLoc, int& channelID,
98 const int subsystemNumber,
99 const int octantNumber,
100 const int moduleNumber, const int layerNumber,
101 const int rNumber, const int wireOrStrip,
102 const int channelNumber,
103 bool adChannel = false) const;
104
105 // element ID -> readout IDs
106 bool getReadoutIDfromElementID(const Identifier& elementID,
107 int& subdetectorID, int& rodID) const;
108
109 // readout IDs -> element ID
111 const int subDetectorID, const int rodID,
112 const int sswID, const int sbLoc,
113 const int channelID,
114 bool orChannel = false) const;
115
116 // HPT ID -> readout ID
117 bool getReadoutIDfromHPTID(const int phi, const bool isAside,
118 const bool isEndcap, const bool isStrip,
119 const int id, int& subsectorID, int& rodID,
120 int& sswID, int& sbLoc) const;
121
122 // readout ID -> SLB ID
123 bool getSLBIDfromReadoutID(int& phi, bool& isAside, bool& isEndcap,
124 int& moduleType, int& id, const int subsectorID,
125 const int rodID, const int sswID,
126 const int sbLoc) const;
127
128 // readout ID -> slbAddr
129 bool getSLBAddressfromReadoutID(int& slbAddr, const int subsectorID,
130 const int rodID, const int sswID,
131 const int sbLoc) const;
132
133 // ROD_ID / SSW_ID / RX_ID -> SLB ID
134 bool getSLBIDfromRxID(int& phi, bool& isAside, bool& isEndcap,
135 int& moduleType, int& id, const int subsectorID,
136 const int rodID, const int sswID,
137 const int rxId) const;
138
139 // SLB ID -> readout ID
140 bool getReadoutIDfromSLBID(const int phi, const bool isAside,
141 const bool isEndcap, const int moduleType,
142 const int id, int& subsectorID, int& rodID,
143 int& sswID, int& sbLoc) const;
144
145 // readout ID (ROD) -> SL ID
146 bool getSLIDfromReadoutID(int& phi, bool& isAside, bool& isEndcap,
147 const int subsectorID, const int rodID,
148 const int sswID, const int sbLoc) const;
149
150 // readout ID (SROD) -> SL ID
151 bool getSLIDfromSReadoutID(int& phi, bool& isAside, const int subsectorID,
152 const int srodID, const int sector,
153 const bool forward) const;
154 // SL ID -> readout ID ( ROD )
155 bool getReadoutIDfromSLID(const int phi, const bool isAside,
156 const bool isEndcap, int& subsectorID, int& rodID,
157 int& sswID, int& sbLoc) const;
158
159 // SL ID -> readout ID ( SROD )
160 bool getSReadoutIDfromSLID(const int phi, const bool isAside,
161 const bool isEndcap, int& subsectorID,
162 int& srodID, int& sswID, int& sbLoc) const;
163 // HighPtID used in Simulation -> HighPtID in RDO
164 bool getRDOHighPtIDfromSimHighPtID(const bool isForward, const bool isStrip,
165 int& index, int& chip, int& hitId) const;
166
167 // HighPtID in RDO -> HighPtID used in Simulation
168 bool getSimHighPtIDfromRDOHighPtID(const bool isForward, const bool isStrip,
169 int& index, int& chip, int& hitId) const;
170
171 // high pt coincidence IDs -> offline IDs
172 bool getOfflineIDfromHighPtID(Identifier& offlineID,
173 const int subDetectorID, const int rodID,
174 const int sectorInReadout, const bool isStrip,
175 const bool isForward, const int hpb,
176 const int chip, const int hitID,
177 const int pos) const;
178
179 // offline IDs -> high pt coincidence IDs
180 bool getHighPtIDfromOfflineID(const Identifier& offlineID,
181 int& subDetectorID, int& rodID,
182 int& sectorInReadout, bool& isStrip,
183 bool& isForward, int& hpb, int& chip,
184 int& hitID, int& pos) const;
185
186 // HPT HitID -> ROI Number
187 bool getROINumberfromHighPtID(int& roi, bool isForward, int hpb_wire,
188 int chip_wire, int hitId_wire, int sub_wire,
189 int chip_strip, int hitId_strip,
190 int sub_strip) const;
191
192 // HPT HitID -> ROI Number
193 bool getHighPtIDfromROINumber(int roi, bool isForward, bool isStrip,
194 int& hpb, int& chip, int& hitID,
195 int& sub) const;
196
197 // low pt coincidence IDs -> offline IDs
199 const int subDetectorID,
200 const int rodID, const int sswID,
201 const int sbLoc, const int block,
202 const int pos,
203 bool middle = false) const;
204
205 private:
207 int m_AsideId{103};
208 int m_CsideId{104};
209};
210
211} // namespace Muon
214
215#endif
Scalar phi() const
phi method
Hold mappings of ranges to condition objects.
#define CONDCONT_DEF(...)
Definition CondCont.h:1413
macros to associate a CLID to a type
#define CLASS_DEF(NAME, CID, VERSION)
associate a clid and a version to a type eg
AthMessaging(IMessageSvc *msgSvc, const std::string &name)
Constructor.
Interface for Helper service that creates muon Identifiers and can be used to print Identifiers.
bool getOfflineIDfromHighPtID(Identifier &offlineID, const int subDetectorID, const int rodID, const int sectorInReadout, const bool isStrip, const bool isForward, const int hpb, const int chip, const int hitID, const int pos) const
bool getCoveragefromSRodID(const int srodID, int &startEndcapSector, int &coverageOfEndcapSector, int &startForwardSector, int &coverageOfForwardSector) const
bool getSLBAddressfromReadoutID(int &slbAddr, const int subsectorID, const int rodID, const int sswID, const int sbLoc) const
bool getSLBIDfromReadoutID(int &phi, bool &isAside, bool &isEndcap, int &moduleType, int &id, const int subsectorID, const int rodID, const int sswID, const int sbLoc) const
bool getReadoutIDfromHPTID(const int phi, const bool isAside, const bool isEndcap, const bool isStrip, const int id, int &subsectorID, int &rodID, int &sswID, int &sbLoc) const
const Muon::IMuonIdHelperSvc * m_idHelperSvc
bool getHighPtIDfromOfflineID(const Identifier &offlineID, int &subDetectorID, int &rodID, int &sectorInReadout, bool &isStrip, bool &isForward, int &hpb, int &chip, int &hitID, int &pos) const
bool getElementIDfromReadoutID(Identifier &elementID, const int subDetectorID, const int rodID, const int sswID, const int sbLoc, const int channelID, bool orChannel=false) const
bool getReadoutIDfromSLBID(const int phi, const bool isAside, const bool isEndcap, const int moduleType, const int id, int &subsectorID, int &rodID, int &sswID, int &sbLoc) const
static constexpr int getMaxRodId()
bool getReadoutIDfromOnlineID(int &subDetectorID, int &rodID, int &sswID, int &sbLoc, int &channelID, const int subsystemNumber, const int octantNumber, const int moduleNumber, const int layerNumber, const int rNumber, const int wireOrStrip, const int channelNumber, bool adChannel=false) const
bool getRDOHighPtIDfromSimHighPtID(const bool isForward, const bool isStrip, int &index, int &chip, int &hitId) const
bool getOnlineIDfromReadoutID(const int subDetectorID, const int rodID, const int sswID, const int sbLoc, const int channelID, int &subsystemNumber, int &octantNumber, int &moduleNumber, int &layerNumber, int &rNumber, int &wireOrStrip, int &channelNumber, bool orChannel=false) const
bool getOfflineIDfromReadoutID(Identifier &offlineID, const int subDetectorID, const int rodID, const int sswID, const int sbLoc, const int channelID, bool orChannel=false) const
To be ported.
bool getSLIDfromReadoutID(int &phi, bool &isAside, bool &isEndcap, const int subsectorID, const int rodID, const int sswID, const int sbLoc) const
bool getReadoutIDfromOfflineID(const Identifier &offlineID, int &subDetectorID, int &rodID, int &sswID, int &sbLoc, int &channelID, bool adChannel=false) const
const MuonTGC_Cabling::TGCCabling * getTGCCabling() const
bool getHighPtIDfromROINumber(int roi, bool isForward, bool isStrip, int &hpb, int &chip, int &hitID, int &sub) const
bool getOnlineIDfromOfflineID(const Identifier &offlineID, int &subsystemNumber, int &octantNumber, int &moduleNumber, int &layerNumber, int &rNumber, int &wireOrStrip, int &channelNumber) const
bool getSimHighPtIDfromRDOHighPtID(const bool isForward, const bool isStrip, int &index, int &chip, int &hitId) const
bool getSLBIDfromRxID(int &phi, bool &isAside, bool &isEndcap, int &moduleType, int &id, const int subsectorID, const int rodID, const int sswID, const int rxId) const
bool getOfflineIDfromLowPtCoincidenceID(Identifier &offlineID, const int subDetectorID, const int rodID, const int sswID, const int sbLoc, const int block, const int pos, bool middle=false) const
bool getSReadoutIDfromSLID(const int phi, const bool isAside, const bool isEndcap, int &subsectorID, int &srodID, int &sswID, int &sbLoc) const
bool hasAdjacentChannel(const Identifier &offlineID) const
bool getROINumberfromHighPtID(int &roi, bool isForward, int hpb_wire, int chip_wire, int hitId_wire, int sub_wire, int chip_strip, int hitId_strip, int sub_strip) const
bool getReadoutIDfromSLID(const int phi, const bool isAside, const bool isEndcap, int &subsectorID, int &rodID, int &sswID, int &sbLoc) const
bool getSLIDfromSReadoutID(int &phi, bool &isAside, const int subsectorID, const int srodID, const int sector, const bool forward) const
void getReadoutIDRanges(int &maxRodId, int &maxSRodId, int &maxSswId, int &maxSbloc, int &minChannelId, int &maxChannelId) const
bool isOredChannel(const int subDetectorID, const int rodID, const int sswID, const int sbLoc, const int channelID) const
To be ported.
TgcCablingMap(const Config &cfg)
bool getReadoutIDfromElementID(const Identifier &elementID, int &subdetectorID, int &rodID) const
bool getOfflineIDfromOnlineID(Identifier &offlineID, const int subsystemNumber, const int octantNumber, const int moduleNumber, const int layerNumber, const int rNumber, const int wireOrStrip, const int channelNumber) const
NRpcCablingAlg reads raw condition data and writes derived condition data to the condition store.
Definition index.py:1
const Muon::IMuonIdHelperSvc * idHelperSvc