diff --git a/InnerDetector/InDetConfig/python/InDetRecToolConfig.py b/InnerDetector/InDetConfig/python/InDetRecToolConfig.py index b64a1fe6a64790da73775f80d5c2d0dd60d613ec..45b097ae3a97b4cdab545a7d25b9e030a3a8f086 100644 --- a/InnerDetector/InDetConfig/python/InDetRecToolConfig.py +++ b/InnerDetector/InDetConfig/python/InDetRecToolConfig.py @@ -408,7 +408,7 @@ def SCT_TdaqEnabledCondAlgCfg(flags, name="SCT_TdaqEnabledCondAlg", **kwargs): result.merge( addFolders(flags, [folder], detDb="TDAQ", className="CondAttrListCollection") ) acc = SCT_CablingToolCfg(flags) - kwargs.setdefault( "SCT_CablingTool", acc.popPrivateTool() ) + kwargs.setdefault( "SCT_CablingTool", acc.popPrivateTools() ) result.merge(acc) result.addCondAlgo( CompFactory.SCT_TdaqEnabledCondAlg(name=name, **kwargs) ) diff --git a/Trigger/TrigHypothesis/TrigEgammaHypo/src/TrigEgammaDielectronMassHypoTool.cxx b/Trigger/TrigHypothesis/TrigEgammaHypo/src/TrigEgammaDielectronMassHypoTool.cxx new file mode 100644 index 0000000000000000000000000000000000000000..699bd56fcea19e27cb5bb1479bfcd57926611d55 --- /dev/null +++ b/Trigger/TrigHypothesis/TrigEgammaHypo/src/TrigEgammaDielectronMassHypoTool.cxx @@ -0,0 +1,81 @@ +/* + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration +*/ + +/************************************************************************** + ** + ** File: Trigger/TrigHypothesis/TrigEgammaHypo/src/TrigEgammaDielectronMassHypoTool.h + ** + ** Description: - Hypothesis Tool: search for electron pairs with + ** invariant mass in some interval; intended for Z->ee + ** - Modified from TrigL2DielectronMassHypo by R. Goncalo + ** - Modified from TrigEFDielectronMassHypo by + ** Debottam Bakshi Gupta + ** + ** Author: T. Hrynova <thrynova@mail.cern.ch> + ** + ** Created: Nov 13 2009 + ** + **************************************************************************/ + + +#include "TrigEgammaDielectronMassHypoTool.h" + +#include <cmath> + +using namespace TrigCompositeUtils; + +TrigEgammaDielectronMassHypoTool::TrigEgammaDielectronMassHypoTool(const std::string& type, const std::string& name, const IInterface* parent) + : ComboHypoToolBase(type, name, parent) {} + + +StatusCode TrigEgammaDielectronMassHypoTool::initialize() +{ + ATH_MSG_DEBUG("AcceptAll = " << (m_acceptAll==true ? "True" : "False") ); + ATH_MSG_DEBUG("LowerMassCut = " << m_lowerMassElectronClusterCut ); + ATH_MSG_DEBUG("UpperMassCut = " << m_upperMassElectronClusterCut ); + + if ( not m_monTool.name().empty() ) { + ATH_CHECK( m_monTool.retrieve() ); + ATH_MSG_DEBUG("m_monTool name: " << m_monTool); + } + + ATH_MSG_DEBUG("Initialization completed successfully"); + + return StatusCode::SUCCESS; +} + +bool TrigEgammaDielectronMassHypoTool::executeAlg(std::vector<LegDecision> &combination) const { + +//retrieve the electrons + std::vector<ElementLink<xAOD::ElectronContainer>> selected_electrons; + for (auto el: combination){ + auto EL= el.second; + auto dec= (*EL); + auto electronLink = TrigCompositeUtils::findLink<xAOD::ElectronContainer>( dec, featureString() ).link; + selected_electrons.push_back(electronLink); + } + auto electronLink1=selected_electrons[0]; + auto electronLink2=selected_electrons[1]; + TLorentzVector hlv1 = (*electronLink1)->p4(); + TLorentzVector hlv2 = (*electronLink2)->p4(); + double mass = (hlv1+hlv2).M(); + ATH_MSG_DEBUG("Found two Electrons with mass " <<mass); + + // apply the cut + bool pass=true; + if (mass<m_lowerMassElectronClusterCut || mass>m_upperMassElectronClusterCut){ + ATH_MSG_DEBUG("Combination failed mass cut: " << mass << " not in [" << m_lowerMassElectronClusterCut << "," << m_upperMassElectronClusterCut << "]"); + pass=false; + } + + if (pass) + ATH_MSG_DEBUG( " Invariant mass " << mass << " is within [" <<m_lowerMassElectronClusterCut<< "," << m_upperMassElectronClusterCut << "] This seleciton passed! "); + + return pass; + +} + + + + diff --git a/Trigger/TrigHypothesis/TrigEgammaHypo/src/TrigEgammaDielectronMassHypoTool.h b/Trigger/TrigHypothesis/TrigEgammaHypo/src/TrigEgammaDielectronMassHypoTool.h new file mode 100644 index 0000000000000000000000000000000000000000..424dea96b825cbe1773d9ff98540fd1b925d298a --- /dev/null +++ b/Trigger/TrigHypothesis/TrigEgammaHypo/src/TrigEgammaDielectronMassHypoTool.h @@ -0,0 +1,80 @@ +/* + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration +*/ + +#ifndef TRIGEGAMMAHYPO_TRIGEGAMMADIELECTRONMASSHYPOTOOL_H +#define TRIGEGAMMAHYPO_TRIGEGAMMADIELECTRONMASSHYPOTOOL_H + +/************************************************************************** + ** + ** File: Trigger/TrigHypothesis/TrigEgammaHypo/src/TrigEgammaDielectronMassHypoTool.h + ** + ** Description: - Hypothesis Tool: search for electron pairs with + ** invariant mass in some interval; intended for Z->ee + ** - Modified from TrigL2DielectronMassHypo by R. Goncalo + ** - Modified from TrigEFDielectronMassHypo by + ** Debottam Bakshi Gupta + ** + ** Author: T. Hrynova <thrynova@mail.cern.ch> + ** + ** Created: Nov 13 2009 + ** + **************************************************************************/ + +#include <string> +#include <vector> + +#include "DecisionHandling/ComboHypoToolBase.h" + +#include "xAODTracking/TrackParticleContainer.h" +#include "xAODTrigEgamma/TrigElectron.h" +#include "xAODEgamma/ElectronContainer.h" + +#include "TrigCompositeUtils/HLTIdentifier.h" +#include "TrigCompositeUtils/TrigCompositeUtils.h" + +#include "AthenaMonitoringKernel/Monitored.h" +#include "AthenaMonitoringKernel/GenericMonitoringTool.h" + + +/** + * \class TrigEgammaDielectronMassHypoTool + * \brief TrigEgammaDielectronMassHypoTool is a ComboHypoTool that calculates the inv mass + * Apply inv mass cuts (upper and lower cut) to the two electrons and accepts the event if condition is + * satisfied + * + */ + + +class TrigEgammaDielectronMassHypoTool: public ComboHypoToolBase { + + public: + + TrigEgammaDielectronMassHypoTool(const std::string& type, + const std::string& name, + const IInterface* parent); + + virtual ~TrigEgammaDielectronMassHypoTool() {}; + virtual StatusCode initialize() override; + + + private: + + virtual bool executeAlg(std::vector<LegDecision>& thecomb) const override; + + // flags + Gaudi::Property< bool > m_acceptAll {this, "AcceptAll", false, "Ignore selection" }; + + // cuts + Gaudi::Property<float> m_lowerMassElectronClusterCut {this,"LowerMassElectronClusterCut", 50000.0, "Lower mass cut for electron-cluster pair"}; //!< lower inv mass cut (e,cluster) + Gaudi::Property<float> m_upperMassElectronClusterCut {this,"UpperMassElectronClusterCut", 130000.0, "Upper mass cut for electron-cluster pair"}; //!< upper inv mass cut (e,cluster) + + // monitoring + ToolHandle<GenericMonitoringTool> m_monTool { this, "MonTool", "", "Monitoring tool" }; + + +}; // TRIGEGAMMAHYPO_TRIGEGAMMADIELECTRONMASSHYPOTOOL_H +#endif + + + diff --git a/Trigger/TrigHypothesis/TrigEgammaHypo/src/components/TrigEgammaHypo_entries.cxx b/Trigger/TrigHypothesis/TrigEgammaHypo/src/components/TrigEgammaHypo_entries.cxx index da14c5524812d5eec4f86bc5a307c31425c3858d..0c58c9a66ebc930b5d9974c06abfc92085330f59 100644 --- a/Trigger/TrigHypothesis/TrigEgammaHypo/src/components/TrigEgammaHypo_entries.cxx +++ b/Trigger/TrigHypothesis/TrigEgammaHypo/src/components/TrigEgammaHypo_entries.cxx @@ -30,6 +30,7 @@ #include "../TrigEgammaPrecisionElectronHypoAlgMT.h" #include "../TrigEgammaPrecisionPhotonHypoToolMult.h" #include "../TrigEgammaPrecisionElectronHypoToolMult.h" +#include "../TrigEgammaDielectronMassHypoTool.h" DECLARE_COMPONENT( TrigL2CaloHypo ) DECLARE_COMPONENT( TrigL2ElectronFex ) @@ -63,3 +64,5 @@ DECLARE_COMPONENT( TrigEgammaPrecisionPhotonHypoAlgMT ) DECLARE_COMPONENT( TrigEgammaPrecisionElectronHypoAlgMT ) DECLARE_COMPONENT( TrigEgammaPrecisionPhotonHypoToolMult ) DECLARE_COMPONENT( TrigEgammaPrecisionElectronHypoToolMult ) +DECLARE_COMPONENT( TrigEgammaDielectronMassHypoTool ) + diff --git a/Trigger/TrigValidation/TrigAnalysisTest/share/ref_RDOtoRDOTrig_mt1_build.ref b/Trigger/TrigValidation/TrigAnalysisTest/share/ref_RDOtoRDOTrig_mt1_build.ref index 4ceb03769136600fd83b4e79e1c9de55a96170fc..e9891fa733077631202046c535f3cbadecce9a70 100644 --- a/Trigger/TrigValidation/TrigAnalysisTest/share/ref_RDOtoRDOTrig_mt1_build.ref +++ b/Trigger/TrigValidation/TrigAnalysisTest/share/ref_RDOtoRDOTrig_mt1_build.ref @@ -111,6 +111,9 @@ TrigSignatureMoniMT INFO -- #899946230 Features TrigSignatureMoniMT INFO HLT_e17_lhvloose_nod0_L1EM15VH #140779220 TrigSignatureMoniMT INFO -- #140779220 Events 8 8 6 6 6 5 - - - - - - - - 5 TrigSignatureMoniMT INFO -- #140779220 Features 6 78 10 5 - - - - - - - - +TrigSignatureMoniMT INFO HLT_e20_lhmedium_e15_lhmedium_Zee_L12EM3 #1784800924 +TrigSignatureMoniMT INFO -- #1784800924 Events 20 20 0 0 0 0 - - - - - - - - 0 +TrigSignatureMoniMT INFO -- #1784800924 Features 0 0 0 0 - - - - - - - - TrigSignatureMoniMT INFO HLT_e26_etcut_L1EM22VHI #1703681121 TrigSignatureMoniMT INFO -- #1703681121 Events 6 6 6 6 6 - - - - - - - - - 6 TrigSignatureMoniMT INFO -- #1703681121 Features 7 133 7 - - - - - - - - - diff --git a/Trigger/TrigValidation/TriggerTest/share/ref_data_v1Dev_build.ref b/Trigger/TrigValidation/TriggerTest/share/ref_data_v1Dev_build.ref index eaabbf36b5a0c2e595247af7e89ef07311962ed7..68bf0c5cbaaa2568fb8f9cad953fefacc9ba1d39 100644 --- a/Trigger/TrigValidation/TriggerTest/share/ref_data_v1Dev_build.ref +++ b/Trigger/TrigValidation/TriggerTest/share/ref_data_v1Dev_build.ref @@ -111,6 +111,9 @@ TrigSignatureMoniMT INFO -- #899946230 Features TrigSignatureMoniMT INFO HLT_e17_lhvloose_nod0_L1EM15VH #140779220 TrigSignatureMoniMT INFO -- #140779220 Events 20 20 0 0 0 0 - - - - - - - - 0 TrigSignatureMoniMT INFO -- #140779220 Features 0 0 0 0 - - - - - - - - +TrigSignatureMoniMT INFO HLT_e20_lhmedium_e15_lhmedium_Zee_L12EM3 #1784800924 +TrigSignatureMoniMT INFO -- #1784800924 Events 20 20 0 0 0 0 - - - - - - - - 0 +TrigSignatureMoniMT INFO -- #1784800924 Features 0 0 0 0 - - - - - - - - TrigSignatureMoniMT INFO HLT_e26_etcut_L1EM22VHI #1703681121 TrigSignatureMoniMT INFO -- #1703681121 Events 20 20 1 1 0 - - - - - - - - - 0 TrigSignatureMoniMT INFO -- #1703681121 Features 1 2 0 - - - - - - - - - diff --git a/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Egamma/ElectronDef.py b/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Egamma/ElectronDef.py index b0f1d7e2a281316d128e4dc3916ef91583e6a9df..b76f533dc6654e2b47ede7196d75e4a53569433b 100644 --- a/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Egamma/ElectronDef.py +++ b/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Egamma/ElectronDef.py @@ -1,4 +1,4 @@ -# Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration from AthenaCommon.Logging import logging logging.getLogger().info("Importing %s",__name__) @@ -33,6 +33,15 @@ def precisionCaloSequenceCfg( flags ): def precisionElectronSequenceCfg( flags ): return precisionElectronMenuSequence() +# this must be moved to the HypoTool file: +def diElectronMassComboHypoToolFromDict(chainDict): + from TrigEgammaHypo.TrigEgammaHypoConf import TrigEgammaDielectronMassHypoTool + name = chainDict['chainName'] + tool= TrigEgammaDielectronMassHypoTool(name) + tool.LowerMassElectronClusterCut = 50000 + tool.UpperMassElectronClusterCut = 130000 + return tool + #---------------------------------------------------------------- # Class to configure chain #---------------------------------------------------------------- @@ -68,7 +77,7 @@ class ElectronChainConfiguration(ChainConfigurationBase): log.debug('electron chain part = ' + str(self.chainPart)) key = self.chainPart['extra'] + self.chainPart['IDinfo'] + self.chainPart['L2IDAlg'] + self.chainPart['isoInfo'] - + for addInfo in self.chainPart['addInfo']: key+=addInfo @@ -110,6 +119,10 @@ class ElectronChainConfiguration(ChainConfigurationBase): return self.getStep(3,stepName,[ precisionCaloSequenceCfg]) def getPrecisionElectron(self): - stepName = "precision_electron" - return self.getStep(4,stepName,[ precisionElectronSequenceCfg]) + if "Zee" in self.chainName: + stepName = "precision_topoelectron" + return self.getStep(4,stepName,sequenceCfgArray=[precisionElectronSequenceCfg], comboTools=[diElectronMassComboHypoToolFromDict]) + else: + stepName = "precision_electron" + return self.getStep(4,stepName,[ precisionElectronSequenceCfg]) diff --git a/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Menu/LS2_v1.py b/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Menu/LS2_v1.py index 98a597cd13611207dc29896ab367985f5880ae34..bc4ad4640d80a16915650147162a7cd0ad89dab5 100644 --- a/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Menu/LS2_v1.py +++ b/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Menu/LS2_v1.py @@ -109,6 +109,7 @@ def setupMenu(): ChainProp(name='HLT_e5_lhmedium_noringer_L1EM3', groups=SingleElectronGroup), ChainProp(name='HLT_e5_lhtight_noringer_L1EM3', groups=SingleElectronGroup), ChainProp(name='HLT_e5_lhtight_noringer_nod0_L1EM3', groups=SingleElectronGroup), + ChainProp(name='HLT_e20_lhmedium_e15_lhmedium_Zee_L12EM3', groups=MultiPhotonGroup), # Primary ChainProp(name='HLT_e26_lhtight_L1EM22VHI', groups=SingleElectronGroup), @@ -299,3 +300,4 @@ def setupMenu(): Prescales = mc_menu.Prescales + diff --git a/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Menu/SignatureDicts.py b/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Menu/SignatureDicts.py index 1018c922d09bd6492c744a620d2da9ebb5ebb65c..eb42124b4c2a12dd84790d0cdc3b881171dff538 100644 --- a/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Menu/SignatureDicts.py +++ b/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Menu/SignatureDicts.py @@ -840,3 +840,4 @@ def getBasePattern(): +