ATLAS Offline Software
Loading...
Searching...
No Matches
RoIsUnpackingToolBase.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3*/
4#ifndef HLTSEEDING_ROISUNPACKINGTOOLBASE_H
5#define HLTSEEDING_ROISUNPACKINGTOOLBASE_H
6
8
11#include "TrigConfData/L1Menu.h"
15
18
20
21
22namespace ROIB {
23 class RoIBResult;
24}
25
32class RoIsUnpackingToolBase : public extends<AthAlgTool, IRoIsUnpackingTool> {
33public:
34 RoIsUnpackingToolBase(const std::string& type,
35 const std::string& name,
36 const IInterface* parent);
37
38 virtual StatusCode initialize() override;
39
40 virtual StatusCode unpack(const EventContext& /*ctx*/,
41 const ROIB::RoIBResult& /*roib*/,
42 const HLT::IDSet& /*activeChains*/) const override { return StatusCode::SUCCESS; }
43
44 virtual StatusCode unpack(const EventContext& /*ctx*/,
45 const xAOD::TrigComposite& /*l1TriggerResult*/,
46 const HLT::IDSet& /*activeChains*/) const override { return StatusCode::SUCCESS; }
47
48protected:
52 this, "Decisions", "RoIDecisions", "Decisions for each RoI"};
53
55 this, "DecisionsProbe", "", "Optional secondary set of Decisions for each RoI for probe a.k.a. delayed a.k.a. rerun chains"};
56
58 this, "OutputTrigRoIs", "", "Name of the RoIs collection produced by the unpacker"};
59
61 this, "L1TriggerMenu", "DetectorStore+L1TriggerMenu", "Name of the L1Menu object to read configuration from"};
62
64 this, "HLTTriggerMenu", "DetectorStore+HLTTriggerMenu", "Name of the HLTMenu object to read configuration from"};
65
66
67 ToolHandle<GenericMonitoringTool> m_monTool{ this, "MonTool", "", "Monitoring tool" };
68 ToolHandle<IRoiUpdaterTool> m_roiupdater{ this, "RoiUpdater", "", "Roi Updater" };
69
70 std::map<HLT::Identifier, HLT::IDVec> m_thresholdToChainMapping;
71 std::map<HLT::Identifier, HLT::Identifier> m_legToChainMapping;
72
73 using ThrVec = std::vector<std::shared_ptr<TrigConf::L1Threshold>>;
74 using ThrVecRef = std::reference_wrapper<const ThrVec>;
83 StatusCode getL1Thresholds(const TrigConf::L1Menu& l1Menu, const std::string& thrType, std::optional<ThrVecRef>& thrVec) const;
84
90 static std::string getProbeThresholdName(const std::string& thresholdName);
91
98 StatusCode decodeMapping( std::function< bool(const std::string&)>&& filter );
99
100 void addChainsToDecision( HLT::Identifier thresholdId,
102 const HLT::IDSet& activeChains ) const;
103};
104
105#endif
Class holding the LVL1 RoIB result build by the RoIBuilder.
Definition RoIBResult.h:47
virtual StatusCode unpack(const EventContext &, const xAOD::TrigComposite &, const HLT::IDSet &) const override
std::map< HLT::Identifier, HLT::Identifier > m_legToChainMapping
SG::WriteHandleKey< TrigCompositeUtils::DecisionContainer > m_decisionsKey
ToolHandle< IRoiUpdaterTool > m_roiupdater
virtual StatusCode unpack(const EventContext &, const ROIB::RoIBResult &, const HLT::IDSet &) const override
std::vector< std::shared_ptr< TrigConf::L1Threshold > > ThrVec
RoIsUnpackingToolBase(const std::string &type, const std::string &name, const IInterface *parent)
ToolHandle< GenericMonitoringTool > m_monTool
SG::ReadHandleKey< TrigConf::L1Menu > m_l1MenuKey
void addChainsToDecision(HLT::Identifier thresholdId, TrigCompositeUtils::Decision *d, const HLT::IDSet &activeChains) const
std::reference_wrapper< const ThrVec > ThrVecRef
SG::WriteHandleKey< TrigCompositeUtils::DecisionContainer > m_decisionsKeyProbe
virtual StatusCode initialize() override
SG::WriteHandleKey< TrigRoiDescriptorCollection > m_trigRoIsKey
SG::ReadHandleKey< TrigConf::HLTMenu > m_HLTMenuKey
StatusCode getL1Thresholds(const TrigConf::L1Menu &l1Menu, const std::string &thrType, std::optional< ThrVecRef > &thrVec) const
Retrieve a vector of thresholds with type thrType from L1Menu.
StatusCode decodeMapping(std::function< bool(const std::string &)> &&filter)
Fills mapping from L1 threshold -> to HLT chain.
static std::string getProbeThresholdName(const std::string &thresholdName)
Concatenate the probe identifier string with the threshold name string.
std::map< HLT::Identifier, HLT::IDVec > m_thresholdToChainMapping
Property holding a SG store/key/clid from which a ReadHandle is made.
Property holding a SG store/key/clid from which a WriteHandle is made.
L1 menu configuration.
Definition L1Menu.h:28
std::set< HLT::Identifier > IDSet
Namespace of the LVL1 RoIB simulation.
TrigComposite_v1 TrigComposite
Declare the latest version of the class.