ATLAS Offline Software
Loading...
Searching...
No Matches
L1TriggerByteStreamDecoderAlg.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef TRIGT1RESULTBYTESTREAM_L1TRIGGERBYTESTREAMDECODERALG_H
6#define TRIGT1RESULTBYTESTREAM_L1TRIGGERBYTESTREAMDECODERALG_H
7
8// Trigger includes
10
11// Athena includes
16
21public:
23 L1TriggerByteStreamDecoderAlg(const std::string& name, ISvcLocator* svcLoc);
24
25 // ------------------------- AthReentrantAlgorithm methods -------------------
26 virtual StatusCode initialize() override;
27 virtual StatusCode start() override;
28 virtual StatusCode finalize() override;
29 virtual StatusCode execute(const EventContext& eventContext) const override;
30
31private:
32 // ------------------------- Tool/Service handles ----------------------------
34 ToolHandleArray<IL1TriggerByteStreamTool> m_decoderTools {
35 this, "DecoderTools", {}, "Array of tools performing the decoding work"};
36
38 this, "ROBDataProviderSvc", "ROBDataProviderSvc", "ROB data provider"};
39
40 ToolHandle<GenericMonitoringTool> m_monTool{
41 this, "MonTool", "", "Monitoring tool"};
42
43 // ------------------------- Properties --------------------------------------
46 this, "ByteStreamMetadataRHKey", "InputMetaDataStore+ByteStreamMetadata",
47 "Key of the ByteStreamMetadataContainer to retrieve the detector mask"
48 };
49
50 Gaudi::Property<std::vector<uint32_t>> m_maybeMissingRobsProp {
51 this, "MaybeMissingROBs", {},
52 "List of ROB IDs allowed to be missing. If a decoder tool requests one of these "
53 "and it is not available in the event, no errors will be reported",
54 "OrderedSet<T>"
55 };
56
57 Gaudi::Property<std::string> m_robStatusCheckLevel {
58 this, "ROBStatusCheckLevel", "Warning",
59 "ROB status word check behaviour. Can be 'None' - status is not checked, 'Warning' - only print warnings "
60 "for non-zero status, 'Error' - only print errors for non-zero status, 'Fatal' - return FAILURE "
61 "from the algorithm if non-zero status is found. MaybeMissingROBs are always exempt from this check."
62 };
63
64 Gaudi::Property<std::string> m_robFormatCheckLevel {
65 this, "ROBFormatCheckLevel", "Fatal",
66 "ROB format (data consistency) check behaviour. Can be 'None' - format is not checked, 'Warning' - only print warnings "
67 "for corrupted data, 'Error' - only print errors for corrupted data, 'Fatal' - return FAILURE "
68 "from the algorithm if corrupted data are found. MaybeMissingROBs are always exempt from this check."
69 };
70
71 // ------------------------- Helper methods ----------------------------------
81 StatusCode filterRobs(const IROBDataProviderSvc::VROBFRAG& in,
83 const std::vector<uint32_t>& ids,
84 std::string_view toolName,
85 const EventContext& eventContext) const;
87 StatusCode checkRobs(const IROBDataProviderSvc::VROBFRAG& robs, std::string_view toolName, const EventContext& eventContext) const;
88
89 // ------------------------- Other private members ---------------------------
91 std::vector<uint32_t> m_robIds;
93 std::set<uint32_t> m_maybeMissingRobs;
98};
99
100#endif // TRIGT1RESULTBYTESTREAM_L1TRIGGERBYTESTREAMDECODERALG_H
This file contains the class definition for the ByteStreamMetadataContainer class.
Header file to be included by clients of the Monitored infrastructure.
An algorithm that can be simultaneously executed in multiple threads.
std::vector< const ROBF * > VROBFRAG
std::set< uint32_t > m_maybeMissingRobs
Set of ROB IDs allowed to be missing because they are disabled.
virtual StatusCode execute(const EventContext &eventContext) const override
StatusCode checkRobs(const IROBDataProviderSvc::VROBFRAG &robs, std::string_view toolName, const EventContext &eventContext) const
Check ROB status word and report if different from zero.
ROBCheckBehaviour
The behaviour for non-zero ROB status words.
StatusCode filterRobs(const IROBDataProviderSvc::VROBFRAG &in, IROBDataProviderSvc::VROBFRAG &out, const std::vector< uint32_t > &ids, std::string_view toolName, const EventContext &eventContext) const
Copy over ROBFragment pointers from in to out for ROBs with IDs from the ids list.
Gaudi::Property< std::string > m_robFormatCheckLevel
Set behaviour for corrupted ROB data.
std::vector< uint32_t > m_robIds
Vector of ROB IDs to request, filled from all decoder tools in initialize.
Gaudi::Property< std::string > m_robStatusCheckLevel
Set behaviour for non-zero ROB status words.
L1TriggerByteStreamDecoderAlg(const std::string &name, ISvcLocator *svcLoc)
Standard constructor.
ServiceHandle< IROBDataProviderSvc > m_robDataProviderSvc
ROBDataProvider service handle.
Gaudi::Property< std::vector< uint32_t > > m_maybeMissingRobsProp
Allow some ROBs to be missing.
ToolHandleArray< IL1TriggerByteStreamTool > m_decoderTools
Tool performing the decoding work.
ToolHandle< GenericMonitoringTool > m_monTool
Monitoring tool to create online histograms.
SG::ReadHandleKey< ByteStreamMetadataContainer > m_bsMetaDataContRHKey
StoreGate key for the ByteStreamMetadata container to retrieve detector mask.
Property holding a SG store/key/clid from which a ReadHandle is made.