Commit da6e523e authored by Fabio Cardillo's avatar Fabio Cardillo
Browse files

Separate options for egamma pileup and SC leakage corrections

parent 5890a95d
......@@ -59,6 +59,8 @@ namespace top {
if (m_config->useEgammaLeakageCorrection()) {
top::check(asg::setProperty(isolationCorr, "Apply_SC_leakcorr", true),
"Failed to setProperty Apply_SC_leakcorr"); // super cluster based core correction
}
if (m_config->useEgammaPileupCorrection()) {
top::check(asg::setProperty(isolationCorr, "Apply_etaEDParPU_correction", true),
"Failed to setProperty Apply_etaEDParPU_correction"); // improved energy density based pileup
// correction with eta variations
......
......@@ -80,7 +80,9 @@ namespace top {
registerParameter("UseElectronChargeIDSelection",
"True/False. Switch on/off electron charge ID selection (Default False).", "False");
registerParameter("UseEgammaLeakageCorrection",
"True/False. Switch on/off leakage correction -- REQUIRES ptag>p3947 (Default True).", "True");
"True/False. Switch on/off super cluster based core leakage correction -- REQUIRES ptag>p3947 (Default True).", "False");
registerParameter("UseEgammaPileupCorrection",
"True/False. Switch on/off improved egamma pileup correction is correction", "True");
registerParameter("EnablePromptLeptonImprovedVetoStudies",
"True/False. Adds the (many!) variables necessary to validate the PromptLeptonImprovedVeto electron+muon isolation -- TEMPORARY, for studies only (Default False).",
"False");
......
......@@ -210,7 +210,8 @@ namespace top {
m_electronIDDecoration("SetMe"),
m_electronIDLooseDecoration("SetMe"),
m_useElectronChargeIDSelection(false),
m_useEgammaLeakageCorrection(true),
m_useEgammaLeakageCorrection(false),
m_useEgammaPileupCorrection(true),
m_enablePromptLeptonImprovedVetoStudies(false),
// Fwd electron configuration
......@@ -1163,6 +1164,7 @@ namespace top {
}
this->useElectronChargeIDSelection(settings->value("UseElectronChargeIDSelection"));
this->useEgammaLeakageCorrection(settings->value("UseEgammaLeakageCorrection"));
this->useEgammaPileupCorrection(settings->value("UseEgammaPileupCorrection"));
this->electronPtcut(std::stof(settings->value("ElectronPt")));
this->enablePromptLeptonImprovedVetoStudies(settings->value("EnablePromptLeptonImprovedVetoStudies"));
......@@ -3500,6 +3502,7 @@ namespace top {
out->m_electronIsolationLoose = m_electronIsolationLoose;
out->m_useElectronChargeIDSelection = m_useElectronChargeIDSelection;
out->m_useEgammaLeakageCorrection = m_useEgammaLeakageCorrection;
out->m_useEgammaPileupCorrection = m_useEgammaPileupCorrection;
out->m_enablePromptLeptonImprovedVetoStudies = m_enablePromptLeptonImprovedVetoStudies;
out->m_fwdElectronID = m_fwdElectronID;
......@@ -3655,6 +3658,7 @@ namespace top {
m_electronIsolationLoose = settings->m_electronIsolationLoose;
m_useElectronChargeIDSelection = settings->m_useElectronChargeIDSelection;
m_useEgammaLeakageCorrection = settings->m_useEgammaLeakageCorrection;
m_useEgammaPileupCorrection = settings->m_useEgammaPileupCorrection;
m_enablePromptLeptonImprovedVetoStudies = settings->m_enablePromptLeptonImprovedVetoStudies;
m_fwdElectronID = settings->m_fwdElectronID;
......
......@@ -36,7 +36,8 @@ namespace top {
m_electronIsolation("SetMe"),
m_electronIsolationLoose("SetMe"),
m_useElectronChargeIDSelection(false),
m_useEgammaLeakageCorrection(true),
m_useEgammaLeakageCorrection(false),
m_useEgammaPileupCorrection(true),
m_enablePromptLeptonImprovedVetoStudies(false),
m_fwdElectronID("SetMe"),
......
......@@ -781,6 +781,11 @@ namespace top {
m_useEgammaLeakageCorrection = (s == "True" || s == "true");
}
}
inline virtual void useEgammaPileupCorrection(const std::string& s) {
if (!m_configFixed) {
m_useEgammaPileupCorrection = (s == "True" || s == "true");
}
}
inline virtual void enablePromptLeptonImprovedVetoStudies(const std::string& s) {
if (!m_configFixed) {
......@@ -809,6 +814,7 @@ namespace top {
inline const std::string& electronIDLooseDecoration() const {return m_electronIDLooseDecoration;}
inline bool useElectronChargeIDSelection() const {return m_useElectronChargeIDSelection;}
inline bool useEgammaLeakageCorrection() const {return m_useEgammaLeakageCorrection;}
inline bool useEgammaPileupCorrection() const {return m_useEgammaPileupCorrection;}
inline bool enablePromptLeptonImprovedVetoStudies() const {return m_enablePromptLeptonImprovedVetoStudies;}
// Fwd electron
......@@ -2284,6 +2290,7 @@ namespace top {
std::string m_electronIDLooseDecoration;
bool m_useElectronChargeIDSelection;
bool m_useEgammaLeakageCorrection;
bool m_useEgammaPileupCorrection;
bool m_enablePromptLeptonImprovedVetoStudies;
//Fwd electron configuration
......
......@@ -63,6 +63,7 @@ namespace top {
std::string m_electronIsolationLoose;
bool m_useElectronChargeIDSelection;
bool m_useEgammaLeakageCorrection;
bool m_useEgammaPileupCorrection;
bool m_enablePromptLeptonImprovedVetoStudies;
std::string m_fwdElectronID;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment