ATLAS Offline Software
NSWPRDValAlg.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef MUONPRDTEST_NSWPRDVALALG_H
6 #define MUONPRDTEST_NSWPRDVALALG_H
7 
9 
10 #include "EDM_object.h"
15 
17 public:
18  NSWPRDValAlg(const std::string& name, ISvcLocator* pSvcLocator);
19 
20  StatusCode initialize() override;
21  StatusCode finalize() override;
22  StatusCode execute() override;
23  unsigned int cardinality() const override final { return 1; }
24 
25  // Matching algorithm
26  StatusCode NSWMatchingAlg(); // First set up which object should be matched, given the input used to fill the NSW Ntuple
28  EDM_object data1); // This part of the matching algortihm does the actual comparison given two EDM obects
30  EDM_object& oData,
31  const TString& branch_name); // This function couples the branch of the NSW validation Ntuple with the EDM object.
32 
33 private:
34  MuonVal::MuonTesterTree m_tree{"NSWValTree", "NSWPRDValAlg"};
35 
36  ServiceHandle<MuonTGC_CablingSvc> m_tgcCabling{this, "TGCCablingSvc", "MuonTGC_CablingSvc"};
37 
38  ServiceHandle<Muon::IMuonIdHelperSvc> m_idHelperSvc{this, "MuonIdHelperSvc", "Muon::MuonIdHelperSvc/MuonIdHelperSvc"};
39  PublicToolHandle<Muon::ICSC_RDO_Decoder> m_csc_decoder{this, "CscRDODecoder", "Muon::CscRDO_Decoder/CSC_RDODecoder"};
40 
41  Gaudi::Property<bool> m_isData{this, "isData", false}; // if false use MuonDetectorManager from detector store everywhere
42  Gaudi::Property<bool> m_doTruth{this, "doTruth", false}; // switch on the output of the MC truth
43  Gaudi::Property<bool> m_doMuEntry{this, "doMuEntry", false}; // switch on the output of the Muon Entry Layer
44  Gaudi::Property<bool> m_doSTGCHit{this, "doSTGCHit", false}; // switch on the output of the Small TGC simulated hits
45  Gaudi::Property<bool> m_doSTGCFastDigit{this, "doSTGCFastDigit", false}; // switch on the output of the Small TGC fast digitization
46  Gaudi::Property<bool> m_doSTGCDigit{this, "doSTGCDigit", false}; // swicth on the output of the Small TGC digit
47  Gaudi::Property<bool> m_doSTGCRDO{this, "doSTGCRDO", false}; // switch on the output of the Small TGC RDO
48  Gaudi::Property<bool> m_doSTGCPRD{this, "doSTGCPRD", false}; // swicth on the output of the Small TGC prepdata
49  Gaudi::Property<bool> m_doMMHit{this, "doMMHit", false}; // switch on the output of the MicroMegas simulated hits
50  Gaudi::Property<bool> m_doMMFastDigit{this, "doMMFastDigit", false}; // switch on the output of the MicroMegas fast digitization
51  Gaudi::Property<bool> m_doMMDigit{this, "doMMDigit", false}; // switch on the output of the MicroMegas digitization
52  Gaudi::Property<bool> m_doMMRDO{this, "doMMRDO", false}; // switch on the output of the MicroMegas RDO
53  Gaudi::Property<bool> m_doMMPRD{this, "doMMPRD", false}; // switch on the output of the MicroMegas prepdata
54  Gaudi::Property<bool> m_doCSCHit{this, "doCSCHit", false}; // switch on the output of the CSC simulated hits
55  Gaudi::Property<bool> m_doCSCSDO{this, "doCSCSDO", false}; // switch on the output of the CSC SDO
56  Gaudi::Property<bool> m_doCSCDigit{this, "doCSCDigit", false}; // switch on the output of the CSC digitization
57  Gaudi::Property<bool> m_doCSCRDO{this, "doCSCRDO", false}; // switch on the output of the CSC RDO
58  Gaudi::Property<bool> m_doCSCPRD{this, "doCSCPRD", false}; // switch on the output of the CSC prepdata
59  Gaudi::Property<bool> m_doMDTHit{this, "doMDTHit", false}; // switch on the output of the MDT simulated hits
60  Gaudi::Property<bool> m_doMDTSDO{this, "doMDTSDO", false}; // switch on the output of the MDT SDO
61  Gaudi::Property<bool> m_doMDTDigit{this, "doMDTDigit", false}; // switch on the output of the MDT digitization
62  Gaudi::Property<bool> m_doRPCHit{this, "doRPCHit", false}; // switch on the output of the RPC simulated hits
63  Gaudi::Property<bool> m_doRPCSDO{this, "doRPCSDO", false}; // switch on the output of the RPC SDO
64  Gaudi::Property<bool> m_doRPCDigit{this, "doRPCDigit", false}; // switch on the output of the RPC digitization
65  Gaudi::Property<bool> m_doTGCHit{this, "doTGCHit", false}; // switch on the output of the TGC simulated hits
66  Gaudi::Property<bool> m_doTGCSDO{this, "doTGCSDO", false}; // switch on the output of the TGC SDO
67  Gaudi::Property<bool> m_doTGCDigit{this, "doTGCDigit", false}; // switch on the output of the TGC digitization
68  Gaudi::Property<bool> m_doTGCRDO{this, "doTGCRDO", false}; // switch on the output of the TGC RDO
69  Gaudi::Property<bool> m_doTGCPRD{this, "doTGCPRD", false}; // switch on the output of the TGC prepdata
70  Gaudi::Property<bool> m_doMMSDO{this, "doMMSDO", false}; // switch on the output of the MicroMegas SDO
71  Gaudi::Property<bool> m_doSTGCSDO{this, "doSTGCSDO", false}; // switch on the output of the sTGC SDO
72 
73  Gaudi::Property<std::string> m_Truth_ContainerName{this, "Truth_ContainerName", "TruthEvent"};
74  Gaudi::Property<std::string> m_MuEntry_ContainerName{this, "MuonEntryLayer_ContainerName", "MuonEntryLayer"};
75 
76  Gaudi::Property<std::string> m_NSWsTGC_ContainerName{this, "NSWsTGC_ContainerName", "sTGC_Hits"};
77  Gaudi::Property<std::string> m_NSWsTGC_SDOContainerName{this, "NSWsTGC_SDOContainerName", "sTGC_SDO"};
78  Gaudi::Property<std::string> m_NSWsTGC_DigitContainerName{this, "NSWsTGC_DigitContainerName", "sTGC_DIGITS"};
79  Gaudi::Property<std::string> m_NSWsTGC_RDOContainerName{this, "NSWsTGC_RDOContainerName", "sTGCRDO"};
80  Gaudi::Property<std::string> m_NSWsTGC_PRDContainerName{this, "NSWsTGC_PRDContainerName", "STGC_Measurements"};
81 
82  Gaudi::Property<std::string> m_NSWMM_ContainerName{this, "NSWMM_ContainerName", "MM_Hits"};
83  Gaudi::Property<std::string> m_NSWMM_SDOContainerName{this, "NSWMM_SDOContainerName", "MM_SDO"};
84  Gaudi::Property<std::string> m_NSWMM_DigitContainerName{this, "NSWMM_DigitContainerName", "MM_DIGITS"};
85  Gaudi::Property<std::string> m_NSWMM_RDOContainerName{this, "NSWMM_RDOContainerName", "MMRDO"};
86  Gaudi::Property<std::string> m_NSWMM_PRDContainerName{this, "NSWMM_PRDContainerName", "MM_Measurements"};
87 
88  Gaudi::Property<std::string> m_CSC_SimContainerName{this, "CSC_SimContainerName", "CSC_Hits"};
89  Gaudi::Property<std::string> m_CSC_SDOContainerName{this, "CSC_SDOContainerName", "CSC_SDO"};
90  Gaudi::Property<std::string> m_CSC_DigitContainerName{this, "CSC_DigitContainerName", "CSC_DIGITS"};
91  Gaudi::Property<std::string> m_CSC_RDOContainerName{this, "CSC_RDOContainerName", "CSCRDO"};
92  Gaudi::Property<std::string> m_CSC_PRDContainerName{this, "CSC_PRDContainerName", "CSC_Clusters"};
93 
94  Gaudi::Property<std::string> m_MDT_SimContainerName{this, "MDT_SimContainerName", "MDT_Hits"};
95  Gaudi::Property<std::string> m_MDT_SDOContainerName{this, "MDT_SDOContainerName", "MDT_SDO"};
96  Gaudi::Property<std::string> m_MDT_DigitContainerName{this, "MDT_DigitContainerName", "MDT_DIGITS"};
97 
98  Gaudi::Property<std::string> m_RPC_SimContainerName{this, "RPC_SimContainerName", "RPC_Hits"};
99  Gaudi::Property<std::string> m_RPC_SDOContainerName{this, "RPC_SDOContainerName", "RPC_SDO"};
100  Gaudi::Property<std::string> m_RPC_DigitContainerName{this, "RPC_DigitContainerName", "RPC_DIGITS"};
101 
102  Gaudi::Property<std::string> m_TGC_SimContainerName{this, "TGC_SimContainerName", "TGC_Hits"};
103  Gaudi::Property<std::string> m_TGC_SDOContainerName{this, "TGC_SDOContainerName", "TGC_SDO"};
104  Gaudi::Property<std::string> m_TGC_DigitContainerName{this, "TGC_DigitContainerName", "TGC_DIGITS"};
105  Gaudi::Property<std::string> m_TGC_RDOContainerName{this, "TGC_RDOContainerName", "TGCRDO"};
106  Gaudi::Property<std::string> m_TGC_PRDContainerName{this, "TGC_PRDContainerName", "TGC_Measurements"};
107 
108  // Matching algorithm
109 
110  Gaudi::Property<bool> m_doNSWMatching{this, "doNSWMatchingAlg", false};
111  Gaudi::Property<bool> m_doNSWMatchingMuon{this, "doNSWMatchingMuonOnly", false};
112  Gaudi::Property<uint> m_maxStripDiff{this, "setMaxStripDistance", 3};
113  // this property is temporarely added to be able to deactivate the "No match found!" warning when running on the grid
114  Gaudi::Property<bool> m_noMatchWarning{this, "suppressNoMatchWarning", false};
115 };
116 
117 #endif // NSWPRDVALALG_H
NSWPRDValAlg::m_doMMRDO
Gaudi::Property< bool > m_doMMRDO
Definition: NSWPRDValAlg.h:52
NSWPRDValAlg::m_maxStripDiff
Gaudi::Property< uint > m_maxStripDiff
Definition: NSWPRDValAlg.h:112
ICSC_RDO_Decoder.h
NSWPRDValAlg::m_doMDTDigit
Gaudi::Property< bool > m_doMDTDigit
Definition: NSWPRDValAlg.h:61
NSWPRDValAlg::m_doCSCHit
Gaudi::Property< bool > m_doCSCHit
Definition: NSWPRDValAlg.h:54
NSWPRDValAlg::m_NSWsTGC_PRDContainerName
Gaudi::Property< std::string > m_NSWsTGC_PRDContainerName
Definition: NSWPRDValAlg.h:80
NSWPRDValAlg::m_doCSCRDO
Gaudi::Property< bool > m_doCSCRDO
Definition: NSWPRDValAlg.h:57
MuonTGC_CablingSvc.h
NSWPRDValAlg::m_NSWMM_ContainerName
Gaudi::Property< std::string > m_NSWMM_ContainerName
Definition: NSWPRDValAlg.h:82
NSWPRDValAlg::m_doTGCPRD
Gaudi::Property< bool > m_doTGCPRD
Definition: NSWPRDValAlg.h:69
NSWPRDValAlg::m_CSC_DigitContainerName
Gaudi::Property< std::string > m_CSC_DigitContainerName
Definition: NSWPRDValAlg.h:90
NSWPRDValAlg::m_TGC_SDOContainerName
Gaudi::Property< std::string > m_TGC_SDOContainerName
Definition: NSWPRDValAlg.h:103
EDM_object
Definition: EDM_object.h:14
NSWPRDValAlg::m_TGC_SimContainerName
Gaudi::Property< std::string > m_TGC_SimContainerName
Definition: NSWPRDValAlg.h:102
NSWPRDValAlg::m_doMMHit
Gaudi::Property< bool > m_doMMHit
Definition: NSWPRDValAlg.h:49
NSWPRDValAlg::m_doNSWMatchingMuon
Gaudi::Property< bool > m_doNSWMatchingMuon
Definition: NSWPRDValAlg.h:111
NSWPRDValAlg::setDataAdress
StatusCode setDataAdress(EDM_object &oData, const TString &branch_name)
Definition: NSWPRDValAlg.cxx:305
NSWPRDValAlg::NSWPRDValAlg
NSWPRDValAlg(const std::string &name, ISvcLocator *pSvcLocator)
Definition: NSWPRDValAlg.cxx:21
NSWPRDValAlg::m_doMMSDO
Gaudi::Property< bool > m_doMMSDO
Definition: NSWPRDValAlg.h:70
NSWPRDValAlg::m_NSWsTGC_DigitContainerName
Gaudi::Property< std::string > m_NSWsTGC_DigitContainerName
Definition: NSWPRDValAlg.h:78
NSWPRDValAlg::m_doMDTSDO
Gaudi::Property< bool > m_doMDTSDO
Definition: NSWPRDValAlg.h:60
NSWPRDValAlg::m_doCSCDigit
Gaudi::Property< bool > m_doCSCDigit
Definition: NSWPRDValAlg.h:56
MuonTesterTree.h
NSWPRDValAlg::m_CSC_SDOContainerName
Gaudi::Property< std::string > m_CSC_SDOContainerName
Definition: NSWPRDValAlg.h:89
const
bool const RAWDATA *ch2 const
Definition: LArRodBlockPhysicsV0.cxx:560
NSWPRDValAlg::m_RPC_SDOContainerName
Gaudi::Property< std::string > m_RPC_SDOContainerName
Definition: NSWPRDValAlg.h:99
NSWPRDValAlg::m_doSTGCPRD
Gaudi::Property< bool > m_doSTGCPRD
Definition: NSWPRDValAlg.h:48
NSWPRDValAlg::m_doSTGCHit
Gaudi::Property< bool > m_doSTGCHit
Definition: NSWPRDValAlg.h:44
NSWPRDValAlg::m_NSWsTGC_RDOContainerName
Gaudi::Property< std::string > m_NSWsTGC_RDOContainerName
Definition: NSWPRDValAlg.h:79
NSWPRDValAlg::m_doTruth
Gaudi::Property< bool > m_doTruth
Definition: NSWPRDValAlg.h:42
NSWPRDValAlg::m_doRPCSDO
Gaudi::Property< bool > m_doRPCSDO
Definition: NSWPRDValAlg.h:63
NSWPRDValAlg::m_MDT_SDOContainerName
Gaudi::Property< std::string > m_MDT_SDOContainerName
Definition: NSWPRDValAlg.h:95
NSWPRDValAlg::m_tree
MuonVal::MuonTesterTree m_tree
Definition: NSWPRDValAlg.h:34
NSWPRDValAlg::m_MuEntry_ContainerName
Gaudi::Property< std::string > m_MuEntry_ContainerName
Definition: NSWPRDValAlg.h:74
NSWPRDValAlg::m_doMMPRD
Gaudi::Property< bool > m_doMMPRD
Definition: NSWPRDValAlg.h:53
NSWPRDValAlg::m_TGC_DigitContainerName
Gaudi::Property< std::string > m_TGC_DigitContainerName
Definition: NSWPRDValAlg.h:104
NSWPRDValAlg::m_NSWsTGC_ContainerName
Gaudi::Property< std::string > m_NSWsTGC_ContainerName
Definition: NSWPRDValAlg.h:76
AthHistogramAlgorithm.h
NSWPRDValAlg::m_doMMFastDigit
Gaudi::Property< bool > m_doMMFastDigit
Definition: NSWPRDValAlg.h:50
NSWPRDValAlg::m_RPC_DigitContainerName
Gaudi::Property< std::string > m_RPC_DigitContainerName
Definition: NSWPRDValAlg.h:100
NSWPRDValAlg::m_idHelperSvc
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Definition: NSWPRDValAlg.h:38
NSWPRDValAlg::m_doMuEntry
Gaudi::Property< bool > m_doMuEntry
Definition: NSWPRDValAlg.h:43
NSWPRDValAlg::initialize
StatusCode initialize() override
Definition: NSWPRDValAlg.cxx:23
MuonVal::MuonTesterTree
Definition: MuonTesterTree.h:30
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
NSWPRDValAlg::m_CSC_SimContainerName
Gaudi::Property< std::string > m_CSC_SimContainerName
Definition: NSWPRDValAlg.h:88
NSWPRDValAlg::m_doTGCRDO
Gaudi::Property< bool > m_doTGCRDO
Definition: NSWPRDValAlg.h:68
NSWPRDValAlg::execute
StatusCode execute() override
Definition: NSWPRDValAlg.cxx:99
NSWPRDValAlg::NSWMatchingAlg
StatusCode NSWMatchingAlg()
Definition: NSWPRDValAlg.cxx:117
NSWPRDValAlg::m_RPC_SimContainerName
Gaudi::Property< std::string > m_RPC_SimContainerName
Definition: NSWPRDValAlg.h:98
NSWPRDValAlg::m_MDT_SimContainerName
Gaudi::Property< std::string > m_MDT_SimContainerName
Definition: NSWPRDValAlg.h:94
AthHistogramAlgorithm
Definition: AthHistogramAlgorithm.h:32
NSWPRDValAlg::m_doCSCPRD
Gaudi::Property< bool > m_doCSCPRD
Definition: NSWPRDValAlg.h:58
NSWPRDValAlg::m_doTGCDigit
Gaudi::Property< bool > m_doTGCDigit
Definition: NSWPRDValAlg.h:67
NSWPRDValAlg::m_doTGCSDO
Gaudi::Property< bool > m_doTGCSDO
Definition: NSWPRDValAlg.h:66
NSWPRDValAlg::m_doNSWMatching
Gaudi::Property< bool > m_doNSWMatching
Definition: NSWPRDValAlg.h:110
NSWPRDValAlg::m_tgcCabling
ServiceHandle< MuonTGC_CablingSvc > m_tgcCabling
Definition: NSWPRDValAlg.h:36
NSWPRDValAlg::m_NSWMM_PRDContainerName
Gaudi::Property< std::string > m_NSWMM_PRDContainerName
Definition: NSWPRDValAlg.h:86
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
NSWPRDValAlg::m_CSC_PRDContainerName
Gaudi::Property< std::string > m_CSC_PRDContainerName
Definition: NSWPRDValAlg.h:92
NSWPRDValAlg::finalize
StatusCode finalize() override
Definition: NSWPRDValAlg.cxx:92
NSWPRDValAlg::m_doSTGCDigit
Gaudi::Property< bool > m_doSTGCDigit
Definition: NSWPRDValAlg.h:46
NSWPRDValAlg::m_doSTGCRDO
Gaudi::Property< bool > m_doSTGCRDO
Definition: NSWPRDValAlg.h:47
NSWPRDValAlg::m_isData
Gaudi::Property< bool > m_isData
Definition: NSWPRDValAlg.h:41
NSWPRDValAlg::cardinality
unsigned int cardinality() const override final
Definition: NSWPRDValAlg.h:23
RTTAlgmain.data1
data1
Definition: RTTAlgmain.py:54
NSWPRDValAlg::m_Truth_ContainerName
Gaudi::Property< std::string > m_Truth_ContainerName
Definition: NSWPRDValAlg.h:73
NSWPRDValAlg::m_NSWMM_SDOContainerName
Gaudi::Property< std::string > m_NSWMM_SDOContainerName
Definition: NSWPRDValAlg.h:83
NSWPRDValAlg::m_doRPCDigit
Gaudi::Property< bool > m_doRPCDigit
Definition: NSWPRDValAlg.h:64
EDM_object.h
NSWPRDValAlg::m_doCSCSDO
Gaudi::Property< bool > m_doCSCSDO
Definition: NSWPRDValAlg.h:55
NSWPRDValAlg::m_TGC_RDOContainerName
Gaudi::Property< std::string > m_TGC_RDOContainerName
Definition: NSWPRDValAlg.h:105
NSWPRDValAlg::m_doSTGCFastDigit
Gaudi::Property< bool > m_doSTGCFastDigit
Definition: NSWPRDValAlg.h:45
NSWPRDValAlg::m_NSWMM_RDOContainerName
Gaudi::Property< std::string > m_NSWMM_RDOContainerName
Definition: NSWPRDValAlg.h:85
NSWPRDValAlg::m_doTGCHit
Gaudi::Property< bool > m_doTGCHit
Definition: NSWPRDValAlg.h:65
NSWPRDValAlg::m_doSTGCSDO
Gaudi::Property< bool > m_doSTGCSDO
Definition: NSWPRDValAlg.h:71
NSWPRDValAlg::m_doMDTHit
Gaudi::Property< bool > m_doMDTHit
Definition: NSWPRDValAlg.h:59
NSWPRDValAlg::m_NSWMM_DigitContainerName
Gaudi::Property< std::string > m_NSWMM_DigitContainerName
Definition: NSWPRDValAlg.h:84
NSWPRDValAlg::m_TGC_PRDContainerName
Gaudi::Property< std::string > m_TGC_PRDContainerName
Definition: NSWPRDValAlg.h:106
NSWPRDValAlg
Definition: NSWPRDValAlg.h:16
NSWPRDValAlg::m_csc_decoder
PublicToolHandle< Muon::ICSC_RDO_Decoder > m_csc_decoder
Definition: NSWPRDValAlg.h:39
NSWPRDValAlg::m_CSC_RDOContainerName
Gaudi::Property< std::string > m_CSC_RDOContainerName
Definition: NSWPRDValAlg.h:91
NSWPRDValAlg::m_doMMDigit
Gaudi::Property< bool > m_doMMDigit
Definition: NSWPRDValAlg.h:51
IMuonIdHelperSvc.h
NSWPRDValAlg::m_NSWsTGC_SDOContainerName
Gaudi::Property< std::string > m_NSWsTGC_SDOContainerName
Definition: NSWPRDValAlg.h:77
NSWPRDValAlg::m_doRPCHit
Gaudi::Property< bool > m_doRPCHit
Definition: NSWPRDValAlg.h:62
ServiceHandle< MuonTGC_CablingSvc >
NSWPRDValAlg::m_MDT_DigitContainerName
Gaudi::Property< std::string > m_MDT_DigitContainerName
Definition: NSWPRDValAlg.h:96
NSWPRDValAlg::m_noMatchWarning
Gaudi::Property< bool > m_noMatchWarning
Definition: NSWPRDValAlg.h:114