00001 #ifndef QUICK_ANA__TOP_ELECTRON_TOOL_H 00002 #define QUICK_ANA__TOP_ELECTRON_TOOL_H 00003 00004 00005 // This module still needs to be documented. The interface provided 00006 // in this module is intended for experts only. The module is 00007 // considered to be in the pre-alpha stage. 00008 00009 // It is flexible enough to provide: 00010 // Defintions corresponding to the default top group object selection(s) 00011 // (as implemented in the AnalysisTop packages) 00012 // Definitions for some other analyses that use slightly modified object selections 00013 // (e.g., Top/Exotics SS+bjets) 00014 00015 00016 00017 #include <QuickAna/Global.h> 00018 00019 #include <QuickAna/AnaToolCorrect.h> 00020 #include <QuickAna/AnaToolSelect.h> 00021 00022 // #include <QuickAna/IsolationTools.h> 00023 #include <QuickAna/SelectionCut.h> 00024 00025 namespace ana 00026 { 00031 class TopElectronToolPreCorrect : virtual public AnaToolCorrect<xAOD::ElectronContainer> 00032 { 00033 00035 ASG_TOOL_CLASS (TopElectronToolPreCorrect, ana::IAnaTool) 00036 00037 public: 00038 // Public interface methods 00039 00041 TopElectronToolPreCorrect (const std::string& name); 00042 00044 public: 00045 virtual AnalysisStep step () const override; 00046 00048 StatusCode initialize() override; 00049 00051 virtual StatusCode 00052 correctObject (xAOD::Electron& electron) override; 00053 00054 private: 00055 bool trackSelector(const xAOD::TrackParticle &trk); 00056 }; 00057 00058 00063 class TopElectronToolSelect : virtual public AnaToolSelect<xAOD::ElectronContainer> 00064 { 00065 00067 ASG_TOOL_CLASS (TopElectronToolSelect, ana::IAnaTool) 00068 00069 public: 00070 // Public interface methods 00071 00073 TopElectronToolSelect (const std::string& name); 00074 00076 StatusCode initialize() override; 00077 00079 virtual StatusCode 00080 selectObject (xAOD::Electron& electron) override; 00081 00082 private: 00083 00084 // Configuration 00085 00087 std::string m_idStr; 00088 00090 double m_ptMin; 00092 double m_etaMax; // Note: this is not configurable in TopObjectSelectionTools 00094 bool m_vetoCrack; 00095 00097 double m_z0cut; 00098 00099 public: 00101 std::unique_ptr<IsolationBase> m_isolation; 00102 00103 SelectionCut cut_author; 00104 SelectionCut cut_pt; 00105 SelectionCut cut_id; 00106 SelectionCut cut_etaMax; 00107 SelectionCut cut_etaCrack; 00108 SelectionCut cut_z0; 00109 SelectionCut cut_isolation; 00110 }; 00111 00112 00113 StatusCode makeTopElectronTool (DefinitionArgs& args, 00114 const std::string& quality_str, 00115 IsolationBase* isolation=nullptr, 00116 double z0cut=-1., 00117 bool vetoCrack=true); 00118 } 00119 00120 #endif