#include <memory>
#include <cstdlib>
#include <TFile.h>
#include <TError.h>
#include <TString.h>
#include "xAODEventInfo/EventInfo.h"
#include "xAODEgamma/PhotonContainer.h"
#include "xAODEgamma/Egamma.h"
#include "xAODEgamma/EgammaxAODHelpers.h"
#include "IsolationCorrections/IsolationCorrectionTool.h"
#include "xAODCore/ShallowCopy.h"
#include "PathResolver/PathResolver.h"
#include <PATInterfaces/SystematicsUtil.h>
#include <iostream>
#include <string>
Go to the source code of this file.
|
int | main (int argc, char *argv[]) |
|
◆ CHECK
◆ main()
int main |
( |
int |
argc, |
|
|
char * |
argv[] |
|
) |
| |
Definition at line 45 of file TestIsolationCorrections.cxx.
63 std::unique_ptr< TFile >
ifile( TFile::Open(
fileName,
"READ" ) );
75 Long64_t
entries =
event.getEntries();
77 const Long64_t
e = atoll(
argv[ 2 ] );
86 CHECK( m_isoCorrTool.setProperty(
"IsMC",
true) );
89 CHECK(m_isoCorrTool.setProperty(
"CorrFile",file_unc));
91 if(!m_isoCorrTool.initialize()){
92 std::cout <<
"Failed to initialize the tool, check for errors"<<std::endl;
98 std::cout <<
"loop on " <<
entries <<
" entries"<<std::endl;
102 event.getEntry(
entry );
122 for( ; ph_itr != ph_end; ++ph_itr, ++
i ) {
126 if(ph->
pt()<10000.0)
continue;
127 if( fabs(ph->
eta())>2.47)
continue;
132 CHECK(m_isoCorrTool.applyCorrection(*ph));
139 CHECK(m_isoCorrTool.finalize());
std::pair< std::unique_ptr< T >, std::unique_ptr< ShallowAuxContainer > > shallowCopyContainer(const T &cont, [[maybe_unused]] const EventContext &ctx)
Function making a shallow copy of a constant container.