63 {
64
65
67
68 MSG::Level mylevel=MSG::DEBUG;
69 dummymsg.msg().setLevel(mylevel);
71
72 if( argc < 2 ) {
74 MSG_ERROR(
" Usage: %s [xAOD file name]");
75 return EXIT_FAILURE;
76 }
77
78
80
81
84 std::unique_ptr< TFile >
ifile( TFile::Open( fileName,
"READ" ) );
86
87
89 if( argc < 4 ) {
91 } else {
92 int argv1 =
atoi(argv[ 3 ]);
96 }
97
98
99
101
102
103
104
107
108 MSG_INFO(
"Number of events in the file: "<< pers.getEntries());
109
110
111 Long64_t
entries = pers.getEntries();
112 if( argc > 2 ) {
113 const Long64_t
e = atoll( argv[ 2 ] );
116 }
117 }
118
119
121
122 std::unique_ptr<AsgElectronChargeIDSelectorTool> m_electronECIDS = std::make_unique<AsgElectronChargeIDSelectorTool> ("tightECIDS");
123 std::string trainingfile = std::string(std::getenv("ROOTCOREBIN")) + "/data/ElectronPhotonSelectorTools/ECIDS_20161125for2017Moriond.root";
124 CHECK(m_electronECIDS->setProperty(
"TrainingFile", trainingfile));
125 CHECK(m_electronECIDS->setProperty(
"CutOnBDT", 0));
126 m_electronECIDS->msg().setLevel(mylevel);
127 CHECK(m_electronECIDS->initialize());
128
129
130 std::unique_ptr<AsgElectronLikelihoodTool> m_TightLH = std::make_unique<AsgElectronLikelihoodTool> ("TightLH");
131 CHECK(m_TightLH->setProperty(
"WorkingPoint",
"TightLHElectron"));
132 m_TightLH->msg().setLevel(mylevel);
133 CHECK(m_TightLH->initialize());
134
135
137
138
139 pers.getEntry( entry );
140 MSG_INFO(
"============================");
142
144 CHECK(pers.retrieve(electrons,
"Electrons"));
145
148 MSG_INFO(
"---------------------------");
150 MSG_INFO(
"Electron LH Tight accept result: " <<m_TightLH->accept(el));
151
152 MSG_INFO(
"Electron Cut ECIDS accept result: " <<m_electronECIDS->accept(el));
153 MSG_INFO(
"Electron stored Tight: " <<
el->passSelection(
"Tight") );
155 }
156 }
157
158 }
159 else {
160
161 std::unique_ptr<AsgPhotonIsEMSelector> m_photonTightIsEMSelector = std::make_unique<AsgPhotonIsEMSelector> ("photonTightIsEMSelector");
162 CHECK(m_photonTightIsEMSelector->setProperty(
"WorkingPoint",
"TightPhoton"));
163 m_photonTightIsEMSelector->msg().setLevel(mylevel);
164 CHECK(m_photonTightIsEMSelector->initialize());
165
166
168
169
170 pers.getEntry( entry );
171 MSG_INFO(
"============================");
173
175 CHECK(pers.retrieve(photons,
"Photons"));
179 MSG_INFO(
"---------------------------");
181 MSG_INFO(
"Photon Tight accept result: " <<m_photonTightIsEMSelector->accept(ph));
183 }
184 }
185 }
186 }
187
188
190 return 0;
191}
bool isElectron(const T &p)
ReadStats & stats()
Access the object belonging to the current thread.
static IOStats & instance()
Singleton object accessor.
void printSmartSlimmingBranchList(bool autoIncludeLinks=false) const
Print the accessed variables, formatted for smart slimming.
Tool for accessing xAOD files outside of Athena.
@ kAthenaAccess
Access containers/objects like Athena does.
A relatively simple transient store for objects created in analysis.
int atoi(std::string_view str)
Helper functions to unpack numbers decoded in string into integers and doubles The strings are requir...
const uint16_t AuthorCaloTopo35
Photon reconstructed by SW CaloTopo35 seeded clusters.
StatusCode Init(const char *appname)
Function initialising ROOT/PyROOT for using the ATLAS EDM.
PhotonContainer_v1 PhotonContainer
Definition of the current "photon container version".
ElectronContainer_v1 ElectronContainer
Definition of the current "electron container version".
Photon_v1 Photon
Definition of the current "egamma version".
Electron_v1 Electron
Definition of the current "egamma version".