CMS 3D CMS Logo

GlobalEvFOutputModule.cc
Go to the documentation of this file.
2 
6 
10 
16 
18 
21 
24 
28 
31 
33 
34 #include <sys/stat.h>
35 #include <filesystem>
36 #include <boost/algorithm/string.hpp>
37 
39 
40 namespace evf {
41  using namespace edm::streamer;
42 
44 
45  struct MetaDataCache {
47  edm::BranchIDLists const& branchLists,
49  : buffer_() {
50  auto ret = builders.serializeEventMetaData(buffer_, branchLists, helper);
51  builder_ = std::move(ret.first);
52  checksum_ = ret.second;
53  }
55  std::unique_ptr<EventMsgBuilder> builder_;
56  uint32_t checksum_;
57  };
58 
60  public:
62  unsigned int ls,
63  std::shared_ptr<MetaDataCache const> iMetaData)
64  : filePath_(filePath),
65  ls_(ls),
66  accepted_(0),
67  stream_writer_events_(new StreamerOutputFile(filePath)),
68  meta_(std::move(iMetaData)) {}
69 
71 
72  void setMetaCache(std::shared_ptr<MetaDataCache const> iMetaData) { meta_ = std::move(iMetaData); }
73 
74  bool close() {
75  stream_writer_events_->close();
76  return (discarded_ || edm::Service<evf::EvFDaqDirector>()->lumisectionDiscarded(ls_));
77  }
78 
79  void doOutputEvent(EventMsgBuilder const& msg, bool inc) {
80  EventMsgView eview(msg.startAddress());
81  stream_writer_events_->write(eview);
82  if (inc)
83  incAccepted();
84  }
85 
86  void doOutputEventAsync(std::unique_ptr<EventMsgBuilder> msg, edm::WaitingTaskHolder iHolder) {
87  throttledCheck();
88  discardedCheck();
89  if (discarded_) {
90  incAccepted();
91  msg.reset();
92  return;
93  }
94  auto group = iHolder.group();
95  writeQueue_.push(*group, [holder = std::move(iHolder), msg = msg.release(), this]() mutable {
96  try {
97  std::unique_ptr<EventMsgBuilder> own(msg);
98  if (meta_) {
99  auto m = std::move(meta_);
100  assert(m->builder_);
101  doOutputEvent(*m->builder_, false);
102  }
103  doOutputEvent(*msg, true); //msg is written and discarded at this point
104  } catch (...) {
105  auto tmp = holder;
106  tmp.doneWaiting(std::current_exception());
107  }
108  });
109  }
110 
111  inline void throttledCheck() {
112  unsigned int counter = 0;
113  while (edm::Service<evf::EvFDaqDirector>()->inputThrottled() && !discarded_) {
114  if (edm::shutdown_flag.load(std::memory_order_relaxed))
115  break;
116  if (!(counter % 100))
117  edm::LogWarning("FedRawDataInputSource") << "Input throttled detected, writing is paused...";
118  usleep(100000);
119  counter++;
120  if (edm::Service<evf::EvFDaqDirector>()->lumisectionDiscarded(ls_)) {
121  edm::LogWarning("FedRawDataInputSource") << "Detected that the lumisection is discarded -: " << ls_;
122  discarded_ = true;
123  }
124  }
125  }
126 
127  inline void discardedCheck() {
128  if (!discarded_ && edm::Service<evf::EvFDaqDirector>()->lumisectionDiscarded(ls_)) {
129  edm::LogWarning("FedRawDataInputSource") << "Detected that the lumisection is discarded -: " << ls_;
130  discarded_ = true;
131  }
132  }
133 
134  uint32 get_adler32() const { return stream_writer_events_->adler32(); }
135 
136  std::string const& getFilePath() const { return filePath_; }
137 
138  unsigned long getAccepted() const { return accepted_; }
139  void incAccepted() { accepted_++; }
140 
141  edm::SerialTaskQueue& queue() { return writeQueue_; }
142 
143  private:
145  const unsigned ls_;
146  std::atomic<unsigned long> accepted_;
148  std::shared_ptr<MetaDataCache const> meta_;
150  bool discarded_ = false;
151  };
152 
154  public:
155  GlobalEvFOutputJSONDef(std::string const& streamLabel, bool writeJsd);
156  void updateDestination(std::string const& streamLabel);
157 
162  };
163 
165  public:
168  std::string const& outJsonDefName,
169  jsoncollector::StringJ const& transferDestination,
170  jsoncollector::StringJ const& mergeType);
171 
183  std::shared_ptr<jsoncollector::FastMonitor> jsonMonitor_;
184  };
185 
192 
194  public:
195  explicit GlobalEvFOutputModule(edm::ParameterSet const& ps);
196  ~GlobalEvFOutputModule() override;
197  static void fillDescriptions(edm::ConfigurationDescriptions& descriptions);
198 
199  private:
200  std::unique_ptr<SerializeDataBuffer> beginStream(edm::StreamID) const final;
201 
202  std::shared_ptr<GlobalEvFOutputJSONDef> globalBeginRun(edm::RunForOutput const& run) const final;
203 
204  void acquire(edm::StreamID, edm::EventForOutput const&, edm::WaitingTaskWithArenaHolder) const final;
205  void write(edm::EventForOutput const& e) final;
206 
207  //pure in parent class but unused here
209  void writeRun(edm::RunForOutput const&) final {}
210  void globalEndRun(edm::RunForOutput const&) const final {}
211 
212  void respondToOpenInputFile(edm::FileBlock const&) final;
214 
215  void beginJob() final;
216  void cacheEventMetaData();
217 
218  std::shared_ptr<GlobalEvFOutputEventWriter> globalBeginLuminosityBlock(
220  void globalEndLuminosityBlock(edm::LuminosityBlockForOutput const& iLB) const final;
221 
222  Trig getTriggerResults(edm::EDGetTokenT<edm::TriggerResults> const& token, edm::EventForOutput const& e) const;
223 
226  std::string streamLabel_;
227  edm::EDGetTokenT<edm::TriggerResults> trToken_;
228  edm::EDGetTokenT<edm::SendJobHeader::ParameterSetMap> psetToken_;
229 
231 
232  std::shared_ptr<MetaDataCache const> metaDataCache_;
233  //if a new file appears and has different meta data but the same lumi, we need
234  // to update the writer to write out the new meta data
235  mutable std::atomic<GlobalEvFOutputEventWriter*> lastWriter_ = nullptr;
236  unsigned int presentBranchIDListSize_ = 0;
237  }; //end-of-class-def
238 
240  std::string baseRunDir = edm::Service<evf::EvFDaqDirector>()->baseRunDir();
241  LogDebug("GlobalEvFOutputModule") << "writing .dat files to -: " << baseRunDir;
242 
243  outJsonDef_.setDefaultGroup("data");
244  outJsonDef_.addLegendItem("Processed", "integer", jsoncollector::DataPointDefinition::SUM);
245  outJsonDef_.addLegendItem("Accepted", "integer", jsoncollector::DataPointDefinition::SUM);
246  outJsonDef_.addLegendItem("ErrorEvents", "integer", jsoncollector::DataPointDefinition::SUM);
247  outJsonDef_.addLegendItem("ReturnCodeMask", "integer", jsoncollector::DataPointDefinition::BINARYOR);
248  outJsonDef_.addLegendItem("Filelist", "string", jsoncollector::DataPointDefinition::MERGE);
249  outJsonDef_.addLegendItem("Filesize", "integer", jsoncollector::DataPointDefinition::SUM);
250  outJsonDef_.addLegendItem("InputFiles", "string", jsoncollector::DataPointDefinition::CAT);
251  outJsonDef_.addLegendItem("FileAdler32", "integer", jsoncollector::DataPointDefinition::ADLER32);
252  outJsonDef_.addLegendItem("TransferDestination", "string", jsoncollector::DataPointDefinition::SAME);
253  outJsonDef_.addLegendItem("MergeType", "string", jsoncollector::DataPointDefinition::SAME);
254  outJsonDef_.addLegendItem("HLTErrorEvents", "integer", jsoncollector::DataPointDefinition::SUM);
255 
256  std::stringstream ss;
257  ss << baseRunDir << "/"
258  << "output_" << getpid() << ".jsd";
259  outJsonDefName_ = ss.str();
260 
261  if (writeJsd) {
262  std::stringstream tmpss;
263  tmpss << baseRunDir << "/open/"
264  << "output_" << getpid() << ".jsd";
265  std::string outTmpJsonDefName = tmpss.str();
266  edm::Service<evf::EvFDaqDirector>()->createRunOpendirMaybe();
267  edm::Service<evf::EvFDaqDirector>()->lockInitLock();
268  struct stat fstat;
269  if (stat(outJsonDefName_.c_str(), &fstat) != 0) { //file does not exist
270  LogDebug("GlobalEvFOutputModule") << "writing output definition file -: " << outJsonDefName_;
274  std::filesystem::rename(outTmpJsonDefName, outJsonDefName_);
275  }
276  }
277  edm::Service<evf::EvFDaqDirector>()->unlockInitLock();
278  }
279 
281  transferDestination_ = edm::Service<evf::EvFDaqDirector>()->getStreamDestinations(streamLabel);
282  mergeType_ = edm::Service<evf::EvFDaqDirector>()->getStreamMergeType(streamLabel, evf::MergeTypeDAT);
283  }
284 
286  jsoncollector::DataPointDefinition const& outJsonDef,
287  std::string const& outJsonDefName,
288  jsoncollector::StringJ const& transferDestination,
289  jsoncollector::StringJ const& mergeType)
290  : processed_(0),
291  accepted_(0),
292  errorEvents_(0),
293  retCodeMask_(0),
294  filelist_(),
295  filesize_(0),
296  inputFiles_(),
297  fileAdler32_(1),
298  transferDestination_(transferDestination),
299  mergeType_(mergeType),
300  hltErrorEvents_(0) {
301  processed_.setName("Processed");
302  accepted_.setName("Accepted");
303  errorEvents_.setName("ErrorEvents");
304  retCodeMask_.setName("ReturnCodeMask");
305  filelist_.setName("Filelist");
306  filesize_.setName("Filesize");
307  inputFiles_.setName("InputFiles");
308  fileAdler32_.setName("FileAdler32");
309  transferDestination_.setName("TransferDestination");
310  mergeType_.setName("MergeType");
311  hltErrorEvents_.setName("HLTErrorEvents");
312 
313  jsonMonitor_.reset(new jsoncollector::FastMonitor(&outJsonDef, true));
314  jsonMonitor_->setDefPath(outJsonDefName);
315  jsonMonitor_->registerGlobalMonitorable(&processed_, false);
316  jsonMonitor_->registerGlobalMonitorable(&accepted_, false);
317  jsonMonitor_->registerGlobalMonitorable(&errorEvents_, false);
318  jsonMonitor_->registerGlobalMonitorable(&retCodeMask_, false);
319  jsonMonitor_->registerGlobalMonitorable(&filelist_, false);
320  jsonMonitor_->registerGlobalMonitorable(&filesize_, false);
321  jsonMonitor_->registerGlobalMonitorable(&inputFiles_, false);
322  jsonMonitor_->registerGlobalMonitorable(&fileAdler32_, false);
323  jsonMonitor_->registerGlobalMonitorable(&transferDestination_, false);
324  jsonMonitor_->registerGlobalMonitorable(&mergeType_, false);
325  jsonMonitor_->registerGlobalMonitorable(&hltErrorEvents_, false);
326  jsonMonitor_->commit(nullptr);
327  }
328 
330  : edm::global::OutputModuleBase(ps),
332  commonParameters_(StreamerOutputMsgBuilders::parameters(ps)),
333  streamLabel_(ps.getParameter<std::string>("@module_label")),
334  trToken_(consumes<edm::TriggerResults>(edm::InputTag("TriggerResults"))),
335  psetToken_(consumes<edm::SendJobHeader::ParameterSetMap, edm::InRun>(
336  ps.getUntrackedParameter<edm::InputTag>("psetMap"))) {
337  //replace hltOutoputA with stream if the HLT menu uses this convention
338  std::string testPrefix = "hltOutput";
339  if (streamLabel_.find(testPrefix) == 0)
340  streamLabel_ = std::string("stream") + streamLabel_.substr(testPrefix.size());
341 
342  if (streamLabel_.find('_') != std::string::npos) {
343  throw cms::Exception("GlobalEvFOutputModule")
344  << "Underscore character is reserved can not be used for stream names in "
345  "FFF, but was detected in stream name -: "
346  << streamLabel_;
347  }
348 
349  std::string streamLabelLow = streamLabel_;
350  boost::algorithm::to_lower(streamLabelLow);
351  auto streampos = streamLabelLow.rfind("stream");
352  if (streampos != 0 && streampos != std::string::npos)
353  throw cms::Exception("GlobalEvFOutputModule")
354  << "stream (case-insensitive) sequence was found in stream suffix. This is reserved and can not be used for "
355  "names in FFF based HLT, but was detected in stream name";
356 
357  //output initemp file. This lets hltd know number of streams early on
358  if (!edm::Service<evf::EvFDaqDirector>().isAvailable())
359  throw cms::Exception("GlobalEvFOutputModule") << "EvFDaqDirector is not available";
360 
361  const std::string iniFileName = edm::Service<evf::EvFDaqDirector>()->getInitTempFilePath(streamLabel_);
362  std::ofstream file(iniFileName);
363  if (!file)
364  throw cms::Exception("GlobalEvFOutputModule") << "can not create " << iniFileName << "error: " << strerror(errno);
365  file.close();
366 
367  edm::LogInfo("GlobalEvFOutputModule") << "Constructor created initemp file -: " << iniFileName;
368 
369  //create JSD
371 
373  }
374 
376 
381  desc.addUntracked<edm::InputTag>("psetMap", {"hltPSetMap"})
382  ->setComment("Optionally allow the map of ParameterSets to be calculated externally.");
383  descriptions.add("globalEvfOutputModule", desc);
384  }
385 
386  std::unique_ptr<SerializeDataBuffer> GlobalEvFOutputModule::beginStream(edm::StreamID) const {
387  return std::make_unique<SerializeDataBuffer>();
388  }
389 
390  std::shared_ptr<GlobalEvFOutputJSONDef> GlobalEvFOutputModule::globalBeginRun(edm::RunForOutput const& run) const {
391  //create run Cache holding JSON file writer and variables
392  auto jsonDef = std::make_unique<GlobalEvFOutputJSONDef>(streamLabel_, false);
393  jsonDef->updateDestination(streamLabel_);
394 
395  //output INI file (non-const). This doesn't require globalBeginRun to be finished
396  const std::string openIniFileName = edm::Service<evf::EvFDaqDirector>()->getOpenInitFilePath(streamLabel_);
397  edm::LogInfo("GlobalEvFOutputModule") << "beginRun init stream -: " << openIniFileName;
398 
399  StreamerOutputFile stream_writer_preamble(openIniFileName);
400  uint32 preamble_adler32 = 1;
401 
402  auto psetMapHandle = run.getHandle(psetToken_);
403 
405  std::unique_ptr<InitMsgBuilder> init_message =
406  msgBuilders_->serializeRegistry(buffer,
409  moduleDescription().mainParameterSetID(),
410  psetMapHandle.isValid() ? psetMapHandle.product() : nullptr);
411 
412  //Let us turn it into a View
413  InitMsgView view(init_message->startAddress());
414 
415  //output header
416  stream_writer_preamble.write(view);
417  preamble_adler32 = stream_writer_preamble.adler32();
418  stream_writer_preamble.close();
419 
420  struct stat istat;
421  stat(openIniFileName.c_str(), &istat);
422  //read back file to check integrity of what was written
423  off_t readInput = 0;
424  uint32_t adlera = 1, adlerb = 0;
425  std::ifstream src(openIniFileName, std::ifstream::binary);
426  if (!src)
427  throw cms::Exception("GlobalEvFOutputModule")
428  << "can not read back " << openIniFileName << " error: " << strerror(errno);
429 
430  //allocate buffer to write INI file
431  std::unique_ptr<char[]> outBuf = std::make_unique<char[]>(1024 * 1024);
432  while (readInput < istat.st_size) {
433  size_t toRead = readInput + 1024 * 1024 < istat.st_size ? 1024 * 1024 : istat.st_size - readInput;
434  src.read(outBuf.get(), toRead);
435  //cms::Adler32(const_cast<const char*>(reinterpret_cast<char*>(outBuf.get())), toRead, adlera, adlerb);
436  cms::Adler32(const_cast<const char*>(outBuf.get()), toRead, adlera, adlerb);
437  readInput += toRead;
438  }
439  src.close();
440 
441  //free output buffer needed only for the file write
442  outBuf.reset();
443 
444  uint32_t adler32c = (adlerb << 16) | adlera;
445  if (adler32c != preamble_adler32) {
446  throw cms::Exception("GlobalEvFOutputModule") << "Checksum mismatch of ini file -: " << openIniFileName
447  << " expected:" << preamble_adler32 << " obtained:" << adler32c;
448  } else {
449  LogDebug("GlobalEvFOutputModule") << "Ini file checksum -: " << streamLabel_ << " " << adler32c;
450  std::filesystem::rename(openIniFileName, edm::Service<evf::EvFDaqDirector>()->getInitFilePath(streamLabel_));
451  }
452 
453  return jsonDef;
454  }
455 
457  edm::EventForOutput const& e) const {
458  Trig result;
459  e.getByToken<edm::TriggerResults>(token, result);
460  return result;
461  }
462 
463  std::shared_ptr<GlobalEvFOutputEventWriter> GlobalEvFOutputModule::globalBeginLuminosityBlock(
464  edm::LuminosityBlockForOutput const& iLB) const {
465  auto openDatFilePath = edm::Service<evf::EvFDaqDirector>()->getOpenDatFilePath(iLB.luminosityBlock(), streamLabel_);
466 
467  auto ret = std::make_shared<GlobalEvFOutputEventWriter>(openDatFilePath, iLB.luminosityBlock(), metaDataCache_);
468  lastWriter_ = ret.get();
469  return ret;
470  }
471 
473  msgBuilders_ = std::make_unique<StreamerOutputMsgBuilders>(
475 
477  }
478 
482  if (lastWriter_) {
483  lastWriter_.load()->setMetaCache(metaDataCache_);
484  }
485  }
486  }
487 
489  metaDataCache_ = std::make_shared<MetaDataCache>(*msgBuilders_, *branchIDLists(), *thinnedAssociationsHelper());
490  }
491 
493  edm::EventForOutput const& e,
494  edm::WaitingTaskWithArenaHolder iHolder) const {
496 
497  auto buffer = streamCache(id);
498  std::unique_ptr<EventMsgBuilder> msg =
499  msgBuilders_->serializeEvent(*buffer, e, triggerResults, selectorConfig(), metaDataCache_->checksum_);
500 
501  auto lumiWriter = luminosityBlockCache(e.getLuminosityBlock().index());
502  const_cast<evf::GlobalEvFOutputEventWriter*>(lumiWriter)
503  ->doOutputEventAsync(std::move(msg), iHolder.makeWaitingTaskHolderAndRelease());
504  }
506 
508  auto lumiWriter = luminosityBlockCache(iLB.index());
509  //close dat file
510  const bool discarded = const_cast<evf::GlobalEvFOutputEventWriter*>(lumiWriter)->close();
511 
512  //auto jsonWriter = const_cast<GlobalEvFOutputJSONWriter*>(runCache(iLB.getRun().index()));
513  auto jsonDef = runCache(iLB.getRun().index());
515  jsonDef->outJsonDef_,
516  jsonDef->outJsonDefName_,
517  jsonDef->transferDestination_,
518  jsonDef->mergeType_);
519 
520  jsonWriter.fileAdler32_.value() = lumiWriter->get_adler32();
521  jsonWriter.accepted_.value() = lumiWriter->getAccepted();
522 
523  bool abortFlag = false;
524 
525  if (!discarded) {
526  jsonWriter.processed_.value() = fms_->getEventsProcessedForLumi(iLB.luminosityBlock(), &abortFlag);
527  } else {
528  jsonWriter.errorEvents_.value() = fms_->getEventsProcessedForLumi(iLB.luminosityBlock(), &abortFlag);
529  jsonWriter.processed_.value() = 0;
530  jsonWriter.accepted_.value() = 0;
531  edm::LogInfo("GlobalEvFOutputModule")
532  << "Output suppressed, setting error events for LS -: " << iLB.luminosityBlock();
533  }
534 
535  if (abortFlag) {
536  edm::LogInfo("GlobalEvFOutputModule") << "Abort flag has been set. Output is suppressed";
537  return;
538  }
539 
540  if (jsonWriter.processed_.value() != 0) {
541  struct stat istat;
542  std::filesystem::path openDatFilePath = lumiWriter->getFilePath();
543  stat(openDatFilePath.string().c_str(), &istat);
544  jsonWriter.filesize_ = istat.st_size;
545  std::filesystem::rename(openDatFilePath.string().c_str(),
547  jsonWriter.filelist_ = openDatFilePath.filename().string();
548  } else {
549  //remove empty file when no event processing has occurred
550  remove(lumiWriter->getFilePath().c_str());
551  jsonWriter.filesize_ = 0;
552  jsonWriter.filelist_ = "";
553  jsonWriter.fileAdler32_.value() = -1; //no files in signed long
554  }
555 
556  //produce JSON file
557  jsonWriter.jsonMonitor_->snap(iLB.luminosityBlock());
558  const std::string outputJsonNameStream =
559  edm::Service<evf::EvFDaqDirector>()->getOutputJsonFilePath(iLB.luminosityBlock(), streamLabel_);
560  jsonWriter.jsonMonitor_->outputFullJSON(outputJsonNameStream, iLB.luminosityBlock());
561  }
562 
563 } // namespace evf
564 
565 using namespace evf;
size
Write out results.
void doOutputEvent(EventMsgBuilder const &msg, bool inc)
RunIndex index() const
Definition: RunForOutput.cc:32
Definition: fillJson.h:27
std::shared_ptr< jsoncollector::FastMonitor > jsonMonitor_
jsoncollector::DataPointDefinition outJsonDef_
std::vector< BranchIDList > BranchIDLists
Definition: BranchIDList.h:19
Definition: helper.py:1
LuminosityBlockNumber_t luminosityBlock() const
std::atomic< GlobalEvFOutputEventWriter * > lastWriter_
ret
prodAgent to be discontinued
void respondToCloseInputFile(edm::FileBlock const &) final
std::unique_ptr< EventMsgBuilder > builder_
volatile std::atomic< bool > shutdown_flag
std::shared_ptr< GlobalEvFOutputJSONDef > globalBeginRun(edm::RunForOutput const &run) const final
static bool serialize(JsonSerializable *pObj, std::string &output)
edm::EDGetTokenT< edm::TriggerResults > trToken_
StreamerOutputMsgBuilders::Parameters commonParameters_
std::string to_lower(const std::string &s)
std::string const & getFilePath() const
LuminosityBlockIndex index() const
void write(const InitMsgBuilder &)
std::unique_ptr< T, impl::DeviceDeleter > unique_ptr
assert(be >=bs)
ModuleDescription const & description() const
edm::EDGetTokenT< edm::SendJobHeader::ParameterSetMap > psetToken_
void beginJob()
Definition: Breakpoints.cc:14
void globalEndRun(edm::RunForOutput const &) const final
std::shared_ptr< MetaDataCache const > metaDataCache_
ThinnedAssociationsHelper const * thinnedAssociationsHelper() const
oneapi::tbb::task_group * group() const noexcept
void updateDestination(std::string const &streamLabel)
static void fillDescription(ParameterSetDescription &desc)
void writeRun(edm::RunForOutput const &) final
void respondToOpenInputFile(edm::FileBlock const &) final
BranchIDLists const * branchIDLists() const
virtual void setName(std::string name)
RunForOutput const & getRun() const
GlobalEvFOutputEventWriter(std::string const &filePath, unsigned int ls, std::shared_ptr< MetaDataCache const > iMetaData)
jsoncollector::StringJ transferDestination_
std::atomic< unsigned long > accepted_
Trig getTriggerResults(edm::EDGetTokenT< edm::TriggerResults > const &token, edm::EventForOutput const &e) const
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:16
std::unique_ptr< SerializeDataBuffer > beginStream(edm::StreamID) const final
std::shared_ptr< GlobalEvFOutputEventWriter > globalBeginLuminosityBlock(edm::LuminosityBlockForOutput const &iLB) const final
static std::string const triggerResults
Definition: EdmProvDump.cc:47
static void writeStringToFile(std::string const &filename, std::string &content)
Definition: FileIO.cc:21
evf::FastMonitoringService * fms_
std::shared_ptr< MetaDataCache const > meta_
void globalEndLuminosityBlock(edm::LuminosityBlockForOutput const &iLB) const final
Log< level::Info, false > LogInfo
void Adler32(char const *data, size_t len, uint32_t &a, uint32_t &b)
def ls(path, rec=False)
Definition: eostools.py:349
ParameterSetID selectorConfig() const
SelectedProductsForBranchType const & keptProducts() const
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
std::vector< bool > getTriggerResults(const std::vector< unsigned int > &triggers, const edm::TriggerResults &triggerResults)
Definition: L1TCommon.cc:34
jsoncollector::StringJ transferDestination_
def load(fileName)
Definition: svgfig.py:547
void write(edm::EventForOutput const &e) final
edm::global::OutputModule< edm::RunCache< GlobalEvFOutputJSONDef >, edm::LuminosityBlockCache< evf::GlobalEvFOutputEventWriter >, edm::StreamCache< SerializeDataBuffer >, edm::WatchInputFiles, edm::ExternalWork > GlobalEvFOutputModuleType
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
void add(std::string const &label, ParameterSetDescription const &psetDescription)
tuple msg
Definition: mps_check.py:286
std::map< ParameterSetID, ParameterSetBlob > ParameterSetMap
std::vector< AlignmentParameters * > Parameters
Definition: Utilities.h:32
HLT enums.
void acquire(edm::StreamID, edm::EventForOutput const &, edm::WaitingTaskWithArenaHolder) const final
edm::detail::TriggerResultsBasedEventSelector::handle_t Trig
void doOutputEventAsync(std::unique_ptr< EventMsgBuilder > msg, edm::WaitingTaskHolder iHolder)
std::unique_ptr< const StreamerOutputMsgBuilders > msgBuilders_
void writeLuminosityBlock(edm::LuminosityBlockForOutput const &) final
unsigned int getEventsProcessedForLumi(unsigned int lumi, bool *abortFlag=nullptr)
GlobalEvFOutputModule(edm::ParameterSet const &ps)
edm::propagate_const< std::unique_ptr< StreamerOutputFile > > stream_writer_events_
const ModuleDescription & moduleDescription() const
Log< level::Warning, false > LogWarning
unsigned int uint32
Definition: MsgTools.h:14
tmp
align.sh
Definition: createJobs.py:716
void setMetaCache(std::shared_ptr< MetaDataCache const > iMetaData)
std::string const & moduleLabel() const
static void fillDescription(ParameterSetDescription &desc, std::vector< std::string > const &iDefaultOutputCommands=ProductSelectorRules::defaultSelectionStrings())
SerializeDataBuffer buffer_
GlobalEvFOutputJSONWriter(std::string const &streamLabel, jsoncollector::DataPointDefinition const &, std::string const &outJsonDefName, jsoncollector::StringJ const &transferDestination, jsoncollector::StringJ const &mergeType)
def move(src, dest)
Definition: eostools.py:511
jsoncollector::StringJ mergeType_
MetaDataCache(StreamerOutputMsgBuilders const &builders, edm::BranchIDLists const &branchLists, edm::ThinnedAssociationsHelper const helper)
#define LogDebug(id)