CMS 3D CMS Logo

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

#include <DQMHistPlotter.h>

Inheritance diagram for TauDQMHistPlotter:
edm::EDAnalyzer edm::EDConsumerBase

Classes

struct  cfgEntryAxisX
 
struct  cfgEntryAxisY
 
struct  cfgEntryDrawJob
 
struct  cfgEntryDrawOption
 
struct  cfgEntryLabel
 
struct  cfgEntryLegend
 
struct  cfgEntryProcess
 
struct  plotDefEntry
 

Public Member Functions

void analyze (const edm::Event &, const edm::EventSetup &) override
 
void endRun (const edm::Run &r, const edm::EventSetup &c) override
 
 TauDQMHistPlotter (const edm::ParameterSet &)
 
 ~TauDQMHistPlotter () 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
 
std::vector< ESProxyIndex > const & esGetTokenIndicesVector (edm::Transition iTrans) const
 
std::vector< ESRecordIndex > const & esGetTokenRecordIndicesVector (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::array< std::vector< ModuleDescription const * > *, NumBranchTypes > &modulesAll, std::vector< ModuleProcessName > &modulesInPreviousProcesses, 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 Types

typedef dqm::legacy::DQMStore DQMStore
 
typedef dqm::legacy::MonitorElement MonitorElement
 
typedef std::list< plotDefEntryplotDefList
 
typedef std::vector< std::string > vstring
 

Private Attributes

int canvasSizeX_
 
int canvasSizeY_
 
int cfgError_
 
std::list< cfgEntryDrawJobdrawJobs_
 
std::map< std::string, cfgEntryDrawOptiondrawOptionEntries_
 
std::string indOutputFileName_
 
std::map< std::string, cfgEntryLabellabels_
 
std::map< std::string, cfgEntryLegendlegends_
 
std::string outputFileName_
 
std::string outputFilePath_
 
std::map< std::string, cfgEntryProcessprocesses_
 
bool toFile_
 
std::map< std::string, cfgEntryAxisXxAxes_
 
std::map< std::string, cfgEntryAxisYyAxes_
 

Additional Inherited Members

- Public Types inherited from edm::EDAnalyzer
typedef EDAnalyzer ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- 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 wantsInputProcessBlocks ()
 
static bool wantsProcessBlocks ()
 
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 = InEvent>
EDConsumerBaseAdaptor< B > consumes (edm::InputTag tag) noexcept
 
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<Transition Tr = Transition::Event>
constexpr auto esConsumes () noexcept
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<Transition Tr = Transition::Event>
auto esConsumes (ESInputTag tag) noexcept
 
template<Transition Tr = Transition::Event>
ESGetTokenGeneric esConsumes (eventsetup::EventSetupRecordKey const &iRecord, eventsetup::DataKey const &iKey)
 Used with EventSetupRecord::doGet. More...
 
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

Class to plot histograms and create a postscript file

Author
Christian Veelken, UC Davis

Definition at line 27 of file DQMHistPlotter.h.

Member Typedef Documentation

◆ DQMStore

Definition at line 28 of file DQMHistPlotter.h.

◆ MonitorElement

Definition at line 29 of file DQMHistPlotter.h.

◆ plotDefList

typedef std::list<plotDefEntry> TauDQMHistPlotter::plotDefList
private

Definition at line 136 of file DQMHistPlotter.h.

◆ vstring

typedef std::vector<std::string> TauDQMHistPlotter::vstring
private

Definition at line 31 of file DQMHistPlotter.h.

Constructor & Destructor Documentation

◆ TauDQMHistPlotter()

TauDQMHistPlotter::TauDQMHistPlotter ( const edm::ParameterSet cfg)
explicit

Definition at line 556 of file DQMHistPlotter.cc.

556  {
557  if (verbosity)
558  std::cout << "<TauDQMHistPlotter::TauDQMHistPlotter>:" << std::endl;
559 
560  toFile_ = cfg.getParameter<bool>("PrintToFile");
561  cfgError_ = 0;
562 
563  //--- configure processes
564  //std::cout << "--> configuring processes..." << std::endl;
565  edm::ParameterSet cfgParSet_processes = cfg.getParameter<edm::ParameterSet>("processes");
566  readCfgParameter<cfgEntryProcess>(cfgParSet_processes, processes_);
567 
568  //--- check that process types are defined
569  //std::cout << "--> checking configuration parameters..." << std::endl;
570 
571  int numProcesses_Data = 0;
572  int numProcesses_sumMC = 0;
573  for (std::map<std::string, cfgEntryProcess>::const_iterator process = processes_.begin(); process != processes_.end();
574  ++process) {
575  const std::string& type = process->second.type_;
576 
577  if (!((type == type_smMC) || (type == type_bsmMC) || (type == type_smSumMC) || (type == type_Data))) {
578  edm::LogError("TauDQMHistPlotter") << " Undefined process type = " << type << " !!";
579  cfgError_ = 1;
580  }
581 
582  if (type == type_smSumMC)
583  ++numProcesses_sumMC;
584  if (type == type_Data)
585  ++numProcesses_Data;
586  }
587 
588  if ((numProcesses_Data > 1) || (numProcesses_sumMC > 1)) {
589  edm::LogError("TauDQMHistPlotter") << " Cannot have more than one process of types sumMC and Data !!";
590  cfgError_ = 1;
591  }
592 
593  //--- configure x-axes
594  //std::cout << "--> configuring x-axes..." << std::endl;
595  edm::ParameterSet cfgParSet_xAxes = cfg.getParameter<edm::ParameterSet>("xAxes");
596  readCfgParameter<cfgEntryAxisX>(cfgParSet_xAxes, xAxes_);
597 
598  //--- configure y-axes
599  //std::cout << "--> configuring y-axes..." << std::endl;
600  edm::ParameterSet cfgParSet_yAxes = cfg.getParameter<edm::ParameterSet>("yAxes");
601  readCfgParameter<cfgEntryAxisY>(cfgParSet_yAxes, yAxes_);
602 
603  //--- configure legends
604  //std::cout << "--> configuring legends..." << std::endl;
605  edm::ParameterSet cfgParSet_legends = cfg.getParameter<edm::ParameterSet>("legends");
606  readCfgParameter<cfgEntryLegend>(cfgParSet_legends, legends_);
607 
608  //--- configure labels
609  //std::cout << "--> configuring labels..." << std::endl;
610  edm::ParameterSet cfgParSet_labels = cfg.getParameter<edm::ParameterSet>("labels");
611  readCfgParameter<cfgEntryLabel>(cfgParSet_labels, labels_);
612 
613  //--- configure drawOptions
614  //std::cout << "--> configuring drawOptions..." << std::endl;
615  if (cfg.exists("drawOptionSets")) {
616  edm::ParameterSet drawOptionSets = cfg.getParameter<edm::ParameterSet>("drawOptionSets");
617  vstring drawOptionSetNames = drawOptionSets.getParameterNamesForType<edm::ParameterSet>();
618  for (vstring::const_iterator drawOptionSetName = drawOptionSetNames.begin();
619  drawOptionSetName != drawOptionSetNames.end();
620  ++drawOptionSetName) {
621  edm::ParameterSet drawOptionSet = drawOptionSets.getParameter<edm::ParameterSet>(*drawOptionSetName);
622 
623  vstring drawOptionEntryNames = drawOptionSet.getParameterNamesForType<edm::ParameterSet>();
624  for (vstring::const_iterator drawOptionEntryName = drawOptionEntryNames.begin();
625  drawOptionEntryName != drawOptionEntryNames.end();
626  ++drawOptionEntryName) {
627  edm::ParameterSet drawOptionEntry = drawOptionSet.getParameter<edm::ParameterSet>(*drawOptionEntryName);
628 
629  std::string drawOptionEntryName_full =
630  std::string(*drawOptionSetName).append(drawOptionSeparator).append(*drawOptionEntryName);
631  drawOptionEntries_.insert(std::pair<std::string, cfgEntryDrawOption>(
632  drawOptionEntryName_full, cfgEntryDrawOption(drawOptionEntryName_full, drawOptionEntry)));
633  }
634  }
635  }
636 
637  if (cfg.exists("drawOptionEntries")) {
638  edm::ParameterSet cfgParSet_drawOptionEntries = cfg.getParameter<edm::ParameterSet>("drawOptionEntries");
639  readCfgParameter<cfgEntryDrawOption>(cfgParSet_drawOptionEntries, drawOptionEntries_);
640  }
641 
642  //--- configure drawJobs
643  //std::cout << "--> configuring drawJobs..." << std::endl;
644  edm::ParameterSet drawJobs = cfg.getParameter<edm::ParameterSet>("drawJobs");
645  vstring drawJobNames = drawJobs.getParameterNamesForType<edm::ParameterSet>();
646  for (vstring::const_iterator drawJobName = drawJobNames.begin(); drawJobName != drawJobNames.end(); ++drawJobName) {
647  edm::ParameterSet drawJob = drawJobs.getParameter<edm::ParameterSet>(*drawJobName);
648 
649  std::map<int, plotDefList> plotDefMap;
650 
651  if (drawJob.existsAs<edm::ParameterSet>("plots")) { // display same monitor element for different processes
653 
654  vstring dqmMonitorElements = plots.getParameter<vstring>("dqmMonitorElements");
655  vstring processes = plots.getParameter<vstring>("processes");
656 
657  std::string drawOptionSet = drawJob.getParameter<std::string>("drawOptionSet");
658  //std::cout << "drawOptionSet = " << drawOptionSet << std::endl;
659 
660  vstring stack = (cfg.exists("stack")) ? drawJob.getParameter<vstring>("stack") : vstring();
661 
662  for (vstring::const_iterator process = processes.begin(); process != processes.end(); ++process) {
663  int index = 0;
664  for (vstring::const_iterator dqmMonitorElement = dqmMonitorElements.begin();
665  dqmMonitorElement != dqmMonitorElements.end();
666  ++dqmMonitorElement) {
667  bool stack_dqmMonitorElement = find_vstring(stack, *process);
668  std::string drawOptionEntry = std::string(drawOptionSet).append(drawOptionSeparator).append(*process);
669  plotDefMap[index].push_back(
670  plotDefEntry(*dqmMonitorElement, drawOptionEntry, "", "", *process, stack_dqmMonitorElement));
671  ++index;
672  }
673  }
674  } else { // display different monitor elements for same process
675  typedef std::vector<edm::ParameterSet> vParameterSet;
676  vParameterSet plots = drawJob.getParameter<vParameterSet>("plots");
677 
678  std::string process = (drawJob.exists("process")) ? drawJob.getParameter<std::string>("process") : "";
679  //std::cout << "process (globally set) = " << process << std::endl;
680 
681  for (vParameterSet::const_iterator plot = plots.begin(); plot != plots.end(); ++plot) {
682  if (process.empty() || plot->exists("process")) {
683  process = plot->getParameter<std::string>("process");
684  //std::cout << "process (locally set) = " << process << std::endl;
685  }
686 
687  std::string drawOptionEntry = plot->getParameter<std::string>("drawOptionEntry");
688  //std::cout << "drawOptionEntry = " << drawOptionEntry << std::endl;
689 
690  std::string legendEntry = "", legendEntryErrorBand = "";
691  if (plot->exists("legendEntry")) {
692  legendEntry = plot->getParameter<std::string>("legendEntry");
693  legendEntryErrorBand = (plot->exists("legendEntryErrorBand"))
694  ? plot->getParameter<std::string>("legendEntryErrorBand")
695  : std::string(legendEntry).append(" Uncertainty");
696  }
697  //std::cout << "legendEntry = " << legendEntry << std::endl;
698  //std::cout << "legendEntryErrorBand = " << legendEntryErrorBand << std::endl;
699 
700  vstring dqmMonitorElements = plot->getParameter<vstring>("dqmMonitorElements");
701  int index = 0;
702  for (vstring::const_iterator dqmMonitorElement = dqmMonitorElements.begin();
703  dqmMonitorElement != dqmMonitorElements.end();
704  ++dqmMonitorElement) {
705  plotDefMap[index].push_back(
706  plotDefEntry(*dqmMonitorElement, drawOptionEntry, legendEntry, legendEntryErrorBand, process, false));
707  ++index;
708  }
709  }
710  }
711 
712  //--- check that number of displayed monitor elements is the same for each plot
713  unsigned numMonitorElements_ref = 0;
714  bool isFirstEntry = true;
715  for (std::map<int, plotDefList>::const_iterator plot = plotDefMap.begin(); plot != plotDefMap.end(); ++plot) {
716  if (isFirstEntry) {
717  numMonitorElements_ref = plot->second.size();
718  isFirstEntry = false;
719  } else {
720  if (plot->second.size() != numMonitorElements_ref) {
721  edm::LogError("TauDQMHistPlotter::TauDQMHistPlotter")
722  << " Numbers of dqmMonitorElements must be the same for all plots"
723  << " --> skipping drawJob = " << (*drawJobName) << " !!";
724  cfgError_ = 1;
725  }
726  }
727  }
728 
729  //--- expand process directories in names of dqmMonitorElements
730  for (std::map<int, plotDefList>::iterator plot = plotDefMap.begin(); plot != plotDefMap.end(); ++plot) {
731  for (plotDefList::iterator entry = plot->second.begin(); entry != plot->second.end(); ++entry) {
732  std::string dqmMonitorElement = entry->dqmMonitorElement_;
733  std::string process = entry->process_;
734 
735  std::map<std::string, cfgEntryProcess>::const_iterator it = processes_.find(process);
736  if (it != processes_.end()) {
737  std::string process_dqmDirectory = it->second.dqmDirectory_;
738 
739  //std::cout << "replacing processDir = " << process_dqmDirectory << " in drawJob = " << (*drawJobName) << std::endl;
740 
741  int errorFlag = 0;
742  std::string dqmMonitorElement_expanded =
743  replace_string(dqmMonitorElement, processDirKeyword, process_dqmDirectory, 0, 1, errorFlag);
744  //std::cout << " dqmMonitorElement_expanded = " << dqmMonitorElement_expanded << std::endl;
745 
746  if (!errorFlag) {
747  entry->dqmMonitorElement_ = dqmMonitorElement_expanded;
748  } else {
749  cfgError_ = 1;
750  }
751  } else {
752  edm::LogError("TauDQMHistPlotter::TauDQMHistPlotter") << " Undefined process = " << process << " !!";
753  cfgError_ = 1;
754  }
755  }
756  }
757 
758  std::string title = (drawJob.exists("title")) ? drawJob.getParameter<std::string>("title") : "";
759 
760  std::string xAxis = drawJob.getParameter<std::string>("xAxis");
761  std::string yAxis = drawJob.getParameter<std::string>("yAxis");
762 
763  std::string legend = drawJob.getParameter<std::string>("legend");
764 
765  vstring labels = (drawJob.exists("labels")) ? drawJob.getParameter<vstring>("labels") : vstring();
766 
767  //--- expand parameters in names of dqmMonitorElements;
768  // create drawJob objects
769  for (std::map<int, plotDefList>::iterator plot = plotDefMap.begin(); plot != plotDefMap.end(); ++plot) {
770  if (drawJob.exists("parameter")) {
771  vstring vparameter = drawJob.getParameter<vstring>("parameter");
772  //std::cout << "replacing parameter = " << format_vstring(vparameter) << " in drawJob = " << (*drawJobName) << std::endl;
773 
774  for (vstring::const_iterator parameter = vparameter.begin(); parameter != vparameter.end(); ++parameter) {
775  plotDefList plot_expanded;
776 
777  for (plotDefList::const_iterator entry = plot->second.begin(); entry != plot->second.end(); ++entry) {
778  std::string dqmMonitorElement = entry->dqmMonitorElement_;
779 
780  int errorFlag = 0;
781  std::string dqmMonitorElement_expanded =
782  replace_string(dqmMonitorElement, parKeyword, *parameter, 1, 1, errorFlag);
783  //std::cout << " dqmMonitorElement_expanded = " << dqmMonitorElement_expanded << std::endl;
784  if (!errorFlag) {
785  plot_expanded.push_back(plotDefEntry(dqmMonitorElement_expanded,
786  entry->drawOptionEntry_,
787  entry->legendEntry_,
788  entry->legendEntryErrorBand_,
789  entry->process_,
790  entry->doStack_));
791  } else {
792  cfgError_ = 1;
793  }
794  }
795 
796  int errorFlag = 0;
797  std::string title_expanded = replace_string(title, parKeyword, *parameter, 0, 1, errorFlag);
798  //std::cout << " title_expanded = " << title_expanded << std::endl;
799  std::string xAxis_expanded = replace_string(xAxis, parKeyword, *parameter, 0, 1, errorFlag);
800  //std::cout << " xAxis_expanded = " << xAxis_expanded << std::endl;
801  std::string yAxis_expanded = replace_string(yAxis, parKeyword, *parameter, 0, 1, errorFlag);
802  //std::cout << " yAxis_expanded = " << yAxis_expanded << std::endl;
803  if (errorFlag)
804  cfgError_ = 1;
805 
806  drawJobs_.push_back(cfgEntryDrawJob(std::string(*drawJobName).append(*parameter),
807  plot_expanded,
808  title_expanded,
809  xAxis_expanded,
810  yAxis_expanded,
811  legend,
812  labels));
813  }
814  } else {
815  drawJobs_.push_back(cfgEntryDrawJob(*drawJobName, plot->second, title, xAxis, yAxis, legend, labels));
816  }
817  }
818  }
819 
820  //--- check that all information neccessary to process drawJob is defined;
821  for (std::list<cfgEntryDrawJob>::const_iterator drawJob = drawJobs_.begin(); drawJob != drawJobs_.end(); ++drawJob) {
822  for (plotDefList::const_iterator plot = drawJob->plots_.begin(); plot != drawJob->plots_.end(); ++plot) {
823  checkCfgDef<cfgEntryDrawOption>(
824  plot->drawOptionEntry_, drawOptionEntries_, cfgError_, "drawOptionEntry", drawJob->name_);
825  checkCfgDef<cfgEntryProcess>(plot->process_, processes_, cfgError_, "process", drawJob->name_);
826  }
827 
828  checkCfgDef<cfgEntryAxisX>(drawJob->xAxis_, xAxes_, cfgError_, "xAxis", drawJob->name_);
829  checkCfgDef<cfgEntryAxisY>(drawJob->yAxis_, yAxes_, cfgError_, "yAxis", drawJob->name_);
830 
831  checkCfgDef<cfgEntryLegend>(drawJob->legend_, legends_, cfgError_, "legend", drawJob->name_);
832 
833  checkCfgDefs<cfgEntryLabel>(drawJob->labels_, labels_, cfgError_, "label", drawJob->name_);
834  }
835 
836  //--- configure canvas size
837  //std::cout << "--> configuring canvas size..." << std::endl;
838  canvasSizeX_ = (cfg.exists("canvasSizeX")) ? cfg.getParameter<int>("canvasSizeX") : defaultCanvasSizeX;
839  canvasSizeY_ = (cfg.exists("canvasSizeY")) ? cfg.getParameter<int>("canvasSizeY") : defaultCanvasSizeY;
840 
841  //--- configure output files
842  //std::cout << "--> configuring postscript output file..." << std::endl;
843 
844  outputFilePath_ = (cfg.exists("outputFilePath")) ? cfg.getParameter<std::string>("outputFilePath") : "";
845  if (outputFilePath_.rbegin() != outputFilePath_.rend()) {
846  if ((*outputFilePath_.rbegin()) == '/')
847  outputFilePath_.erase(outputFilePath_.length() - 1);
848  }
849  //std::cout << " outputFilePath = " << outputFilePath_ << std::endl;
850 
851  outputFileName_ = (cfg.exists("outputFileName")) ? cfg.getParameter<std::string>("outputFileName") : "";
852  //std::cout << " outputFileName = " << outputFileName_ << std::endl;
853 
854  indOutputFileName_ = (cfg.exists("indOutputFileName")) ? cfg.getParameter<std::string>("indOutputFileName") : "";
855  if (!indOutputFileName_.empty() && indOutputFileName_.find('.') == std::string::npos) {
856  edm::LogError("TauDQMHistPlotter") << " Failed to determine type of graphics format from indOutputFileName = "
857  << indOutputFileName_ << " !!";
858  cfgError_ = 1;
859  }
860  //std::cout << " indOutputFileName = " << indOutputFileName_ << std::endl;
861 
862  //--- check that exactly one type of output is specified for the plots
863  // (either separate graphics files displaying one plot each
864  // or postscript file displaying all plots on successive pages;
865  // cannot create both types of output simultaneously,
866  // as TCanvas::Print seems to interfere with TPostScript::NewPage)
867  if (outputFileName_.empty() && indOutputFileName_.empty()) {
868  edm::LogError("TauDQMHistPlotter") << " Either outputFileName or indOutputFileName must be specified !!";
869  cfgError_ = 1;
870  }
871 
872  if (!outputFileName_.empty() && !indOutputFileName_.empty()) {
873  edm::LogError("TauDQMHistPlotter") << " Must not specify outputFileName and indOutputFileName simultaneously !!";
874  cfgError_ = 1;
875  }
876 
877  if (verbosity)
878  std::cout << "done." << std::endl;
879 }

References canvasSizeX_, canvasSizeY_, looper::cfg, cfgError_, gather_cfg::cout, defaultCanvasSizeX, defaultCanvasSizeY, drawJobs_, drawOptionEntries_, drawOptionSeparator, RecoTauValidation_cfi::drawOptionSets, mps_splice::entry, edm::ParameterSet::exists(), edm::ParameterSet::existsAs(), find_vstring(), edm::ParameterSet::getParameter(), edm::ParameterSet::getParameterNamesForType(), indOutputFileName_, SummaryClient_cfi::labels, labels_, listHistos::legend, RecoTauValidation_cfi::legendEntry, legends_, outputFileName_, outputFilePath_, pfMETsysShiftCorrections_cfi::parameter, parKeyword, plotFactory::plot, HLTObjectsMonitor_cfi::plots, LaserDQM_cfg::process, processDirKeyword, dqmiodatasetharvest::processes, processes_, replace_string(), svgfig::stack, AlCaHLTBitMon_QueryRunRegistry::string, runGCPTkAlMap::title, toFile_, type_bsmMC, type_Data, type_smMC, type_smSumMC, verbosity, xAxes_, HLT_FULL_cff::xAxis, yAxes_, and HLT_FULL_cff::yAxis.

◆ ~TauDQMHistPlotter()

TauDQMHistPlotter::~TauDQMHistPlotter ( )
override

Definition at line 881 of file DQMHistPlotter.cc.

881  {
882  // nothing to be done yet...
883 }

Member Function Documentation

◆ analyze()

void TauDQMHistPlotter::analyze ( const edm::Event ,
const edm::EventSetup  
)
overridevirtual

Implements edm::EDAnalyzer.

Definition at line 885 of file DQMHistPlotter.cc.

885  {
886  // nothing to be done yet...
887 }

◆ endRun()

void TauDQMHistPlotter::endRun ( const edm::Run r,
const edm::EventSetup c 
)
overridevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 889 of file DQMHistPlotter.cc.

889  {
890  if (verbosity)
891  std::cout << "<TauDQMHistPlotter::endJob>:" << std::endl;
892 
893  //--- check that configuration parameters contain no errors
894  if (cfgError_) {
895  edm::LogError("endJob") << " Error in Configuration ParameterSet --> histograms will NOT be plotted !!";
896  return;
897  }
898 
899  //--- check that DQMStore service is available
900  if (!edm::Service<DQMStore>().isAvailable()) {
901  edm::LogError("endJob") << " Failed to access dqmStore --> histograms will NOT be plotted !!";
902  return;
903  }
904 
906 
907  //--- stop ROOT from keeping references to all hsitograms
908  //TH1::AddDirectory(false);
909 
910  //--- stop ROOT from opening X-window for canvas output
911  // (in order to be able to run in batch mode)
912  gROOT->SetBatch(true);
913 
914  //--- initialize graphical output;
915  // open postscript file
916  TCanvas canvas("TauDQMHistPlotter", "TauDQMHistPlotter", canvasSizeX_, canvasSizeY_);
917  canvas.SetFillColor(10);
918 
919  //--- restrict area in which histograms are drawn to quadratic TPad in the center of the TCanvas,
920  // in order to make space for axis labels...
921  //TPad pad("EWKTauPad", "EWKTauPad", 0.02, 0.15, 0.98, 0.85);
922  //pad.SetFillColor(10);
923  //pad.Draw();
924  //pad.Divide(1,1);
925  //pad.cd(1);
926 
927  TPostScript* ps = nullptr;
928  if (!outputFileName_.empty()) {
930  (!outputFilePath_.empty()) ? std::string(outputFilePath_).append("/").append(outputFileName_) : outputFileName_;
931  ps = new TPostScript(psFileName.data(), 112);
932  }
933 
934  //--- process drawJobs
935  for (std::list<cfgEntryDrawJob>::const_iterator drawJob = drawJobs_.begin(); drawJob != drawJobs_.end(); ++drawJob) {
936  const std::string& drawJobName = drawJob->name_;
937  if (verbosity)
938  std::cout << "--> processing drawJob " << drawJobName << "..." << std::endl;
939 
940  //--- prepare internally used histogram data-structures
941  TH1* stackedHistogram_sum = nullptr;
942  std::list<TH1*> histogramsToDelete;
943  std::list<plotDefEntry*> drawOptionsToDelete;
944 
945  typedef std::pair<TH1*, const plotDefEntry*> histogram_drawOption_pair;
946  std::list<histogram_drawOption_pair> allHistograms;
947 
948  for (plotDefList::const_iterator plot = drawJob->plots_.begin(); plot != drawJob->plots_.end(); ++plot) {
949  std::string dqmMonitorElementName_full =
950  dqmDirectoryName(std::string(dqmRootDirectory)).append(plot->dqmMonitorElement_);
951  if (verbosity)
952  std::cout << " dqmMonitorElementName_full = " << dqmMonitorElementName_full << std::endl;
953  MonitorElement* dqmMonitorElement = dqmStore.get(dqmMonitorElementName_full);
954 
955  TH1* histogram = dqmMonitorElement->getTH1F();
956  if (verbosity)
957  std::cout << "Got Histogram " << std::endl;
958  // TH1* histogram = ( dqmMonitorElement ) ? dynamic_cast<TH1*>(dqmMonitorElement->getTH1()->Clone()) : NULL;
959  //histogramsToDelete.push_back(histogram);
960 
961  if (histogram == nullptr) {
962  edm::LogError("endJob") << " Failed to access dqmMonitorElement = " << dqmMonitorElementName_full << ","
963  << " needed by drawJob = " << drawJobName << " --> histograms will NOT be plotted !!";
964  continue;
965  }
966 
967  if (!histogram->GetSumw2N())
968  histogram->Sumw2();
969 
970  const cfgEntryDrawOption* drawOptionConfig =
971  findCfgDef<cfgEntryDrawOption>(plot->drawOptionEntry_, drawOptionEntries_, "drawOptionEntry", drawJobName);
972  if (drawOptionConfig == nullptr) {
973  edm::LogError("endJob") << " Failed to access information needed by drawJob = " << drawJobName
974  << " --> histograms will NOT be plotted !!";
975  return;
976  }
977 
978  if (drawOptionConfig->drawOption_ == drawOption_eBand) {
979  //--- add histogram displaying central value as solid line
980  TH1* histogram_centralValue = dynamic_cast<TH1*>(histogram->Clone());
981  histogram_centralValue->SetName(std::string(histogram->GetName()).append("_centralValue").data());
982  cfgEntryDrawOption drawOptionConfig_centralValue(*drawOptionConfig);
983  drawOptionConfig_centralValue.fillColor_ = 0;
984  drawOptionConfig_centralValue.fillStyle_ = 0;
985  drawOptionConfig_centralValue.drawOption_ = "hist";
986  drawOptionConfig_centralValue.drawOptionLegend_ = "l";
987  std::string drawOptionName_centralValue = std::string(plot->drawOptionEntry_).append("_centralValue");
988  //--- entries in std::map need to be unique,
989  // so need to check whether drawOptionEntry already exists...
990  if (drawOptionEntries_.find(drawOptionName_centralValue) == drawOptionEntries_.end())
991  drawOptionEntries_.insert(std::pair<std::string, cfgEntryDrawOption>(
992  drawOptionName_centralValue,
993  cfgEntryDrawOption(drawOptionName_centralValue, drawOptionConfig_centralValue)));
994  plotDefEntry* plot_centralValue = new plotDefEntry(*plot);
995  plot_centralValue->drawOptionEntry_ = drawOptionName_centralValue;
996  allHistograms.push_back(histogram_drawOption_pair(histogram_centralValue, plot_centralValue));
997  histogramsToDelete.push_back(histogram_centralValue);
998  drawOptionsToDelete.push_back(plot_centralValue);
999 
1000  //--- add histogram displaying uncertainty as shaded error band
1001  TH1* histogram_ErrorBand = dynamic_cast<TH1*>(histogram->Clone());
1002  histogram_ErrorBand->SetName(std::string(histogram->GetName()).append("_ErrorBand").data());
1003  cfgEntryDrawOption drawOptionConfig_ErrorBand(*drawOptionConfig);
1004  drawOptionConfig_ErrorBand.markerColor_ = drawOptionConfig_ErrorBand.fillColor_;
1005  drawOptionConfig_ErrorBand.markerSize_ = 0.;
1006  drawOptionConfig_ErrorBand.lineColor_ = drawOptionConfig_ErrorBand.fillColor_;
1007  drawOptionConfig_ErrorBand.lineWidth_ = 0;
1008  drawOptionConfig_ErrorBand.drawOption_ = "e2";
1009  drawOptionConfig_ErrorBand.drawOptionLegend_ = "f";
1010  std::string drawOptionName_ErrorBand = std::string(plot->drawOptionEntry_).append("_ErrorBand");
1011  //--- entries in std::map need to be unique,
1012  // so need to check whether drawOptionEntry already exists...
1013  if (drawOptionEntries_.find(drawOptionName_ErrorBand) == drawOptionEntries_.end())
1014  drawOptionEntries_.insert(std::pair<std::string, cfgEntryDrawOption>(
1015  drawOptionName_ErrorBand, cfgEntryDrawOption(drawOptionName_ErrorBand, drawOptionConfig_ErrorBand)));
1016  plotDefEntry* plot_ErrorBand = new plotDefEntry(*plot);
1017  plot_ErrorBand->drawOptionEntry_ = drawOptionName_ErrorBand;
1018  plot_ErrorBand->isErrorBand_ = true;
1019  allHistograms.push_back(histogram_drawOption_pair(histogram_ErrorBand, plot_ErrorBand));
1020  histogramsToDelete.push_back(histogram_ErrorBand);
1021  drawOptionsToDelete.push_back(plot_ErrorBand);
1022  } else if (plot->doStack_) {
1023  TH1* stackedHistogram = dynamic_cast<TH1*>(histogram->Clone());
1024  if (stackedHistogram_sum)
1025  stackedHistogram->Add(stackedHistogram_sum);
1026  stackedHistogram_sum = stackedHistogram;
1027  histogramsToDelete.push_back(stackedHistogram);
1028  allHistograms.push_back(histogram_drawOption_pair(stackedHistogram, &(*plot)));
1029  } else {
1030  allHistograms.push_back(histogram_drawOption_pair(histogram, &(*plot)));
1031  }
1032  }
1033 
1034  //--- determine normalization of y-axis
1035  // (maximum of any of the histograms included in drawJob)
1036  double yAxisNorm = 0.;
1037  for (std::list<histogram_drawOption_pair>::const_iterator it = allHistograms.begin(); it != allHistograms.end();
1038  ++it) {
1039  yAxisNorm = TMath::Max(yAxisNorm, it->first->GetMaximum());
1040  }
1041  //std::cout << " yAxisNorm = " << yAxisNorm << std::endl;
1042 
1043  //--- prepare histograms for drawing
1044  const cfgEntryAxisX* xAxisConfig = findCfgDef<cfgEntryAxisX>(drawJob->xAxis_, xAxes_, "xAxis", drawJobName);
1045  const cfgEntryAxisY* yAxisConfig = findCfgDef<cfgEntryAxisY>(drawJob->yAxis_, yAxes_, "yAxis", drawJobName);
1046  const cfgEntryLegend* legendConfig = findCfgDef<cfgEntryLegend>(drawJob->legend_, legends_, "legend", drawJobName);
1047  if (xAxisConfig == nullptr || yAxisConfig == nullptr || legendConfig == nullptr) {
1048  edm::LogError("endJob") << " Failed to access information needed by drawJob = " << drawJobName
1049  << " --> histograms will NOT be plotted !!";
1050  return;
1051  }
1052 
1053  //--- WARNING: need to call
1054  // TLegend::TLegend(Double_t, Double_t,Double_t, Double_t, const char* = "", Option_t* = "brNDC")
1055  // constructor, as TLegend::TLegend default constructor causes the created TLegend object to behave differently !!
1056  TLegend legend(defaultLegendPosX,
1060  legendConfig->applyTo(&legend);
1061 
1062  std::list<histoDrawEntry> smProcessHistogramList;
1063  std::list<histoDrawEntry> bsmProcessHistogramList;
1064  std::list<histoDrawEntry> smSumHistogramList;
1065  std::list<histoDrawEntry> smSumUncertaintyHistogramList;
1066  std::list<histoDrawEntry> dataHistogramList;
1067 
1068  for (std::list<histogram_drawOption_pair>::const_iterator it = allHistograms.begin(); it != allHistograms.end();
1069  ++it) {
1070  TH1* histogram = it->first;
1071  const plotDefEntry* drawOption = it->second;
1072 
1073  const cfgEntryDrawOption* drawOptionConfig = findCfgDef<cfgEntryDrawOption>(
1074  drawOption->drawOptionEntry_, drawOptionEntries_, "drawOptionEntry", drawJobName);
1075  const cfgEntryProcess* processConfig =
1076  findCfgDef<cfgEntryProcess>(drawOption->process_, processes_, "process", drawJobName);
1077  if (drawOptionConfig == nullptr || processConfig == nullptr) {
1078  edm::LogError("endJob") << " Failed to access information needed by drawJob = " << drawJobName
1079  << " --> histograms will NOT be plotted !!";
1080  return;
1081  }
1082 
1083  if (!drawJob->title_.empty())
1084  histogram->SetTitle(drawJob->title_.data());
1085 
1086  xAxisConfig->applyTo(histogram);
1087  yAxisConfig->applyTo(histogram, yAxisNorm);
1088 
1089  bool yLogScale = (yAxisConfig->yScale_ == yScale_log) ? true : false;
1090  //std::cout << " yLogScale = " << yLogScale << std::endl;
1091  //pad.SetLogy(yLogScale);
1092  canvas.SetLogy(yLogScale);
1093 
1094  drawOptionConfig->applyTo(histogram);
1095  histogram->SetStats(false);
1096 
1097  if (drawOption->isErrorBand_) {
1098  smSumUncertaintyHistogramList.push_back(histoDrawEntry(histogram, drawOptionConfig->drawOption_.data()));
1099  } else {
1100  if (processConfig->type_ == type_smMC) {
1101  smProcessHistogramList.push_back(histoDrawEntry(histogram, drawOptionConfig->drawOption_.data()));
1102  } else if (processConfig->type_ == type_bsmMC) {
1103  bsmProcessHistogramList.push_back(histoDrawEntry(histogram, drawOptionConfig->drawOption_.data()));
1104  } else if (processConfig->type_ == type_smSumMC) {
1105  smSumHistogramList.push_back(histoDrawEntry(histogram, drawOptionConfig->drawOption_.data()));
1106  } else if (processConfig->type_ == type_Data) {
1107  dataHistogramList.push_back(histoDrawEntry(histogram, drawOptionConfig->drawOption_.data()));
1108  }
1109  }
1110 
1111  std::string legendEntry, legendDrawOption;
1112  if (drawOption->isErrorBand_) {
1113  legendEntry = (!drawOption->legendEntryErrorBand_.empty()) ? drawOption->legendEntryErrorBand_
1114  : processConfig->legendEntryErrorBand_;
1115  legendDrawOption = "f";
1116  } else {
1117  legendEntry = (!drawOption->legendEntry_.empty()) ? drawOption->legendEntry_ : processConfig->legendEntry_;
1118  legendDrawOption = drawOptionConfig->drawOptionLegend_;
1119  }
1120 
1121  legend.AddEntry(histogram, legendEntry.data(), legendDrawOption.data());
1122  }
1123 
1124  std::list<TPaveText> labels;
1125  for (vstring::const_iterator labelName = drawJob->labels_.begin(); labelName != drawJob->labels_.end();
1126  ++labelName) {
1127  const cfgEntryLabel* labelConfig = findCfgDef<cfgEntryLabel>(*labelName, labels_, "label", drawJobName);
1128 
1129  TPaveText label;
1130  labelConfig->applyTo(&label);
1131 
1132  labels.push_back(label);
1133  }
1134 
1135  //--- draw histograms
1136  // - in the order:
1137  // 1. uncertainty on sum of all Standard Model processes
1138  // 2. sum of all Standard Model processes
1139  // 3. individual Standard Model processes
1140  // 4. individual beyond the Standard Model processes
1141  // 5. data
1142  bool isFirstHistogram = true;
1143  drawHistograms(smSumUncertaintyHistogramList, isFirstHistogram);
1144  drawHistograms(smSumHistogramList, isFirstHistogram);
1145 
1146  //--- process histograms for individual Standard Model processes
1147  // in reverse order, so that most stacked histogram gets drawn first
1148  for (std::list<histoDrawEntry>::reverse_iterator it = smProcessHistogramList.rbegin();
1149  it != smProcessHistogramList.rend();
1150  ++it) {
1151  std::string drawOption = (isFirstHistogram) ? it->second : std::string(it->second).append("same");
1152  it->first->Draw(drawOption.data());
1153  isFirstHistogram = false;
1154  }
1155 
1156  drawHistograms(bsmProcessHistogramList, isFirstHistogram);
1157  drawHistograms(dataHistogramList, isFirstHistogram);
1158 
1159  legend.Draw();
1160 
1161  for (std::list<TPaveText>::iterator label = labels.begin(); label != labels.end(); ++label) {
1162  label->Draw();
1163  }
1164 
1165  //pad.RedrawAxis();
1166 
1167  canvas.Update();
1168  //pad.Update();
1169 
1170  if (!indOutputFileName_.empty() && toFile_) {
1171  int errorFlag = 0;
1172  std::string modIndOutputFileName = replace_string(indOutputFileName_, plotKeyword, drawJobName, 1, 1, errorFlag);
1173  if (!errorFlag) {
1174  std::string fullFileName = (!outputFilePath_.empty())
1175  ? std::string(outputFilePath_).append("/").append(modIndOutputFileName)
1176  : modIndOutputFileName;
1177  canvas.Print(fullFileName.data());
1178  } else {
1179  edm::LogError("endJob") << " Failed to decode indOutputFileName = " << indOutputFileName_ << " --> skipping !!";
1180  }
1181  }
1182 
1183  if (ps)
1184  ps->NewPage();
1185 
1186  //--- delete temporarily created histogram and drawOption objects
1187  for (std::list<TH1*>::const_iterator histogram = histogramsToDelete.begin(); histogram != histogramsToDelete.end();
1188  ++histogram) {
1189  delete (*histogram);
1190  }
1191 
1192  for (std::list<plotDefEntry*>::const_iterator drawOption = drawOptionsToDelete.begin();
1193  drawOption != drawOptionsToDelete.end();
1194  ++drawOption) {
1195  delete (*drawOption);
1196  }
1197  }
1198 
1199  //--- close postscript file
1200  canvas.Clear();
1201  if (verbosity)
1202  std::cout << "done." << std::endl;
1203  if (ps)
1204  ps->Close();
1205  delete ps;
1206 }

References mps_setup::append, TauDQMHistPlotter::cfgEntryAxisX::applyTo(), TauDQMHistPlotter::cfgEntryAxisY::applyTo(), TauDQMHistPlotter::cfgEntryLegend::applyTo(), TauDQMHistPlotter::cfgEntryLabel::applyTo(), TauDQMHistPlotter::cfgEntryDrawOption::applyTo(), svgfig::canvas(), canvasSizeX_, canvasSizeY_, cfgError_, gather_cfg::cout, defaultLegendPosX, defaultLegendPosY, defaultLegendSizeX, defaultLegendSizeY, dqmDirectoryName(), dqmRootDirectory, L1TBPTX_cfi::dqmStore, drawHistograms(), drawJobs_, histoStyle::drawOption, TauDQMHistPlotter::cfgEntryDrawOption::drawOption_, drawOption_eBand, drawOptionEntries_, TauDQMHistPlotter::plotDefEntry::drawOptionEntry_, TauDQMHistPlotter::cfgEntryDrawOption::drawOptionLegend_, TauDQMHistPlotter::cfgEntryDrawOption::fillColor_, TauDQMHistPlotter::cfgEntryDrawOption::fillStyle_, dqm::legacy::MonitorElement::getTH1F(), indOutputFileName_, TauDQMHistPlotter::plotDefEntry::isErrorBand_, label, SummaryClient_cfi::labels, labels_, listHistos::legend, RecoTauValidation_cfi::legendEntry, TauDQMHistPlotter::cfgEntryProcess::legendEntry_, TauDQMHistPlotter::cfgEntryProcess::legendEntryErrorBand_, legends_, TauDQMHistPlotter::cfgEntryDrawOption::lineColor_, TauDQMHistPlotter::cfgEntryDrawOption::lineWidth_, TauDQMHistPlotter::cfgEntryDrawOption::markerColor_, TauDQMHistPlotter::cfgEntryDrawOption::markerSize_, Max(), outputFileName_, outputFilePath_, plotFactory::plot, plotKeyword, processes_, HLT_Fake2_cff::psFileName, replace_string(), AlCaHLTBitMon_QueryRunRegistry::string, toFile_, TauDQMHistPlotter::cfgEntryProcess::type_, type_bsmMC, type_Data, type_smMC, type_smSumMC, verbosity, xAxes_, yAxes_, TauDQMHistPlotter::cfgEntryAxisY::yScale_, and yScale_log.

Member Data Documentation

◆ canvasSizeX_

int TauDQMHistPlotter::canvasSizeX_
private

Definition at line 170 of file DQMHistPlotter.h.

Referenced by endRun(), and TauDQMHistPlotter().

◆ canvasSizeY_

int TauDQMHistPlotter::canvasSizeY_
private

Definition at line 171 of file DQMHistPlotter.h.

Referenced by endRun(), and TauDQMHistPlotter().

◆ cfgError_

int TauDQMHistPlotter::cfgError_
private

Definition at line 175 of file DQMHistPlotter.h.

Referenced by endRun(), and TauDQMHistPlotter().

◆ drawJobs_

std::list<cfgEntryDrawJob> TauDQMHistPlotter::drawJobs_
private

Definition at line 169 of file DQMHistPlotter.h.

Referenced by endRun(), and TauDQMHistPlotter().

◆ drawOptionEntries_

std::map<std::string, cfgEntryDrawOption> TauDQMHistPlotter::drawOptionEntries_
private

Definition at line 168 of file DQMHistPlotter.h.

Referenced by endRun(), and TauDQMHistPlotter().

◆ indOutputFileName_

std::string TauDQMHistPlotter::indOutputFileName_
private

Definition at line 174 of file DQMHistPlotter.h.

Referenced by endRun(), and TauDQMHistPlotter().

◆ labels_

std::map<std::string, cfgEntryLabel> TauDQMHistPlotter::labels_
private

◆ legends_

std::map<std::string, cfgEntryLegend> TauDQMHistPlotter::legends_
private

Definition at line 166 of file DQMHistPlotter.h.

Referenced by endRun(), and TauDQMHistPlotter().

◆ outputFileName_

std::string TauDQMHistPlotter::outputFileName_
private

Definition at line 173 of file DQMHistPlotter.h.

Referenced by endRun(), and TauDQMHistPlotter().

◆ outputFilePath_

std::string TauDQMHistPlotter::outputFilePath_
private

Definition at line 172 of file DQMHistPlotter.h.

Referenced by endRun(), and TauDQMHistPlotter().

◆ processes_

std::map<std::string, cfgEntryProcess> TauDQMHistPlotter::processes_
private

Definition at line 163 of file DQMHistPlotter.h.

Referenced by endRun(), and TauDQMHistPlotter().

◆ toFile_

bool TauDQMHistPlotter::toFile_
private

Definition at line 176 of file DQMHistPlotter.h.

Referenced by endRun(), and TauDQMHistPlotter().

◆ xAxes_

std::map<std::string, cfgEntryAxisX> TauDQMHistPlotter::xAxes_
private

Definition at line 164 of file DQMHistPlotter.h.

Referenced by endRun(), and TauDQMHistPlotter().

◆ yAxes_

std::map<std::string, cfgEntryAxisY> TauDQMHistPlotter::yAxes_
private

Definition at line 165 of file DQMHistPlotter.h.

Referenced by endRun(), and TauDQMHistPlotter().

defaultLegendSizeX
const double defaultLegendSizeX
Definition: DQMHistPlotter.cc:50
SummaryClient_cfi.labels
labels
Definition: SummaryClient_cfi.py:61
svgfig.canvas
def canvas(*sub, **attr)
Definition: svgfig.py:482
defaultCanvasSizeY
const int defaultCanvasSizeY
Definition: DQMHistPlotter.cc:86
RecoTauValidation_cfi.drawOptionSets
drawOptionSets
Definition: RecoTauValidation_cfi.py:346
runGCPTkAlMap.title
string title
Definition: runGCPTkAlMap.py:94
drawOption_eBand
const std::string drawOption_eBand
Definition: DQMHistPlotter.cc:82
pfMETsysShiftCorrections_cfi.parameter
parameter
Definition: pfMETsysShiftCorrections_cfi.py:118
mps_splice.entry
entry
Definition: mps_splice.py:68
gather_cfg.cout
cout
Definition: gather_cfg.py:144
replace_string
std::string replace_string(const std::string &src, const std::string &keyword, const std::string &parameter, unsigned minReplacements, unsigned maxReplacements, int &errorFlag)
Definition: dqmAuxFunctions.cc:11
defaultLegendPosX
const double defaultLegendPosX
Definition: DQMHistPlotter.cc:48
dqm::legacy::MonitorElement
Definition: MonitorElement.h:462
defaultCanvasSizeX
const int defaultCanvasSizeX
Definition: DQMHistPlotter.cc:85
parKeyword
const std::string parKeyword
Definition: dqmAuxFunctions.h:12
edm::ParameterSet::existsAs
bool existsAs(std::string const &parameterName, bool trackiness=true) const
checks if a parameter exists as a given type
Definition: ParameterSet.h:171
verbosity
const int verbosity
Definition: DQMHistPlotter.cc:90
plotFactory.plot
plot
Definition: plotFactory.py:109
dqm::legacy::MonitorElement::getTH1F
virtual TH1F * getTH1F() const
Definition: MonitorElement.h:479
type_smSumMC
const std::string type_smSumMC
Definition: DQMHistPlotter.cc:25
dqm::legacy::DQMStore
Definition: DQMStore.h:727
dqmDirectoryName
std::string dqmDirectoryName(const std::string &dqmRootDirectory, const std::string &dqmSubDirectory)
Definition: EwkTauDQM.cc:10
dqmRootDirectory
const std::string dqmRootDirectory
Definition: dqmAuxFunctions.h:38
drawOptionSeparator
const std::string drawOptionSeparator
Definition: DQMHistPlotter.cc:88
RecoTauValidation_cfi.legendEntry
legendEntry
Definition: RecoTauValidation_cfi.py:375
L1TBPTX_cfi.dqmStore
dqmStore
Definition: L1TBPTX_cfi.py:6
processDirKeyword
const std::string processDirKeyword
Definition: dqmAuxFunctions.h:15
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
TauDQMHistPlotter::legends_
std::map< std::string, cfgEntryLegend > legends_
Definition: DQMHistPlotter.h:166
edm::ParameterSet::exists
bool exists(std::string const &parameterName) const
checks if a parameter exists
Definition: ParameterSet.cc:681
svgfig.stack
stack
Definition: svgfig.py:559
TauDQMHistPlotter::vstring
std::vector< std::string > vstring
Definition: DQMHistPlotter.h:31
TauDQMHistPlotter::toFile_
bool toFile_
Definition: DQMHistPlotter.h:176
type_Data
const std::string type_Data
Definition: DQMHistPlotter.cc:26
edm::ParameterSet
Definition: ParameterSet.h:47
HLTObjectsMonitor_cfi.plots
plots
Definition: HLTObjectsMonitor_cfi.py:17
TauDQMHistPlotter::outputFileName_
std::string outputFileName_
Definition: DQMHistPlotter.h:173
type
type
Definition: SiPixelVCal_PayloadInspector.cc:37
HLT_FULL_cff.yAxis
yAxis
Definition: HLT_FULL_cff.py:46156
LaserDQM_cfg.process
process
Definition: LaserDQM_cfg.py:3
histoDrawEntry
std::pair< TH1 *, std::string > histoDrawEntry
Definition: DQMHistPlotter.cc:137
mps_setup.append
append
Definition: mps_setup.py:85
TauDQMHistPlotter::xAxes_
std::map< std::string, cfgEntryAxisX > xAxes_
Definition: DQMHistPlotter.h:164
listHistos.legend
legend
Definition: listHistos.py:41
type_bsmMC
const std::string type_bsmMC
Definition: DQMHistPlotter.cc:24
edm::Service
Definition: Service.h:30
edm::ParameterSet::getParameterNamesForType
std::vector< std::string > getParameterNamesForType(bool trackiness=true) const
Definition: ParameterSet.h:179
HLT_Fake2_cff.psFileName
psFileName
Definition: HLT_Fake2_cff.py:181
TauDQMHistPlotter::labels_
std::map< std::string, cfgEntryLabel > labels_
Definition: DQMHistPlotter.h:167
Max
T Max(T a, T b)
Definition: MathUtil.h:44
defaultLegendPosY
const double defaultLegendPosY
Definition: DQMHistPlotter.cc:49
TauDQMHistPlotter::plotDefList
std::list< plotDefEntry > plotDefList
Definition: DQMHistPlotter.h:136
TauDQMHistPlotter::processes_
std::map< std::string, cfgEntryProcess > processes_
Definition: DQMHistPlotter.h:163
edm::LogError
Log< level::Error, false > LogError
Definition: MessageLogger.h:123
TauDQMHistPlotter::outputFilePath_
std::string outputFilePath_
Definition: DQMHistPlotter.h:172
type_smMC
const std::string type_smMC
Definition: DQMHistPlotter.cc:23
TauDQMHistPlotter::drawOptionEntries_
std::map< std::string, cfgEntryDrawOption > drawOptionEntries_
Definition: DQMHistPlotter.h:168
looper.cfg
cfg
Definition: looper.py:297
TauDQMHistPlotter::cfgError_
int cfgError_
Definition: DQMHistPlotter.h:175
plotKeyword
const std::string plotKeyword
Definition: dqmAuxFunctions.h:13
TauDQMHistPlotter::drawJobs_
std::list< cfgEntryDrawJob > drawJobs_
Definition: DQMHistPlotter.h:169
TauDQMHistPlotter::canvasSizeY_
int canvasSizeY_
Definition: DQMHistPlotter.h:171
HLT_FULL_cff.xAxis
xAxis
Definition: HLT_FULL_cff.py:46154
dqmiodatasetharvest.processes
processes
Definition: dqmiodatasetharvest.py:190
vstring
vector< string > vstring
Definition: ExoticaDQM.cc:8
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
AlignmentPI::index
index
Definition: AlignmentPayloadInspectorHelper.h:46
defaultLegendSizeY
const double defaultLegendSizeY
Definition: DQMHistPlotter.cc:51
find_vstring
bool find_vstring(const std::vector< std::string > &vs, const std::string &s)
Definition: DQMHistPlotter.cc:151
drawHistograms
void drawHistograms(const std::list< histoDrawEntry > &histogramList, bool &isFirstHistogram)
Definition: DQMHistPlotter.cc:139
TauDQMHistPlotter::canvasSizeX_
int canvasSizeX_
Definition: DQMHistPlotter.h:170
label
const char * label
Definition: PFTauDecayModeTools.cc:11
yScale_log
const std::string yScale_log
Definition: DQMHistPlotter.cc:40
TauDQMHistPlotter::indOutputFileName_
std::string indOutputFileName_
Definition: DQMHistPlotter.h:174
TauDQMHistPlotter::yAxes_
std::map< std::string, cfgEntryAxisY > yAxes_
Definition: DQMHistPlotter.h:165
histoStyle.drawOption
drawOption
Definition: histoStyle.py:56