Project

General

Profile

Feature #23801

Request to extend TriggerNameServices to read names from previous jobs

Added by Giuseppe Cerati about 2 months ago. Updated about 1 month ago.

Status:
Under Discussion
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
Start date:
12/23/2019
Due date:
% Done:

0%

Estimated time:
Scope:
Internal
Experiment:
-
SSI Package:
Duration:

Description

TriggerNameServices is currently built based on the trigger results from the current job.
However, it would be good it could return the trigger names of filters run on previous jobs.
The functionality could be similar to what is currently done in EventSelector::acceptEvent(TriggerResults const& tr).

Here is a code snipped that works for me:

  art::ValidHandle<art::TriggerResults> filter = e.getValidHandle<art::TriggerResults>(art::InputTag("TriggerResults","","OverlayFiltersPostStage2"));
  std::vector<std::string> trigger_path_names;
  fhicl::ParameterSet pset;
  if (!fhicl::ParameterSetRegistry::get(filter->parameterSetID(), pset)) { throw cet::exception("PSet Not Found???"); }
  trigger_path_names = pset.get<std::vector<std::string> >("trigger_paths", {});
  if (trigger_path_names.size()!=filter->size()) { throw cet::exception("Size mismatch???"); }
  for (size_t itp=0;itp<filter->size();itp++) {
    std::cout << "filter name=" << trigger_path_names.at(itp) << " decision=" << filter->at(itp).accept()  << std::endl;
  }

(Thanks Kyle for the help!)

History

#1 Updated by Kyle Knoepfel about 1 month ago

  • Scope set to Internal
  • Status changed from New to Under Discussion
  • Project changed from LArSoft to art

#2 Updated by Kyle Knoepfel about 1 month ago

The art developers will discuss this feature. In particular, any issues related to multi-threading need to be understood before this feature is implemented.



Also available in: Atom PDF