Commit 5b53498b authored by Nils Erik Krumnack's avatar Nils Erik Krumnack
Browse files

Merge branch '21.2-AT-HeavyIonConfigJetMET' into '21.2'

AnalysisTop: Adding a flag to set the special HeavyIon configurations

See merge request !45206
parents c5a05a9e 9d7a9939
......@@ -31,40 +31,8 @@
namespace top {
JetMETCPTools::JetMETCPTools(const std::string& name) :
asg::AsgTool(name),
asg::AsgTool(name) {
m_jetJVT_ConfigFile("JVTlikelihood_20140805.root"),
// Calibration strings for R21 only
m_jetAntiKt4_Data_ConfigFile("JES_MC16Recommendation_Consolidated_EMTopo_Apr2019_Rel21.config"),
m_jetAntiKt4_Data_CalibSequence("JetArea_Residual_EtaJES_GSC_Insitu"),
m_jetAntiKt4_MCFS_ConfigFile("JES_MC16Recommendation_Consolidated_EMTopo_Apr2019_Rel21.config"),
m_jetAntiKt4_MCFS_CalibSequence("JetArea_Residual_EtaJES_GSC_Smear"),
m_jetAntiKt4_Data_JMS_ConfigFile("JES_JMS_MC16Recommendation_Consolidated_data_only_EMTopo_Sep2019_Rel21.config"),
m_jetAntiKt4_Data_JMS_CalibSequence("JetArea_Residual_EtaJES_GSC_JMS_Insitu"),
m_jetAntiKt4_MCFS_JMS_ConfigFile("JES_JMS_MC16Recommendation_Consolidated_MC_only_EMTopo_July2019_Rel21.config"),
m_jetAntiKt4_MCFS_JMS_CalibSequence("JetArea_Residual_EtaJES_GSC_Smear_JMS"),
m_jetAntiKt4_MCAFII_ConfigFile("JES_MC16Recommendation_AFII_EMTopo_Apr2019_Rel21.config"),
m_jetAntiKt4_MCAFII_CalibSequence("JetArea_Residual_EtaJES_GSC_Smear"),
m_jetAntiKt4_MCAFII_PFlow_ConfigFile("JES_MC16Recommendation_AFII_PFlow_Apr2019_Rel21.config"),
m_jetAntiKt4_MCAFII_PFlow_CalibSequence("JetArea_Residual_EtaJES_GSC_Smear"),
m_jetAntiKt4_Data_PFlow_ConfigFile("JES_MC16Recommendation_Consolidated_PFlow_Apr2019_Rel21.config"),
m_jetAntiKt4_Data_PFlow_CalibSequence("JetArea_Residual_EtaJES_GSC_Insitu"),
m_jetAntiKt4_PFlow_MCFS_ConfigFile("JES_MC16Recommendation_Consolidated_PFlow_Apr2019_Rel21.config"),
m_jetAntiKt4_PFlow_MCFS_CalibSequence("JetArea_Residual_EtaJES_GSC_Smear"),
m_jetAntiKt4_Data_PFlow_JMS_ConfigFile("JES_JMS_MC16Recommendation_Consolidated_data_only_PFlow_July2019_Rel21.config"),
m_jetAntiKt4_Data_PFlow_JMS_CalibSequence("JetArea_Residual_EtaJES_GSC_JMS_Insitu"),
m_jetAntiKt4_PFlow_MCFS_JMS_ConfigFile("JES_JMS_MC16Recommendation_Consolidated_MC_only_PFlow_July2019_Rel21.config"),
m_jetAntiKt4_PFlow_MCFS_JMS_CalibSequence("JetArea_Residual_EtaJES_GSC_Smear_JMS") {
declareProperty("config", m_config);
declareProperty("JetCalibrationTool", m_jetCalibrationTool);
......@@ -99,6 +67,7 @@ namespace top {
declareProperty("met_maker", m_met_maker);
declareProperty("met_systematics", m_met_systematics);
}
StatusCode JetMETCPTools::initialize() {
......@@ -111,6 +80,71 @@ namespace top {
if (m_config->getDerivationStream() == "PHYS") {
m_truthJetCollForHS = "AntiKt4TruthDressedWZJets";
}
if (m_config->useHItoolsConfiguration()) { // Heavy Ion special setup
m_jetJVT_ConfigFile = "JVTlikelihood_20140805.root";
m_jetAntiKt4_Data_ConfigFile = "JES_MC16Recommendation_LowMu1718_EMTopo_Aug2019_Rel21.config";
m_jetAntiKt4_Data_CalibSequence = "EtaJES";
m_jetAntiKt4_MCFS_ConfigFile = "JES_MC16Recommendation_LowMu1718_EMTopo_Aug2019_Rel21.config";
m_jetAntiKt4_MCFS_CalibSequence ="EtaJES";
m_jetAntiKt4_Data_JMS_ConfigFile = "JES_JMS_MC16Recommendation_Consolidated_data_only_EMTopo_Sep2019_Rel21.config";
m_jetAntiKt4_Data_JMS_CalibSequence = "JetArea_Residual_EtaJES_GSC_JMS_Insitu";
m_jetAntiKt4_MCFS_JMS_ConfigFile = "JES_JMS_MC16Recommendation_Consolidated_MC_only_EMTopo_July2019_Rel21.config";
m_jetAntiKt4_MCFS_JMS_CalibSequence = "JetArea_Residual_EtaJES_GSC_Smear_JMS";
m_jetAntiKt4_MCAFII_ConfigFile = "JES_MC16Recommendation_AFII_EMTopo_Apr2019_Rel21.config";
m_jetAntiKt4_MCAFII_CalibSequence = "JetArea_Residual_EtaJES_GSC_Smear";
m_jetAntiKt4_MCAFII_PFlow_ConfigFile = "JES_MC16Recommendation_AFII_PFlow_Apr2019_Rel21.config";
m_jetAntiKt4_MCAFII_PFlow_CalibSequence = "JetArea_Residual_EtaJES_GSC_Smear";
m_jetAntiKt4_Data_PFlow_ConfigFile = "JES_MC16Recommendation_Consolidated_PFlow_Apr2019_Rel21.config";
m_jetAntiKt4_Data_PFlow_CalibSequence = "JetArea_Residual_EtaJES_GSC_Insitu";
m_jetAntiKt4_PFlow_MCFS_ConfigFile = "JES_MC16Recommendation_Consolidated_PFlow_Apr2019_Rel21.config";
m_jetAntiKt4_PFlow_MCFS_CalibSequence = "JetArea_Residual_EtaJES_GSC_Smear";
m_jetAntiKt4_Data_PFlow_JMS_ConfigFile = "JES_JMS_MC16Recommendation_Consolidated_data_only_PFlow_July2019_Rel21.config";
m_jetAntiKt4_Data_PFlow_JMS_CalibSequence = "JetArea_Residual_EtaJES_GSC_JMS_Insitu";
m_jetAntiKt4_PFlow_MCFS_JMS_ConfigFile = "JES_JMS_MC16Recommendation_Consolidated_MC_only_PFlow_July2019_Rel21.config";
m_jetAntiKt4_PFlow_MCFS_JMS_CalibSequence = "JetArea_Residual_EtaJES_GSC_Smear_JMS";
} else { // standard pp collisions
m_jetJVT_ConfigFile = "JVTlikelihood_20140805.root";
m_jetAntiKt4_Data_ConfigFile = "JES_MC16Recommendation_Consolidated_EMTopo_Apr2019_Rel21.config";
m_jetAntiKt4_Data_CalibSequence = "JetArea_Residual_EtaJES_GSC_Insitu";
m_jetAntiKt4_MCFS_ConfigFile = "JES_MC16Recommendation_Consolidated_EMTopo_Apr2019_Rel21.config";
m_jetAntiKt4_MCFS_CalibSequence ="JetArea_Residual_EtaJES_GSC_Smear";
m_jetAntiKt4_Data_JMS_ConfigFile = "JES_JMS_MC16Recommendation_Consolidated_data_only_EMTopo_Sep2019_Rel21.config";
m_jetAntiKt4_Data_JMS_CalibSequence = "JetArea_Residual_EtaJES_GSC_JMS_Insitu";
m_jetAntiKt4_MCFS_JMS_ConfigFile = "JES_JMS_MC16Recommendation_Consolidated_MC_only_EMTopo_July2019_Rel21.config";
m_jetAntiKt4_MCFS_JMS_CalibSequence = "JetArea_Residual_EtaJES_GSC_Smear_JMS";
m_jetAntiKt4_MCAFII_ConfigFile = "JES_MC16Recommendation_AFII_EMTopo_Apr2019_Rel21.config";
m_jetAntiKt4_MCAFII_CalibSequence = "JetArea_Residual_EtaJES_GSC_Smear";
m_jetAntiKt4_MCAFII_PFlow_ConfigFile = "JES_MC16Recommendation_AFII_PFlow_Apr2019_Rel21.config";
m_jetAntiKt4_MCAFII_PFlow_CalibSequence = "JetArea_Residual_EtaJES_GSC_Smear";
m_jetAntiKt4_Data_PFlow_ConfigFile = "JES_MC16Recommendation_Consolidated_PFlow_Apr2019_Rel21.config";
m_jetAntiKt4_Data_PFlow_CalibSequence = "JetArea_Residual_EtaJES_GSC_Insitu";
m_jetAntiKt4_PFlow_MCFS_ConfigFile = "JES_MC16Recommendation_Consolidated_PFlow_Apr2019_Rel21.config";
m_jetAntiKt4_PFlow_MCFS_CalibSequence = "JetArea_Residual_EtaJES_GSC_Smear";
m_jetAntiKt4_Data_PFlow_JMS_ConfigFile = "JES_JMS_MC16Recommendation_Consolidated_data_only_PFlow_July2019_Rel21.config";
m_jetAntiKt4_Data_PFlow_JMS_CalibSequence = "JetArea_Residual_EtaJES_GSC_JMS_Insitu";
m_jetAntiKt4_PFlow_MCFS_JMS_ConfigFile = "JES_JMS_MC16Recommendation_Consolidated_MC_only_PFlow_July2019_Rel21.config";
m_jetAntiKt4_PFlow_MCFS_JMS_CalibSequence = "JetArea_Residual_EtaJES_GSC_Smear_JMS";
}
if (m_config->useJets()) {
if (m_config->makeAllCPTools()) {// skiping calibrations on mini-xAODs
......
......@@ -459,6 +459,7 @@ namespace top {
registerParameter("DoTight", "Dumps the normal non-\"*_Loose\" trees : Data, MC, Both (default), False", "Both");
registerParameter("DoLoose", "Run Loose selection and dumps the Loose trees : Data (default), MC, Both, False",
"Data");
registerParameter("UseHItoolsConfiguration", "Flag to tell the code to use heavy ion specific tool setup. Default is False", "False", {"True","False"});
registerParameter("DoSysts", "Run systematics on given selection: Both (default), Tight, Loose", "Both");
registerParameter("UseLooseObjectsInMETInLooseTree",
......
......@@ -105,6 +105,7 @@ namespace top {
m_doTightEvents(true),
// Runs Loose selection and dumps the "*_Loose" trees
m_doLooseEvents(false),
m_useHItoolsConfiguration(false),
// Runs systematics on the given selection
m_doTightSysts(true),
m_doLooseSysts(true),
......@@ -773,6 +774,10 @@ namespace top {
this->jetSubstructureName(settings->value("LargeJetSubstructure"));
this->decoKeyJetGhostTrack(settings->value("JetGhostTrackDecoName"));
bool useHItoolsConfiguration(false);
settings->retrieve("UseHItoolsConfiguration", useHItoolsConfiguration);
this->setUseHItoolsConfiguration(useHItoolsConfiguration);
// check that jets use tagged collection name for new derivations
// this is due to b-tagging breaking changes in derivations
if (m_aodMetaData->valid()) {
......@@ -2954,7 +2959,6 @@ namespace top {
(*i).second));
}
// TTree index
unsigned int TTreeIndex(0);
if (m_doTightEvents) {
......
......@@ -247,6 +247,9 @@ namespace top {
// Default is true for Data and false for MC
inline bool doLooseEvents() const {return m_doLooseEvents;}
inline void setUseHItoolsConfiguration(const bool flag) {m_useHItoolsConfiguration = flag;}
inline bool useHItoolsConfiguration() const {return m_useHItoolsConfiguration;}
// Run systematics on Loose selection
// Default is true
inline bool doTightSysts() const {return m_doTightSysts;}
......@@ -2303,6 +2306,8 @@ namespace top {
bool m_doTightEvents;
// Dumps the "*_Loose trees (on demand)
bool m_doLooseEvents;
bool m_useHItoolsConfiguration;
// Run systematics on the given selection
bool m_doTightSysts;
......
Markdown is supported
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