Commit 23346da3 authored by Jonathan Jamieson's avatar Jonathan Jamieson
Browse files

Add advanced configurable option for MET config path, remove call to AFII...

Add advanced configurable option for MET config path, remove call to AFII config when running July2020 MET recs
parent 4900bccf
......@@ -544,11 +544,15 @@ namespace top {
m_met_systematics = asg::ToolStore::get<IMETSystematicsTool>("met::METSystematicsTool");
} else {
met::METSystematicsTool* metSyst = new met::METSystematicsTool("met::METSystematicsTool");
std::string METconfigDir = m_config->METUncertaintiesConfigDir();
if (METconfigDir == "Latest") METconfigDir = "METUtilities/run2_13TeV/"; //Find calib files here: /cvmfs/atlas.cern.ch/repo/sw/database/GroupData/METUtilities/
top::check(metSyst->setProperty("ConfigPrefix", METconfigDir), "Failed to set METsyst calibration area"); //Set calib area explicitly - removes potential for crash when default area is changed in METSyst code
// TST (Track soft terms)
if (m_config->useParticleFlowJets()) {
top::check(metSyst->setProperty("ConfigSoftTrkFile", "TrackSoftTerms-pflow.config"), "Failed to set property");
} else {
if (m_config->isAFII()) {
if (m_config->isAFII() && METconfigDir == "METUtilities/data17_13TeV/prerec_Jan16/") {
top::check(metSyst->setProperty("ConfigSoftTrkFile", "TrackSoftTerms_AFII.config"), "Failed to set property");
} else {
top::check(metSyst->setProperty("ConfigSoftTrkFile", "TrackSoftTerms.config"), "Failed to set property");
......
......@@ -174,7 +174,8 @@ namespace top {
registerParameter("ForwardJVTinMETCalculation",
"Use fJVT cut on forward jets to improve resolution in the MET recalculation? \'False\' (default - must set false if using pflow jets with derivations older than P4173), or \'True\'", "False");
registerParameter("SaveFailForwardJVTJets", "Save the jets that failed the fJVT cut? \'False\' (default), or \'True\'", "False");
registerParameter("AdvancedUsage_METUncertaintiesConfigDir", "Path to directory containing MET uncertainties configs (including trailing /) \'Latest\' (default), or previous \'METUtilities/data17_13TeV/prerec_Jan16/\'", "Latest");
registerParameter("JetPtGhostTracks",
"Jet pT threshold for ghost track systematic variations calculation (in MeV). Default 25 GeV.",
"25000.");
......
......@@ -258,6 +258,9 @@ namespace top {
m_doForwardJVTInMETCalculation(false),
m_saveFailForwardJVTJets(false),
m_fJVTWP("None"),
// MET configuration
m_METUncertaintiesConfigDir("SetMe"),
// Ghost Track Configuration
m_ghostTrackspT(500.),
......@@ -1310,6 +1313,7 @@ namespace top {
ATH_MSG_WARNING("TopConfig::setConfigSettings: fJVT WP set to Medium and fJVT in MET requested, MET working point will be changed to Tenacious to maintain compatibility with fJVT!!!");
}
this->largeRJetPtcut(std::stof(settings->value("LargeRJetPt")));
this->largeRJetEtacut(std::stof(settings->value("LargeRJetEta")));
this->largeRJetUncertainties_NPModel(settings->value("LargeRJetUncertainties_NPModel"));
......@@ -1369,6 +1373,9 @@ namespace top {
this->jetStoreTruthLabels(true);
}
// MET Configuration
this->METUncertaintiesConfigDir(settings->value("AdvancedUsage_METUncertaintiesConfigDir"));
// for top mass analysis, per default set to 1.0!
m_JSF = std::stof(settings->value("JSF"));
m_bJSF = std::stof(settings->value("bJSF"));
......
......@@ -1363,6 +1363,14 @@ namespace top {
inline virtual float JSF() const {return m_JSF;}
inline virtual float bJSF() const {return m_bJSF;}
// MET Configuration
inline virtual void METUncertaintiesConfigDir(const std::string& METConfigDir) {
if (!m_configFixed) {
m_METUncertaintiesConfigDir = METConfigDir;
}
}
inline virtual const std::string& METUncertaintiesConfigDir() const {return m_METUncertaintiesConfigDir;}
// Tau configuration setters
inline virtual void tauPtcut(const float pt) {
if (!m_configFixed) {
......@@ -2212,6 +2220,9 @@ namespace top {
bool m_doForwardJVTInMETCalculation;
bool m_saveFailForwardJVTJets;
std::string m_fJVTWP;
// MET configuration
std::string m_METUncertaintiesConfigDir; //Path prefix for directory with MET calibration configs
//Ghost tracks quality
float m_ghostTrackspT;
......
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