art-framework-suite / art

The implementation of the art physics event processing framework
Other
2 stars 7 forks source link

Documentation on art::TriggerResults_TriggerResults__<process name> Event branch #102

Open knoepfel opened 2 years ago

knoepfel commented 2 years ago

This issue has been migrated from https://cdcvs.fnal.gov/redmine/issues/24050 (FNAL account required) Originally created by @liangliphy on 2020-02-12 21:11:19


Is there a way to find some detailed information on how the event level trigger products are defined? specifically we would like to know how to do an event counting for each trigger products (filters) using the art files directly.

What we found so far is this one short albeit succinct paragraph at https://cdcvs.fnal.gov/redmine/projects/art/wiki/Event-level_products:

Whenever a producer or filter is included on a trigger path, a TriggerResults product is automatically created and inserted by art, with its corresponding BranchID added to the BranchID list for the current process. The product is written to the art ROOT output files so that the TriggerResults information can be used further downstream. It may, therefore, come as a surprise that even though users do not explicitly create any products with the producers or filters included in a trigger path for a given process, a TriggerResults product (and, therefore, a art::TriggerResults_TriggerResults__ Event branch) is written to the output file.

When opening an art file using ROOT (see screenshot), there are two sub-branches under art::TriggerResults_TriggerResults_.obj, namely "psetid" and "paths", what they are defined for? Assuming we go with the "paths" branch, what's the information stored in the "state", "index", "accept", "status" leaves?

More importantly, how do we "map" the sequence of trigger paths into any of above mentioned leaves? This is what we have in the FHICL:

SelectEvents : [muonPath, inFillLaserPath, laserPath, pedestalPath, asyncPath, strawPath, muonPathWithDQC, inFillLaserPathWithDQC,
strawPathWithDQC, muonPathWithLaserDQC, inFillLaserPathWithLaserDQC, strawPathWithLaserDQC,muonPathWithT0DQC, inFillLaserPathWithT0DQC,
strawPathWithT0DQC, muonPathWithKickerDQC, inFillLaserPathWithKickerDQC, strawPathWithKickerDQC]

Let's say we would like to know how events passed "muonPathWithDQC", which variable we should check via ROOT?

The "size" leaf stores the same number (18 exactly!) of trigger paths defined in the FHICL (which is a good indication that we are looking at the right branch).

Art workbook has no mentioning of the (common) output file products and structures.

Any additional information is greatly appreciated!

knoepfel commented 2 years ago

Comment by @knoepfel on 2020-06-25 19:14:09


This TriggerResults product can certainly be better documented, and that's why this issue has been accepted. However, I have unassigned the target version as it is not tied to any particular release.