ATLAS Offline Software
Classes | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
Muon::sTgcRdoToPrepDataToolMT Class Reference

#include <sTgcRdoToPrepDataToolMT.h>

Inheritance diagram for Muon::sTgcRdoToPrepDataToolMT:
Collaboration diagram for Muon::sTgcRdoToPrepDataToolMT:

Classes

struct  outputCache
 

Public Member Functions

virtual ~sTgcRdoToPrepDataToolMT ()=default
 Destructor. More...
 
virtual StatusCode initialize () override
 Standard AthAlgTool initialize method. More...
 
StatusCode decode (const EventContext &ctx, const std::vector< IdentifierHash > &idVect) const override
 Decode RDO to PRD
A vector of IdentifierHash are passed in, and the data corresponding to this list (i.e. More...
 
StatusCode decode (const EventContext &ctx, const std::vector< uint32_t > &robIds) const override
 
StatusCode provideEmptyContainer (const EventContext &ctx) const override
 

Protected Member Functions

StatusCode processCollection (const EventContext &ctx, outputCache &xAODcontainers, const STGC_RawDataCollection *rdoColl) const
 
outputCache setupOutputContainers (const EventContext &ctx) const
 
const STGC_RawDataContainergetRdoContainer (const EventContext &ctx) const
 
void processRDOContainer (const EventContext &ctx, outputCache &xAODcontainers, const std::vector< IdentifierHash > &idsToDecode) const
 

Protected Attributes

SG::ReadCondHandleKey< MuonGM::MuonDetectorManagerm_muDetMgrKey {this, "DetectorManagerKey", "MuonDetectorManager", "Key of input MuonDetectorManager condition data"}
 
ServiceHandle< Muon::IMuonIdHelperSvcm_idHelperSvc {this, "MuonIdHelperSvc", "Muon::MuonIdHelperSvc/MuonIdHelperSvc"}
 
SG::ReadHandleKey< STGC_RawDataContainerm_rdoContainerKey {this, "InputCollection", "sTGCRDO", "RDO container to read"}
 
SG::WriteHandleKey< sTgcPrepDataContainerm_stgcPrepDataContainerKey {this, "OutputCollection", "STGC_Measurements", "Muon::sTgcPrepDataContainer to record"}
 
Gaudi::Property< bool > m_merge {this, "Merge", true}
 
ToolHandle< ISTgcClusterBuilderToolm_clusterBuilderTool {this,"ClusterBuilderTool","Muon::SimpleSTgcClusterBuilderTool/SimpleSTgcClusterBuilderTool"}
 
ToolHandle< INSWCalibToolm_calibTool {this,"NSWCalibTool", ""}
 
SG::UpdateHandleKey< sTgcPrepDataCollection_Cachem_prdContainerCacheKey {this, "PrdCacheKey", "", "Optional external cache for the sTGC PRD container"}
 This is the key for the cache for the sTGC PRD containers, can be empty. More...
 
SG::WriteHandleKey< xAOD::sTgcStripContainerm_xAODStripKey {this, "xAODStripKey", "", "If empty, do not produce xAOD, otherwise this is the key of the output xAOD MDT PRD container"}
 
SG::WriteHandleKey< xAOD::sTgcPadContainerm_xAODPadKey {this, "xAODPadKey", "", "If empty, do not produce xAOD, otherwise this is the key of the output xAOD MDT PRD container"}
 
SG::WriteHandleKey< xAOD::sTgcWireContainerm_xAODWireKey {this, "xAODWireKey", "", "If empty, do not produce xAOD, otherwise this is the key of the output xAOD MDT PRD container"}
 
Gaudi::Property< bool > m_useNewGeo
 
const MuonGMR4::MuonDetectorManagerm_detMgrR4 {nullptr}
 

Detailed Description

Definition at line 35 of file sTgcRdoToPrepDataToolMT.h.

Constructor & Destructor Documentation

◆ ~sTgcRdoToPrepDataToolMT()

virtual Muon::sTgcRdoToPrepDataToolMT::~sTgcRdoToPrepDataToolMT ( )
virtualdefault

Destructor.

Member Function Documentation

◆ decode() [1/2]

StatusCode Muon::sTgcRdoToPrepDataToolMT::decode ( const EventContext &  ctx,
const std::vector< IdentifierHash > &  idVect 
) const
override

Decode RDO to PRD
A vector of IdentifierHash are passed in, and the data corresponding to this list (i.e.

in a Region of Interest) are converted.

Parameters
requestedIdHashVectVector of hashes to convert i.e. the hashes of ROD collections in a 'Region of Interest'
Returns
selectedIdHashVect This is the subset of requestedIdVect which were actually found to contain data
(i.e. if you want you can use this vector of hashes to optimise the retrieval of data in subsequent steps.)

Definition at line 320 of file sTgcRdoToPrepDataToolMT.cxx.

321  {
322  ATH_MSG_DEBUG("Size of the input hash id vector: " << idVect.size());
323 
324  outputCache outCache = setupOutputContainers(ctx);
325  if (!outCache.isValid) return StatusCode::FAILURE;
326 
327  processRDOContainer(ctx, outCache, idVect);
328  return StatusCode::SUCCESS;
329 }

◆ decode() [2/2]

StatusCode Muon::sTgcRdoToPrepDataToolMT::decode ( const EventContext &  ctx,
const std::vector< uint32_t > &  robIds 
) const
override

Definition at line 333 of file sTgcRdoToPrepDataToolMT.cxx.

333  {
334  ATH_MSG_FATAL("ROB based decoding is not supported....");
335  return StatusCode::FAILURE;
336 }

◆ getRdoContainer()

const STGC_RawDataContainer * Muon::sTgcRdoToPrepDataToolMT::getRdoContainer ( const EventContext &  ctx) const
protected

Definition at line 277 of file sTgcRdoToPrepDataToolMT.cxx.

278 {
279  auto rdoContainerHandle = SG::makeHandle(m_rdoContainerKey, ctx);
280  if(rdoContainerHandle.isValid()) {
281  ATH_MSG_DEBUG("STGC_getRdoContainer success");
282  return rdoContainerHandle.cptr();
283  }
284  ATH_MSG_WARNING("Retrieval of STGC_RawDataContainer failed !");
285 
286  return nullptr;
287 }

◆ initialize()

StatusCode Muon::sTgcRdoToPrepDataToolMT::initialize ( )
overridevirtual

Standard AthAlgTool initialize method.

Definition at line 24 of file sTgcRdoToPrepDataToolMT.cxx.

25 {
26  ATH_MSG_DEBUG(" in initialize()");
27  ATH_CHECK( m_idHelperSvc.retrieve() );
28  // check if the initialization of the data container is success
30  ATH_CHECK(m_rdoContainerKey.initialize());
32  ATH_CHECK(m_calibTool.retrieve());
33  ATH_CHECK(m_prdContainerCacheKey.initialize(!m_prdContainerCacheKey.key().empty()) );
34 
35  if (m_useNewGeo) {
37  }
38 
39  ATH_CHECK(m_xAODStripKey.initialize(!m_xAODStripKey.empty()));
40  ATH_CHECK(m_xAODWireKey.initialize(!m_xAODWireKey.empty()));
41  ATH_CHECK(m_xAODPadKey.initialize(!m_xAODPadKey.empty()));
42  return StatusCode::SUCCESS;
43 }

◆ processCollection()

StatusCode Muon::sTgcRdoToPrepDataToolMT::processCollection ( const EventContext &  ctx,
outputCache xAODcontainers,
const STGC_RawDataCollection rdoColl 
) const
protected

Currently there's no 2D covariance yet

Definition at line 47 of file sTgcRdoToPrepDataToolMT.cxx.

49  {
50 
51  const sTgcIdHelper& id_helper = m_idHelperSvc->stgcIdHelper();
52  const IdentifierHash hash = rdoColl->identifyHash();
53 
54  ATH_MSG_DEBUG(" ***************** Start of process STGC Collection with hash Id: " << hash);
55 
56  auto stgcPrepDataContainer = xAODcontainers.prd;
57  // check if the collection already exists, otherwise add it
58  if ( stgcPrepDataContainer->indexFindPtr(hash) != nullptr ) {
59  ATH_MSG_DEBUG("In processCollection: collection already contained in the sTGC PrepData container");
60  return StatusCode::FAILURE;
61 
62  }
63 
64  // Get write handle for this collection
65  sTgcPrepDataContainer::IDC_WriteHandle lock = stgcPrepDataContainer->getWriteHandle( hash );
66  // Check if collection already exists (via the cache, i.e. in online trigger mode)
67  if( lock.OnlineAndPresentInAnotherView() ) {
68  ATH_MSG_DEBUG("In processCollection: collection already available in the sTgc PrepData container (via cache)");
69  return StatusCode::SUCCESS;
70  }
71 
72  // Make the PRD collection (will be added to container later
73  std::unique_ptr<sTgcPrepDataCollection> prdColl = std::make_unique<sTgcPrepDataCollection>(hash);
74 
75  // set the offline identifier of the collection Id
76  IdContext context = id_helper.module_context();
77  Identifier moduleId;
78  int getId = id_helper.get_id(hash, moduleId, &context);
79  if ( getId != 0 ) {
80  ATH_MSG_ERROR("Could not convert the hash Id: " << hash << " to identifier");
81  } else {
82  prdColl->setIdentifier(moduleId);
83  }
84 
85  // vectors to hold PRDs decoded for this RDO collection
86  std::vector<sTgcPrepData> sTgcStripPrds;
87  std::vector<sTgcPrepData> sTgcWirePrds;
88  std::vector<sTgcPrepData> sTgcPadPrds;
89  sTgcStripPrds.reserve(rdoColl->size());
90  sTgcPadPrds.reserve(rdoColl->size());
91  sTgcWirePrds.reserve(rdoColl->size());
92 
93  // Count hits with negative charge, which indicates bad calibration
94 
95 
96  // MuonDetectorManager from the conditions store
97  const MuonGM::MuonDetectorManager* muonDetMgr{nullptr};
98  ATH_CHECK(SG::get(muonDetMgr,m_muDetMgrKey,ctx));
99  // convert the RDO collection to a PRD collection
100  for ( const STGC_RawData* rdo : * rdoColl) {
101 
102  ATH_MSG_DEBUG("Adding a new sTgc PrepRawData");
103 
104  const Identifier rdoId = rdo->identify();
105 
106  std::vector<Identifier> rdoList{rdoId};
107 
108  // get the local and global positions
109  const MuonGM::sTgcReadoutElement* detEl = muonDetMgr->getsTgcReadoutElement(rdoId);
111 
112  int channelType = id_helper.channelType(rdoId);
113  if (channelType < 0 || channelType > 2) {
114  ATH_MSG_ERROR("Unknown sTGC channel type");
115  return StatusCode::FAILURE;
116  }
117  if (!detEl->stripPosition(rdoId, localPos)) {
118  ATH_MSG_ERROR("Could not get the local strip position for "<<m_idHelperSvc->toString(rdoId));
119  return StatusCode::FAILURE;
120  }
121 
122  // get the resolution from strip width
123  // to be fixed: for now do not set the resolution, it will be added in the next update
124  const int gasGap = id_helper.gasGap(rdoId);
125  const int channel = id_helper.channel(rdoId);
126 
127  NSWCalib::CalibratedStrip calibStrip;
128  ATH_CHECK (m_calibTool->calibrateStrip(ctx, rdo, calibStrip));
129  int calibratedCharge = static_cast<int>(calibStrip.charge);
130  if (calibratedCharge < 0 && channelType == 1) { // we only want to protect against negatively charged strips and we should not lose wire or pad hits because of bad calibrations since charge does not matter for them in reco.
131  if (!hitNegativeCharge) {
132  ATH_MSG_DEBUG("One sTGC RDO or more, such as one with pdo = "<<rdo->charge() << " counts, corresponds to a negative charge (" << calibratedCharge << "). Skipping these RDOs");
133  hitNegativeCharge = true;
134  }
135  continue;
136  }
137 
138  double width{0.};
139  if (channelType == sTgcIdHelper::sTgcChannelTypes::Pad) { // Pads
140  const MuonGM::MuonPadDesign* design = detEl->getPadDesign(rdoId);
141  if (!design) {
142  ATH_MSG_WARNING("Failed to get design for sTGC pad" );
143  } else {
144  width = design->channelWidth(localPos, true);
145  }
146  } else { // Strips and wires
147  const MuonGM::MuonChannelDesign* design = detEl->getDesign(rdoId);
148  if (!design) {
149  ATH_MSG_WARNING("Failed to get design for sTGC strip/wire" );
150  } else {
151  width = design->channelWidth();
152  }
153  }
154 
155  const double resolution = width/ std::sqrt(12.);
156  auto cov = Amg::MatrixX(1,1);
157  cov.setIdentity();
158  (cov)(0,0) = resolution*resolution;
159 
160  ATH_MSG_DEBUG("Adding a new STGC PRD, gasGap: " << gasGap << " channel: " << channel << " type: " << channelType << " resolution " << resolution );
161 
162  if(m_merge) {
163  std::vector<sTgcPrepData>& sTgcPrds = channelType == sTgcIdHelper::Pad ? sTgcPadPrds :
164  (channelType == sTgcIdHelper::Strip ? sTgcStripPrds : sTgcWirePrds);
165 
166  // check if the same RdoId is already present; keep the one with the smallest time
167  auto it = std::find_if(sTgcPrds.begin(), sTgcPrds.end(), [&rdoId](const sTgcPrepData& prd) {
168  return (prd.identify() == rdoId);
169  });
170  if (it == sTgcPrds.end()) {
171  sTgcPrds.emplace_back(rdoId, hash, std::move(localPos), std::move(rdoList), std::move(cov), detEl, calibratedCharge, calibStrip.time);
172  sTgcPrds.back().setAuthor(sTgcPrepData::Author::RdoToPrdConverter);
173  } else if (it->time() > calibStrip.time) {
174  *it = sTgcPrepData(rdoId, hash, std::move(localPos), std::move(rdoList), std::move(cov), detEl, calibratedCharge, calibStrip.time);
176  }
177 
178  // TODO - add merging for xAOD
179 
180  } else {
181  // if not merging just add the PRD to the collection
182  prdColl->push_back(std::make_unique<sTgcPrepData>(rdoId,
183  hash,
184  std::move(localPos),
185  std::move(rdoList),
186  std::move(cov),
187  detEl,
188  calibratedCharge,
189  calibStrip.time));
190  }
191  }
192 
193  if(m_merge) {
194  // merge strip prds that fire closeby channels (not clusterizing wires and pads)
195  std::vector<std::unique_ptr<Muon::sTgcPrepData>> sTgcStripClusters;
196  ATH_CHECK(m_clusterBuilderTool->getClusters(ctx, std::move(sTgcStripPrds), sTgcStripClusters)); // Clusterize strips
197 
198  for ( std::unique_ptr<Muon::sTgcPrepData>& it : sTgcStripClusters ) {
199  it->setHashAndIndex(prdColl->identifyHash(), prdColl->size());
200  prdColl->push_back(std::move(it));
201  }
202  for ( Muon::sTgcPrepData& prd : sTgcWirePrds ) {
203  prd.setHashAndIndex(prdColl->identifyHash(), prdColl->size());
204  prdColl->push_back(std::make_unique<sTgcPrepData>(std::move(prd)));
205  }
206  for (Muon::sTgcPrepData& prd : sTgcPadPrds ) {
207  prd.setHashAndIndex(prdColl->identifyHash(), prdColl->size());
208  prdColl->push_back(std::make_unique<sTgcPrepData>(std::move(prd)));
209  }
210  }
211  const bool convertXAOD = !m_xAODPadKey.empty() || !m_xAODStripKey.empty() ||
212  !m_xAODWireKey.empty();
213 
214  if (convertXAOD) {
215  for (const Muon::sTgcPrepData* prd : *prdColl) {
216  const Identifier prdId = prd->identify();
217  const int gasGap = id_helper.gasGap(prdId);
218  const int channel = id_helper.channel(prdId);
219  const int chType = id_helper.channelType(prdId);
220  xAOD::sTgcMeasurement* outHit{nullptr};
221  ATH_MSG_VERBOSE("Convert "
222  <<m_idHelperSvc->toString(prdId)<<". "<<Amg::toString(prd->localPosition())
223  <<", cov: "<<prd->localCovariance()(0,0)
224  <<" global pos: "<<Amg::toString(prd->globalPosition()));
225  if (!m_xAODPadKey.empty() && chType == sTgcIdHelper::sTgcChannelTypes::Pad) {
226  outHit = xAODcontainers.pad->push_back(std::make_unique<xAOD::sTgcPadHit>());
228  lCov(0,0) = prd->localCovariance()(0,0);
230  // lCov(1,1) = prd->localCovariance()(1,1);
231  outHit->setMeasurement<2>(m_idHelperSvc->detElementHash(prdId),
232  xAOD::toStorage(prd->localPosition()),
233  std::move(lCov));
234  } else if (chType == sTgcIdHelper::sTgcChannelTypes::Wire && !m_xAODWireKey.empty()) {
235  outHit = xAODcontainers.wire->push_back(std::make_unique<xAOD::sTgcWireHit>());
236  } else if (chType == sTgcIdHelper::sTgcChannelTypes::Strip && !m_xAODStripKey.empty()) {
237  auto stripHit = xAODcontainers.strip->push_back(std::make_unique<xAOD::sTgcStripCluster>());
238  stripHit->setStripCharges(prd->stripCharges());
239  stripHit->setStripNumbers(prd->stripNumbers());
240  stripHit->setStripTimes(prd->stripTimes());
241  outHit = stripHit;
242  }
243  if (!outHit) {
244  continue;
245  }
246  if (chType != sTgcIdHelper::sTgcChannelTypes::Pad){
247  xAOD::MeasVector<1> lPos = prd->localPosition().x() * xAOD::MeasVector<1>::UnitX();
248  xAOD::MeasMatrix<1> lCov{};
249  lCov(0,0) = prd->localCovariance()(0,0);
250  outHit->setMeasurement<1>(m_idHelperSvc->detElementHash(prdId),
251  std::move(lPos),
252  std::move(lCov));
253 
254  }
255  outHit->setChannelNumber(channel);
256  outHit->setGasGap(gasGap);
257  outHit->setAuthor(prd->author());
258  outHit->setTime(prd->time());
259  outHit->setCharge(prd->charge());
260  outHit->setIdentifier(prdId.get_compact());
261  if (m_detMgrR4) {
262  outHit->setReadoutElement(m_detMgrR4->getsTgcReadoutElement(prdId));
263  }
264  }
265  }
266 
267 
268  // now add the collection to the container
269  ATH_CHECK( lock.addOrDelete(std::move( prdColl ) ) );
270  ATH_MSG_DEBUG("PRD hash " << hash << " has been moved to container");
271 
272  return StatusCode::SUCCESS;
273 }

◆ processRDOContainer()

void Muon::sTgcRdoToPrepDataToolMT::processRDOContainer ( const EventContext &  ctx,
outputCache xAODcontainers,
const std::vector< IdentifierHash > &  idsToDecode 
) const
protected

Definition at line 291 of file sTgcRdoToPrepDataToolMT.cxx.

294 {
295  ATH_MSG_DEBUG("In processRDOContainer");
296  const STGC_RawDataContainer* rdoContainer = getRdoContainer(ctx);
297  if (!rdoContainer) return;
298 
299  // run in unseeded mode
300  for (const STGC_RawDataCollection* rdoColl : *rdoContainer) {
301  if (rdoColl->empty()) continue;
302  ATH_MSG_DEBUG("New RDO collection with " << rdoColl->size() << "STGC Hits");
303 
304  const IdentifierHash hash = rdoColl->identifyHash();
305 
306  // check if we actually want to decode this RDO collection
307  if(!idsToDecode.empty() and std::find(idsToDecode.begin(), idsToDecode.end(), hash)==idsToDecode.end()) {
308  ATH_MSG_DEBUG("Hash ID " << hash << " not in input list, ignore");
309  continue;
310  } else ATH_MSG_DEBUG("Going to decode " << hash);
311 
312  if(processCollection(ctx, xAODcontainers, rdoColl).isFailure()) {
313  ATH_MSG_DEBUG("processCsm returns a bad StatusCode - keep going for new data collections in this event");
314  }
315  }
316 }

◆ provideEmptyContainer()

StatusCode Muon::sTgcRdoToPrepDataToolMT::provideEmptyContainer ( const EventContext &  ctx) const
override

Definition at line 337 of file sTgcRdoToPrepDataToolMT.cxx.

337  {
338  return setupOutputContainers(ctx).isValid ? StatusCode::SUCCESS : StatusCode::FAILURE;
339 }

◆ setupOutputContainers()

sTgcRdoToPrepDataToolMT::outputCache sTgcRdoToPrepDataToolMT::setupOutputContainers ( const EventContext &  ctx) const
protected

use the cache to get the container

Definition at line 343 of file sTgcRdoToPrepDataToolMT.cxx.

343  {
344  outputCache containers;
345  if (!m_xAODStripKey.empty()) {
347  if (!containers.strip.record(std::make_unique<xAOD::sTgcStripContainer>(),
348  std::make_unique<xAOD::sTgcStripAuxContainer>()).isSuccess()){
349  ATH_MSG_FATAL("Failed to record "<<m_xAODStripKey.fullKey());
350  return containers;
351  }
352  }
353  if (!m_xAODPadKey.empty()) {
355  if (!containers.pad.record(std::make_unique<xAOD::sTgcPadContainer>(),
356  std::make_unique<xAOD::sTgcPadAuxContainer>()).isSuccess()){
357  ATH_MSG_FATAL("Failed to record "<<m_xAODPadKey.fullKey());
358  return containers;
359  }
360  }
361  if (!m_xAODWireKey.empty()) {
363  if (!containers.wire.record(std::make_unique<xAOD::sTgcWireContainer>(),
364  std::make_unique<xAOD::sTgcWireAuxContainer>()).isSuccess()){
365  ATH_MSG_FATAL("Failed to record "<<m_xAODWireKey.fullKey());
366  return containers;
367  }
368  }
369 
371  if(m_prdContainerCacheKey.key().empty()) {
372  // No external cache, just record the container
373  const int hashMax = m_idHelperSvc->stgcIdHelper().module_hash_max();
374  if (!containers.prd.record(std::make_unique<Muon::sTgcPrepDataContainer>(hashMax)).isSuccess()){
375  ATH_MSG_FATAL("Faile to record "<<m_stgcPrepDataContainerKey.fullKey());
376  return containers;
377  }
378  } else {
381  if (!update.isValid()) {
382  ATH_MSG_FATAL("Invalid UpdateHandle " << m_prdContainerCacheKey.key());
383  return containers;
384  }
385  if (!containers.prd.record(std::make_unique<Muon::sTgcPrepDataContainer>(update.ptr())).isSuccess()) {
386  ATH_MSG_FATAL("Failed to record "<<m_stgcPrepDataContainerKey.fullKey()
387  <<" from "<<m_prdContainerCacheKey.fullKey());
388  return containers;
389  }
390  }
391  containers.isValid = true;
392  return containers;
393 }

Member Data Documentation

◆ m_calibTool

ToolHandle<INSWCalibTool> Muon::sTgcRdoToPrepDataToolMT::m_calibTool {this,"NSWCalibTool", ""}
protected

Definition at line 87 of file sTgcRdoToPrepDataToolMT.h.

◆ m_clusterBuilderTool

ToolHandle<ISTgcClusterBuilderTool> Muon::sTgcRdoToPrepDataToolMT::m_clusterBuilderTool {this,"ClusterBuilderTool","Muon::SimpleSTgcClusterBuilderTool/SimpleSTgcClusterBuilderTool"}
protected

Definition at line 86 of file sTgcRdoToPrepDataToolMT.h.

◆ m_detMgrR4

const MuonGMR4::MuonDetectorManager* Muon::sTgcRdoToPrepDataToolMT::m_detMgrR4 {nullptr}
protected

Definition at line 100 of file sTgcRdoToPrepDataToolMT.h.

◆ m_idHelperSvc

ServiceHandle<Muon::IMuonIdHelperSvc> Muon::sTgcRdoToPrepDataToolMT::m_idHelperSvc {this, "MuonIdHelperSvc", "Muon::MuonIdHelperSvc/MuonIdHelperSvc"}
protected

Definition at line 79 of file sTgcRdoToPrepDataToolMT.h.

◆ m_merge

Gaudi::Property<bool> Muon::sTgcRdoToPrepDataToolMT::m_merge {this, "Merge", true}
protected

Definition at line 84 of file sTgcRdoToPrepDataToolMT.h.

◆ m_muDetMgrKey

SG::ReadCondHandleKey<MuonGM::MuonDetectorManager> Muon::sTgcRdoToPrepDataToolMT::m_muDetMgrKey {this, "DetectorManagerKey", "MuonDetectorManager", "Key of input MuonDetectorManager condition data"}
protected

Definition at line 77 of file sTgcRdoToPrepDataToolMT.h.

◆ m_prdContainerCacheKey

SG::UpdateHandleKey<sTgcPrepDataCollection_Cache> Muon::sTgcRdoToPrepDataToolMT::m_prdContainerCacheKey {this, "PrdCacheKey", "", "Optional external cache for the sTGC PRD container"}
protected

This is the key for the cache for the sTGC PRD containers, can be empty.

Definition at line 90 of file sTgcRdoToPrepDataToolMT.h.

◆ m_rdoContainerKey

SG::ReadHandleKey<STGC_RawDataContainer> Muon::sTgcRdoToPrepDataToolMT::m_rdoContainerKey {this, "InputCollection", "sTGCRDO", "RDO container to read"}
protected

Definition at line 82 of file sTgcRdoToPrepDataToolMT.h.

◆ m_stgcPrepDataContainerKey

SG::WriteHandleKey<sTgcPrepDataContainer> Muon::sTgcRdoToPrepDataToolMT::m_stgcPrepDataContainerKey {this, "OutputCollection", "STGC_Measurements", "Muon::sTgcPrepDataContainer to record"}
protected

Definition at line 83 of file sTgcRdoToPrepDataToolMT.h.

◆ m_useNewGeo

Gaudi::Property<bool> Muon::sTgcRdoToPrepDataToolMT::m_useNewGeo
protected
Initial value:
{this, "UseR4DetMgr", false,
"Switch between the legacy and the new geometry"}

Definition at line 97 of file sTgcRdoToPrepDataToolMT.h.

◆ m_xAODPadKey

SG::WriteHandleKey<xAOD::sTgcPadContainer> Muon::sTgcRdoToPrepDataToolMT::m_xAODPadKey {this, "xAODPadKey", "", "If empty, do not produce xAOD, otherwise this is the key of the output xAOD MDT PRD container"}
protected

Definition at line 94 of file sTgcRdoToPrepDataToolMT.h.

◆ m_xAODStripKey

SG::WriteHandleKey<xAOD::sTgcStripContainer> Muon::sTgcRdoToPrepDataToolMT::m_xAODStripKey {this, "xAODStripKey", "", "If empty, do not produce xAOD, otherwise this is the key of the output xAOD MDT PRD container"}
protected

Definition at line 93 of file sTgcRdoToPrepDataToolMT.h.

◆ m_xAODWireKey

SG::WriteHandleKey<xAOD::sTgcWireContainer> Muon::sTgcRdoToPrepDataToolMT::m_xAODWireKey {this, "xAODWireKey", "", "If empty, do not produce xAOD, otherwise this is the key of the output xAOD MDT PRD container"}
protected

Definition at line 95 of file sTgcRdoToPrepDataToolMT.h.


The documentation for this class was generated from the following files:
python.PyKernel.retrieve
def retrieve(aClass, aKey=None)
Definition: PyKernel.py:110
MuonGM::MuonPadDesign
Parameters defining the design of the readout sTGC pads.
Definition: MuonPadDesign.h:40
dumpTgcDigiDeadChambers.gasGap
list gasGap
Definition: dumpTgcDigiDeadChambers.py:33
Muon::sTgcRdoToPrepDataToolMT::m_clusterBuilderTool
ToolHandle< ISTgcClusterBuilderTool > m_clusterBuilderTool
Definition: sTgcRdoToPrepDataToolMT.h:86
NSWCalib::CalibratedStrip::time
double time
Definition: INSWCalibTool.h:26
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition: AthMsgStreamMacros.h:34
Amg::MatrixX
Eigen::Matrix< double, Eigen::Dynamic, Eigen::Dynamic > MatrixX
Dynamic Matrix - dynamic allocation.
Definition: EventPrimitives.h:27
Muon::sTgcPrepData::Author::RdoToPrdConverter
@ RdoToPrdConverter
NSWCalib::CalibratedStrip::charge
double charge
Definition: INSWCalibTool.h:25
plotting.yearwise_efficiency.channel
channel
Definition: yearwise_efficiency.py:24
MuonIdHelper::get_id
virtual int get_id(const IdentifierHash &hash_id, Identifier &id, const IdContext *context=0) const override
Create compact id from hash id (return == 0 for OK)
Definition: MuonIdHelper.cxx:68
find
std::string find(const std::string &s)
return a remapped string
Definition: hcg.cxx:135
Amg::Vector2D
Eigen::Matrix< double, 2, 1 > Vector2D
Definition: GeoPrimitives.h:48
Muon::sTgcRdoToPrepDataToolMT::m_detMgrR4
const MuonGMR4::MuonDetectorManager * m_detMgrR4
Definition: sTgcRdoToPrepDataToolMT.h:100
Muon::sTgcRdoToPrepDataToolMT::m_idHelperSvc
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Definition: sTgcRdoToPrepDataToolMT.h:79
Muon::sTgcRdoToPrepDataToolMT::m_useNewGeo
Gaudi::Property< bool > m_useNewGeo
Definition: sTgcRdoToPrepDataToolMT.h:97
skel.it
it
Definition: skel.GENtoEVGEN.py:407
plotBeamSpotVxVal.cov
cov
Definition: plotBeamSpotVxVal.py:200
Muon::STGC_RawDataContainer
Definition: STGC_RawDataContainer.h:18
MuonGM::sTgcReadoutElement::getDesign
const MuonChannelDesign * getDesign(const Identifier &id) const
returns the MuonChannelDesign class for the given identifier
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/sTgcReadoutElement.h:279
xAOD::toStorage
MeasVector< N > toStorage(const AmgVector(N)&amgVec)
Converts the double precision of the AmgVector into the floating point storage precision of the MeasV...
Definition: MeasurementDefs.h:69
sTgcIdHelper::Strip
@ Strip
Definition: sTgcIdHelper.h:190
Muon::sTgcRdoToPrepDataToolMT::m_merge
Gaudi::Property< bool > m_merge
Definition: sTgcRdoToPrepDataToolMT.h:84
python.RatesEmulationExample.lock
lock
Definition: RatesEmulationExample.py:148
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
sTgcIdHelper::sTgcChannelTypes
sTgcChannelTypes
Definition: sTgcIdHelper.h:190
Muon::sTgcRdoToPrepDataToolMT::getRdoContainer
const STGC_RawDataContainer * getRdoContainer(const EventContext &ctx) const
Definition: sTgcRdoToPrepDataToolMT.cxx:277
Muon::MuonPrepDataCollection::setIdentifier
virtual void setIdentifier(Identifier id)
Dedxcorrection::resolution
double resolution[nGasTypes][nParametersResolution]
Definition: TRT_ToT_Corrections.h:46
Muon::sTgcRdoToPrepDataToolMT::processCollection
StatusCode processCollection(const EventContext &ctx, outputCache &xAODcontainers, const STGC_RawDataCollection *rdoColl) const
Definition: sTgcRdoToPrepDataToolMT.cxx:47
Muon::STGC_RawDataCollection::identifyHash
const IdentifierHash & identifyHash() const
Definition: STGC_RawDataCollection.h:26
MuonGM::sTgcReadoutElement::stripPosition
virtual bool stripPosition(const Identifier &id, Amg::Vector2D &pos) const override final
strip position - should be renamed to channel position If the strip number is outside the range of va...
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/sTgcReadoutElement.h:321
SG::makeHandle
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
Definition: ReadCondHandle.h:274
Muon::sTgcRdoToPrepDataToolMT::setupOutputContainers
outputCache setupOutputContainers(const EventContext &ctx) const
Definition: sTgcRdoToPrepDataToolMT.cxx:343
Muon::sTgcRdoToPrepDataToolMT::m_rdoContainerKey
SG::ReadHandleKey< STGC_RawDataContainer > m_rdoContainerKey
Definition: sTgcRdoToPrepDataToolMT.h:82
Muon::MuonPrepDataCollection::identifyHash
virtual IdentifierHash identifyHash() const override final
Amg::toString
std::string toString(const Translation3D &translation, int precision=4)
GeoPrimitvesToStringConverter.
Definition: GeoPrimitivesToStringConverter.h:40
Muon::sTgcRdoToPrepDataToolMT::processRDOContainer
void processRDOContainer(const EventContext &ctx, outputCache &xAODcontainers, const std::vector< IdentifierHash > &idsToDecode) const
Definition: sTgcRdoToPrepDataToolMT.cxx:291
sTgcIdHelper::channel
int channel(const Identifier &id) const override
Definition: sTgcIdHelper.cxx:1027
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
IsoCloseByCorrectionTest.containers
containers
Associate the close-by pflow objects and the calorimeter clusters.
Definition: IsoCloseByCorrectionTest.py:82
Muon::STGC_RawData
Definition: STGC_RawData.h:14
SG::get
const T * get(const ReadCondHandleKey< T > &key, const EventContext &ctx)
Convenience function to retrieve an object given a ReadCondHandleKey.
Definition: ReadCondHandle.h:287
Muon::sTgcRdoToPrepDataToolMT::outputCache::isValid
bool isValid
Definition: sTgcRdoToPrepDataToolMT.h:63
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
MuonGM::sTgcReadoutElement
An sTgcReadoutElement corresponds to a single STGC module; therefore typicaly a barrel muon station c...
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/sTgcReadoutElement.h:30
Muon::sTgcRdoToPrepDataToolMT::m_muDetMgrKey
SG::ReadCondHandleKey< MuonGM::MuonDetectorManager > m_muDetMgrKey
Definition: sTgcRdoToPrepDataToolMT.h:77
sTgcIdHelper::gasGap
int gasGap(const Identifier &id) const override
get the hashes
Definition: sTgcIdHelper.cxx:1020
IdentifiableContainerMT::IDC_WriteHandle
Definition: IdentifiableContainerMT.h:34
Muon::sTgcRdoToPrepDataToolMT::m_prdContainerCacheKey
SG::UpdateHandleKey< sTgcPrepDataCollection_Cache > m_prdContainerCacheKey
This is the key for the cache for the sTGC PRD containers, can be empty.
Definition: sTgcRdoToPrepDataToolMT.h:90
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
NSWCalib::CalibratedStrip
Definition: INSWCalibTool.h:24
MuonGM::MuonPadDesign::channelWidth
double channelWidth(const Amg::Vector2D &pos, bool measPhi, bool preciseMeas=false) const
calculate local channel width
Definition: MuonPadDesign.h:142
xAOD::MeasVector
Eigen::Matrix< float, N, 1 > MeasVector
Abrivation of the Matrix & Covariance definitions.
Definition: MeasurementDefs.h:53
Muon::sTgcRdoToPrepDataToolMT::m_calibTool
ToolHandle< INSWCalibTool > m_calibTool
Definition: sTgcRdoToPrepDataToolMT.h:87
Muon::sTgcRdoToPrepDataToolMT::m_xAODPadKey
SG::WriteHandleKey< xAOD::sTgcPadContainer > m_xAODPadKey
Definition: sTgcRdoToPrepDataToolMT.h:94
python.PyKernel.detStore
detStore
Definition: PyKernel.py:41
Muon::sTgcRdoToPrepDataToolMT::m_stgcPrepDataContainerKey
SG::WriteHandleKey< sTgcPrepDataContainer > m_stgcPrepDataContainerKey
Definition: sTgcRdoToPrepDataToolMT.h:83
SG::UpdateHandle
Definition: UpdateHandle.h:91
DataVector::push_back
value_type push_back(value_type pElem)
Add an element to the end of the collection.
sTgcIdHelper
Definition: sTgcIdHelper.h:55
SG::CondHandleKey::initialize
StatusCode initialize(bool used=true)
SG::WriteHandle
Definition: StoreGate/StoreGate/WriteHandle.h:73
MuonGM::MuonChannelDesign
Definition: MuonChannelDesign.h:24
Base_Fragment.width
width
Definition: Sherpa_i/share/common/Base_Fragment.py:59
CaloCondBlobAlgs_fillNoiseFromASCII.hash
dictionary hash
Definition: CaloCondBlobAlgs_fillNoiseFromASCII.py:108
MuonGM::MuonDetectorManager
The MuonDetectorManager stores the transient representation of the Muon Spectrometer geometry and pro...
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/MuonDetectorManager.h:51
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
sTgcIdHelper::Pad
@ Pad
Definition: sTgcIdHelper.h:190
MuonIdHelper::module_context
IdContext module_context() const
id for module
Definition: MuonIdHelper.cxx:733
Muon::STGC_RawDataCollection
Definition: STGC_RawDataCollection.h:18
xAOD::MeasMatrix
Eigen::Matrix< float, N, N > MeasMatrix
Definition: MeasurementDefs.h:55
MuonGM::sTgcReadoutElement::getPadDesign
const MuonPadDesign * getPadDesign(const Identifier &id) const
returns the MuonChannelDesign class for the given identifier
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/sTgcReadoutElement.h:285
Muon::sTgcRdoToPrepDataToolMT::m_xAODWireKey
SG::WriteHandleKey< xAOD::sTgcWireContainer > m_xAODWireKey
Definition: sTgcRdoToPrepDataToolMT.h:95
Muon::sTgcRdoToPrepDataToolMT::m_xAODStripKey
SG::WriteHandleKey< xAOD::sTgcStripContainer > m_xAODStripKey
Definition: sTgcRdoToPrepDataToolMT.h:93
MuonGM::MuonChannelDesign::channelWidth
double channelWidth() const
calculate local channel width
Definition: MuonChannelDesign.h:394
Muon::sTgcPrepData
Class to represent sTgc measurements.
Definition: sTgcPrepData.h:20
sTgcIdHelper::channelType
int channelType(const Identifier &id) const
Definition: sTgcIdHelper.cxx:1022
IdContext
This class saves the "context" of an expanded identifier (ExpandedIdentifier) for compact or hash ver...
Definition: IdContext.h:26
DataVector::size
size_type size() const noexcept
Returns the number of elements in the collection.
WriteBchToCool.update
update
Definition: WriteBchToCool.py:67
xAOD::sTgcMeasurement_v1
Definition: sTgcMeasurement_v1.h:21
generate::Zero
void Zero(TH1D *hin)
Definition: generate.cxx:32
Identifier
Definition: IdentifierFieldParser.cxx:14