ATLAS Offline Software
Loading...
Searching...
No Matches
TgcDigitCrosstalkData.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4
6
9
10void TgcDigitCrosstalkData::setStripProbability(const uint16_t layer_id, const std::array<float, N_PROB> prob)
11{
12 m_stripProb.emplace(layer_id, prob);
13}
14
15float TgcDigitCrosstalkData::getStripProbability(const uint16_t layer_id, const unsigned int index_prob) const
16{
17 if (index_prob >= N_PROB) return 0.;
18 auto pLayer = m_stripProb.find(layer_id);
19 if (pLayer == m_stripProb.end()) return 0.;
20 return pLayer->second[index_prob];
21}
22
23void TgcDigitCrosstalkData::setWireProbability(const uint16_t layer_id, const std::array<float, N_PROB> prob)
24{
25 m_wireProb.emplace(layer_id, prob);
26}
27
28float TgcDigitCrosstalkData::getWireProbability(const uint16_t layer_id, const unsigned int index_prob) const
29{
30 if (index_prob >= N_PROB) return 0.;
31 auto pLayer = m_wireProb.find(layer_id);
32 if (pLayer == m_wireProb.end()) return 0.;
33 return pLayer->second[index_prob];
34}
void setStripProbability(const uint16_t layer_id, const std::array< float, N_PROB > prob)
float getStripProbability(const uint16_t layer_id, const unsigned int index_prob) const
std::map< uint16_t, std::array< float, N_PROB > > m_stripProb
void setWireProbability(const uint16_t layer_id, const std::array< float, N_PROB > prob)
static constexpr unsigned int N_PROB
float getWireProbability(const uint16_t layer_id, const unsigned int index_prob) const
std::map< uint16_t, std::array< float, N_PROB > > m_wireProb