diff --git a/Reconstruction/Jet/JetRecTools/JetRecTools/ConstitTimeCutTool.h b/Reconstruction/Jet/JetRecTools/JetRecTools/ConstitTimeCutTool.h index fda1903b5b86eac51a2c9b94465ff12c8f90bfa7..522717c9213b99852f0114522e4623a63f4c495d 100644 --- a/Reconstruction/Jet/JetRecTools/JetRecTools/ConstitTimeCutTool.h +++ b/Reconstruction/Jet/JetRecTools/JetRecTools/ConstitTimeCutTool.h @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2018 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration */ #ifndef JETRECTOOLS_CONSTITTIMECUTTOOL_H @@ -38,7 +38,6 @@ class ConstitTimeCutTool : public JetConstituentModifierBase{ float m_timeCutSmallQ; float m_etaMax; - bool m_ignoreChargedPFOs; }; diff --git a/Reconstruction/Jet/JetRecTools/Root/ConstitTimeCutTool.cxx b/Reconstruction/Jet/JetRecTools/Root/ConstitTimeCutTool.cxx index c8ea2582d7efb8d51adab131b7921deb61c57899..e3cbee3fda6622add3186c232095bd6bd766e6fd 100644 --- a/Reconstruction/Jet/JetRecTools/Root/ConstitTimeCutTool.cxx +++ b/Reconstruction/Jet/JetRecTools/Root/ConstitTimeCutTool.cxx @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2018 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration */ #include <vector> @@ -19,8 +19,6 @@ ConstitTimeCutTool::ConstitTimeCutTool(const std::string& name) : JetConstituent declareProperty("TimeCutSmallQ", m_timeCutSmallQ = 15); declareProperty("MaxEtaForCut", m_etaMax = 2.5); - declareProperty("IgnoreChargedPFO", m_ignoreChargedPFOs); - } StatusCode ConstitTimeCutTool::initialize() { @@ -30,11 +28,6 @@ StatusCode ConstitTimeCutTool::initialize() { ATH_MSG_ERROR("Incompatible configuration: ApplyToNeutralPFO=False -- what kind of pileup do you wish to suppress?"); return StatusCode::FAILURE; } - else if(m_ignoreChargedPFOs && m_applyToChargedPFO) { - ATH_MSG_ERROR("Incompatible configuration: setting both IgnoreChargedPFO and ApplyToChargedPFO to true" - << "will set all cPFOs to zero"); - return StatusCode::FAILURE; - } } else { if(m_inputType!=xAOD::Type::CaloCluster) { diff --git a/Reconstruction/Jet/JetRecTools/Root/SoftKillerWeightTool.cxx b/Reconstruction/Jet/JetRecTools/Root/SoftKillerWeightTool.cxx index e8ce58d641a6af6cf6858c0a9f723a18a3feb85e..add2f1b330530bcb40f8c9cf431d73eb84c9732b 100644 --- a/Reconstruction/Jet/JetRecTools/Root/SoftKillerWeightTool.cxx +++ b/Reconstruction/Jet/JetRecTools/Root/SoftKillerWeightTool.cxx @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration */ #include "JetRecTools/SoftKillerWeightTool.h" @@ -27,7 +27,7 @@ SoftKillerWeightTool::SoftKillerWeightTool(const std::string& name) : JetConstit , m_rapmax(2.5) , m_rapminApplied(0) , m_rapmaxApplied(10) - , m_ignoreChargedPFOs(false) + , m_ignoreChargedPFOs(true) { @@ -41,7 +41,7 @@ SoftKillerWeightTool::SoftKillerWeightTool(const std::string& name) : JetConstit declareProperty("HCalGridSize", m_hCalGrid); // Option to disregard cPFOs in the weight calculation - declareProperty("IgnoreChargedPFO", m_ignoreChargedPFOs=true); + declareProperty("IgnoreChargedPFO", m_ignoreChargedPFOs); } @@ -97,6 +97,7 @@ StatusCode SoftKillerWeightTool::process_impl(xAOD::IParticleContainer* cont) co // The partSK collection contains all particles that aren't cut, so particles below // its min pT are cut double SoftKillerWeightTool::findMinPt(const vector<fastjet::PseudoJet> &partSK) const { + if (partSK.empty()) {return 0.;} double minPt = 999999999999; for(unsigned int i=0; i < partSK.size(); i++){ @@ -122,7 +123,7 @@ double SoftKillerWeightTool::getSoftKillerMinPt(xAOD::IParticleContainer& cont) // However, we might still want to use the cPFOs for the min pt calculation if(m_inputType==xAOD::Type::ParticleFlow && m_ignoreChargedPFOs) { xAOD::PFO* pfo = static_cast<xAOD::PFO*>(part); - accept = fabs(pfo->charge())>1e-9; + accept = fabs(pfo->charge())<1e-9; } if(accept) { partPJ.push_back( fastjet::PseudoJet( part->p4() )); @@ -151,7 +152,7 @@ std::pair<double,double> SoftKillerWeightTool::getSoftKillerMinPtSplit(xAOD::IPa // However, we might still want to use the cPFOs for the min pt calculation if(m_inputType==xAOD::Type::ParticleFlow && m_ignoreChargedPFOs) { xAOD::PFO* pfo = static_cast<xAOD::PFO*>(part); - accept = fabs(pfo->charge())>1e-9; + accept = fabs(pfo->charge())<1e-9; } if(accept) { double center_lambda = acc_clambda.isAvailable(*part) ? acc_clambda(*part) : 0.;