12 const std::string& name,
13 const IInterface* parent)
21 return StatusCode::SUCCESS;
27 return name.find(
'J') == 0 or name.find(
"JF") == 0 or name.find(
"JB") == 0;
29 return StatusCode::SUCCESS;
45 std::optional<ThrVecRef> jetThresholds;
50 constexpr static unsigned int s_maxJetTOBs{4};
51 std::unordered_map<unsigned int, std::unordered_map<unsigned int, unsigned int>> tobCounts;
55 for (
const auto & roi : jetFragment.roIVec() ) {
56 uint32_t roIWord = roi.roIWord();
58 ATH_MSG_DEBUG(
"Skipping RoI as it is not JET threshold " << roIWord <<
" Type "<< roi.roIType() );
65 overflow = (++tobCounts[crate][module] > s_maxJetTOBs);
68 recRoIs->push_back( std::make_unique<LVL1::RecJetRoI>(roIWord, l1Menu.
cptr()) );
71 trigRoIs->push_back( std::make_unique<TrigRoiDescriptor>(
76 ATH_MSG_DEBUG(
"RoI word: 0x" << MSG::hex << std::setw( 8 ) << roIWord << MSG::dec );
81 std::vector<unsigned> passedThresholdIDs;
83 for (
const auto& th : jetThresholds.value().get()) {
84 ATH_MSG_VERBOSE(
"Checking if the threshold " << th->name() <<
" passed" );
92 return std::vector<TrigCompositeUtils::DecisionID>( ids.begin(), ids.end() ); }() );
96 decision->
setDetail(
"thresholds", passedThresholdIDs );
108 for (
Decision* decision : *decisionOutput) {
109 decision->setDetail(
"overflow",
static_cast<char>(overflow));
112 if ( msgLvl(MSG::DEBUG) ) {
113 for (
auto roi: *trigRoIs ) {
114 ATH_MSG_DEBUG(
"RoI Eta: " << roi->eta() <<
" Phi: " << roi->phi() <<
" RoIWord: " << roi->roiWord() );
128 return StatusCode::SUCCESS;
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_VERBOSE(x)
#define ATH_MSG_WARNING(x)
xAOD::TrigComposite Decision
SG::WriteHandle< DecisionContainer > createAndStore(const SG::WriteHandleKey< DecisionContainer > &key, const EventContext &ctx)
Creates and right away records the DecisionContainer with the key.
Header file to be included by clients of the Monitored infrastructure.
ElementLink implementation for ROOT usage.
virtual double eta() const =0
virtual double phi() const =0
Methods to retrieve data members.
This class defines the reconstructed em/tau hadron ROI.
virtual double eta() const
returns eta coord of ROI
virtual double phi() const
returns phi coord of ROI
bool passedThreshold(unsigned int thresholdNumber) const
returns TRUE if threshold number threshold_number has been passed by this ROI.
Group of local monitoring quantities and retain correlation when filling histograms
Declare a monitored scalar variable.
Class holding the LVL1 RoIB result build by the RoIBuilder.
const std::vector< JetEnergyResult > & jetEnergyResult() const
Gets the jet/energy part of the L1 RDO.
virtual bool isValid() override final
Can the handle be successfully dereferenced?
const_pointer_type cptr()
Dereference the pointer.
pointer_type ptr()
Dereference the pointer.
bool setObjectLink(const std::string &name, const ElementLink< CONTAINER > &link)
Set the link to an object.
bool setDetail(const std::string &name, const TYPE &value)
Set an TYPE detail on the object.
std::set< HLT::Identifier > IDSet
ValuesCollection< T > Collection(std::string name, const T &collection)
Declare a monitored (double-convertible) collection.
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
SG::WriteHandle< CONT > createAndStoreNoAux(const SG::WriteHandleKey< CONT > &key, const EventContext &ctx)
Creates and right away records the Container CONT with the key.
Decision * newDecisionIn(DecisionContainer *dc, const std::string &name)
Helper method to create a Decision object, place it in the container and return a pointer to it.
std::set< DecisionID > DecisionIDContainer
const std::string & initialRecRoIString()
const std::string & initialRoIString()
const std::string & hltSeedingNodeName()
void decisionIDs(const Decision *d, DecisionIDContainer &destination)
Extracts DecisionIDs stored in the Decision object.