.. _program_listing_file_xAODAnaHelpers_METConstructor.h: Program Listing for File METConstructor.h ========================================= |exhale_lsh| :ref:`Return to documentation for file ` (``xAODAnaHelpers/METConstructor.h``) .. |exhale_lsh| unicode:: U+021B0 .. UPWARDS ARROW WITH TIP LEFTWARDS .. code-block:: cpp #ifndef xAODAnaHelpers_METConstructor_H #define xAODAnaHelpers_METConstructor_H #include // Infrastructure include(s): #include "xAODRootAccess/Init.h" #include "xAODRootAccess/TEvent.h" #include "xAODRootAccess/TStore.h" #include "AsgTools/AnaToolHandle.h" #include "METInterface/IMETMaker.h" #include "METInterface/IMETSystematicsTool.h" #include "METInterface/IMETSignificance.h" #include "TauAnalysisTools/ITauSelectionTool.h" #include "PATInterfaces/SystematicRegistry.h" //look at https://twiki.cern.ch/twiki/bin/view/AtlasComputing/SoftwareTutorialxAODAnalysisInROOT using std::string; class METConstructor : public xAH::Algorithm { // put your configuration variables here as public variables. // that way they can be set directly from CINT and python. public: // configuration variables std::string m_mapName = "METAssoc_AntiKt4LCTopo"; std::string m_coreName = "MET_Core_AntiKt4LCTopo"; std::string m_outputContainer = "NewRefFinal"; std::string m_systConfigPrefix = "METUtilities/R22_PreRecs"; std::string m_systConfigSoftTrkFile = "TrackSoftTerms-pflow_Dec24.config"; std::string m_inputJets = ""; std::string m_inputElectrons = ""; std::string m_inputPhotons = ""; std::string m_inputTaus = ""; std::string m_inputMuons = ""; bool m_doElectronCuts = false; bool m_doPhotonCuts = false; bool m_doTauCuts = false; bool m_doMuonCuts = false; bool m_doMuonEloss = false; bool m_doIsolMuonEloss = false; bool m_doJVTCut = false; bool m_dofJVTCut = false; std::string m_fJVTdecorName = "passFJVT"; bool m_doPFlow = true; std::string m_METWorkingPoint = ""; bool m_rebuildUsingTracksInJets = false; bool m_addSoftClusterTerms = false; // MET significance bool m_calculateSignificance = false; bool m_significanceTreatPUJets = true; double m_significanceSoftTermReso = 10.0; // used for systematics bool m_runNominal = true; std::string m_systName = "All"; float m_systVal = 1.0; bool m_writeSystToMetadata = false; std::string m_jetSystematics = ""; std::string m_eleSystematics = ""; std::string m_muonSystematics = ""; std::string m_tauSystematics = ""; std::string m_phoSystematics = ""; std::string m_outputAlgoSystNames = ""; private: // tools asg::AnaToolHandle m_metmaker_handle{"met::METMaker/METMaker", this}; asg::AnaToolHandle m_metSyst_handle{"met::METSystematicsTool/METSystematicsTool", this}; asg::AnaToolHandle m_metSignificance_handle{"met::METSignificance/METSignificance", this}; asg::AnaToolHandle m_tauSelTool_handle{"TauAnalysisTools::TauSelectionTool/TauSelectionTool", this}; std::vector m_sysList; int m_numEvent; // variables that don't get filled at submission time should be // protected from being send from the submission node to the worker // node (done by the //!) public: // Tree *myTree; //! // TH1 *myHist; //! // this is a standard constructor METConstructor (); // these are the functions inherited from Algorithm virtual EL::StatusCode setupJob (EL::Job& job); virtual EL::StatusCode fileExecute (); virtual EL::StatusCode histInitialize (); virtual EL::StatusCode changeInput (bool firstFile); virtual EL::StatusCode initialize (); virtual EL::StatusCode execute (); virtual EL::StatusCode postExecute(); virtual EL::StatusCode finalize(); virtual EL::StatusCode histFinalize(); // this is needed to distribute the algorithm to the workers ClassDef(METConstructor, 1); }; #endif