CMS 3D CMS Logo

HLTriggerJSONMonitoring.cc
Go to the documentation of this file.
1 
7 #include <atomic>
8 #include <fstream>
9 #include <sstream>
10 #include <vector>
11 #include <string>
12 #include <memory>
13 #include <algorithm>
14 
15 #include <fmt/printf.h>
16 
35 
36 //note this was updated 20/10/22 to change the logic such that instead
37 //of having it passing the L1Seed, it is now number passing pre prescale
38 //this is indentical for "standard" paths and more meaningful for
39 //the special paths which are affected
40 //a standard path logic goes "trigger type -> l1 seed -> prescale -> other selection"
41 
43  // variables accumulated event by event in each stream
44  struct stream {
45  unsigned int processed; // number of events processed
46  std::vector<unsigned int> hltWasRun; // number of events where each path was run
47  std::vector<unsigned int> hltPrePS; // number of events where each path made it to the prescale module
48  std::vector<unsigned int> hltPostPS; // number of events where each path passed the prescale
49  std::vector<unsigned int> hltAccept; // number of events accepted by each path
50  std::vector<unsigned int> hltReject; // number of events rejected by each path
51  std::vector<unsigned int> hltErrors; // number of events with errors in each path
52  std::vector<unsigned int> datasets; // number of events accepted by each dataset
53  };
54 
55  // variables initialised for each run
56  struct run {
59  std::string baseRunDir; // base directory from EvFDaqDirector
60  std::string jsdFileName; // definition file name for JSON with rates
61 
62  HLTConfigProvider hltConfig; // HLT configuration for the current run
63  std::vector<int> posPre; // position of last HLT prescale filter in each path, or -1 if not present
64  std::vector<std::vector<unsigned int>> datasets; // list of paths in each dataset
65  std::vector<unsigned int> indicesOfTriggerPaths; // indices of triggers (without DatasetPaths) in TriggerNames
66  };
67 
68  // variables accumulated over the whole lumisection
69  struct lumisection {
70  jsoncollector::HistoJ<unsigned int> processed; // number of events processed
71  jsoncollector::HistoJ<unsigned int> hltWasRun; // number of events where each path was run
72  jsoncollector::HistoJ<unsigned int> hltPrePS; // number of events where each path made it to the prescale module
73  jsoncollector::HistoJ<unsigned int> hltPostPS; // number of events where each path passed the prescale
74  jsoncollector::HistoJ<unsigned int> hltAccept; // number of events accepted by each path
75  jsoncollector::HistoJ<unsigned int> hltReject; // number of events rejected by each path
76  jsoncollector::HistoJ<unsigned int> hltErrors; // number of events with errors in each path
77  jsoncollector::HistoJ<unsigned int> datasets; // number of events accepted by each dataset
78  };
79 };
80 
82  // per-stream information
83  edm::StreamCache<HLTriggerJSONMonitoringData::stream>,
84  // per-run accounting
85  edm::RunCache<HLTriggerJSONMonitoringData::run>,
86  // accumulate per-lumisection statistics
87  edm::LuminosityBlockSummaryCache<HLTriggerJSONMonitoringData::lumisection>> {
88 public:
89  // constructor
91 
92  // destructor
93  ~HLTriggerJSONMonitoring() override = default;
94 
95  // validate the configuration and optionally fill the default values
96  static void fillDescriptions(edm::ConfigurationDescriptions& descriptions);
97 
98  // called for each Event
99  void analyze(edm::StreamID, edm::Event const&, edm::EventSetup const&) const override;
100 
101  // -- inherited from edm::StreamCache<HLTriggerJSONMonitoringData::stream>
102 
103  // called once for each Stream being used in the job to create the cache object that will be used for that particular Stream
104  std::unique_ptr<HLTriggerJSONMonitoringData::stream> beginStream(edm::StreamID) const override;
105 
106  // called when the Stream is switching from one LuminosityBlock to a new LuminosityBlock.
108 
109  // -- inherited from edm::RunCache<HLTriggerJSONMonitoringData::run>
110 
111  // called each time the Source sees a new Run, and guaranteed to finish before any Stream calls streamBeginRun for that same Run
112  std::shared_ptr<HLTriggerJSONMonitoringData::run> globalBeginRun(edm::Run const&,
113  edm::EventSetup const&) const override;
114 
115  // called after all Streams have finished processing a given Run (i.e. streamEndRun for all Streams have completed)
116  void globalEndRun(edm::Run const&, edm::EventSetup const&) const override;
117 
118  // -- inherited from edm::LuminosityBlockSummaryCache<HLTriggerJSONMonitoringData::lumisection>
119 
120  // called each time the Source sees a new LuminosityBlock
121  std::shared_ptr<HLTriggerJSONMonitoringData::lumisection> globalBeginLuminosityBlockSummary(
122  edm::LuminosityBlock const&, edm::EventSetup const&) const override;
123 
124  // called when a Stream has finished processing a LuminosityBlock, after streamEndLuminosityBlock
126  edm::LuminosityBlock const&,
127  edm::EventSetup const&,
129 
130  // called after the streamEndLuminosityBlockSummary method for all Streams have finished processing a given LuminosityBlock
132  edm::EventSetup const&,
134 
135 private:
136  static constexpr const char* streamName_ = "streamHLTRates";
137 
138  static constexpr const char* datasetPathNamePrefix_ = "Dataset_";
139 
141  static void writeIniFile(HLTriggerJSONMonitoringData::run const&, unsigned int);
142 
143  // configuration
144  const edm::InputTag triggerResults_; // InputTag for TriggerResults
146 };
147 
148 // constructor
150  : triggerResults_(config.getParameter<edm::InputTag>("triggerResults")),
151  triggerResultsToken_(consumes(triggerResults_)) {}
152 
153 // validate the configuration and optionally fill the default values
156  desc.add<edm::InputTag>("triggerResults", edm::InputTag("TriggerResults", "", "@currentProcess"));
157  descriptions.add("HLTriggerJSONMonitoring", desc);
158 }
159 
160 // called once for each Stream being used in the job to create the cache object that will be used for that particular Stream
161 std::unique_ptr<HLTriggerJSONMonitoringData::stream> HLTriggerJSONMonitoring::beginStream(edm::StreamID) const {
162  return std::make_unique<HLTriggerJSONMonitoringData::stream>();
163 }
164 
165 // called each time the Source sees a new Run, and guaranteed to finish before any Stream calls streamBeginRun for that same Run
166 std::shared_ptr<HLTriggerJSONMonitoringData::run> HLTriggerJSONMonitoring::globalBeginRun(
167  edm::Run const& run, edm::EventSetup const& setup) const {
168  auto rundata = std::make_shared<HLTriggerJSONMonitoringData::run>();
169 
170  // set the DAQ parameters
172  rundata->streamDestination = edm::Service<evf::EvFDaqDirector>()->getStreamDestinations(streamName_);
173  rundata->streamMergeType =
175  rundata->baseRunDir = edm::Service<evf::EvFDaqDirector>()->baseRunDir();
176  } else {
177  rundata->streamDestination = "";
178  rundata->streamMergeType = "";
179  rundata->baseRunDir = ".";
180  }
181 
182  // initialize HLTConfigProvider
183  bool changed = true;
184  if (not rundata->hltConfig.init(run, setup, triggerResults_.process(), changed)) {
185  edm::LogError("HLTriggerJSONMonitoring") << "HLTConfigProvider initialization failed!";
186  } else if (changed) {
187  // triggerNames from TriggerResults (includes DatasetPaths)
188  auto const& triggerNames = rundata->hltConfig.triggerNames();
189  auto const triggerNamesSize = triggerNames.size();
190 
191  // update the list of indices of the HLT Paths (without DatasetPaths) in the TriggerNames list
192  rundata->indicesOfTriggerPaths.clear();
193  rundata->indicesOfTriggerPaths.reserve(triggerNamesSize);
194  for (auto triggerNameIdx = 0u; triggerNameIdx < triggerNamesSize; ++triggerNameIdx) {
195  // skip DatasetPaths
196  if (triggerNames[triggerNameIdx].find(datasetPathNamePrefix_) != 0) {
197  rundata->indicesOfTriggerPaths.emplace_back(triggerNameIdx);
198  }
199  }
200  auto const triggersSize = rundata->indicesOfTriggerPaths.size();
201 
202  // update the list of paths in each dataset
203  auto const& datasets = rundata->hltConfig.datasetContents();
204  auto const& datasetNames = rundata->hltConfig.datasetNames();
205  auto const datasetsSize = datasetNames.size();
206  rundata->datasets.resize(datasetsSize);
207  for (auto ds = 0u; ds < datasetsSize; ++ds) {
208  auto& dataset = rundata->datasets[ds];
209  // check if TriggerNames include the DatasetPath corresponding to this Dataset
210  // - DatasetPaths are normal cms.Path objects
211  // - in Run-3 HLT menus, DatasetPaths are used to define PrimaryDatasets
212  auto const datasetPathName = datasetPathNamePrefix_ + datasetNames[ds];
213  auto const datasetPathExists =
214  std::find(triggerNames.begin(), triggerNames.end(), datasetPathName) != triggerNames.end();
215  if (datasetPathExists) {
216  // if a DatasetPath exists, only that Path is assigned to the Dataset
217  // - this way, the counts of the Dataset properly include prescales on the DatasetPath
218  // and smart-Prescales applied by the DatasetPath to its triggers
219  dataset.reserve(1);
220  auto const index = rundata->hltConfig.triggerIndex(datasetPathName);
221  if (index < triggerNamesSize)
222  dataset.push_back(index);
223  } else {
224  auto const paths = datasets[ds].size();
225  dataset.reserve(paths);
226  for (auto p = 0u; p < paths; p++) {
227  auto const index = rundata->hltConfig.triggerIndex(datasets[ds][p]);
228  if (index < triggerNamesSize)
229  dataset.push_back(index);
230  }
231  }
232  }
233 
234  // find the positions of the prescale filters
235  rundata->posPre.resize(triggersSize);
236  for (auto i = 0u; i < triggersSize; ++i) {
237  rundata->posPre[i] = -1;
238  auto const trigNameIndx = rundata->indicesOfTriggerPaths[i];
239  auto const& moduleLabels = rundata->hltConfig.moduleLabels(trigNameIndx);
240  for (auto j = 0u; j < moduleLabels.size(); ++j) {
241  auto const& moduleType = rundata->hltConfig.moduleType(moduleLabels[j]);
242  if (moduleType == "HLTPrescaler") {
243  rundata->posPre[i] = j;
244  break;
245  }
246  }
247  }
248  }
249 
250  // write the per-run .jsd file
251  rundata->jsdFileName = fmt::sprintf("run%06d_ls0000_streamHLTRates_pid%05d.jsd", run.run(), getpid());
252  writeJsdFile(*rundata);
253 
254  // write the per-run .ini file
255  //iniFileName = fmt::sprintf("run%06d_ls0000_streamHLTRates_pid%05d.ini", run.run(), getpid());
256  writeIniFile(*rundata, run.run());
257 
258  return rundata;
259 }
260 
261 // called after all Streams have finished processing a given Run (i.e. streamEndRun for all Streams have completed)
263 
264 // called for each Event
266  auto& stream = *streamCache(sid);
267  auto const& rundata = *runCache(event.getRun().index());
268 
269  ++stream.processed;
270 
271  // check that the HLTConfigProvider for the current run has been successfully initialised
272  if (not rundata.hltConfig.inited())
273  return;
274 
275  // get hold of TriggerResults
277  if (not event.getByToken(triggerResultsToken_, handle) or not handle.isValid()) {
278  edm::LogError("HLTriggerJSONMonitoring")
279  << "TriggerResults with label [" + triggerResults_.encode() + "] not present or invalid";
280  return;
281  }
283  assert(results.size() == rundata.hltConfig.triggerNames().size());
284 
285  // check the results for each HLT path
286  for (auto idx = 0u; idx < rundata.indicesOfTriggerPaths.size(); ++idx) {
287  auto const triggerPathIdx = rundata.indicesOfTriggerPaths[idx];
288  auto const& status = results[triggerPathIdx];
289  if (status.wasrun()) {
290  ++stream.hltWasRun[idx];
291  if (status.accept()) {
292  ++stream.hltPrePS[idx];
293  ++stream.hltPostPS[idx];
294  ++stream.hltAccept[idx];
295  } else {
296  int const index = (int)status.index();
297  if (index >= rundata.posPre[idx])
298  ++stream.hltPrePS[idx];
299  if (index > rundata.posPre[idx])
300  ++stream.hltPostPS[idx];
301  if (status.error())
302  ++stream.hltErrors[idx];
303  else
304  ++stream.hltReject[idx];
305  }
306  }
307  }
308 
309  // check the decision for each dataset
310  // FIXME this ignores the prescales, "smart" prescales, and event selection applied in the OutputModule itself
311  for (auto i = 0u; i < rundata.datasets.size(); ++i)
312  if (std::any_of(rundata.datasets[i].begin(), rundata.datasets[i].end(), [&](unsigned int path) {
313  return results.accept(path);
314  }))
315  ++stream.datasets[i];
316 }
317 
318 // called each time the Source sees a new LuminosityBlock
319 std::shared_ptr<HLTriggerJSONMonitoringData::lumisection> HLTriggerJSONMonitoring::globalBeginLuminosityBlockSummary(
320  edm::LuminosityBlock const& lumi, edm::EventSetup const&) const {
321  unsigned int triggers = 0;
322  unsigned int datasets = 0;
323  auto const& rundata = *runCache(lumi.getRun().index());
324  if (rundata.hltConfig.inited()) {
325  triggers = rundata.indicesOfTriggerPaths.size();
326  datasets = rundata.hltConfig.datasetNames().size();
327  };
328 
329  // the API of jsoncollector::HistoJ does not really match our use case,
330  // but it is the only vector-like object available in JsonMonitorable.h
331  auto lumidata = std::make_shared<HLTriggerJSONMonitoringData::lumisection>(HLTriggerJSONMonitoringData::lumisection{
332  jsoncollector::HistoJ<unsigned int>(1), // processed
333  jsoncollector::HistoJ<unsigned int>(triggers), // hltWasRun
334  jsoncollector::HistoJ<unsigned int>(triggers), // hltPrePS
335  jsoncollector::HistoJ<unsigned int>(triggers), // hltPostPS
336  jsoncollector::HistoJ<unsigned int>(triggers), // hltAccept
337  jsoncollector::HistoJ<unsigned int>(triggers), // hltReject
338  jsoncollector::HistoJ<unsigned int>(triggers), // hltErrors
340  });
341  // repeated calls to `update` necessary to set the internal element counter
342  lumidata->processed.update(0);
343  for (unsigned int i = 0; i < triggers; ++i)
344  lumidata->hltWasRun.update(0);
345  for (unsigned int i = 0; i < triggers; ++i)
346  lumidata->hltPrePS.update(0);
347  for (unsigned int i = 0; i < triggers; ++i)
348  lumidata->hltPostPS.update(0);
349  for (unsigned int i = 0; i < triggers; ++i)
350  lumidata->hltAccept.update(0);
351  for (unsigned int i = 0; i < triggers; ++i)
352  lumidata->hltReject.update(0);
353  for (unsigned int i = 0; i < triggers; ++i)
354  lumidata->hltErrors.update(0);
355  for (unsigned int i = 0; i < datasets; ++i)
356  lumidata->datasets.update(0);
357 
358  return lumidata;
359 }
360 
361 // called when the Stream is switching from one LuminosityBlock to a new LuminosityBlock.
363  edm::LuminosityBlock const& lumi,
364  edm::EventSetup const&) const {
365  auto& stream = *streamCache(sid);
366 
367  unsigned int triggers = 0;
368  unsigned int datasets = 0;
369  auto const& rundata = *runCache(lumi.getRun().index());
370  if (rundata.hltConfig.inited()) {
371  triggers = rundata.indicesOfTriggerPaths.size();
372  datasets = rundata.hltConfig.datasetNames().size();
373  };
374 
375  // reset the stream counters
376  stream.processed = 0;
377  stream.hltWasRun.assign(triggers, 0);
378  stream.hltPrePS.assign(triggers, 0);
379  stream.hltPostPS.assign(triggers, 0);
380  stream.hltAccept.assign(triggers, 0);
381  stream.hltReject.assign(triggers, 0);
382  stream.hltErrors.assign(triggers, 0);
383  stream.datasets.assign(datasets, 0);
384 }
385 
386 // called when a Stream has finished processing a LuminosityBlock, after streamEndLuminosityBlock
388  edm::LuminosityBlock const& lumi,
389  edm::EventSetup const&,
391  auto const& stream = *streamCache(sid);
392  auto const& rundata = *runCache(lumi.getRun().index());
393  lumidata->processed.value()[0] += stream.processed;
394 
395  // check that the HLTConfigProvider for the current run has been successfully initialised
396  if (not rundata.hltConfig.inited())
397  return;
398 
399  auto const triggers = rundata.indicesOfTriggerPaths.size();
400  for (auto i = 0u; i < triggers; ++i) {
401  lumidata->hltWasRun.value()[i] += stream.hltWasRun[i];
402  lumidata->hltPrePS.value()[i] += stream.hltPrePS[i];
403  lumidata->hltPostPS.value()[i] += stream.hltPostPS[i];
404  lumidata->hltAccept.value()[i] += stream.hltAccept[i];
405  lumidata->hltReject.value()[i] += stream.hltReject[i];
406  lumidata->hltErrors.value()[i] += stream.hltErrors[i];
407  }
408  auto const datasets = rundata.hltConfig.datasetNames().size();
409  for (auto i = 0u; i < datasets; ++i)
410  lumidata->datasets.value()[i] += stream.datasets[i];
411 }
412 
413 // called after the streamEndLuminosityBlockSummary method for all Streams have finished processing a given LuminosityBlock
415  edm::EventSetup const&,
417  unsigned int ls = lumi.luminosityBlock();
418  unsigned int run = lumi.run();
419 
420  bool writeFiles = true;
421  if (edm::Service<evf::MicroStateService>().isAvailable()) {
424  if (fms)
425  writeFiles = fms->shouldWriteFiles(ls);
426  }
427  if (not writeFiles)
428  return;
429 
430  unsigned int processed = lumidata->processed.value().at(0);
431  auto const& rundata = *runCache(lumi.getRun().index());
433 
434  // [SIC]
435  char hostname[33];
436  gethostname(hostname, 32);
437  std::string sourceHost(hostname);
438 
439  // [SIC]
440  std::stringstream sOutDef;
441  sOutDef << rundata.baseRunDir << "/"
442  << "output_" << getpid() << ".jsd";
443 
444  std::string jsndataFileList = "";
445  unsigned int jsndataSize = 0;
446  unsigned int jsndataAdler32 = 1; // adler32 checksum for an empty file
447 
448  if (processed) {
449  // write the .jsndata files which contain the actual rates
450  Json::Value jsndata;
451  jsndata[jsoncollector::DataPoint::SOURCE] = sourceHost;
452  jsndata[jsoncollector::DataPoint::DEFINITION] = rundata.jsdFileName;
461 
462  auto jsndataFileName = fmt::sprintf("run%06d_ls%04d_streamHLTRates_pid%05d.jsndata", run, ls, getpid());
463 
464  std::string result = writer.write(jsndata);
465  std::ofstream jsndataFile(rundata.baseRunDir + "/" + jsndataFileName);
466  jsndataFile << result;
467  jsndataFile.close();
468 
469  jsndataFileList = jsndataFileName;
470  jsndataSize = result.size();
471  jsndataAdler32 = cms::Adler32(result.c_str(), result.size());
472  }
473 
474  // create a metadata json file for the "HLT rates" pseudo-stream
475  unsigned int jsnProcessed = processed;
476  unsigned int jsnAccepted = processed;
477  unsigned int jsnErrorEvents = 0;
478  unsigned int jsnRetCodeMask = 0;
479  std::string jsnInputFiles = "";
480  unsigned int jsnHLTErrorEvents = 0;
481 
482  Json::Value jsn;
483  jsn[jsoncollector::DataPoint::SOURCE] = sourceHost;
484  jsn[jsoncollector::DataPoint::DEFINITION] = sOutDef.str();
485  jsn[jsoncollector::DataPoint::DATA].append(jsnProcessed);
486  jsn[jsoncollector::DataPoint::DATA].append(jsnAccepted);
487  jsn[jsoncollector::DataPoint::DATA].append(jsnErrorEvents);
488  jsn[jsoncollector::DataPoint::DATA].append(jsnRetCodeMask);
489  jsn[jsoncollector::DataPoint::DATA].append(jsndataFileList);
490  jsn[jsoncollector::DataPoint::DATA].append(jsndataSize);
491  jsn[jsoncollector::DataPoint::DATA].append(jsnInputFiles);
492  jsn[jsoncollector::DataPoint::DATA].append(jsndataAdler32);
493  jsn[jsoncollector::DataPoint::DATA].append(rundata.streamDestination);
494  jsn[jsoncollector::DataPoint::DATA].append(rundata.streamMergeType);
495  jsn[jsoncollector::DataPoint::DATA].append(jsnHLTErrorEvents);
496 
497  auto jsnFileName = fmt::sprintf("run%06d_ls%04d_streamHLTRates_pid%05d.jsn", run, ls, getpid());
498  std::ofstream jsnFile(rundata.baseRunDir + "/" + jsnFileName);
499  jsnFile << writer.write(jsn);
500  jsnFile.close();
501 }
502 
504  std::ofstream file(rundata.baseRunDir + "/" + rundata.jsdFileName);
505  file << R"""({
506  "data" : [
507  { "name" : "Processed", "type" : "integer", "operation" : "histo"},
508  { "name" : "Path-WasRun", "type" : "integer", "operation" : "histo"},
509  { "name" : "Path-AfterL1Seed", "type" : "integer", "operation" : "histo"},
510  { "name" : "Path-AfterPrescale", "type" : "integer", "operation" : "histo"},
511  { "name" : "Path-Accepted", "type" : "integer", "operation" : "histo"},
512  { "name" : "Path-Rejected", "type" : "integer", "operation" : "histo"},
513  { "name" : "Path-Errors", "type" : "integer", "operation" : "histo"},
514  { "name" : "Dataset-Accepted", "type" : "integer", "operation" : "histo"}
515  ]
516 }
517 )""";
518  file.close();
519 }
520 
523 
525  for (auto idx : rundata.indicesOfTriggerPaths)
526  triggerNames.append(rundata.hltConfig.triggerNames()[idx]);
527  content["Path-Names"] = triggerNames;
528 
530  for (auto const& name : rundata.hltConfig.datasetNames())
531  datasetNames.append(name);
532  content["Dataset-Names"] = datasetNames;
533 
534  std::string iniFileName = fmt::sprintf("run%06d_ls0000_streamHLTRates_pid%05d.ini", run, getpid());
535  std::ofstream file(rundata.baseRunDir + "/" + iniFileName);
537  file << writer.write(content);
538  file.close();
539 }
540 
541 // declare as a framework plugin
static constexpr const char * streamName_
void globalEndRun(edm::Run const &, edm::EventSetup const &) const override
static constexpr const char * datasetPathNamePrefix_
static const std::string SOURCE
Definition: DataPoint.h:116
std::string encode() const
Definition: InputTag.cc:159
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:16
~HLTriggerJSONMonitoring() override=default
std::vector< std::vector< unsigned int > > datasets
HLTriggerJSONMonitoring(const edm::ParameterSet &)
void streamBeginLuminosityBlock(edm::StreamID, edm::LuminosityBlock const &, edm::EventSetup const &) const override
static void writeIniFile(HLTriggerJSONMonitoringData::run const &, unsigned int)
Value & append(const Value &value)
Append value to array at the end.
Definition: config.py:1
jsoncollector::HistoJ< unsigned int > hltReject
Represents a JSON value.
Definition: value.h:99
Log< level::Error, false > LogError
uint32_t T const *__restrict__ uint32_t const *__restrict__ int32_t int Histo::index_type cudaStream_t stream
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition: FindCaloHit.cc:19
assert(be >=bs)
const edm::EDGetTokenT< edm::TriggerResults > triggerResultsToken_
jsoncollector::HistoJ< unsigned int > hltErrors
std::vector< T > & value()
static const std::string DATA
Definition: DataPoint.h:118
void analyze(edm::StreamID, edm::Event const &, edm::EventSetup const &) const override
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e< void, edm::EventID const &, edm::Timestamp const & > We also list in braces which AR_WATCH_USING_METHOD_ is used for those or
Definition: Activities.doc:12
std::unique_ptr< HLTriggerJSONMonitoringData::stream > beginStream(edm::StreamID) const override
std::shared_ptr< HLTriggerJSONMonitoringData::lumisection > globalBeginLuminosityBlockSummary(edm::LuminosityBlock const &, edm::EventSetup const &) const override
void Adler32(char const *data, size_t len, uint32_t &a, uint32_t &b)
def ls(path, rec=False)
Definition: eostools.py:349
virtual Json::Value toJsonValue() const
static void writeJsdFile(HLTriggerJSONMonitoringData::run const &)
void add(std::string const &label, ParameterSetDescription const &psetDescription)
jsoncollector::HistoJ< unsigned int > hltWasRun
const std::vector< std::string > & triggerNames() const
names of trigger paths
void streamEndLuminosityBlockSummary(edm::StreamID, edm::LuminosityBlock const &, edm::EventSetup const &, HLTriggerJSONMonitoringData::lumisection *) const override
HLT enums.
const edm::InputTag triggerResults_
void globalEndLuminosityBlockSummary(edm::LuminosityBlock const &, edm::EventSetup const &, HLTriggerJSONMonitoringData::lumisection *) const override
bool isAvailable() const
Definition: Service.h:40
jsoncollector::HistoJ< unsigned int > hltPrePS
jsoncollector::HistoJ< unsigned int > processed
std::string const & process() const
Definition: InputTag.h:40
const std::vector< std::string > & datasetNames() const
Writes a Value in JSON format in a human friendly way.
Definition: writer.h:63
bool shouldWriteFiles(unsigned int lumi, unsigned int *proc=nullptr)
static const std::string DEFINITION
Definition: DataPoint.h:117
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
jsoncollector::HistoJ< unsigned int > datasets
std::vector< unsigned int > indicesOfTriggerPaths
std::shared_ptr< HLTriggerJSONMonitoringData::run > globalBeginRun(edm::Run const &, edm::EventSetup const &) const override
Definition: event.py:1
Definition: Run.h:45
jsoncollector::HistoJ< unsigned int > hltAccept
jsoncollector::HistoJ< unsigned int > hltPostPS
array value (ordered list)
Definition: value.h:30