ATLAS Offline Software
Loading...
Searching...
No Matches
LArNoisyROMonAlg.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3*/
4
10
11#ifndef LARMONITORING_LARNOISYROMONALG_H
12#define LARMONITORING_LARNOISYROMONALG_H
13
16
19
22
26
29
30#include <string>
31#include <array>
32
34{
35public:
36 LArNoisyROMonAlg(const std::string& name, ISvcLocator* pSvcLocator);
37
38 virtual ~LArNoisyROMonAlg() override final {};
39
40 virtual StatusCode initialize() override final;
41 virtual StatusCode fillHistograms(const EventContext& ctx) const override final;
42
43 size_t partitionNumber(const HWIdentifier) const;
44
46
48
49 Gaudi::Property<std::string> m_MonGroupName {this, "NoisyROGroupName", "LArNoisyROMonGroup"};
50 Gaudi::Property<std::vector<std::string> > m_SubDetNames{this, "SubDetNames", {} };
51 Gaudi::Property<std::vector<std::string> > m_partitions {this, "PartitionNames", {} };
52 Gaudi::Property<bool> m_doTrigger {this, "doTrigger", false};
53 Gaudi::Property<bool> m_storeLooseMNBFEBs {this, "storeLooseMNBFEBs", false};
54
55 Gaudi::Property<std::vector<std::string> > m_EF_NoiseBurst_Triggers {this, "EFNoiseBurstTriggers", {} };
56 Gaudi::Property<std::vector<std::string> > m_L1_NoiseBurst_Triggers {this, "L1NoiseBurstTriggers", {} };
57
58 Gaudi::Property<bool> m_doHisto {this, "doHisto", true};
59
60 SG::ReadHandleKey<LArNoisyROSummary> m_inputKey {this, "inputKey", "LArNoisyROSummary"};
61
62 SG::ReadCondHandleKey<LArBadFebCont> m_badFebKey{this,"KonwnBadFebKey","LArKnownBadFEBs","Key of known Bad-Feb object"};
63 SG::ReadCondHandleKey<LArBadFebCont> m_MNBFebKey{this,"KonwnMNBFebKey","LArKnownMNBFEBs","Key of known MNB-Feb object"};
64 SG::ReadCondHandleKey<LArHVIdMapping> m_hvMapKey {this, "HVMapKey", "", "key to read OnOff mapping"};
65
66 //To get the data-dependency right ...
67 SG::ReadDecorHandleKey<xAOD::EventInfo> m_eventInfoDecorKey{this, "LArStatusFlag", "EventInfo.larFlags", "Key for EventInfo object"};
68
80
81 /* Histogram grouping (part) */
82 std::vector<std::map<std::string,int> > m_histoGroups;
83
84 // fill histogram of triggers
85 void fillTriggerHisto(size_t partition, unsigned long triggerbits, unsigned long L1triggerbits) const;
86
87 void fillHistogramsOnce(const EventContext& ctx, const bool isMC) const;
88
89 mutable std::once_flag m_onceFlag ATLAS_THREAD_SAFE;
90
91};
92
93inline size_t LArNoisyROMonAlg::partitionNumber(const HWIdentifier hwid) const {
94
95 int pn=m_LArOnlineIDHelper->pos_neg(hwid);
96 if (m_LArOnlineIDHelper->isEMECchannel(hwid)) {
97 if (pn)
98 return 3; //positive EMECA side
99 else
100 return 2; //negative EMECC side
101 }
102 if (m_LArOnlineIDHelper->isEMBchannel(hwid)) {
103 if (pn)
104 return 1; //positive EMBA side
105 else
106 return 0; //negative EMBC side
107 }
108
109 return 4;//Anything else
110}
111
112
113#endif
Property holding a SG store/key/clid/attr name from which a ReadDecorHandle is made.
Property holding a SG store/key/clid from which a ReadHandle is made.
AthMonitorAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor.
Gaudi::Property< std::vector< std::string > > m_EF_NoiseBurst_Triggers
Gaudi::Property< std::vector< std::string > > m_L1_NoiseBurst_Triggers
void fillTriggerHisto(size_t partition, unsigned long triggerbits, unsigned long L1triggerbits) const
std::vector< std::map< std::string, int > > m_histoGroups
std::once_flag m_onceFlag ATLAS_THREAD_SAFE
SG::ReadHandleKey< LArNoisyROSummary > m_inputKey
Gaudi::Property< bool > m_doTrigger
size_t partitionNumber(const HWIdentifier) const
virtual ~LArNoisyROMonAlg() override final
Gaudi::Property< std::string > m_MonGroupName
const LArOnlineID * m_LArOnlineIDHelper
Gaudi::Property< bool > m_storeLooseMNBFEBs
Gaudi::Property< std::vector< std::string > > m_partitions
SG::ReadCondHandleKey< LArBadFebCont > m_badFebKey
SG::ReadDecorHandleKey< xAOD::EventInfo > m_eventInfoDecorKey
SG::ReadCondHandleKey< LArHVIdMapping > m_hvMapKey
SG::ReadCondHandleKey< LArBadFebCont > m_MNBFebKey
Gaudi::Property< bool > m_doHisto
Gaudi::Property< std::vector< std::string > > m_SubDetNames
void fillHistogramsOnce(const EventContext &ctx, const bool isMC) const
Support class for PropertyMgr.
Definition Property.h:23
Property holding a SG store/key/clid/attr name from which a ReadDecorHandle is made.
Property holding a SG store/key/clid from which a ReadHandle is made.
=============================================================================
STL namespace.
void initialize()
std::vector< int > * v_candidate_MNBTightFEB
std::vector< int > * v_candidate_MNBLooseFEB
std::vector< int > * v_candidate_MNBTight_PsVetoFEB
#define private