Commit 4bde4900 authored by Atlas-Software Librarian's avatar Atlas-Software Librarian Committed by Graeme Stewart
Browse files

'CMakeLists.txt' (DerivationFrameworkHiggs-00-03-67)

parent 4bbd4a6d
################################################################################
# Package: DerivationFrameworkHiggs
################################################################################
# Declare the package name:
atlas_subdir( DerivationFrameworkHiggs )
# Declare the package's dependencies:
atlas_depends_on_subdirs( PUBLIC
Control/AthenaBaseComps
Event/xAOD/xAODEgamma
Event/xAOD/xAODJet
Event/xAOD/xAODMuon
PhysicsAnalysis/DerivationFramework/DerivationFrameworkInterfaces
Trigger/TrigAnalysis/TrigDecisionTool
PRIVATE
Event/xAOD/xAODEventInfo
Event/xAOD/xAODTracking
GaudiKernel )
# External dependencies:
find_package( CLHEP )
# Component(s) in the package:
atlas_add_library( DerivationFrameworkHiggsLib
src/*.cxx
PUBLIC_HEADERS DerivationFrameworkHiggs
PRIVATE_INCLUDE_DIRS ${CLHEP_INCLUDE_DIRS}
PRIVATE_DEFINITIONS ${CLHEP_DEFINITIONS}
LINK_LIBRARIES AthenaBaseComps xAODEgamma xAODJet xAODMuon TrigDecisionToolLib
PRIVATE_LINK_LIBRARIES ${CLHEP_LIBRARIES} xAODEventInfo xAODTracking GaudiKernel )
atlas_add_component( DerivationFrameworkHiggs
src/components/*.cxx
INCLUDE_DIRS ${CLHEP_INCLUDE_DIRS}
LINK_LIBRARIES ${CLHEP_LIBRARIES} AthenaBaseComps xAODEgamma xAODJet xAODMuon TrigDecisionToolLib xAODEventInfo xAODTracking GaudiKernel DerivationFrameworkHiggsLib )
# Install files from the package:
atlas_install_python_modules( python/*.py )
atlas_install_joboptions( share/*.py )
/*
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
*/
///////////////////////////////////////////////////////////////////
// SkimmingToolHIGG1.h, (c) ATLAS Detector software
///////////////////////////////////////////////////////////////////
#ifndef DERIVATIONFRAMEWORK_SKIMMINGTOOLHSG1_H
#define DERIVATIONFRAMEWORK_SKIMMINGTOOLHSG1_H 1
#include <string>
#include <vector>
#include <algorithm>
// Gaudi & Athena basics
#include "AthenaBaseComps/AthAlgTool.h"
// DerivationFramework includes
#include "DerivationFrameworkInterfaces/ISkimmingTool.h"
// xAOD header files
#include "xAODEgamma/ElectronContainer.h"
#include "xAODEgamma/PhotonContainer.h"
#include "xAODJet/JetContainer.h"
#include "xAODMuon/MuonContainer.h"
#include "TrigDecisionTool/TrigDecisionTool.h"
namespace DerivationFramework {
/** @class SkimmingToolHIGG1
@author jsaxon@cern.ch
@author magdac@cern.ch
*/
class SkimmingToolHIGG1 : public AthAlgTool, public ISkimmingTool {
public:
/** Constructor with parameters */
SkimmingToolHIGG1( const std::string& t, const std::string& n, const IInterface* p );
/** Destructor */
~SkimmingToolHIGG1();
// Athena algtool's Hooks
StatusCode initialize();
StatusCode finalize();
/** Check that the current event passes this filter */
virtual bool eventPassesFilter() const;
private:
///////////////
///// TOOLS
ToolHandle<Trig::TrigDecisionTool> m_trigDecisionTool;
///////////////
///// SETTINGS
std::string m_photonSGKey;
std::string m_electronSGKey;
std::string m_muonSGKey;
// CUTS TO APPLY OR NOT
bool m_reqGRL;
bool m_reqLArError;
bool m_reqTrigger;
bool m_reqPreselection;
bool m_incSingleElectron;
bool m_incDoubleElectron;
bool m_incSingleMuon;
bool m_reqKinematic;
bool m_reqQuality;
bool m_reqIsolation;
bool m_reqInvariantMass;
// CUT VALUES/SETTINGS
std::string m_goodRunList;
std::string m_defaultTrigger;
std::vector<std::string> m_triggers;
mutable bool m_isMC;
double m_minPhotonPt;
bool m_removeCrack;
double m_maxEta;
bool m_relativePtCuts;
double m_leadingPhotonPt;
double m_subleadingPhotonPt;
double m_minInvariantMass;
double m_maxInvariantMass;
double m_minElectronPt;
double m_minMuonPt;
double m_maxMuonEta;
////////////////
///// FUNCTIONS
// Cuts
bool SubcutGoodRunList() const;
bool SubcutLArError() const;
bool SubcutTrigger() const;
bool SubcutPreselect() const;
bool SubcutOnePhotonOneElectron() const;
bool SubcutTwoElectrons() const;
bool SubcutOnePhotonOneMuon() const;
bool SubcutKinematic() const;
bool SubcutQuality() const;
bool SubcutIsolation() const;
bool SubcutInvariantMass() const;
// Calculators
bool PhotonPreselect(const xAOD::Photon *ph) const;
bool ElectronPreselect(const xAOD::Electron *el) const;
bool MuonPreselect(const xAOD::Muon *mu) const;
void CalculateInvariantMass() const;
void GetDiphotonVertex() const;
double CorrectedEnergy(const xAOD::Photon *ph) const;
double CorrectedEta(const xAOD::Photon *ph) const;
double ReturnRZ_1stSampling_cscopt2(double eta1) const;
///////////////
///// COUNTERS
mutable unsigned int n_tot;
mutable unsigned int n_passGRL;
mutable unsigned int n_passLArError;
mutable unsigned int n_passTrigger;
mutable unsigned int n_passPreselect;
mutable unsigned int n_passSingleElectronPreselect;
mutable unsigned int n_passDoubleElectronPreselect;
mutable unsigned int n_passSingleMuonPreselect;
mutable unsigned int n_passKinematic;
mutable unsigned int n_passQuality;
mutable unsigned int n_passIsolation;
mutable unsigned int n_passInvariantMass;
mutable unsigned int n_pass;
/////////////////////////////
///// EVENT LEVEL QUANTITIES
mutable std::vector<const xAOD::Photon*> e_leadingPhotons;
mutable TLorentzVector leadPhotonLV;
mutable TLorentzVector sublPhotonLV;
mutable bool e_tot;
mutable bool e_passGRL;
mutable bool e_passLArError;
mutable bool e_passTrigger;
mutable bool e_passPreselect;
mutable bool e_passSingleElectronPreselect;
mutable bool e_passDoubleElectronPreselect;
mutable bool e_passSingleMuonPreselect;
mutable bool e_passKinematic;
mutable bool e_passQuality;
mutable bool e_passIsolation;
mutable bool e_passInvariantMass;
mutable bool e_pass;
mutable int ph_pos_lead, ph_pos_subl;
mutable double ph_pt_lead, ph_eta_lead, ph_phi_lead, ph_e_lead;
mutable double ph_pt_subl, ph_eta_subl, ph_phi_subl, ph_e_subl;
mutable int ph_tight_lead, ph_tight_subl;
mutable int ph_iso_lead, ph_iso_subl;
mutable double e_invariantMass;
mutable double e_diphotonZ;
/////////////////////////////
///// FUNCTIONS
static const double s_MZ;
};
}
#endif // DERIVATIONFRAMEWORK_SKIMMINGTOOLEXAMPLE_H
/*
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
*/
///////////////////////////////////////////////////////////////////
// SkimmingToolHIGG2.h, (c) ATLAS Detector software
///////////////////////////////////////////////////////////////////
#ifndef DERIVATIONFRAMEWORK_SKIMMINGTOOLHSG2_H
#define DERIVATIONFRAMEWORK_SKIMMINGTOOLHSG2_H 1
#include<string>
#include<vector>
#include<map>
// Gaudi & Athena basics
#include "AthenaBaseComps/AthAlgTool.h"
// DerivationFramework includes
#include "DerivationFrameworkInterfaces/ISkimmingTool.h"
// xAOD header files
#include "xAODEgamma/ElectronContainer.h"
#include "xAODEgamma/PhotonContainer.h"
#include "xAODJet/JetContainer.h"
#include "xAODMuon/MuonContainer.h"
#include "TrigDecisionTool/TrigDecisionTool.h"
namespace DerivationFramework {
/** @class SkimmingToolHIGG2
@author Susumu.Oda@cern.ch
*/
class SkimmingToolHIGG2 : public AthAlgTool, public ISkimmingTool {
public:
/** Constructor with parameters */
SkimmingToolHIGG2( const std::string& t, const std::string& n, const IInterface* p );
/** Destructor */
~SkimmingToolHIGG2();
// Athena algtool's Hooks
StatusCode initialize();
StatusCode finalize();
/** Check that the current event passes this filter */
virtual bool eventPassesFilter() const;
private:
enum {
NUMBER_OF_MERGED_JET_TYPES = 3
};
ToolHandle<Trig::TrigDecisionTool> m_trigDecisionTool;
mutable unsigned int m_ntot;
mutable unsigned int m_npass;
bool m_skipTriggerRequirement;
mutable std::vector<const xAOD::Electron*> m_goodElectrons;
mutable std::vector<const xAOD::Muon*> m_goodMuons;
mutable std::vector<const xAOD::Jet*> m_goodJets;
mutable std::vector<const xAOD::Jet*> m_goodMergedJets[NUMBER_OF_MERGED_JET_TYPES];
mutable std::vector<const xAOD::Photon*> m_goodPhotons;
mutable std::vector<const xAOD::TrackParticle*> m_goodTracks;
std::string m_filterType;
std::string m_electronSGKey;
std::string m_muonSGKey;
std::string m_jetSGKey;
std::string m_mergedJetSGKey[NUMBER_OF_MERGED_JET_TYPES];
std::string m_photonSGKey;
std::string m_trackSGKey;
unsigned int m_nLeptons;
unsigned int m_nElectrons;
unsigned int m_nMuons;
unsigned int m_nJets;
unsigned int m_nMergedJets[NUMBER_OF_MERGED_JET_TYPES];
unsigned int m_nPhotons;
unsigned int m_nTracks;
std::string m_electronQual;
std::string m_muonQual;
std::string m_tightMuonQual;
std::string m_tightElectronQual;
std::string m_jetQual;
std::string m_mergedJetQual[NUMBER_OF_MERGED_JET_TYPES];
std::string m_photonQual;
std::string m_primaryElectronQual4L;
std::vector<std::string> m_trigger2L;
std::vector<std::string> m_triggerTP;
std::vector<std::string> m_trigger2L2Q;
std::vector<std::string> m_triggerJPSI;
std::vector<std::string> m_triggerPHI;
double m_electronEtCut;
double m_muonPtCut;
double m_tightElectronEtCut;
double m_tightMuonPtCut;
double m_jetPtCut;
double m_mergedJetPtCut[NUMBER_OF_MERGED_JET_TYPES];
double m_photonPtCut;
double m_trackPtCut;
double m_electronEtaCut;
double m_muonEtaCut;
double m_caloMuonEtaCut;
double m_jetEtaCut;
double m_mergedJetEtaCut[NUMBER_OF_MERGED_JET_TYPES];
double m_photonEtaCut;
double m_invariantMassCut;
double m_invariantMassJpsiLowCut;
double m_invariantMassJpsiUpCut;
double m_invariantMassUpsilonLowCut;
double m_invariantMassUpsilonUpCut;
double m_invariantMassPhiLowCut;
double m_invariantMassPhiUpCut;
double m_leadingElectronEtCut;
double m_leadingMuonPtCut;
double m_dRElectronJetCut;
bool m_checkLArError;
bool m_defaultElectronFourMomentum;
// bool m_DFCommonElectronFourMomentum;
// mutable std::map<const xAOD::Electron*, unsigned int> m_mapElectrons;
// mutable const std::vector<float> *m_DFCommonElectrons_pt;
// mutable const std::vector<float> *m_DFCommonElectrons_eta;
// mutable const std::vector<float> *m_DFCommonElectrons_phi;
bool m_DFCommonJetFourMomentum;
bool m_requireTightLeptons;
bool checkElectronQuality(const xAOD::Electron *el, const bool isTight=false) const;
bool checkMuonQuality(const xAOD::Muon *mu, const bool isTight=false) const;
bool checkJetQuality(const xAOD::Jet *jet) const;
bool checkMergedJetQuality(const xAOD::Jet *jet, const unsigned int type) const;
bool checkPhotonQuality(const xAOD::Photon *ph) const;
bool checkTrackQuality(const xAOD::TrackParticle *trk) const;
bool check2L() const;
bool check4L() const;
bool checkTP() const;
bool check2L2Q() const;
bool checkJPSI() const;
bool checkPHI() const;
TLorentzVector electronFourMomentum(const xAOD::Electron *el) const;
TLorentzVector muonFourMomentum(const xAOD::Muon *mu) const;
TLorentzVector jetFourMomentum(const xAOD::Jet *jet) const;
double getDeltaR(const double eta1, const double phi1, const double eta2, const double phi2) const;
static const double s_MZ;
static const double s_MKplus;
};
}
#endif // DERIVATIONFRAMEWORK_SKIMMINGTOOLEXAMPLE_H
/*
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
*/
///////////////////////////////////////////////////////////////////
// SkimmingToolHIGG5VBF.h, (c) ATLAS Detector software
///////////////////////////////////////////////////////////////////
#ifndef DERIVATIONFRAMEWORK_SKIMMINGTOOLHSG5VBF_H
#define DERIVATIONFRAMEWORK_SKIMMINGTOOLHSG5VBF_H
#include<string>
#include<vector>
// Gaudi & Athena basics
#include "AthenaBaseComps/AthAlgTool.h"
// DerivationFramework includes
#include "DerivationFrameworkInterfaces/ISkimmingTool.h"
// xAOD header files
#include "xAODJet/JetContainer.h"
#include "xAODEgamma/PhotonContainer.h"
#include "TrigDecisionTool/TrigDecisionTool.h"
class TLoretzVector;
namespace DerivationFramework {
/** @class SkimmingToolHIGG5VBF
@author Yasuyuki.Okumura@cern.ch
*/
class SkimmingToolHIGG5VBF : public AthAlgTool, public ISkimmingTool {
public:
/** Constructor with parameters */
SkimmingToolHIGG5VBF( const std::string& t, const std::string& n, const IInterface* p );
/** Destructor */
~SkimmingToolHIGG5VBF();
// Athena algtool's Hooks
StatusCode initialize();
StatusCode finalize();
/** Check that the current event passes this filter */
virtual bool eventPassesFilter() const;
private:
bool m_debug;
ToolHandle<Trig::TrigDecisionTool> m_trigDecisionTool;
mutable unsigned int m_ntot;
mutable unsigned int m_npass;
mutable std::vector<TLorentzVector> m_goodAllJets;
mutable std::vector<TLorentzVector> m_goodCentralJets;
std::string m_jetSGKey;
std::string m_calibedJetMomKey;
// for jet multiplicity
bool m_reqNAllJets;
unsigned int m_nAllJets;
double m_allJetPtCut;
double m_allJetEtaCut;
bool m_reqNCentralJets;
unsigned int m_nCentralJets;
double m_centralJetPtCut;
double m_centralJetEtaCut;
// for trigger
bool m_reqTrigger;
std::vector<std::string> m_triggers;
// for Mjj
bool m_reqVbfMjj;
double m_vbfMjjCut;
bool checkAllJetQuality(const TLorentzVector& jet) const;
bool checkCentralJetQuality(const TLorentzVector& jet) const;
TLorentzVector getCalibedJets(const xAOD::Jet* jet) const;
//for photon (p. rose)
std::string m_phSGKey;
bool m_reqPh;
double m_phPtCut;
double m_centralPhEtaCut;
};
}
#endif // #ifndef DERIVATIONFRAMEWORK_SKIMMINGTOOLHSG5VBF_H
package DerivationFrameworkHiggs
author James Catmore <james.catmore@cern.ch>
#################################################################
# public use statements
use AtlasPolicy AtlasPolicy-*
use AthenaBaseComps AthenaBaseComps-* Control
use DerivationFrameworkInterfaces DerivationFrameworkInterfaces-* PhysicsAnalysis/DerivationFramework
use TrigDecisionTool TrigDecisionTool-* Trigger/TrigAnalysis
use xAODEgamma xAODEgamma-* Event/xAOD
use xAODJet xAODJet-* Event/xAOD
use xAODMuon xAODMuon-* Event/xAOD
private
use AtlasCLHEP AtlasCLHEP-* External
use GaudiInterface GaudiInterface-* External
use xAODEventInfo xAODEventInfo-* Event/xAOD
use xAODTracking xAODTracking-* Event/xAOD
#################################################################
#
public
## declare the directories CMT should know about
branches python share src
apply_pattern dual_use_library files= " *.cxx "
apply_pattern declare_joboptions files=" *.py"
apply_pattern declare_python_modules files="*.py"
# Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
#Content included in addition to the Smart Slimming Content
HIGG2D1ExtraContent=[
"egammaClusters.rawE.phi_sampl.calM",
"GSFTrackParticles.expectNextToInnermostPixelLayerHit.numberOfNextToInnermostPixelLayerHits.numberOfNextToInnermostPixelLayerOutliers",
"Muons.quality.etcone20.ptconecoreTrackPtrCorrection",
"ExtrapolatedMuonTrackParticles.numberOfTRTHits.numberOfTRTOutliers",
"AntiKt4EMTopoJets.JetEMScaleMomentum_pt.JetEMScaleMomentum_eta.JetEMScaleMomentum_phi.JetEMScaleMomentum_m"
]
HIGG2D1ExtraContentTruth=[
]
HIGG2D1ExtraContainers=[