CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Private Member Functions | Private Attributes
SiStripCommissioningSource Class Reference

#include <SiStripCommissioningSource.h>

Inheritance diagram for SiStripCommissioningSource:
edm::EDAnalyzer edm::EDConsumerBase

Public Types

typedef dqm::legacy::DQMStore DQMStore
 
typedef dqm::legacy::MonitorElement MonitorElement
 
typedef std::map< unsigned int, CommissioningTask * > TaskMap
 
typedef std::vector< CommissioningTask * > VecOfTasks
 
typedef std::vector< VecOfTasksVecOfVecOfTasks
 
- Public Types inherited from edm::EDAnalyzer
typedef EDAnalyzer ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 

Public Member Functions

void analyze (const edm::Event &, const edm::EventSetup &) override
 
void beginRun (edm::Run const &, const edm::EventSetup &) override
 
void endJob () override
 
 SiStripCommissioningSource (const edm::ParameterSet &)
 
 ~SiStripCommissioningSource () override
 
- Public Member Functions inherited from edm::EDAnalyzer
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzer ()
 
SerialTaskQueueglobalLuminosityBlocksQueue ()
 
SerialTaskQueueglobalRunsQueue ()
 
ModuleDescription const & moduleDescription () const
 
std::string workerType () const
 
 ~EDAnalyzer () override
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
void convertCurrentProcessAlias (std::string const &processName)
 Convert "@currentProcess" in InputTag process names to the actual current process name. More...
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase &&)=default
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
ESProxyIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
ProductResolverIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
std::vector< ProductResolverIndexAndSkipBit > const & itemsToGetFrom (BranchType iType) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProxyIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Private Member Functions

void clearCablingTasks ()
 
void clearTasks ()
 
void createCablingTasks ()
 
void createRunNumber ()
 
void createTask (const SiStripEventSummary *const, const edm::EventSetup &)
 
void createTasks (sistrip::RunType, const edm::EventSetup &)
 
void directory (std::stringstream &, uint32_t run_number=0)
 
DQMStore *const dqm (std::string method="") const
 
void fillCablingHistos (const SiStripEventSummary *const, const edm::DetSetVector< SiStripRawDigi > &)
 
void fillHistos (const SiStripEventSummary *const, const edm::DetSetVector< SiStripRawDigi > &, const edm::DetSetVector< SiStripRawDigi > &=edm::DetSetVector< SiStripRawDigi >(), const edmNew::DetSetVector< SiStripCluster > &=edmNew::DetSetVector< SiStripCluster >())
 
void remove ()
 
 SiStripCommissioningSource ()=delete
 

Private Attributes

std::string base_
 
bool cablingTask_
 
TaskMap cablingTasks_
 
edm::EDGetTokenT< edmNew::DetSetVector< SiStripCluster > > clustersToken_
 
edm::EDGetTokenT< edm::DetSetVector< SiStripRawDigi > > digiFineDelaySelectionToken_
 
edm::EDGetTokenT< edm::DetSetVector< SiStripRawDigi > > digiReorderedToken_
 
edm::EDGetTokenT< edm::DetSetVector< SiStripRawDigi > > digiScopeModeToken_
 
edm::EDGetTokenT< edm::DetSetVector< SiStripRawDigi > > digiVirginRawToken_
 
DQMStoredqm_
 
SiStripFecCablingfecCabling_
 
SiStripFedCablingfedCabling_
 
std::string filename_
 
std::string inputClusterLabel_
 
std::string inputModuleLabel_
 
std::string inputModuleLabelAlt_
 
std::string inputModuleLabelSummary_
 
edm::EDGetTokenT< SiStripEventSummaryinputModuleSummaryToken_
 
bool isSpy_
 
edm::ParameterSet parameters_
 
std::string partitionName_
 
uint32_t run_
 
sistrip::RunType task_
 
std::string taskConfigurable_
 
VecOfVecOfTasks tasks_
 
bool tasksExist_
 
int32_t time_
 
int updateFreq_
 
std::string view_
 

Additional Inherited Members

- Static Public Member Functions inherited from edm::EDAnalyzer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &)
 
static bool wantsGlobalLuminosityBlocks ()
 
static bool wantsGlobalRuns ()
 
static bool wantsStreamLuminosityBlocks ()
 
static bool wantsStreamRuns ()
 
- Protected Member Functions inherited from edm::EDConsumerBase
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes ()
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 

Detailed Description

Definition at line 29 of file SiStripCommissioningSource.h.

Member Typedef Documentation

◆ DQMStore

Definition at line 35 of file SiStripCommissioningSource.h.

◆ MonitorElement

Definition at line 36 of file SiStripCommissioningSource.h.

◆ TaskMap

typedef std::map<unsigned int, CommissioningTask*> SiStripCommissioningSource::TaskMap

Map of task objects, identified through FedChanelId

Definition at line 32 of file SiStripCommissioningSource.h.

◆ VecOfTasks

Definition at line 33 of file SiStripCommissioningSource.h.

◆ VecOfVecOfTasks

Definition at line 34 of file SiStripCommissioningSource.h.

Constructor & Destructor Documentation

◆ SiStripCommissioningSource() [1/2]

SiStripCommissioningSource::SiStripCommissioningSource ( const edm::ParameterSet pset)

Definition at line 54 of file SiStripCommissioningSource.cc.

55  : dqm_(nullptr),
56  fedCabling_(nullptr),
57  fecCabling_(nullptr),
58  inputModuleLabel_(pset.getParameter<std::string>("InputModuleLabel")),
59  inputModuleLabelAlt_(pset.existsAs<std::string>("InputModuleLabelAlt")
60  ? pset.getParameter<std::string>("InputModuleLabelAlt")
61  : ""),
62  inputModuleLabelSummary_(pset.getParameter<std::string>("SummaryInputModuleLabel")),
64  pset.existsAs<std::string>("InputClusterLabel") ? pset.getParameter<std::string>("InputClusterLabel") : ""),
65  filename_(pset.getUntrackedParameter<std::string>("RootFileName", sistrip::dqmSourceFileName_)),
66  run_(0),
67  partitionName_(pset.existsAs<std::string>("PartitionName") ? pset.getParameter<std::string>("PartitionName")
68  : ""),
69  time_(0),
70  isSpy_(pset.existsAs<bool>("isSpy") ? pset.getParameter<bool>("isSpy") : false),
71  taskConfigurable_(pset.getUntrackedParameter<std::string>("CommissioningTask", "UNDEFINED")),
73  tasks_(),
74  cablingTasks_(),
75  tasksExist_(false),
76  cablingTask_(false),
77  updateFreq_(pset.getUntrackedParameter<int>("HistoUpdateFreq", 1)),
78  base_(""),
79  view_(pset.getUntrackedParameter<std::string>("View", "Default")),
80  parameters_(pset) {
81  inputModuleSummaryToken_ = consumes<SiStripEventSummary>(edm::InputTag(inputModuleLabelSummary_));
82  digiVirginRawToken_ = mayConsume<edm::DetSetVector<SiStripRawDigi> >(edm::InputTag(inputModuleLabel_, "VirginRaw"));
84  mayConsume<edm::DetSetVector<SiStripRawDigi> >(edm::InputTag(inputModuleLabel_, "FineDelaySelection"));
85  digiReorderedToken_ = mayConsume<edm::DetSetVector<SiStripRawDigi> >(edm::InputTag(inputModuleLabel_, "Reordered"));
87  if (not isSpy_)
88  digiScopeModeToken_ = mayConsume<edm::DetSetVector<SiStripRawDigi> >(edm::InputTag(inputModuleLabel_, "ScopeMode"));
89  else {
91  mayConsume<edm::DetSetVector<SiStripRawDigi> >(edm::InputTag(inputModuleLabelAlt_, "ScopeRawDigis"));
92  clustersToken_ = mayConsume<edmNew::DetSetVector<SiStripCluster> >(edm::InputTag(inputClusterLabel_));
93  }
95  LogTrace(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
96  << " Constructing object...";
97  tasks_.clear();
98  tasks_.resize(1024, VecOfTasks(96, static_cast<CommissioningTask*>(nullptr)));
99 }

References clustersToken_, digiFineDelaySelectionToken_, digiReorderedToken_, digiScopeModeToken_, digiVirginRawToken_, inputClusterLabel_, inputModuleLabel_, inputModuleLabelAlt_, inputModuleLabelSummary_, inputModuleSummaryToken_, HLT_2018_cff::InputTag, isSpy_, LogTrace, sistrip::mlDqmSource_, and tasks_.

◆ ~SiStripCommissioningSource()

SiStripCommissioningSource::~SiStripCommissioningSource ( )
override

Definition at line 103 of file SiStripCommissioningSource.cc.

103  {
104  LogTrace(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
105  << " Destructing object...";
106 }

References LogTrace, and sistrip::mlDqmSource_.

◆ SiStripCommissioningSource() [2/2]

SiStripCommissioningSource::SiStripCommissioningSource ( )
privatedelete

Private default constructor.

Member Function Documentation

◆ analyze()

void SiStripCommissioningSource::analyze ( const edm::Event event,
const edm::EventSetup setup 
)
overridevirtual

Implements edm::EDAnalyzer.

Definition at line 283 of file SiStripCommissioningSource.cc.

283  {
284  // Retrieve commissioning information from "event summary"
286  // event.getByLabel( inputModuleLabelSummary_, summary );
287  event.getByToken(inputModuleSummaryToken_, summary);
288 
289  // Check if EventSummary has info attached
290  if ((summary->runType() == sistrip::UNDEFINED_RUN_TYPE || summary->runType() == sistrip::UNKNOWN_RUN_TYPE) &&
291  summary->nullParams()) {
292  edm::LogWarning(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
293  << " Unknown/undefined RunType and NULL parameter values!"
294  << " It may be that the 'trigger FED' object was not found!";
295  }
296 
297  // Check if need to rebuild FED/FEC cabling objects for connection run
298  //cablingForConnectionRun( summary->runType() ); //@@ do not use!
299 
300  // Extract run number and forward to client
301  if (event.id().run() != run_) {
302  run_ = event.id().run();
303  createRunNumber();
304  }
305 
306  // Coarse event rate counter
307  if (!(event.id().event() % updateFreq_)) {
308  std::stringstream ss;
309  ss << "[SiStripCommissioningSource::" << __func__ << "]"
310  << " The last " << updateFreq_ << " events were processed at a rate of ";
311  if (time(nullptr) == time_) {
312  ss << ">" << updateFreq_ << " Hz";
313  } else {
314  ss << (updateFreq_ / (time(nullptr) - time_)) << " Hz";
315  }
316  edm::LogVerbatim(mlDqmSource_) << ss.str();
317  time_ = time(nullptr);
318  }
319 
320  // Create commissioning task objects
321  if (!tasksExist_) {
322  createTask(summary.product(), setup);
323  } else {
324  for (auto& v : tasks_) {
325  for (auto& t : v) {
326  t->eventSetup(&setup);
327  }
328  }
329  }
330 
331  // Retrieve raw digis with mode appropriate to task
335 
336  if (task_ == sistrip::DAQ_SCOPE_MODE) { // scop-mode runs
337  if (not isSpy_ and
338  summary->fedReadoutMode() == FED_VIRGIN_RAW) { // if the readout is virgin raw just take the VR digis
339  event.getByToken(digiVirginRawToken_, raw);
340  } else if (not isSpy_ and summary->fedReadoutMode() == FED_SCOPE_MODE) {
341  event.getByToken(digiScopeModeToken_, raw);
342  } else if (isSpy_) { // spy case take both re-ordered and scope mode
343  event.getByToken(digiScopeModeToken_, rawAlt);
344  event.getByToken(digiReorderedToken_, raw);
345  if (not inputClusterLabel_.empty())
346  event.getByToken(clustersToken_, cluster);
347  } else {
348  std::stringstream ss;
349  ss << "[SiStripCommissioningSource::" << __func__ << "]"
350  << " Requested DAQ_SCOPE_MODE but unknown FED"
351  << " readout mode retrieved from SiStripEventSummary: "
352  << SiStripEnumsAndStrings::fedReadoutMode(summary->fedReadoutMode());
353  edm::LogWarning(mlDqmSource_) << ss.str();
354  }
357  event.getByToken(digiScopeModeToken_, raw);
362  event.getByToken(digiVirginRawToken_, raw);
363  } else if (task_ == sistrip::APV_LATENCY || task_ == sistrip::FINE_DELAY) {
364  event.getByToken(digiFineDelaySelectionToken_, raw);
365  } else {
366  std::stringstream ss;
367  ss << "[SiStripCommissioningSource::" << __func__ << "]"
368  << " Unknown CommissioningTask: " << SiStripEnumsAndStrings::runType(task_)
369  << " Unable to establish FED readout mode and retrieve digi container!"
370  << " Check if SiStripEventSummary object is found/present in Event";
371  edm::LogWarning(mlDqmSource_) << ss.str();
372  return;
373  }
374 
375  // Check for NULL pointer to digi container
376  if (not raw.isValid()) {
377  std::stringstream ss;
378  ss << "[SiStripCommissioningSource::" << __func__ << "]" << std::endl
379  << " NULL pointer to DetSetVector!" << std::endl
380  << " Unable to fill histograms!";
381  edm::LogWarning(mlDqmSource_) << ss.str();
382  return;
383  }
384 
385  if (isSpy_ and not inputModuleLabelAlt_.empty() and not rawAlt.isValid()) {
386  std::stringstream ss;
387  ss << "[SiStripCommissioningSource::" << __func__ << "]" << std::endl
388  << " NULL pointer to DetSetVector!" << std::endl
389  << " Unable to fill histograms!";
390  edm::LogWarning(mlDqmSource_) << ss.str();
391  return;
392  }
393 
394  if (isSpy_ and not inputClusterLabel_.empty() and not cluster.isValid()) {
395  std::stringstream ss;
396  ss << "[SiStripCommissioningSource::" << __func__ << "]" << std::endl
397  << " NULL pointer to DetSetVector!" << std::endl
398  << " Unable to fill histograms!";
399  edm::LogWarning(mlDqmSource_) << ss.str();
400  return;
401  }
402 
403  if (!cablingTask_) {
404  fillHistos(summary.product(), *raw, *rawAlt, *cluster);
405  } else {
406  fillCablingHistos(summary.product(), *raw);
407  }
408 }

References sistrip::APV_LATENCY, sistrip::APV_TIMING, cablingTask_, sistrip::CALIBRATION, sistrip::CALIBRATION_DECO, sistrip::CALIBRATION_SCAN, sistrip::CALIBRATION_SCAN_DECO, clustersToken_, createRunNumber(), createTask(), sistrip::DAQ_SCOPE_MODE, digiFineDelaySelectionToken_, digiReorderedToken_, digiScopeModeToken_, digiVirginRawToken_, sistrip::FAST_CABLING, sistrip::FED_CABLING, sistrip::FED_SCOPE_MODE, sistrip::FED_TIMING, sistrip::FED_VIRGIN_RAW, SiStripEnumsAndStrings::fedReadoutMode(), fillCablingHistos(), fillHistos(), sistrip::FINE_DELAY, inputClusterLabel_, inputModuleLabelAlt_, inputModuleSummaryToken_, isSpy_, edm::HandleBase::isValid(), sistrip::mlDqmSource_, sistrip::NOISE, sistrip::OPTO_SCAN, sistrip::PEDESTALS, sistrip::PEDS_FULL_NOISE, sistrip::PEDS_ONLY, run_, SiStripEnumsAndStrings::runType(), singleTopDQM_cfi::setup, contentValuesCheck::ss, edmLumisInFiles::summary, OrderedSet::t, task_, tasks_, tasksExist_, ntuplemaker::time, time_, sistrip::UNDEFINED_RUN_TYPE, sistrip::UNKNOWN_RUN_TYPE, updateFreq_, findQualityFiles::v, and sistrip::VPSP_SCAN.

◆ beginRun()

void SiStripCommissioningSource::beginRun ( edm::Run const &  run,
const edm::EventSetup setup 
)
overridevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 130 of file SiStripCommissioningSource.cc.

130  {
131  LogTrace(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
132  << " Configuring..." << std::endl;
133 
134  // ---------- DQM back-end interface ----------
135 
136  dqm_ = edm::Service<DQMStore>().operator->();
137  edm::LogInfo(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
138  << " DQMStore service: " << dqm_;
139  dqm(__func__);
140 
141  // ---------- Base directory ----------
142 
143  std::stringstream dir("");
144  base_ = dir.str();
145 
146  // ---------- FED and FEC cabling ----------
147 
149  setup.get<SiStripFedCablingRcd>().get(fed_cabling);
150  fedCabling_ = const_cast<SiStripFedCabling*>(fed_cabling.product());
151  LogDebug(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
152  << "Initialized FED cabling. Number of FEDs is " << fedCabling_->fedIds().size();
153  fecCabling_ = new SiStripFecCabling(*fed_cabling);
154  if (fecCabling_->crates().empty()) {
155  std::stringstream ss;
156  ss << "[SiStripCommissioningSource::" << __func__ << "]"
157  << " Empty std::vector returned by FEC cabling object!"
158  << " Check if database connection failed...";
159  edm::LogWarning(mlDqmSource_) << ss.str();
160  }
161 
162  // ---------- Reset ----------
163 
164  tasksExist_ = false;
166  cablingTask_ = false;
167 
168  remove();
169 
171  clearTasks();
172 }

References base_, cablingTask_, clearCablingTasks(), clearTasks(), SiStripFecCabling::crates(), DeadROC_duringRun::dir, dqm(), dqm_, fecCabling_, fedCabling_, SiStripFedCabling::fedIds(), get, LogDebug, LogTrace, sistrip::mlDqmSource_, edm::ESHandle< T >::product(), remove(), singleTopDQM_cfi::setup, contentValuesCheck::ss, task_, tasksExist_, and sistrip::UNDEFINED_RUN_TYPE.

◆ clearCablingTasks()

void SiStripCommissioningSource::clearCablingTasks ( )
private

Definition at line 1044 of file SiStripCommissioningSource.cc.

1044  {
1045  if (cablingTasks_.empty()) {
1046  return;
1047  }
1048  for (TaskMap::iterator itask = cablingTasks_.begin(); itask != cablingTasks_.end(); itask++) {
1049  if (itask->second) {
1050  delete itask->second;
1051  }
1052  }
1053  cablingTasks_.clear();
1054 }

References cablingTasks_.

Referenced by beginRun().

◆ clearTasks()

void SiStripCommissioningSource::clearTasks ( )
private

Definition at line 1058 of file SiStripCommissioningSource.cc.

1058  {
1059  if (tasks_.empty()) {
1060  return;
1061  }
1062  VecOfVecOfTasks::iterator ifed = tasks_.begin();
1063  for (; ifed != tasks_.end(); ifed++) {
1064  VecOfTasks::iterator ichan = ifed->begin();
1065  for (; ichan != ifed->end(); ichan++) {
1066  if (*ichan) {
1067  delete *ichan;
1068  *ichan = 0;
1069  }
1070  }
1071  ifed->resize(96, nullptr);
1072  }
1073  tasks_.resize(1024);
1074 }

References tasks_.

Referenced by beginRun().

◆ createCablingTasks()

void SiStripCommissioningSource::createCablingTasks ( )
private

Definition at line 771 of file SiStripCommissioningSource.cc.

771  {
772  // Iterate through FEC cabling and create commissioning task objects
773  uint16_t booked = 0;
774  for (std::vector<SiStripFecCrate>::const_iterator icrate = fecCabling_->crates().begin();
775  icrate != fecCabling_->crates().end();
776  icrate++) {
777  for (std::vector<SiStripFec>::const_iterator ifec = icrate->fecs().begin(); ifec != icrate->fecs().end(); ifec++) {
778  for (std::vector<SiStripRing>::const_iterator iring = ifec->rings().begin(); iring != ifec->rings().end();
779  iring++) {
780  for (std::vector<SiStripCcu>::const_iterator iccu = iring->ccus().begin(); iccu != iring->ccus().end();
781  iccu++) {
782  for (std::vector<SiStripModule>::const_iterator imodule = iccu->modules().begin();
783  imodule != iccu->modules().end();
784  imodule++) {
785  // Build FEC key
787  icrate->fecCrate(), ifec->fecSlot(), iring->fecRing(), iccu->ccuAddr(), imodule->ccuChan());
788 
789  // Check if FEC key is invalid
790  if (!path.isValid()) {
791  continue;
792  }
793 
794  // Set working directory prior to booking histograms
795  std::string dir = base_ + path.path();
797 
798  // Iterate through all APV pairs for this module
799  for (uint16_t ipair = 0; ipair < imodule->nApvPairs(); ipair++) {
800  // Retrieve active APV devices
801  SiStripModule::PairOfU16 apvs = imodule->activeApvPair(imodule->lldChannel(ipair));
802 
803  // Create connection object to hold all relevant info
804  FedChannelConnection conn(icrate->fecCrate(),
805  ifec->fecSlot(),
806  iring->fecRing(),
807  iccu->ccuAddr(),
808  imodule->ccuChan(),
809  apvs.first,
810  apvs.second,
811  imodule->dcuId(),
812  imodule->detId(),
813  imodule->nApvPairs());
814 
815  // Define key encoding control path
816  uint32_t key = SiStripFecKey(icrate->fecCrate(),
817  ifec->fecSlot(),
818  iring->fecRing(),
819  iccu->ccuAddr(),
820  imodule->ccuChan(),
821  imodule->lldChannel(ipair))
822  .key();
823 
824  // Check key is non zero
825  if (!key) {
826  edm::LogWarning(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
827  << " Unexpected NULL value for FEC key!";
828  continue;
829  }
830 
831  // Create cabling task objects if not already existing
832  if (cablingTasks_.find(key) == cablingTasks_.end()) {
833  if (task_ == sistrip::FED_CABLING) {
835  } else if (task_ == sistrip::UNDEFINED_RUN_TYPE) {
836  edm::LogWarning(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
837  << " Undefined CommissioningTask"
838  << " Unable to create FedCablingTask object!";
839  } else if (task_ == sistrip::UNKNOWN_RUN_TYPE) {
840  edm::LogWarning(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
841  << " Unknown CommissioningTask"
842  << " Unable to create FedCablingTask object!";
843  } else {
845  << "[SiStripCommissioningSource::" << __func__ << "]"
846  << " Unexpected CommissioningTask: " << SiStripEnumsAndStrings::runType(task_)
847  << " Unable to create FedCablingTask object!";
848  }
849 
850  // Check if key is found and, if so, book histos and set update freq
851  if (cablingTasks_.find(key) != cablingTasks_.end()) {
852  if (cablingTasks_[key]) {
853  cablingTasks_[key]->bookHistograms();
854  cablingTasks_[key]->updateFreq(1); //@@ hardwired to update every event!!!
855  booked++;
856  std::stringstream ss;
857  ss << "[SiStripCommissioningSource::" << __func__ << "]"
858  << " Booking histograms for '" << cablingTasks_[key]->myName() << "' object with key 0x"
859  << std::hex << std::setfill('0') << std::setw(8) << key << std::dec << " in directory \"" << dir
860  << "\"";
861  LogTrace(mlDqmSource_) << ss.str();
862  } else {
863  std::stringstream ss;
864  ss << "[SiStripCommissioningSource::" << __func__ << "]"
865  << " NULL pointer to CommissioningTask for key 0x" << std::hex << std::setfill('0')
866  << std::setw(8) << key << std::dec << " in directory " << dir << " Unable to book histograms!";
867  edm::LogWarning(mlDqmSource_) << ss.str();
868  }
869  } else {
870  std::stringstream ss;
871  ss << "[SiStripCommissioningSource::" << __func__ << "]"
872  << " Unable to find CommissioningTask for key 0x" << std::hex << std::setfill('0') << std::setw(8)
873  << key << std::dec << " in directory " << dir << " Unable to book histograms!";
874  edm::LogWarning(mlDqmSource_) << ss.str();
875  }
876 
877  } else {
878  std::stringstream ss;
879  ss << "[SiStripCommissioningSource::" << __func__ << "]"
880  << " CommissioningTask object already exists for key 0x" << std::hex << std::setfill('0')
881  << std::setw(8) << key << std::dec << " in directory " << dir
882  << " Unable to create FedCablingTask object!";
883  edm::LogWarning(mlDqmSource_) << ss.str();
884  }
885 
886  } // loop through apv pairs
887  } // loop through modules
888  } // loop through ccus
889  } // loop through rings
890  } // loop through fecs
891  } // loop through crates
892 
893  edm::LogVerbatim(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
894  << " Created " << booked << " CommissioningTask objects and booked histograms";
895 }

References base_, cablingTasks_, SiStripCommissioningClient_cfg::conn, SiStripFecCabling::crates(), TauDecayModes::dec, DeadROC_duringRun::dir, dqm(), fecCabling_, sistrip::FED_CABLING, crabWrapper::key, LogTrace, sistrip::mlDqmSource_, castor_dqm_sourceclient_file_cfg::path, SiStripEnumsAndStrings::runType(), dqm::implementation::DQMStore::setCurrentFolder(), contentValuesCheck::ss, AlCaHLTBitMon_QueryRunRegistry::string, task_, sistrip::UNDEFINED_RUN_TYPE, and sistrip::UNKNOWN_RUN_TYPE.

Referenced by createTask().

◆ createRunNumber()

void SiStripCommissioningSource::createRunNumber ( )
private

Definition at line 674 of file SiStripCommissioningSource.cc.

674  {
675  // Set commissioning task to default ("undefined") value
676  if (!run_) {
677  edm::LogWarning(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
678  << " NULL run number!";
679  return;
680  }
681 
682  // Create MonitorElement that identifies run number
684  std::stringstream run;
685  run << run_;
687 }

References base_, dqm::implementation::IBooker::bookString(), dqm(), sistrip::mlDqmSource_, sistrip::root_, writedatasetfile::run, run_, sistrip::runNumber_, sistrip::sep_, dqm::implementation::DQMStore::setCurrentFolder(), and AlCaHLTBitMon_QueryRunRegistry::string.

Referenced by analyze().

◆ createTask()

void SiStripCommissioningSource::createTask ( const SiStripEventSummary * const  summary,
const edm::EventSetup setup 
)
private

Definition at line 691 of file SiStripCommissioningSource.cc.

691  {
692  // Set commissioning task to default ("undefined") value
694 
695  // Retrieve commissioning task from EventSummary
696  if (summary) {
697  task_ = summary->runType();
698  std::stringstream ss;
699  ss << "[SiStripCommissioningSource::" << __func__ << "]"
700  << " Identified CommissioningTask from EventSummary to be \"" << SiStripEnumsAndStrings::runType(task_) << "\"";
701  LogTrace(mlDqmSource_) << ss.str();
702  } else {
704  std::stringstream ss;
705  ss << "[SiStripCommissioningSource::" << __func__ << "]"
706  << " NULL pointer to SiStripEventSummary!"
707  << " Check SiStripEventSummary is found/present in Event";
708  edm::LogWarning(mlDqmSource_) << ss.str();
709  }
710 
711  // Override task with ParameterSet configurable (if defined)
713  if (configurable != sistrip::UNDEFINED_RUN_TYPE && configurable != sistrip::UNKNOWN_RUN_TYPE) {
714  std::stringstream ss;
715  ss << "[SiStripCommissioningSource::" << __func__ << "]"
716  << " Overriding CommissioningTask from EventSummary (\"" << SiStripEnumsAndStrings::runType(task_)
717  << "\") with value retrieved from .cfg file (\"" << SiStripEnumsAndStrings::runType(configurable) << "\")!";
718  LogTrace(mlDqmSource_) << ss.str();
719  task_ = configurable;
720  }
721 
722  // Create ME (std::string) that identifies commissioning task
725  dqm()->bookString(std::string(sistrip::taskId_) + sistrip::sep_ + task_str, task_str);
726 
727  // Check commissioning task is known / defined
729  std::stringstream ss;
730  ss << "[SiStripCommissioningSource::" << __func__ << "]"
731  << " Unexpected CommissioningTask found (" << static_cast<uint16_t>(task_) << ") \""
733  << " Unexpected value found in SiStripEventSummary and/or cfg file"
734  << " If SiStripEventSummary is not present in Event,"
735  << " check 'CommissioningTask' configurable in cfg file";
736  edm::LogWarning(mlDqmSource_) << ss.str();
737  return;
738  } else {
739  std::stringstream ss;
740  ss << "[SiStripCommissioningSource::" << __func__ << "]"
741  << " Identified CommissioningTask to be \"" << SiStripEnumsAndStrings::runType(task_) << "\"";
742  LogTrace(mlDqmSource_) << ss.str();
743  }
744 
745  // Check if commissioning task is FED cabling
746  if (task_ == sistrip::FED_CABLING) {
747  cablingTask_ = true;
748  } else {
749  cablingTask_ = false;
750  }
751 
752  std::stringstream ss;
753  ss << "[SiStripCommissioningSource::" << __func__ << "]"
754  << " CommissioningTask: " << SiStripEnumsAndStrings::runType(summary->runType());
755  LogTrace(mlDqmSource_) << ss.str();
756 
757  edm::LogVerbatim(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
758  << " Creating CommissioningTask objects and booking histograms...";
759  if (cablingTask_) {
761  } else {
763  }
764  edm::LogVerbatim(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
765  << " Finished booking histograms!";
766  tasksExist_ = true;
767 }

References base_, dqm::implementation::IBooker::bookString(), cablingTask_, createCablingTasks(), createTasks(), dqm(), sistrip::FED_CABLING, LogTrace, sistrip::mlDqmSource_, sistrip::root_, SiStripEnumsAndStrings::runType(), sistrip::sep_, dqm::implementation::DQMStore::setCurrentFolder(), singleTopDQM_cfi::setup, contentValuesCheck::ss, AlCaHLTBitMon_QueryRunRegistry::string, edmLumisInFiles::summary, task_, taskConfigurable_, sistrip::taskId_, tasksExist_, sistrip::UNDEFINED_RUN_TYPE, and sistrip::UNKNOWN_RUN_TYPE.

Referenced by analyze().

◆ createTasks()

void SiStripCommissioningSource::createTasks ( sistrip::RunType  run_type,
const edm::EventSetup setup 
)
private

Definition at line 899 of file SiStripCommissioningSource.cc.

899  {
900  uint16_t booked = 0;
901 
902  // latency has partition-level histos, so treat separately
903  if (task_ == sistrip::APV_LATENCY) {
904  for (uint16_t partition = 0; partition < 4; ++partition) {
905  // make a task for every partition; tracker-wide histo is shared
906  tasks_[0][partition] = new LatencyTask(
907  dqm(),
910  tasks_[0][partition]->eventSetup(&setup);
911  tasks_[0][partition]->bookHistograms();
912  tasks_[0][partition]->updateFreq(updateFreq_);
913  booked++;
914  }
915 
916  // fine-delay has 1 histo for the whole tracker, so treat separately
917  } else if (task_ == sistrip::FINE_DELAY) {
918  tasks_[0][0] = new FineDelayTask(dqm(), FedChannelConnection());
919  tasks_[0][0]->eventSetup(&setup);
920  tasks_[0][0]->bookHistograms();
921  tasks_[0][0]->updateFreq(updateFreq_);
922  booked++;
923 
924  } else { // now do any other task
925 
926  // Iterate through FED ids and channels
927  for (auto ifed = fedCabling_->fedIds().begin(); ifed != fedCabling_->fedIds().end(); ++ifed) {
928  // Iterate through connected FED channels
929  auto conns = fedCabling_->fedConnections(*ifed);
930  for (auto iconn = conns.begin(); iconn != conns.end(); ++iconn) {
931  // Create FEC key
932  SiStripFecKey fec_key(
933  iconn->fecCrate(), iconn->fecSlot(), iconn->fecRing(), iconn->ccuAddr(), iconn->ccuChan());
934  // Create FED key and check if non-zero
935  SiStripFedKey fed_key(
936  iconn->fedId(), SiStripFedKey::feUnit(iconn->fedCh()), SiStripFedKey::feChan(iconn->fedCh()));
937  if (!iconn->isConnected()) {
938  continue;
939  }
940 
941  // define the view in which to work and paths for histograms
942  // currently FecView (control view) and FedView (readout view)
943  // DetView (detector view) implementation has started
944  // Set working directory prior to booking histograms
945  std::stringstream dir;
946  dir << base_;
947  if (view_ == "Default") { // default
948  if (run_type == sistrip::FAST_CABLING) {
949  dir << fed_key.path(); // cabling in fed view
950  } else {
951  dir << fec_key.path(); // all other runs in control view
952  }
953  } else if (view_ == "FecView") {
954  dir << fec_key.path();
955  } else if (view_ == "FedView") {
956  dir << fed_key.path();
957  } else if (view_ == "DetView") {
958  // currently just by detid from the connection, which is empty...
960  } else {
961  edm::LogWarning(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
962  << " Invalid view " << view_ << std::endl
963  << " Histograms will end up all in the top directory.";
964  } // end if view_ == ...
965  dqm()->setCurrentFolder(dir.str());
966 
967  // Create commissioning task objects
968  if (!tasks_[iconn->fedId()][iconn->fedCh()]) {
969  if (task_ == sistrip::FAST_CABLING) {
970  tasks_[iconn->fedId()][iconn->fedCh()] = new FastFedCablingTask(dqm(), *iconn);
971  } else if (task_ == sistrip::APV_TIMING) {
972  tasks_[iconn->fedId()][iconn->fedCh()] = new ApvTimingTask(dqm(), *iconn);
973  } else if (task_ == sistrip::FED_TIMING) {
974  tasks_[iconn->fedId()][iconn->fedCh()] = new FedTimingTask(dqm(), *iconn);
975  } else if (task_ == sistrip::OPTO_SCAN) {
976  tasks_[iconn->fedId()][iconn->fedCh()] = new OptoScanTask(dqm(), *iconn);
977  } else if (task_ == sistrip::VPSP_SCAN) {
978  tasks_[iconn->fedId()][iconn->fedCh()] = new VpspScanTask(dqm(), *iconn);
979  } else if (task_ == sistrip::PEDESTALS) {
980  tasks_[iconn->fedId()][iconn->fedCh()] = new PedestalsTask(dqm(), *iconn);
981  } else if (task_ == sistrip::PEDS_ONLY) {
982  tasks_[iconn->fedId()][iconn->fedCh()] = new PedsOnlyTask(dqm(), *iconn);
983  } else if (task_ == sistrip::NOISE) {
984  tasks_[iconn->fedId()][iconn->fedCh()] = new NoiseTask(dqm(), *iconn);
985  } else if (task_ == sistrip::PEDS_FULL_NOISE) {
986  tasks_[iconn->fedId()][iconn->fedCh()] = new PedsFullNoiseTask(dqm(), *iconn, parameters_);
987  } else if (task_ == sistrip::DAQ_SCOPE_MODE) {
988  tasks_[iconn->fedId()][iconn->fedCh()] = new DaqScopeModeTask(dqm(), *iconn, parameters_);
990  tasks_[iconn->fedId()][iconn->fedCh()] =
991  new CalibrationScanTask(dqm(), *iconn, task_, filename_.c_str(), run_, setup);
993  tasks_[iconn->fedId()][iconn->fedCh()] =
994  new CalibrationTask(dqm(), *iconn, task_, filename_.c_str(), run_, setup);
995  } else if (task_ == sistrip::UNDEFINED_RUN_TYPE) {
996  edm::LogWarning(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
997  << " Undefined CommissioningTask"
998  << " Unable to create CommissioningTask object!";
999  } else {
1000  edm::LogWarning(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
1001  << " Unknown CommissioningTask"
1002  << " Unable to create CommissioningTask object!";
1003  }
1004 
1005  // Check if fed_key is found and, if so, book histos and set update freq
1006  if (tasks_[iconn->fedId()][iconn->fedCh()]) {
1007  tasks_[iconn->fedId()][iconn->fedCh()]->eventSetup(&setup);
1008 
1011  tasks_[iconn->fedId()][iconn->fedCh()]->bookHistograms();
1012  else {
1014  static_cast<CalibrationScanTask*>(tasks_[iconn->fedId()][iconn->fedCh()])->setCurrentFolder(dir.str());
1016  static_cast<CalibrationTask*>(tasks_[iconn->fedId()][iconn->fedCh()])->setCurrentFolder(dir.str());
1017  }
1018  tasks_[iconn->fedId()][iconn->fedCh()]->updateFreq(updateFreq_);
1019  booked++;
1020  } else {
1021  std::stringstream ss;
1022  ss << "[SiStripCommissioningSource::" << __func__ << "]"
1023  << " NULL pointer to CommissioningTask for key 0x" << std::hex << std::setfill('0') << std::setw(8)
1024  << fed_key.key() << std::dec << " in directory " << dir.str() << " Unable to book histograms!";
1025  edm::LogWarning(mlDqmSource_) << ss.str();
1026  }
1027  } else {
1028  std::stringstream ss;
1029  ss << "[SiStripCommissioningSource::" << __func__ << "]"
1030  << " CommissioningTask object already exists for key 0x" << std::hex << std::setfill('0') << std::setw(8)
1031  << fed_key.key() << std::dec << " in directory " << dir.str()
1032  << " Unable to create CommissioningTask object!";
1033  edm::LogWarning(mlDqmSource_) << ss.str();
1034  }
1035  } // loop over fed channels
1036  } // loop over feds
1037  } // end other tasks
1038  edm::LogVerbatim(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
1039  << " Created " << booked << " CommissioningTask objects and booked histograms";
1040 }

References sistrip::APV_LATENCY, sistrip::APV_TIMING, base_, sistrip::CALIBRATION, sistrip::CALIBRATION_DECO, sistrip::CALIBRATION_SCAN, sistrip::CALIBRATION_SCAN_DECO, sistrip::DAQ_SCOPE_MODE, TauDecayModes::dec, sistrip::detectorView_, DeadROC_duringRun::dir, sistrip::dir_, dqm(), sistrip::FAST_CABLING, SiStripFedKey::feChan(), sistrip::FED_TIMING, fedCabling_, SiStripFedCabling::fedConnections(), SiStripFedCabling::fedIds(), SiStripFedKey::feUnit(), filename_, sistrip::FINE_DELAY, sistrip::invalid_, sistrip::mlDqmSource_, sistrip::NOISE, sistrip::OPTO_SCAN, or, parameters_, sistrip::PEDESTALS, sistrip::PEDS_FULL_NOISE, sistrip::PEDS_ONLY, sistrip::root_, run_, dqm::implementation::DQMStore::setCurrentFolder(), singleTopDQM_cfi::setup, contentValuesCheck::ss, task_, tasks_, sistrip::UNDEFINED_RUN_TYPE, updateFreq_, view_, and sistrip::VPSP_SCAN.

Referenced by createTask().

◆ directory()

void SiStripCommissioningSource::directory ( std::stringstream &  dir,
uint32_t  run_number = 0 
)
private

Definition at line 1084 of file SiStripCommissioningSource.cc.

1084  {
1085  // Get details about host
1086  char hn[256];
1087  gethostname(hn, sizeof(hn));
1088  struct hostent* he;
1089  he = gethostbyname(hn);
1090 
1091  // Extract host name and ip
1092  std::string host_name;
1093  std::string host_ip;
1094  if (he) {
1095  host_name = std::string(he->h_name);
1096  host_ip = std::string(inet_ntoa(*(struct in_addr*)(he->h_addr)));
1097  } else {
1098  host_name = "unknown.cern.ch";
1099  host_ip = "255.255.255.255";
1100  }
1101 
1102  // Reformat IP address
1104  std::stringstream ip;
1105  //for ( uint16_t ii = 0; ii < 4; ++ii ) {
1106  while (pos != std::string::npos) {
1107  std::string::size_type tmp = host_ip.find(".", pos);
1108  if (tmp != std::string::npos) {
1109  ip << std::setw(3) << std::setfill('0') << host_ip.substr(pos, tmp - pos) << ".";
1110  pos = tmp + 1; // skip the delimiter "."
1111  } else {
1112  ip << std::setw(3) << std::setfill('0') << host_ip.substr(pos);
1113  pos = std::string::npos;
1114  }
1115  }
1116 
1117  // Get pid
1118  pid_t pid = getpid();
1119 
1120  // Construct string
1121  if (run_number) {
1122  dir << std::setw(8) << std::setfill('0') << run_number << "_";
1123  }
1124  dir << ip.str() << "_" << std::setw(5) << std::setfill('0') << pid;
1125 }

References DeadROC_duringRun::dir, hcalSimParameters_cfi::he, contentValuesCheck::run_number, AlCaHLTBitMon_QueryRunRegistry::string, and createJobs::tmp.

Referenced by endJob().

◆ dqm()

SiStripCommissioningSource::DQMStore *const SiStripCommissioningSource::dqm ( std::string  method = "") const
private

Definition at line 110 of file SiStripCommissioningSource.cc.

110  {
111  if (!dqm_) {
112  std::stringstream ss;
113  if (!method.empty()) {
114  ss << "[SiStripCommissioningSource::" << method << "]" << std::endl;
115  } else {
116  ss << "[SiStripCommissioningSource]" << std::endl;
117  }
118  ss << " NULL pointer to DQMStore";
119  edm::LogWarning(mlDqmSource_) << ss.str();
120  return nullptr;
121  } else {
122  return dqm_;
123  }
124 }

References dqm_, AlcaSiPixelAliHarvester0T_cff::method, sistrip::mlDqmSource_, and contentValuesCheck::ss.

Referenced by beginRun(), createCablingTasks(), createRunNumber(), createTask(), createTasks(), and endJob().

◆ endJob()

void SiStripCommissioningSource::endJob ( void  )
overridevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 176 of file SiStripCommissioningSource.cc.

176  {
177  LogTrace(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
178  << " Halting..." << std::endl;
179 
180  // ---------- Update histograms ----------
181  // Cabling task
182  for (TaskMap::iterator itask = cablingTasks_.begin(); itask != cablingTasks_.end(); itask++) {
183  if (itask->second) {
184  itask->second->updateHistograms();
185  }
186  }
187 
188  if (task_ == sistrip::APV_LATENCY) {
189  for (uint16_t partition = 0; partition < 4; ++partition) {
190  tasks_[0][partition]->updateHistograms();
191  }
192  } else if (task_ == sistrip::FINE_DELAY) {
193  tasks_[0][0]->updateHistograms();
194  } else {
195  // All tasks except cabling
196  uint16_t fed_id = 0;
197  uint16_t fed_ch = 0;
198  auto ifed = fedCabling_->fedIds().begin();
199  for (; ifed != fedCabling_->fedIds().end(); ifed++) {
200  auto conns = fedCabling_->fedConnections(*ifed);
201  for (auto iconn = conns.begin(); iconn != conns.end(); iconn++) {
202  if (!iconn->isConnected()) {
203  continue;
204  }
205  fed_id = iconn->fedId();
206  fed_ch = iconn->fedCh();
207  if (tasks_[fed_id][fed_ch]) {
208  tasks_[fed_id][fed_ch]->updateHistograms();
209  delete tasks_[fed_id][fed_ch];
210  }
211  }
212  }
213  }
214  // ---------- Save histos to root file ----------
215 
216  // Strip filename of ".root" extension
218  if (filename_.find(".root", 0) == std::string::npos) {
219  name = filename_;
220  } else {
221  name = filename_.substr(0, filename_.find(".root", 0));
222  }
223 
224  // Retrieve SCRATCH directory
225  std::string scratch = "SCRATCH"; //@@ remove trailing slash!!!
226  std::string dir = "";
227  if (std::getenv(scratch.c_str()) != nullptr) {
228  dir = std::getenv(scratch.c_str());
229  }
230 
231  // Add directory path
232  std::stringstream ss;
233  if (!dir.empty()) {
234  ss << dir << "/";
235  } else {
236  ss << "/tmp/";
237  }
238 
239  // Add filename with run number, host ip, pid and .root extension
240  ss << name << "_";
241  if (task_ == sistrip::DAQ_SCOPE_MODE and not partitionName_.empty()) // only for spy-runs
242  ss << partitionName_ << "_";
243 
244  directory(ss, run_);
245  ss << ".root";
246 
247  // Save file with appropriate filename (if run number is known)
248  if (!filename_.empty()) {
249  if (run_ != 0) {
250  dqm()->save(ss.str());
251  } else {
252  edm::LogWarning(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
253  << " NULL value for RunNumber! No root file saved!";
254  }
255  } else {
256  edm::LogWarning(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
257  << " NULL value for filename! No root file saved!";
258  }
259 
260  LogTrace(mlDqmSource_) << "[SiStripCommissioningSource::" << __func__ << "]"
261  << " Saved all histograms to file \"" << ss.str() << "\"";
262 
263  // ---------- Delete histograms ----------
264  // Remove all MonitorElements in "SiStrip" dir and below
265  // remove();
266 
267  // Delete histogram objects
268  // clearCablingTasks();
269  // clearTasks();
270 
271  // ---------- Delete cabling ----------
272  if (fedCabling_) {
273  fedCabling_ = nullptr;
274  }
275  if (fecCabling_) {
276  delete fecCabling_;
277  fecCabling_ = nullptr;
278  }
279 }

References sistrip::APV_LATENCY, cablingTasks_, sistrip::DAQ_SCOPE_MODE, DeadROC_duringRun::dir, directory(), dqm(), fecCabling_, fedCabling_, SiStripFedCabling::fedConnections(), SiStripFedCabling::fedIds(), filename_, sistrip::FINE_DELAY, LogTrace, sistrip::mlDqmSource_, Skims_PA_cff::name, partitionName_, run_, dqm::implementation::DQMStore::save(), contentValuesCheck::ss, AlCaHLTBitMon_QueryRunRegistry::string, task_, and tasks_.

◆ fillCablingHistos()

void SiStripCommissioningSource::fillCablingHistos ( const SiStripEventSummary * const  summary,
const edm::DetSetVector< SiStripRawDigi > &  raw 
)
private

Definition at line 412 of file SiStripCommissioningSource.cc.

413  {
414  // Create FEC key using DCU id and LLD channel from SiStripEventSummary
415  const SiStripModule& module = fecCabling_->module(summary->dcuId());
416  uint16_t lld_channel = (summary->deviceId() & 0x3) + 1;
417  SiStripFecKey key_object(module.key().fecCrate(),
418  module.key().fecSlot(),
419  module.key().fecRing(),
420  module.key().ccuAddr(),
421  module.key().ccuChan(),
422  lld_channel);
423  uint32_t fec_key = key_object.key();
424  std::stringstream sss;
425  sss << "[SiStripCommissioningSource::" << __func__ << "]"
426  << " Found DcuId 0x" << std::hex << std::setw(8) << std::setfill('0') << summary->dcuId() << std::dec
427  << " with Crate/FEC/Ring/CCU/Module/LLD: " << module.key().fecCrate() << "/" << module.key().fecSlot() << "/"
428  << module.key().fecRing() << "/" << module.key().ccuAddr() << "/" << module.key().ccuChan() << "/" << lld_channel;
429  edm::LogWarning(mlDqmSource_) << sss.str();
430 
431  //LogTrace(mlTest_) << "TEST : " << key_object;
432 
433  // Check on whether DCU id is found
434  if (key_object.isInvalid(sistrip::CCU_CHAN)) {
435  std::stringstream ss;
436  ss << "[SiStripCommissioningSource::" << __func__ << "]"
437  << " DcuId 0x" << std::hex << std::setw(8) << std::setfill('0') << summary->dcuId() << std::dec
438  << " in 'DAQ register' field not found in cabling map!"
439  << " (NULL values returned for FEC path)";
440  edm::LogWarning(mlDqmSource_) << ss.str();
441  return;
442  }
443 
444  // Iterate through FED ids
445  for (auto ifed = fedCabling_->fedIds().begin(); ifed != fedCabling_->fedIds().end(); ifed++) {
446  // Check if FedId is non-zero
447  if (*ifed == sistrip::invalid_) {
448  continue;
449  }
450 
451  // Container to hold median signal level for FED cabling task
452  std::map<uint16_t, float> medians;
453  medians.clear();
454  std::map<uint16_t, float> medians1;
455  medians1.clear();
456 
457  // Iterate through FED channels
458  for (uint16_t ichan = 0; ichan < 96; ichan++) {
459  // Retrieve digis for given FED key
460  uint32_t fed_key = ((*ifed & sistrip::invalid_) << 16) | (ichan & sistrip::invalid_);
461 
462  std::vector<edm::DetSet<SiStripRawDigi> >::const_iterator digis = raw.find(fed_key);
463  if (digis != raw.end()) {
464  if (digis->data.empty()) {
465  continue;
466  }
467 
468  Averages ave;
469  for (uint16_t idigi = 0; idigi < digis->data.size(); idigi++) {
470  ave.add(static_cast<uint32_t>(digis->data[idigi].adc()));
471  }
473  ave.calc(params);
474  medians[ichan] = params.median_; // Store median signal level
475  medians1[ichan] = digis->data[0].adc();
476  }
477 
478  } // fed channel loop
479 
480  // Calculate mean and spread on all (median) signal levels
481  Averages average;
482  std::map<uint16_t, float>::const_iterator ii = medians.begin();
483  for (; ii != medians.end(); ii++) {
484  average.add(ii->second);
485  }
487  average.calc(tmp);
488 
489  std::stringstream ss;
490  ss << "FED Averages:" << std::endl
491  << " nChans: " << medians.size() << std::endl
492  << " num/mean/median/rms/max/min: " << tmp.num_ << "/" << tmp.mean_ << "/" << tmp.median_ << "/" << tmp.rms_
493  << "/" << tmp.max_ << "/" << tmp.min_ << std::endl;
494  LogTrace(mlDqmSource_) << ss.str();
495 
496  // Calculate mean and spread on "filtered" data
497  Averages truncated;
498  std::map<uint16_t, float>::const_iterator jj = medians.begin();
499  for (; jj != medians.end(); jj++) {
500  if (jj->second < tmp.median_ + tmp.rms_) {
501  truncated.add(jj->second);
502  }
503  }
505  truncated.calc(params);
506 
507  std::stringstream ss1;
508  ss1 << "Truncated Averages:" << std::endl
509  << " nChans: " << medians.size() << std::endl
510  << " num/mean/median/rms/max/min: " << params.num_ << "/" << params.mean_ << "/" << params.median_ << "/"
511  << params.rms_ << "/" << params.max_ << "/" << params.min_ << std::endl;
512  LogTrace(mlDqmSource_) << ss1.str();
513 
514  // Identify channels with signal
515  std::stringstream ss2;
516  std::stringstream ss3;
517  std::map<uint16_t, float> channels;
518  std::map<uint16_t, float>::const_iterator ichan = medians.begin();
519  for (; ichan != medians.end(); ichan++) {
520  if (ichan->second > 200.) {
521  LogTrace(mlTest_) << "TEST FOUND SIGNAL HIGH: " << *ifed << " " << ichan->first << " " << ichan->second;
522  channels[ichan->first] = ichan->second;
523  }
524  ss2 //<< ichan->first << "/"
525  << ichan->second << " ";
526  ss3 //<< ichan->first << "/"
527  << medians1[ichan->first] << " ";
528  }
529 
530  ss2 << std::endl;
531  ss3 << std::endl;
532  LogTrace(mlTest_) << "DUMP for FED " << *ifed << ": " << ss2.str();
533  LogTrace(mlTest_) << "FIRST ADC VAL " << *ifed << ": " << ss3.str();
534 
535  // Fill cabling histograms
536  if (cablingTasks_.find(fec_key) != cablingTasks_.end()) {
537  if (!channels.empty()) {
538  cablingTasks_[fec_key]->fillHistograms(*summary, *ifed, channels);
539  SiStripFecKey path(fec_key);
540  std::stringstream ss;
541  ss << "[SiStripCommissioningSource::" << __func__ << "]"
542  << " Filled histogram for '" << cablingTasks_[fec_key]->myName() << "' object with FecKey: 0x" << std::hex
543  << std::setfill('0') << std::setw(8) << fec_key << std::dec
544  << " and Crate/FEC/ring/CCU/module/LLDchan: " << path.fecCrate() << "/" << path.fecSlot() << "/"
545  << path.fecRing() << "/" << path.ccuAddr() << "/" << path.ccuChan() << "/" << path.channel();
546  LogTrace(mlDqmSource_) << ss.str();
547  }
548  } else {
549  SiStripFecKey path(fec_key);
550  std::stringstream ss;
551  ss << "[SiStripCommissioningSource::" << __func__ << "]"
552  << " Unable to find CommissioningTask object with FecKey: 0x" << std::hex << std::setfill('0') << std::setw(8)
553  << fec_key << std::dec << " and Crate/FEC/ring/CCU/module/LLDchan: " << path.fecCrate() << "/"
554  << path.fecSlot() << "/" << path.fecRing() << "/" << path.ccuAddr() << "/" << path.ccuChan() << "/"
555  << path.channel();
556  edm::LogWarning(mlDqmSource_) << ss.str();
557  }
558 
559  } // fed id loop
560 }

References PDRates::average, cablingTasks_, sistrip::CCU_CHAN, ewkTauDQM_cfi::channels, TauDecayModes::dec, edm::DetSetVector< T >::end(), fecCabling_, fedCabling_, SiStripFedCabling::fedIds(), edm::DetSetVector< T >::find(), cuy::ii, sistrip::invalid_, findQualityFiles::jj, SiStripKey::key(), LogTrace, sistrip::mlDqmSource_, sistrip::mlTest_, SiStripFecCabling::module(), CalibrationSummaryClient_cfi::params, castor_dqm_sourceclient_file_cfg::path, contentValuesCheck::ss, edmLumisInFiles::summary, and createJobs::tmp.

Referenced by analyze().

◆ fillHistos()

void SiStripCommissioningSource::fillHistos ( const SiStripEventSummary * const  summary,
const edm::DetSetVector< SiStripRawDigi > &  raw,
const edm::DetSetVector< SiStripRawDigi > &  rawAlt = edm::DetSetVector<SiStripRawDigi>(),
const edmNew::DetSetVector< SiStripCluster > &  clusters = edmNew::DetSetVector<SiStripCluster>() 
)
private

Definition at line 564 of file SiStripCommissioningSource.cc.

567  {
568  // Iterate through FED ids and channels
569  std::vector<uint16_t> stripOnClusters;
570  auto ifed = fedCabling_->fedIds().begin();
571  for (; ifed != fedCabling_->fedIds().end(); ifed++) {
572  // Iterate through connected FED channels
573  auto conns = fedCabling_->fedConnections(*ifed);
574  for (auto iconn = conns.begin(); iconn != conns.end(); iconn++) {
575  if (!(iconn->fedId()) || iconn->fedId() > sistrip::valid_) {
576  continue;
577  }
578  if (!iconn->isConnected()) {
579  continue;
580  }
581 
582  // Create FED key and check if non-zero
583  // note: the key is not computed using the same formula as in commissioning histograms.
584  // beware that changes here must match changes in raw2digi and in SiStripFineDelayHit
585  uint32_t fed_key = ((iconn->fedId() & sistrip::invalid_) << 16) | (iconn->fedCh() & sistrip::invalid_);
586  // Retrieve digis for given FED key and check if found
587  std::vector<edm::DetSet<SiStripRawDigi> >::const_iterator digis = raw.find(fed_key);
588 
589  // only for spy data-taking --> tick measurement
590  std::vector<edm::DetSet<SiStripRawDigi> >::const_iterator digisAlt;
591  if (not rawAlt.empty()) {
592  digisAlt = rawAlt.find(fed_key);
593  if (digisAlt == rawAlt.end())
594  continue;
595  }
596 
597  // find the strips belonging to the clusters connected to this APV pair
598  stripOnClusters.clear();
599  if (not clusters.empty()) {
600  for (edmNew::DetSetVector<SiStripCluster>::const_iterator DSViter = clusters.begin(); DSViter != clusters.end();
601  DSViter++) {
602  if (DSViter->id() != iconn->detId())
603  continue; // select clusters on this module
604  for (edmNew::DetSet<SiStripCluster>::const_iterator DSiter = DSViter->begin(); DSiter != DSViter->end();
605  DSiter++) { // loop on the clusters
606  if (DSiter->firstStrip() >= iconn->apvPairNumber() * 256 and
607  DSiter->firstStrip() < (1 + iconn->apvPairNumber()) * 256) { // found the right APV
608  for (size_t istrip = 0; istrip < DSiter->amplitudes().size(); istrip++) {
609  stripOnClusters.push_back(DSiter->firstStrip() + istrip - iconn->apvPairNumber() * 256);
610  }
611  }
612  }
613  }
614  }
615 
616  if (digis != raw.end()) {
617  // tasks involving tracking have partition-level histos, so treat separately
618  if (task_ == sistrip::APV_LATENCY) {
619  if (tasks_[0][iconn->fecCrate() - 1]) {
620  tasks_[0][iconn->fecCrate() - 1]->fillHistograms(*summary, *digis);
621  } else {
622  std::stringstream ss;
623  ss << "[SiStripCommissioningSource::" << __func__ << "]"
624  << " Unable to find CommissioningTask for FEC crate " << iconn->fecCrate()
625  << ". Unable to fill histograms!";
626  edm::LogWarning(mlDqmSource_) << ss.str();
627  }
628  } else if (task_ == sistrip::FINE_DELAY) {
629  if (tasks_[0][0]) {
630  tasks_[0][0]->fillHistograms(*summary, *digis);
631  } else {
632  std::stringstream ss;
633  ss << "[SiStripCommissioningSource::" << __func__ << "]"
634  << " Unable to find global CommissioningTask for FineDelay. Unable to fill histograms!";
635  edm::LogWarning(mlDqmSource_) << ss.str();
636  }
637  } else {
638  if (tasks_[iconn->fedId()][iconn->fedCh()]) {
639  if (not rawAlt.empty() or digisAlt == rawAlt.end())
640  tasks_[iconn->fedId()][iconn->fedCh()]->fillHistograms(*summary, *digis);
641  else { // for spy-data
642  if (stripOnClusters.empty())
643  tasks_[iconn->fedId()][iconn->fedCh()]->fillHistograms(*summary, *digis, *digisAlt);
644  else {
645  tasks_[iconn->fedId()][iconn->fedCh()]->fillHistograms(*summary, *digis, *digisAlt, stripOnClusters);
646  }
647  }
648  } else {
649  std::stringstream ss;
650  ss << "[SiStripCommissioningSource::" << __func__ << "]"
651  << " Unable to find CommissioningTask object with FED key " << std::hex << std::setfill('0')
652  << std::setw(8) << fed_key << std::dec << " and FED id/ch " << iconn->fedId() << "/" << iconn->fedCh()
653  << " Unable to fill histograms!";
654  edm::LogWarning(mlDqmSource_) << ss.str();
655  }
656  }
657  } else {
658  // issue a warning only for standard runs, as latency and fine delay only deliver
659  // pseudo zero-suppressed data
661  std::stringstream ss;
662  ss << "[SiStripCommissioningSource::" << __func__ << "]"
663  << " Unable to find any DetSet containing digis for FED key " << std::hex << std::setfill('0')
664  << std::setw(8) << fed_key << std::dec << " and FED id/ch " << iconn->fedId() << "/" << iconn->fedCh();
665  edm::LogWarning(mlDqmSource_) << ss.str();
666  }
667  }
668  } // fed channel loop
669  } // fed id loop
670 }

References sistrip::APV_LATENCY, bsc_activity_cfg::clusters, TauDecayModes::dec, edm::DetSetVector< T >::empty(), edm::DetSetVector< T >::end(), fedCabling_, SiStripFedCabling::fedConnections(), SiStripFedCabling::fedIds(), edm::DetSetVector< T >::find(), sistrip::FINE_DELAY, sistrip::invalid_, sistrip::mlDqmSource_, or, contentValuesCheck::ss, edmLumisInFiles::summary, task_, tasks_, and sistrip::valid_.

Referenced by analyze().

◆ remove()

void SiStripCommissioningSource::remove ( )
private

Definition at line 1078 of file SiStripCommissioningSource.cc.

1078  {
1079  // TODO: remove no longer supported in DQMStore.
1080 }

Referenced by beginRun().

Member Data Documentation

◆ base_

std::string SiStripCommissioningSource::base_
private

◆ cablingTask_

bool SiStripCommissioningSource::cablingTask_
private

Flag to indicate whether task is FED cabling or not.

Definition at line 146 of file SiStripCommissioningSource.h.

Referenced by analyze(), beginRun(), and createTask().

◆ cablingTasks_

TaskMap SiStripCommissioningSource::cablingTasks_
private

Map of cabling task objects (indexed using FEC key).

Definition at line 140 of file SiStripCommissioningSource.h.

Referenced by clearCablingTasks(), createCablingTasks(), endJob(), and fillCablingHistos().

◆ clustersToken_

edm::EDGetTokenT<edmNew::DetSetVector<SiStripCluster> > SiStripCommissioningSource::clustersToken_
private

Definition at line 105 of file SiStripCommissioningSource.h.

Referenced by analyze(), and SiStripCommissioningSource().

◆ digiFineDelaySelectionToken_

edm::EDGetTokenT<edm::DetSetVector<SiStripRawDigi> > SiStripCommissioningSource::digiFineDelaySelectionToken_
private

Definition at line 104 of file SiStripCommissioningSource.h.

Referenced by analyze(), and SiStripCommissioningSource().

◆ digiReorderedToken_

edm::EDGetTokenT<edm::DetSetVector<SiStripRawDigi> > SiStripCommissioningSource::digiReorderedToken_
private

Definition at line 102 of file SiStripCommissioningSource.h.

Referenced by analyze(), and SiStripCommissioningSource().

◆ digiScopeModeToken_

edm::EDGetTokenT<edm::DetSetVector<SiStripRawDigi> > SiStripCommissioningSource::digiScopeModeToken_
private

Definition at line 103 of file SiStripCommissioningSource.h.

Referenced by analyze(), and SiStripCommissioningSource().

◆ digiVirginRawToken_

edm::EDGetTokenT<edm::DetSetVector<SiStripRawDigi> > SiStripCommissioningSource::digiVirginRawToken_
private

Definition at line 101 of file SiStripCommissioningSource.h.

Referenced by analyze(), and SiStripCommissioningSource().

◆ dqm_

DQMStore* SiStripCommissioningSource::dqm_
private

Interface to Data Quality Monitoring framework.

Definition at line 91 of file SiStripCommissioningSource.h.

Referenced by beginRun(), and dqm().

◆ fecCabling_

SiStripFecCabling* SiStripCommissioningSource::fecCabling_
private

◆ fedCabling_

SiStripFedCabling* SiStripCommissioningSource::fedCabling_
private

◆ filename_

std::string SiStripCommissioningSource::filename_
private

Filename of output root file containing source histos.

Definition at line 114 of file SiStripCommissioningSource.h.

Referenced by createTasks(), and endJob().

◆ inputClusterLabel_

std::string SiStripCommissioningSource::inputClusterLabel_
private

Definition at line 111 of file SiStripCommissioningSource.h.

Referenced by analyze(), and SiStripCommissioningSource().

◆ inputModuleLabel_

std::string SiStripCommissioningSource::inputModuleLabel_
private

Name of digi input module.

Definition at line 108 of file SiStripCommissioningSource.h.

Referenced by SiStripCommissioningSource().

◆ inputModuleLabelAlt_

std::string SiStripCommissioningSource::inputModuleLabelAlt_
private

Definition at line 109 of file SiStripCommissioningSource.h.

Referenced by analyze(), and SiStripCommissioningSource().

◆ inputModuleLabelSummary_

std::string SiStripCommissioningSource::inputModuleLabelSummary_
private

Definition at line 110 of file SiStripCommissioningSource.h.

Referenced by SiStripCommissioningSource().

◆ inputModuleSummaryToken_

edm::EDGetTokenT<SiStripEventSummary> SiStripCommissioningSource::inputModuleSummaryToken_
private

Definition at line 100 of file SiStripCommissioningSource.h.

Referenced by analyze(), and SiStripCommissioningSource().

◆ isSpy_

bool SiStripCommissioningSource::isSpy_
private

Is this a spy run ?

Definition at line 126 of file SiStripCommissioningSource.h.

Referenced by analyze(), and SiStripCommissioningSource().

◆ parameters_

edm::ParameterSet SiStripCommissioningSource::parameters_
private

◆ partitionName_

std::string SiStripCommissioningSource::partitionName_
private

Partition name used for root files in spy

Definition at line 120 of file SiStripCommissioningSource.h.

Referenced by endJob().

◆ run_

uint32_t SiStripCommissioningSource::run_
private

Run number used for naming of root file.

Definition at line 117 of file SiStripCommissioningSource.h.

Referenced by analyze(), createRunNumber(), createTasks(), and endJob().

◆ task_

sistrip::RunType SiStripCommissioningSource::task_
private

Identifies commissioning task.

Definition at line 134 of file SiStripCommissioningSource.h.

Referenced by analyze(), beginRun(), createCablingTasks(), createTask(), createTasks(), endJob(), and fillHistos().

◆ taskConfigurable_

std::string SiStripCommissioningSource::taskConfigurable_
private

Identifies commissioning task read from cfg file.

Definition at line 131 of file SiStripCommissioningSource.h.

Referenced by createTask().

◆ tasks_

VecOfVecOfTasks SiStripCommissioningSource::tasks_
private

Vector of vector of task objects (indexed using FED id.ch.

Definition at line 137 of file SiStripCommissioningSource.h.

Referenced by analyze(), clearTasks(), createTasks(), endJob(), fillHistos(), and SiStripCommissioningSource().

◆ tasksExist_

bool SiStripCommissioningSource::tasksExist_
private

Flag to indicate whether histo objects exist or not.

Definition at line 143 of file SiStripCommissioningSource.h.

Referenced by analyze(), beginRun(), and createTask().

◆ time_

int32_t SiStripCommissioningSource::time_
private

Record of time used to calculate event rate.

Definition at line 123 of file SiStripCommissioningSource.h.

Referenced by analyze().

◆ updateFreq_

int SiStripCommissioningSource::updateFreq_
private

Update frequency for histograms (ignored for cabling).

Definition at line 149 of file SiStripCommissioningSource.h.

Referenced by analyze(), and createTasks().

◆ view_

std::string SiStripCommissioningSource::view_
private

flag for choosing the organizational 'view' the DQM histogram tree

Definition at line 155 of file SiStripCommissioningSource.h.

Referenced by createTasks().

SiStripCommissioningSource::filename_
std::string filename_
Definition: SiStripCommissioningSource.h:114
sistrip::CALIBRATION_SCAN
Definition: ConstantsForRunType.h:87
SiStripEnumsAndStrings::runType
static std::string runType(const sistrip::RunType &)
Definition: SiStripEnumsAndStrings.cc:39
edm::ESHandle::product
T const * product() const
Definition: ESHandle.h:86
sistrip::CCU_CHAN
Definition: ConstantsForGranularity.h:93
sistrip::mlDqmSource_
static const char mlDqmSource_[]
Definition: ConstantsForLogger.h:20
SiStripCommissioningSource::fedCabling_
SiStripFedCabling * fedCabling_
Definition: SiStripCommissioningSource.h:94
PedsOnlyTask
Definition: PedsOnlyTask.h:19
sistrip::DAQ_SCOPE_MODE
Definition: ConstantsForRunType.h:83
SiStripFecCabling
Definition: SiStripFecCabling.h:24
Averages::Params
Definition: Averages.h:15
SiStripModule::PairOfU16
std::pair< uint16_t, uint16_t > PairOfU16
Definition: SiStripModule.h:40
SiStripCommissioningSource::tasks_
VecOfVecOfTasks tasks_
Definition: SiStripCommissioningSource.h:137
sistrip::CALIBRATION
Definition: ConstantsForRunType.h:73
sistrip::PEDS_FULL_NOISE
Definition: ConstantsForRunType.h:92
sistrip::VPSP_SCAN
Definition: ConstantsForRunType.h:82
sistrip::FAST_CABLING
Definition: ConstantsForRunType.h:89
PedestalsTask
Definition: PedestalsTask.h:10
SiStripCommissioningSource::digiFineDelaySelectionToken_
edm::EDGetTokenT< edm::DetSetVector< SiStripRawDigi > > digiFineDelaySelectionToken_
Definition: SiStripCommissioningSource.h:104
sistrip::APV_TIMING
Definition: ConstantsForRunType.h:75
edm::DetSetVector::end
iterator end()
Return the off-the-end iterator.
Definition: DetSetVector.h:325
CalibrationSummaryClient_cfi.params
params
Definition: CalibrationSummaryClient_cfi.py:14
sistrip::detectorView_
static const char detectorView_[]
Definition: ConstantsForView.h:22
SiStripKey::key
const uint32_t & key() const
Definition: SiStripKey.h:120
SiStripCommissioningSource::fillCablingHistos
void fillCablingHistos(const SiStripEventSummary *const, const edm::DetSetVector< SiStripRawDigi > &)
Definition: SiStripCommissioningSource.cc:412
AlcaSiPixelAliHarvester0T_cff.method
method
Definition: AlcaSiPixelAliHarvester0T_cff.py:41
pos
Definition: PixelAliasList.h:18
edm::LogInfo
Definition: MessageLogger.h:254
sistrip::dir_
static const char dir_[]
Definition: ConstantsForDqm.h:17
edmNew::DetSetVector::const_iterator
boost::transform_iterator< IterHelp, const_IdIter > const_iterator
Definition: DetSetVectorNew.h:231
sistrip::OPTO_SCAN
Definition: ConstantsForRunType.h:74
SiStripModule
Device and connection information at the level of a front-end module.
Definition: SiStripModule.h:24
DaqScopeModeTask
Definition: DaqScopeModeTask.h:12
SiStripCommissioningClient_cfg.conn
conn
Definition: SiStripCommissioningClient_cfg.py:5
OptoScanTask
Definition: OptoScanTask.h:10
contentValuesCheck.run_number
run_number
Definition: contentValuesCheck.py:38
sistrip::RunType
RunType
Definition: ConstantsForRunType.h:70
SiStripFedKey
A container class for generic run and event-related info, information required by the commissioning a...
Definition: SiStripFedKey.h:56
SiStripCommissioningSource::inputModuleSummaryToken_
edm::EDGetTokenT< SiStripEventSummary > inputModuleSummaryToken_
Definition: SiStripCommissioningSource.h:100
findQualityFiles.v
v
Definition: findQualityFiles.py:179
createJobs.tmp
tmp
align.sh
Definition: createJobs.py:716
edm::Handle
Definition: AssociativeIterator.h:50
NoiseTask
Definition: NoiseTask.h:19
SiStripCommissioningSource::taskConfigurable_
std::string taskConfigurable_
Definition: SiStripCommissioningSource.h:131
singleTopDQM_cfi.setup
setup
Definition: singleTopDQM_cfi.py:37
LatencyTask
Definition: LatencyTask.h:11
SiStripCommissioningSource::dqm
DQMStore *const dqm(std::string method="") const
Definition: SiStripCommissioningSource.cc:110
FedCablingTask
Definition: FedCablingTask.h:13
sistrip::valid_
static const uint16_t valid_
Definition: Constants.h:17
sistrip::FINE_DELAY
Definition: ConstantsForRunType.h:85
edm::DetSetVector::empty
bool empty() const
Return true if we contain no DetSets.
Definition: DetSetVector.h:254
PDRates.average
average
Definition: PDRates.py:139
contentValuesCheck.ss
ss
Definition: contentValuesCheck.py:33
sistrip::sep_
static const char sep_[]
Definition: ConstantsForDqm.h:18
SiStripCommissioningSource::updateFreq_
int updateFreq_
Definition: SiStripCommissioningSource.h:149
SiStripFedCablingRcd
Definition: SiStripCondDataRecords.h:22
SiStripEnumsAndStrings::fedReadoutMode
static std::string fedReadoutMode(const sistrip::FedReadoutMode &)
Definition: SiStripEnumsAndStrings.cc:447
CalibrationScanTask
Definition: CalibrationScanTask.h:10
trigger::size_type
uint16_t size_type
Definition: TriggerTypeDefs.h:18
sistrip::FED_CABLING
Definition: ConstantsForRunType.h:81
SiStripCommissioningSource::inputModuleLabelSummary_
std::string inputModuleLabelSummary_
Definition: SiStripCommissioningSource.h:110
SiStripCommissioningSource::parameters_
edm::ParameterSet parameters_
Definition: SiStripCommissioningSource.h:158
SiStripCommissioningSource::cablingTasks_
TaskMap cablingTasks_
Definition: SiStripCommissioningSource.h:140
SiStripCommissioningSource::remove
void remove()
Definition: SiStripCommissioningSource.cc:1078
SiStripCommissioningSource::directory
void directory(std::stringstream &, uint32_t run_number=0)
Definition: SiStripCommissioningSource.cc:1084
edm::ESHandle< SiStripFedCabling >
dqm::implementation::DQMStore::setCurrentFolder
void setCurrentFolder(std::string const &fullpath) override
Definition: DQMStore.h:569
sistrip::mlTest_
static const char mlTest_[]
Definition: ConstantsForLogger.h:27
FineDelayTask
Definition: FineDelayTask.h:11
SiStripCommissioningSource::fecCabling_
SiStripFecCabling * fecCabling_
Definition: SiStripCommissioningSource.h:97
SiStripCommissioningSource::createCablingTasks
void createCablingTasks()
Definition: SiStripCommissioningSource.cc:771
OrderedSet.t
t
Definition: OrderedSet.py:90
SiStripCommissioningSource::inputClusterLabel_
std::string inputClusterLabel_
Definition: SiStripCommissioningSource.h:111
dqm::implementation::DQMStore::save
DQM_DEPRECATED void save(std::string const &filename, std::string const &path="")
Definition: DQMStore.cc:760
SiStripFecKey
Utility class that identifies a position within the strip tracker control structure,...
Definition: SiStripFecKey.h:45
SiStripCommissioningSource::inputModuleLabel_
std::string inputModuleLabel_
Definition: SiStripCommissioningSource.h:108
SiStripCommissioningSource::run_
uint32_t run_
Definition: SiStripCommissioningSource.h:117
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
edm::LogWarning
Definition: MessageLogger.h:141
SiStripCommissioningSource::tasksExist_
bool tasksExist_
Definition: SiStripCommissioningSource.h:143
bsc_activity_cfg.clusters
clusters
Definition: bsc_activity_cfg.py:36
FedChannelConnection
Class containning control, module, detector and connection information, at the level of a FED channel...
Definition: FedChannelConnection.h:26
sistrip::taskId_
static const char taskId_[]
Definition: ConstantsForDqm.h:31
HLT_2018_cff.InputTag
InputTag
Definition: HLT_2018_cff.py:79016
LogDebug
#define LogDebug(id)
Definition: MessageLogger.h:670
sistrip::FED_SCOPE_MODE
Definition: ConstantsForHardwareSystems.h:132
sistrip::CALIBRATION_DECO
Definition: ConstantsForRunType.h:93
dqm::implementation::IBooker::bookString
MonitorElement * bookString(TString const &name, TString const &value, FUNC onbooking=NOOP())
Definition: DQMStore.h:87
SiStripCommissioningSource::isSpy_
bool isSpy_
Definition: SiStripCommissioningSource.h:126
sistrip::dqmSourceFileName_
static const char dqmSourceFileName_[]
Definition: ConstantsForDqm.h:25
SiStripCommissioningSource::createTasks
void createTasks(sistrip::RunType, const edm::EventSetup &)
Definition: SiStripCommissioningSource.cc:899
sistrip::PEDESTALS
Definition: ConstantsForRunType.h:72
SiStripCommissioningSource::partitionName_
std::string partitionName_
Definition: SiStripCommissioningSource.h:120
sistrip::UNKNOWN_RUN_TYPE
Definition: ConstantsForRunType.h:94
edm::DetSetVector::find
iterator find(det_id_type id)
Definition: DetSetVector.h:264
edm::Service
Definition: Service.h:30
SiStripFedKey::feUnit
const uint16_t & feUnit() const
Definition: SiStripFedKey.h:189
edmLumisInFiles.summary
summary
Definition: edmLumisInFiles.py:39
CalibrationTask
Definition: CalibrationTask.h:10
average
Definition: average.py:1
sistrip::FED_TIMING
Definition: ConstantsForRunType.h:80
edm::LogVerbatim
Definition: MessageLogger.h:297
sistrip::PEDS_ONLY
Definition: ConstantsForRunType.h:90
sistrip::root_
static const char root_[]
Definition: ConstantsForDqm.h:30
FedTimingTask
Definition: FedTimingTask.h:9
sistrip::invalid_
static const uint16_t invalid_
Definition: Constants.h:16
module
Definition: vlib.h:198
get
#define get
SiStripCommissioningSource::view_
std::string view_
Definition: SiStripCommissioningSource.h:155
SiStripCommissioningSource::task_
sistrip::RunType task_
Definition: SiStripCommissioningSource.h:134
sistrip::FED_VIRGIN_RAW
Definition: ConstantsForHardwareSystems.h:133
SiStripCommissioningSource::base_
std::string base_
Definition: SiStripCommissioningSource.h:152
SiStripCommissioningSource::inputModuleLabelAlt_
std::string inputModuleLabelAlt_
Definition: SiStripCommissioningSource.h:109
SiStripFecCabling::crates
const std::vector< SiStripFecCrate > & crates() const
Definition: SiStripFecCabling.h:76
SiStripCommissioningSource::fillHistos
void fillHistos(const SiStripEventSummary *const, const edm::DetSetVector< SiStripRawDigi > &, const edm::DetSetVector< SiStripRawDigi > &=edm::DetSetVector< SiStripRawDigi >(), const edmNew::DetSetVector< SiStripCluster > &=edmNew::DetSetVector< SiStripCluster >())
Definition: SiStripCommissioningSource.cc:564
sistrip::CALIBRATION_SCAN_DECO
Definition: ConstantsForRunType.h:88
writedatasetfile.run
run
Definition: writedatasetfile.py:27
SiStripCommissioningSource::digiVirginRawToken_
edm::EDGetTokenT< edm::DetSetVector< SiStripRawDigi > > digiVirginRawToken_
Definition: SiStripCommissioningSource.h:101
hcalSimParameters_cfi.he
he
Definition: hcalSimParameters_cfi.py:75
SiStripCommissioningSource::clearTasks
void clearTasks()
Definition: SiStripCommissioningSource.cc:1058
sistrip::APV_LATENCY
Definition: ConstantsForRunType.h:76
sistrip::UNDEFINED_RUN_TYPE
Definition: ConstantsForRunType.h:95
ewkTauDQM_cfi.channels
channels
Definition: ewkTauDQM_cfi.py:14
SiStripCommissioningSource::clustersToken_
edm::EDGetTokenT< edmNew::DetSetVector< SiStripCluster > > clustersToken_
Definition: SiStripCommissioningSource.h:105
findQualityFiles.jj
string jj
Definition: findQualityFiles.py:188
SiStripCommissioningSource::digiReorderedToken_
edm::EDGetTokenT< edm::DetSetVector< SiStripRawDigi > > digiReorderedToken_
Definition: SiStripCommissioningSource.h:102
sistrip::NOISE
Definition: ConstantsForRunType.h:91
Skims_PA_cff.name
name
Definition: Skims_PA_cff.py:17
or
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
SiStripFedCabling::fedIds
FedsConstIterRange fedIds() const
Definition: SiStripFedCabling.h:154
castor_dqm_sourceclient_file_cfg.path
path
Definition: castor_dqm_sourceclient_file_cfg.py:37
LogTrace
#define LogTrace(id)
Definition: MessageLogger.h:671
SiStripCommissioningSource::clearCablingTasks
void clearCablingTasks()
Definition: SiStripCommissioningSource.cc:1044
SiStripCommissioningSource::digiScopeModeToken_
edm::EDGetTokenT< edm::DetSetVector< SiStripRawDigi > > digiScopeModeToken_
Definition: SiStripCommissioningSource.h:103
PedsFullNoiseTask
Definition: PedsFullNoiseTask.h:22
edm::HandleBase::isValid
bool isValid() const
Definition: HandleBase.h:70
ntuplemaker.time
time
Definition: ntuplemaker.py:310
event
Definition: event.py:1
SiStripCommissioningSource::createTask
void createTask(const SiStripEventSummary *const, const edm::EventSetup &)
Definition: SiStripCommissioningSource.cc:691
SiStripFedCabling::fedConnections
ConnsConstIterRange fedConnections(uint16_t fed_id) const
Definition: SiStripFedCabling.cc:160
ApvTimingTask
Definition: ApvTimingTask.h:9
crabWrapper.key
key
Definition: crabWrapper.py:19
TauDecayModes.dec
dec
Definition: TauDecayModes.py:143
cuy.ii
ii
Definition: cuy.py:590
FastFedCablingTask
Definition: FastFedCablingTask.h:8
edm::InputTag
Definition: InputTag.h:15
sistrip::runNumber_
static const char runNumber_[]
Definition: ConstantsForDqm.h:33
SiStripCommissioningSource::time_
int32_t time_
Definition: SiStripCommissioningSource.h:123
SiStripCommissioningSource::VecOfTasks
std::vector< CommissioningTask * > VecOfTasks
Definition: SiStripCommissioningSource.h:33
SiStripCommissioningSource::createRunNumber
void createRunNumber()
Definition: SiStripCommissioningSource.cc:674
muonDTDigis_cfi.pset
pset
Definition: muonDTDigis_cfi.py:27
SiStripFedKey::feChan
const uint16_t & feChan() const
Definition: SiStripFedKey.h:190
DeadROC_duringRun.dir
dir
Definition: DeadROC_duringRun.py:23
VpspScanTask
Definition: VpspScanTask.h:9
edmNew::DetSet::const_iterator
const data_type * const_iterator
Definition: DetSetNew.h:31
SiStripFecCabling::module
const SiStripModule & module(const FedChannelConnection &conn) const
Definition: SiStripFecCabling.cc:181
SiStripCommissioningSource::dqm_
DQMStore * dqm_
Definition: SiStripCommissioningSource.h:91
SiStripCommissioningSource::cablingTask_
bool cablingTask_
Definition: SiStripCommissioningSource.h:146