Skip to content

[ATR-19881][ATR-20274] Updates to TrigDecisionTool interface for MT. Addition of associateToEventView()

Following on from https://indico.cern.ch/event/859726/

Some existing parameters were renamed for clarity:

  • The oneFeaturePerLeg enum was poorly named, it did not refer to legs in a multi-leg chain but rather which Step in the chain the feature came from. It is renamed lastFeatureOfType to make it clearer that it will return the last (final) features of the chain which passes all other filtering requirements (type, containerSGKey, navElementLinkKey). allFeaturesPerLeg is hence also renamed to allFeaturesOfType.
  • The container string parameter was renamed to containerSGKey to make it clearer.
  • The featureName string parameter was renamed to navElementLinkKey. This parameter specifies the named key used to get links from Navigation nodes (ElementLink<CONTAINER> objectLink(const std::string& name) interface https://acode-browser.usatlas.bnl.gov/lxr/source/athena/Event/xAOD/xAODTrigger/xAODTrigger/versions/TrigComposite_v1.h#0105).

The logic which filters on containerSGKey was moved deeper into the link fetching logic. This lets it interact correctly with the containerSGKey and navElementLinkKey settings rather than being applied afterwards.

A helper function associateToEventView is added to the TDT. It helps in associating the content of containers produced inside EventViews online to trigger "features" - via the ROI which was used to spawn the EventView. Interfaces are providing starting with either a LinkInfo, a const Decision*, a ElementLink<TrigRoIDescriptorCollection> or a uint32_t index, uint32_t sgKey = 0. These interfaces call down this chain internally.

It returns a pair of start and stop iterators over the target collection, this returned range is associated with the resolved ROI.

@sutt - the demo code here in TrigEDMChecker.cxx is matching to the L1 ROI of final muon objects. But we could feed it with object from earlier steps, include failed objects, or loop directly over the ROI rather than specific "feature"s by overriding the navElementLinkKey. It prints e.g.

TrigEDMChecker 3   0    INFO Muon pT: 13113.3 is from the same ROI as tracks with index 0-24, which is 24 tracks, out of 52 total tracks.
TrigEDMChecker 3   0    INFO Muon pT: 24891.9 is from the same ROI as tracks with index 24-52, which is 28 tracks, out of 52 total tracks.

The EDM is updated to persist the viewIndex decorations on all in-View collections. This is required by associateToEventView. @okuprash - this is using some ugly string parsing, please see if you're OK with this or have any other ideas here!

checkESD.py and TrigEDMChecker.py are updated to provide a test of associateToEventView

Merge request reports