CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Classes | Public Member Functions | Public Attributes | Private Member Functions | Private Attributes
SiStripMonitorDigi Class Reference

#include <DQM/SiStripMonitorDigi/src/SiStripMonitorDigi.cc>

Inheritance diagram for SiStripMonitorDigi:
edm::EDAnalyzer edm::EDConsumerBase

Classes

struct  DigiFailureMEs
 
struct  LayerMEs
 
struct  ModMEs
 
struct  SubDetMEs
 

Public Member Functions

virtual void analyze (const edm::Event &, const edm::EventSetup &)
 
virtual void beginJob ()
 
virtual void beginLuminosityBlock (const edm::LuminosityBlock &, const edm::EventSetup &)
 
virtual void beginRun (const edm::Run &, const edm::EventSetup &)
 
virtual void endJob ()
 
virtual void endLuminosityBlock (const edm::LuminosityBlock &, const edm::EventSetup &)
 
virtual void endRun (const edm::Run &, const edm::EventSetup &)
 
 SiStripMonitorDigi (const edm::ParameterSet &)
 
 ~SiStripMonitorDigi ()
 
- Public Member Functions inherited from edm::EDAnalyzer
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzer ()
 
ModuleDescription const & moduleDescription () const
 
std::string workerType () const
 
virtual ~EDAnalyzer ()
 
- Public Member Functions inherited from edm::EDConsumerBase
 EDConsumerBase ()
 
ProductHolderIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
std::vector
< ProductHolderIndexAndSkipBit >
const & 
itemsToGetFromEvent () const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
bool registeredToConsume (ProductHolderIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
void updateLookup (BranchType iBranchType, ProductHolderIndexHelper const &)
 
virtual ~EDConsumerBase ()
 

Public Attributes

std::string topFolderName_
 

Private Member Functions

void AddApvShotsToSubDet (const std::vector< APVShot > &, std::vector< APVShot > &)
 
bool AllDigis (const edm::EventSetup &es)
 
void bookLayer ()
 
MonitorElementbookME1D (const char *ParameterSetLabel, const char *HistoName)
 
MonitorElementbookMETrend (const char *ParameterSetLabel, const char *HistoName)
 
void bookTrendMEs (const TString &name, int32_t layer, uint32_t id, std::string flag)
 
void createLayerMEs (std::string label, int ndet)
 
void createMEs (const edm::EventSetup &es)
 
void createModuleMEs (ModMEs &mod_single, uint32_t detid)
 
void createSubDetMEs (std::string label)
 
void createSubDetTH2 (std::string label)
 
void FillApvShotsMap (TkHistoMap *, const std::vector< APVShot > &, uint32_t id, int)
 
void fillDigiADCsMEs (int value, std::string name)
 
void fillME (MonitorElement *ME, float value1)
 
void fillME (MonitorElement *ME, float value1, float value2)
 
void fillME (MonitorElement *ME, float value1, float value2, float value3)
 
void fillME (MonitorElement *ME, float value1, float value2, float value3, float value4)
 
void fillTrend (MonitorElement *me, float value, float timeinorbit)
 
int getDigiSourceIndex (uint32_t id)
 
void ResetModuleMEs (uint32_t idet)
 

Private Attributes

edm::InputTag apvPhaseProducer_
 
edm::EDGetTokenT
< APVCyclePhaseCollection
apvPhaseProducerToken_
 
bool calculate_strip_occupancy
 
edm::ParameterSet conf_
 
bool createTrendMEs
 
SiStripDCSStatusdcsStatus_
 
std::map< std::pair
< std::string, int32_t >, bool > 
DetectedLayers
 
std::vector< const
edm::DetSetVector< SiStripDigi > * > 
digi_detset_handles
 
DigiFailureMEs digiFailureMEs
 
std::map< uint32_t, ModMEsDigiMEs
 
std::vector< edm::InputTagdigiProducerList
 
std::vector< edm::EDGetTokenT
< edm::DetSetVector
< SiStripDigi > > > 
digiProducerTokenList
 
bool digitkhistomapon
 
DQMStoredqmStore_
 
int eventNb
 
int firstEvent
 
SiStripFolderOrganizer folder_organizer
 
bool globalsummaryapvshotson
 
bool globalswitchapvshotsApvon
 
bool globalswitchapvshotsonprof
 
bool globalswitchchargemedianapvshotson
 
bool globalswitchnapvshotson
 
bool globalswitchnstripsapvshotson
 
edm::EDGetTokenT
< L1GlobalTriggerEvmReadoutRecord
gtEvmToken_
 
edm::InputTag historyProducer_
 
edm::EDGetTokenT
< EventWithHistory
historyProducerToken_
 
int ignoreFirstNLumisections_
 
int integrateNLumisections_
 
bool isStableBeams
 
std::map< std::string,
std::vector< uint32_t > > 
LayerDetMap
 
std::map< std::string, LayerMEsLayerMEsMap
 
bool layerswitchadccooleston
 
bool layerswitchadchotteston
 
bool layerswitchdigiadcprofon
 
bool layerswitchdigiadcson
 
bool layerswitchnumdigisapvon
 
bool layerswitchnumdigison
 
bool layerswitchnumdigisprofon
 
bool layerswitchstripoccupancyon
 
unsigned long long m_cacheID_
 
MonitorElementMedianChargeApvShotsGlobal
 
bool Mod_On_
 
std::vector< uint32_t > ModulesToBeExcluded_
 
bool moduleswitchadccooleston
 
bool moduleswitchadchotteston
 
bool moduleswitchdigiadcson
 
bool moduleswitchnumdigison
 
bool moduleswitchnumdigispstripon
 
bool moduleswitchstripoccupancyon
 
TString name
 
MonitorElementNApvApvShotsGlobal
 
MonitorElementNApvShotsGlobal
 
MonitorElementNApvShotsGlobalProf
 
int nFedTECm
 
int nFedTECp
 
int nFedTIB
 
int nFedTIDm
 
int nFedTIDp
 
int nFedTOB
 
bool reset_each_run
 
int runNb
 
int SBDeclaredAt
 
bool SBTransitionDone
 
bool select_all_detectors
 
bool shotschargehistomapon
 
bool shotshistomapon
 
bool shotsstripshistomapon
 
MonitorElementShotsVsTimeApvShotsGlobal
 
bool show_control_view
 
bool show_mechanical_structure_view
 
bool show_readout_view
 
edm::ESHandle< SiStripDetCablingSiStripDetCabling_
 
MonitorElementStripMultiplicityApvShotsGlobal
 
std::map< std::string, SubDetMEsSubDetMEsMap
 
std::map< std::string,
std::string > 
SubDetPhasePartMap
 
bool subdetswitchapvcycleprofon
 
bool subdetswitchapvcycleth2on
 
bool subdetswitchapvshotsApvon
 
bool subdetswitchapvshotsonprof
 
bool subdetswitchchargemedianapvshotson
 
bool subdetswitchnapvshotson
 
bool subdetswitchnstripsapvshotson
 
bool subdetswitchtotdigifailureon
 
bool subdetswitchtotdigiproflson
 
bool subdetswitchtotdigiprofon
 
TkHistoMaptkmapdigi
 
TkHistoMaptkmapMedianChargeApvshots
 
TkHistoMaptkmapNApvshots
 
TkHistoMaptkmapNstripApvshot
 
int TotalNShots
 

Additional Inherited Members

- Public Types inherited from edm::EDAnalyzer
typedef EDAnalyzer ModuleType
 
- Static Public Member Functions inherited from edm::EDAnalyzer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &)
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
EDGetToken consumes (const TypeToGet &id, 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 ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 

Detailed Description

Data Quality Monitoring source of the Silicon Strip Tracker. Produces histograms related to digis.

Description: <one line="" class="" summary>="">

Implementation: <Notes on="" implementation>="">

Definition at line 32 of file SiStripMonitorDigi.h.

Constructor & Destructor Documentation

SiStripMonitorDigi::SiStripMonitorDigi ( const edm::ParameterSet iConfig)
explicit

Definition at line 46 of file SiStripMonitorDigi.cc.

References apvPhaseProducer_, apvPhaseProducerToken_, conf_, edm::EDConsumerBase::consumes(), createTrendMEs, dcsStatus_, digiProducerList, digiProducerTokenList, digitkhistomapon, eventNb, firstEvent, edm::ParameterSet::getParameter(), globalsummaryapvshotson, globalswitchapvshotsApvon, globalswitchapvshotsonprof, globalswitchchargemedianapvshotson, globalswitchnapvshotson, globalswitchnstripsapvshotson, gtEvmToken_, historyProducer_, historyProducerToken_, ignoreFirstNLumisections_, integrateNLumisections_, isStableBeams, layerswitchadccooleston, layerswitchadchotteston, layerswitchdigiadcprofon, layerswitchdigiadcson, layerswitchnumdigison, layerswitchnumdigisprofon, layerswitchstripoccupancyon, siStripFEDMonitor_P5_cff::Max, Mod_On_, moduleswitchadccooleston, moduleswitchadchotteston, moduleswitchdigiadcson, moduleswitchnumdigison, moduleswitchnumdigispstripon, moduleswitchstripoccupancyon, SBDeclaredAt, SBTransitionDone, shotschargehistomapon, shotshistomapon, shotsstripshistomapon, AlCaHLTBitMon_QueryRunRegistry::string, SubDetPhasePartMap, subdetswitchapvcycleprofon, subdetswitchapvcycleth2on, subdetswitchapvshotsApvon, subdetswitchapvshotsonprof, subdetswitchchargemedianapvshotson, subdetswitchnapvshotson, subdetswitchnstripsapvshotson, subdetswitchtotdigifailureon, subdetswitchtotdigiprofon, GlobalPosition_Frontier_DevDB_cff::tag, and topFolderName_.

46  :
48  conf_(iConfig),
50  show_readout_view (false),
51  show_control_view (false),
52  select_all_detectors (true),
53  reset_each_run (false),
55  m_cacheID_(0)
56 {
57  firstEvent = -1;
58  eventNb = 0;
59 
60  // Detector Partitions
61  SubDetPhasePartMap["TIB"] = "TI";
62  SubDetPhasePartMap["TID__MINUS"] = "TI";
63  SubDetPhasePartMap["TID__PLUS"] = "TI";
64  SubDetPhasePartMap["TOB"] = "TO";
65  SubDetPhasePartMap["TEC__MINUS"] = "TM";
66  SubDetPhasePartMap["TEC__PLUS"] = "TP";
67 
68  topFolderName_ = conf_.getParameter<std::string>("TopFolderName");
69 
70  // get Digi Producer List
71  digiProducerList = conf_.getParameter<std::vector<edm::InputTag> >("DigiProducersList");
72  for (auto const& tag : digiProducerList) {
74  }
75 
76  //get on/off option for every cluster from cfi
77  edm::ParameterSet ParametersNumberOfDigis = conf_.getParameter<edm::ParameterSet>("TH1NumberOfDigis");
78  layerswitchnumdigison = ParametersNumberOfDigis.getParameter<bool>("layerswitchon");
79  moduleswitchnumdigison = ParametersNumberOfDigis.getParameter<bool>("moduleswitchon");
80 
81  edm::ParameterSet ParametersNumberOfDigisPerStrip = conf_.getParameter<edm::ParameterSet>("TH1NumberOfDigisPerStrip");
82  moduleswitchnumdigispstripon = ParametersNumberOfDigisPerStrip.getParameter<bool>("moduleswitchon");
83 
84  edm::ParameterSet ParametersADCsHottestStrip = conf_.getParameter<edm::ParameterSet>("TH1ADCsHottestStrip");
85  layerswitchadchotteston = ParametersADCsHottestStrip.getParameter<bool>("layerswitchon");
86  moduleswitchadchotteston = ParametersADCsHottestStrip.getParameter<bool>("moduleswitchon");
87 
88  edm::ParameterSet ParametersADCsCoolestStrip = conf_.getParameter<edm::ParameterSet>("TH1ADCsCoolestStrip");
89  layerswitchadccooleston = ParametersADCsCoolestStrip.getParameter<bool>("layerswitchon");
90  moduleswitchadccooleston = ParametersADCsCoolestStrip.getParameter<bool>("moduleswitchon");
91 
92  edm::ParameterSet ParametersDigiADCs = conf_.getParameter<edm::ParameterSet>("TH1DigiADCs");
93  layerswitchdigiadcson = ParametersDigiADCs.getParameter<bool>("layerswitchon");
94  moduleswitchdigiadcson = ParametersDigiADCs.getParameter<bool>("moduleswitchon");
95 
96  edm::ParameterSet ParametersStripOccupancy = conf_.getParameter<edm::ParameterSet>("TH1StripOccupancy");
97  layerswitchstripoccupancyon = ParametersStripOccupancy.getParameter<bool>("layerswitchon");
98  moduleswitchstripoccupancyon = ParametersStripOccupancy.getParameter<bool>("moduleswitchon");
99 
100  edm::ParameterSet ParametersDigiProf = conf_.getParameter<edm::ParameterSet>("TProfNumberOfDigi");
101  layerswitchnumdigisprofon = ParametersDigiProf.getParameter<bool>("layerswitchon");
102 
103  edm::ParameterSet ParametersDigiADC = conf_.getParameter<edm::ParameterSet>("TProfDigiADC");
104  layerswitchdigiadcprofon = ParametersDigiProf.getParameter<bool>("layerswitchon");
105 
106  edm::ParameterSet ParametersTotDigiProf = conf_.getParameter<edm::ParameterSet>("TProfTotalNumberOfDigis");
107  subdetswitchtotdigiprofon = ParametersTotDigiProf.getParameter<bool>("subdetswitchon");
108 
109  // edm::ParameterSet ParametersTotDigisProfVsLS = conf_.getParameter<edm::ParameterSet>("TProfTotalNumberOfDigisVsLS");
110  // subdetswitchtotdigiproflson = ParametersTotDigisProfVsLS.getParameter<bool>("subdetswitchon");
111 
112  edm::ParameterSet ParametersTotDigiFailure = conf_.getParameter<edm::ParameterSet>("TotalNumberOfDigisFailure");
113  subdetswitchtotdigifailureon = ParametersTotDigiFailure.getParameter<bool>("subdetswitchon");
114 
115  edm::ParameterSet ParametersDigiApvProf = conf_.getParameter<edm::ParameterSet>("TProfDigiApvCycle");
116  subdetswitchapvcycleprofon = ParametersDigiApvProf.getParameter<bool>("subdetswitchon");
117 
118  edm::ParameterSet ParametersDigiApvTH2 = conf_.getParameter<edm::ParameterSet>("TH2DigiApvCycle");
119  subdetswitchapvcycleth2on = ParametersDigiApvTH2.getParameter<bool>("subdetswitchon");
120 
121  edm::ParameterSet ParametersNApvShots = conf_.getParameter<edm::ParameterSet>("TH1NApvShots");
122  subdetswitchnapvshotson = ParametersNApvShots.getParameter<bool>("subdetswitchon");
123 
124  edm::ParameterSet ParametersNStripApvShots = conf_.getParameter<edm::ParameterSet>("TH1NStripsApvShots");
125  subdetswitchnstripsapvshotson = ParametersNStripApvShots.getParameter<bool>("subdetswitchon");
126 
127  edm::ParameterSet ParametersChargeMedianApvShots = conf_.getParameter<edm::ParameterSet>("TH1ChargeMedianApvShots");
128  subdetswitchchargemedianapvshotson = ParametersChargeMedianApvShots.getParameter<bool>("subdetswitchon");
129 
130  edm::ParameterSet ParametersApvNumberApvShots = conf_.getParameter<edm::ParameterSet>("TH1ApvNumApvShots");
131  subdetswitchapvshotsApvon = ParametersChargeMedianApvShots.getParameter<bool>("subdetswitchon");
132 
133  edm::ParameterSet ParametersNApvShotsProf = conf_.getParameter<edm::ParameterSet>("TProfNShotsVsTime");
134  subdetswitchapvshotsonprof = ParametersNApvShotsProf.getParameter<bool>("subdetswitchon");
135 
136  //Global Histograms
137 
138  edm::ParameterSet ParametersGlobalNApvShots = conf_.getParameter<edm::ParameterSet>("TH1NApvShots");
139  globalswitchnapvshotson = ParametersGlobalNApvShots.getParameter<bool>("globalswitchon");
140 
141  edm::ParameterSet ParametersGlobalNApvShotsProf = conf_.getParameter<edm::ParameterSet>("TProfGlobalNShots");
142  globalsummaryapvshotson = ParametersGlobalNApvShotsProf.getParameter<bool>("globalswitchon");
143 
144  edm::ParameterSet ParametersGlobalNStripApvShots = conf_.getParameter<edm::ParameterSet>("TH1NStripsApvShots");
145  globalswitchnstripsapvshotson = ParametersGlobalNStripApvShots.getParameter<bool>("globalswitchon");
146 
147  edm::ParameterSet ParametersGlobalApvNumApvShots = conf_.getParameter<edm::ParameterSet>("TH1ApvNumApvShots");
148  globalswitchapvshotsApvon = ParametersGlobalApvNumApvShots.getParameter<bool>("globalswitchon");
149 
150  edm::ParameterSet ParametersGlobalChargeMedianApvShots = conf_.getParameter<edm::ParameterSet>("TH1ChargeMedianApvShots");
151  globalswitchchargemedianapvshotson = ParametersGlobalChargeMedianApvShots.getParameter<bool>("globalswitchon");
152 
153  edm::ParameterSet ParametersGlobalNApvShotsTimeProf = conf_.getParameter<edm::ParameterSet>("TProfNShotsVsTime");
154  globalswitchapvshotsonprof = ParametersGlobalNApvShotsTimeProf.getParameter<bool>("globalswitchon");
155 
156  //Digi and APV Shots Maps
157 
158  digitkhistomapon = conf_.getParameter<bool>("TkHistoMap_On");
159 
160  shotshistomapon = conf_.getParameter<bool>("TkHistoMapNApvShots_On");
161  shotsstripshistomapon = conf_.getParameter<bool>("TkHistoMapNStripApvShots_On");
162  shotschargehistomapon = conf_.getParameter<bool>("TkHistoMapMedianChargeApvShots_On");
163 
164  createTrendMEs = conf_.getParameter<bool>("CreateTrendMEs");
165  Mod_On_ = conf_.getParameter<bool>("Mod_On");
166  // xLumiProf = conf_.getParameter<int>("xLumiProf");
167  // Event History Producer
168  historyProducer_ = conf_.getParameter<edm::InputTag>("HistoryProducer");
169  historyProducerToken_ = consumes<EventWithHistory>(conf_.getParameter<edm::InputTag>("HistoryProducer") );
170 
171  // Apv Phase Producer
172  apvPhaseProducer_ = conf_.getParameter<edm::InputTag>("ApvPhaseProducer");
173  apvPhaseProducerToken_ = consumes<APVCyclePhaseCollection>(conf_.getParameter<edm::InputTag>("ApvPhaseProducer") );
174 
175  gtEvmToken_ = consumes<L1GlobalTriggerEvmReadoutRecord>(edm::InputTag("gtEvmDigis") );
176 
177  // Create DCS Status
178  bool checkDCS = conf_.getParameter<bool>("UseDCSFiltering");
179  if (checkDCS) dcsStatus_ = new SiStripDCSStatus();
180  else dcsStatus_ = 0;
181 
182  //initialize boolean for the data-presence check (needed for TotalNumberOfDigisFailure histogram)
183  isStableBeams = false;
184  SBTransitionDone = false;
185  SBDeclaredAt = 0;
186  ignoreFirstNLumisections_ = TMath::Max ( 0 , ParametersTotDigiFailure.getParameter<int32_t>("ignoreFirstNLumisections") );
187  integrateNLumisections_ = TMath::Max ( 1 , ParametersTotDigiFailure.getParameter<int32_t>("integrateNLumisections") );
188 }
T getParameter(std::string const &) const
edm::InputTag historyProducer_
std::map< std::string, std::string > SubDetPhasePartMap
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
unsigned long long m_cacheID_
SiStripDCSStatus * dcsStatus_
edm::EDGetTokenT< EventWithHistory > historyProducerToken_
edm::EDGetTokenT< L1GlobalTriggerEvmReadoutRecord > gtEvmToken_
std::vector< edm::EDGetTokenT< edm::DetSetVector< SiStripDigi > > > digiProducerTokenList
edm::InputTag apvPhaseProducer_
std::string topFolderName_
edm::ParameterSet conf_
std::vector< edm::InputTag > digiProducerList
edm::EDGetTokenT< APVCyclePhaseCollection > apvPhaseProducerToken_
SiStripFolderOrganizer folder_organizer
SiStripMonitorDigi::~SiStripMonitorDigi ( )

Definition at line 191 of file SiStripMonitorDigi.cc.

References dcsStatus_.

191  {
192  if (dcsStatus_) delete dcsStatus_;
193 }
SiStripDCSStatus * dcsStatus_

Member Function Documentation

void SiStripMonitorDigi::AddApvShotsToSubDet ( const std::vector< APVShot > &  moduleShots,
std::vector< APVShot > &  subdetShots 
)
private

Definition at line 1229 of file SiStripMonitorDigi.cc.

References i.

Referenced by analyze().

1229  {
1230 
1231  for (uint i=0; i<moduleShots.size(); i++){
1232  subdetShots.push_back(moduleShots[i]);
1233  }
1234 }
int i
Definition: DBlmapReader.cc:9
bool SiStripMonitorDigi::AllDigis ( const edm::EventSetup es)
private
void SiStripMonitorDigi::analyze ( const edm::Event iEvent,
const edm::EventSetup iSetup 
)
virtual

Implements edm::EDAnalyzer.

Definition at line 556 of file SiStripMonitorDigi.cc.

References ecalMGPA::adc(), SiStripMonitorDigi::ModMEs::ADCsCoolestStrip, SiStripMonitorDigi::ModMEs::ADCsHottestStrip, AddApvShotsToSubDet(), apvPhaseProducerToken_, L1GtfeExtWord::beamMode(), createTrendMEs, edm::DetSet< T >::data, dcsStatus_, cond::rpcobgas::detid, digi_detset_handles, SiStripMonitorDigi::ModMEs::DigiADCs, digiFailureMEs, DigiMEs, digiProducerList, digiProducerTokenList, digitkhistomapon, eventNb, edm::HandleBase::failedToGet(), TkHistoMap::fill(), MonitorElement::Fill(), HcalObjRepresent::Fill(), FillApvShotsMap(), fillME(), fillTrend(), folder_organizer, edm::EventSetup::get(), edm::Event::getByToken(), getDigiSourceIndex(), APVShotFinder::getShots(), SiStripDCSStatus::getStatus(), SiStripFolderOrganizer::getSubDetFolderAndTag(), globalsummaryapvshotson, globalswitchapvshotsApvon, globalswitchapvshotsonprof, globalswitchchargemedianapvshotson, globalswitchnapvshotson, globalswitchnstripsapvshotson, gtEvmToken_, L1GlobalTriggerEvmReadoutRecord::gtfeWord(), historyProducerToken_, i, edm::EventBase::id(), APVCyclePhaseCollection::invalid, isStableBeams, edm::HandleBase::isValid(), SiStripMonitorDigi::LayerMEs::LayerADCsCoolestStrip, SiStripMonitorDigi::LayerMEs::LayerADCsCoolestStripTrend, SiStripMonitorDigi::LayerMEs::LayerADCsHottestStrip, SiStripMonitorDigi::LayerMEs::LayerADCsHottestStripTrend, LayerDetMap, SiStripMonitorDigi::LayerMEs::LayerDigiADCProfile, SiStripMonitorDigi::LayerMEs::LayerDigiADCs, SiStripMonitorDigi::LayerMEs::LayerDigiADCsTrend, LayerMEsMap, SiStripMonitorDigi::LayerMEs::LayerNumberOfDigis, SiStripMonitorDigi::LayerMEs::LayerNumberOfDigisProfile, SiStripMonitorDigi::LayerMEs::LayerNumberOfDigisTrend, SiStripMonitorDigi::LayerMEs::LayerStripOccupancy, SiStripMonitorDigi::LayerMEs::LayerStripOccupancyTrend, layerswitchadccooleston, layerswitchadchotteston, layerswitchdigiadcprofon, layerswitchdigiadcson, layerswitchnumdigison, layerswitchnumdigisprofon, layerswitchstripoccupancyon, python.multivaluedict::map(), MedianChargeApvShotsGlobal, Mod_On_, moduleswitchadccooleston, moduleswitchadchotteston, moduleswitchdigiadcson, moduleswitchnumdigison, moduleswitchnumdigispstripon, moduleswitchstripoccupancyon, APVCyclePhaseCollection::multiphase, NApvApvShotsGlobal, NApvShotsGlobal, NApvShotsGlobalProf, APVCyclePhaseCollection::nopartition, NORBITS_PER_SECOND, NULL, SiStripMonitorDigi::ModMEs::NumberOfDigis, SiStripMonitorDigi::ModMEs::NumberOfDigisPerStrip, edm::EventBase::orbitNumber(), edm::Handle< T >::product(), edm::ESHandle< class >::product(), edm::EventID::run(), runNb, shotschargehistomapon, shotshistomapon, shotsstripshistomapon, ShotsVsTimeApvShotsGlobal, SiStripDetCabling_, AlCaHLTBitMon_QueryRunRegistry::string, StripMultiplicityApvShotsGlobal, SiStripMonitorDigi::ModMEs::StripOccupancy, SiStripMonitorDigi::SubDetMEs::SubDetApvShots, SiStripMonitorDigi::SubDetMEs::SubDetChargeMedianApvShotsTH1, SiStripMonitorDigi::SubDetMEs::SubDetDigiApvProf, SiStripMonitorDigi::SubDetMEs::SubDetDigiApvTH2, SubDetMEsMap, SiStripMonitorDigi::SubDetMEs::SubDetNApvShotsNApvTH1, SiStripMonitorDigi::SubDetMEs::SubDetNApvShotsProf, SiStripMonitorDigi::SubDetMEs::SubDetNApvShotsTH1, SiStripMonitorDigi::SubDetMEs::SubDetNStripsApvShotsTH1, SubDetPhasePartMap, subdetswitchapvcycleprofon, subdetswitchapvcycleth2on, subdetswitchapvshotsApvon, subdetswitchapvshotsonprof, subdetswitchchargemedianapvshotson, subdetswitchnapvshotson, subdetswitchnstripsapvshotson, subdetswitchtotdigifailureon, subdetswitchtotdigiprofon, SiStripMonitorDigi::SubDetMEs::SubDetTotDigiProf, SiStripMonitorDigi::DigiFailureMEs::SubDetTotDigiProfLS, tkmapdigi, tkmapMedianChargeApvshots, tkmapNApvshots, tkmapNstripApvshot, TotalNShots, and SiStripMonitorDigi::SubDetMEs::totNDigis.

556  {
557 
558  // Filter out events if DCS Event if requested
559  if (dcsStatus_ && !dcsStatus_->getStatus(iEvent, iSetup)) return;
560 
561  //Retrieve tracker topology from geometry
562  edm::ESHandle<TrackerTopology> tTopoHandle;
563  iSetup.get<IdealGeometryRecord>().get(tTopoHandle);
564  const TrackerTopology* const tTopo = tTopoHandle.product();
565 
566  TotalNShots=0;
567 
568  runNb = iEvent.id().run();
569  eventNb++;
570 
571  float iOrbitSec = iEvent.orbitNumber()/NORBITS_PER_SECOND;
572 
573  digi_detset_handles.clear();
574  /*
575  for(std::vector<edm::InputTag>::iterator itDigiProducerList = digiProducerList.begin();
576  itDigiProducerList != digiProducerList.end(); ++itDigiProducerList ) {
577 
578  edm::Handle< edm::DetSetVector<SiStripDigi> > digi_handle;
579 
580  iEvent.getByLabel((*itDigiProducerList),digi_handle);
581  */
582  std::vector<edm::EDGetTokenT<edm::DetSetVector<SiStripDigi> > >::const_iterator iToken = digiProducerTokenList.begin();
583  for(std::vector<edm::InputTag>::const_iterator iter = digiProducerList.begin(), iEnd = digiProducerList.end();
584  iter != iEnd; ++iter, ++iToken) {
586  iEvent.getByToken( *iToken, digi_handle );
587  if (digi_handle.isValid()) digi_detset_handles.push_back(digi_handle.product());
588  }
589 
590  // initialise # of clusters to zero
591  for (std::map<std::string, SubDetMEs>::iterator iSubdet = SubDetMEsMap.begin();
592  iSubdet != SubDetMEsMap.end(); iSubdet++) {
593  iSubdet->second.totNDigis = 0;
594  iSubdet->second.SubDetApvShots.clear();
595  }
596 
597  for (std::map<std::string, std::vector< uint32_t > >::const_iterator iterLayer = LayerDetMap.begin();
598  iterLayer != LayerDetMap.end(); iterLayer++) {
599 
600  std::string layer_label = iterLayer->first;
601 
602  std::vector< uint32_t > layer_dets = iterLayer->second;
603  std::map<std::string, LayerMEs>::iterator iLayerME = LayerMEsMap.find(layer_label);
604 
605  //get Layer MEs
606  LayerMEs local_layermes;
607 
608  if(iLayerME == LayerMEsMap.end()) continue;
609  else local_layermes = iLayerME->second;
610 
611  int largest_adc_layer= 0;
612  int smallest_adc_layer= 99999;
613 
614  int ndigi_layer = 0;
615 
616  uint16_t iDet = 0;
617 
618  std::string subdet_label = "";
619 
620  // loop over all modules in the layer
621  for (std::vector< uint32_t >::const_iterator iterDets = layer_dets.begin() ;
622  iterDets != layer_dets.end() ; iterDets++) {
623  iDet++;
624 
625  // detid and type of ME
626  uint32_t detid = (*iterDets);
627 
628  // Get SubDet label once
629  if (subdet_label.size() == 0) subdet_label = folder_organizer.getSubDetFolderAndTag(detid, tTopo).second;
630 
631  // DetId and corresponding set of MEs
632 
633  std::map<uint32_t, ModMEs >::iterator pos = DigiMEs.find(detid);
634  ModMEs local_modmes = pos->second;
635 
636  // search digis of detid
637  int loc = getDigiSourceIndex(detid);
638 
639  int ndigi_det = 0;
640 
641  if (loc > -1) {
642  ndigi_det = (*(digi_detset_handles[loc]))[detid].size();
643  APVShotFinder theShotFinder = APVShotFinder((*(digi_detset_handles[loc]))[detid]);
644  const std::vector<APVShot>& shots = theShotFinder.getShots();
645  AddApvShotsToSubDet(shots,SubDetMEsMap[subdet_label].SubDetApvShots);
646  if (shotshistomapon) tkmapNApvshots->fill(detid,shots.size());
649  }
650 
651  if(Mod_On_ && moduleswitchnumdigison && (local_modmes.NumberOfDigis != NULL))
652  (local_modmes.NumberOfDigis)->Fill(ndigi_det);
653 
655  local_layermes.LayerNumberOfDigisProfile->Fill(iDet*1.0,ndigi_det);
656 
657  if (digitkhistomapon) tkmapdigi->fill(detid,ndigi_det);
658 
659  if (ndigi_det == 0) continue; // no digis for this detid => jump to next step of loop
660 
661  const edm::DetSet<SiStripDigi> & digi_detset = (*(digi_detset_handles[loc]))[detid];
662 
663  ndigi_layer += ndigi_det;
664 
665  // ADCs
666  int largest_adc=(digi_detset.data.begin())->adc();
667  int smallest_adc=(digi_detset.data.begin())->adc();
668 
669 
670  // Check if these parameters are really needed
671  float det_occupancy = 0.0;
672 
673  for(edm::DetSet<SiStripDigi>::const_iterator digiIter = digi_detset.data.begin();
674  digiIter!= digi_detset.data.end(); digiIter++ ){
675 
676  int this_adc = digiIter->adc();
677 
678  if (this_adc > 0.0) det_occupancy++;
679 
680  if(this_adc>largest_adc) largest_adc = this_adc;
681  if(this_adc<smallest_adc) smallest_adc = this_adc;
682 
683  if(Mod_On_ && moduleswitchnumdigispstripon && (local_modmes.NumberOfDigisPerStrip != NULL) && (this_adc > 0.0) )
684  (local_modmes.NumberOfDigisPerStrip)->Fill(digiIter->strip());
685 
686  if(Mod_On_ && moduleswitchdigiadcson && (local_modmes.DigiADCs != NULL) )
687  (local_modmes.DigiADCs)->Fill(static_cast<float>(this_adc));
688 
689  //Fill #ADCs for this digi at layer level
691  fillME(local_layermes.LayerDigiADCs , this_adc);
692  if (createTrendMEs) fillTrend(local_layermes.LayerDigiADCsTrend, this_adc, iOrbitSec);
693  }
694 
696  local_layermes.LayerDigiADCProfile->Fill(iDet*1.0,this_adc);
697 
698  }//end of loop over digis in this det
699 
700  // Occupancy
701  short nstrips = SiStripDetCabling_->nApvPairs(detid) * 2 * 128;
702  if (nstrips > 0 && det_occupancy > 0 ) {
703  det_occupancy = det_occupancy/nstrips;
704  if (Mod_On_ && moduleswitchstripoccupancyon && (local_modmes.StripOccupancy != NULL))
705  (local_modmes.StripOccupancy)->Fill(det_occupancy);
707  fillME(local_layermes.LayerStripOccupancy, det_occupancy);
708  if (createTrendMEs) fillTrend(local_layermes.LayerStripOccupancyTrend, det_occupancy, iOrbitSec);
709  }
710  }
711 
712  if (largest_adc > largest_adc_layer) largest_adc_layer = largest_adc;
713  if (smallest_adc < smallest_adc_layer) smallest_adc_layer = smallest_adc;
714 
715  // nr. of adcs for hottest strip
716  if( Mod_On_ && moduleswitchadchotteston && (local_modmes.ADCsHottestStrip != NULL))
717  (local_modmes.ADCsHottestStrip)->Fill(static_cast<float>(largest_adc));
718 
719  // nr. of adcs for coolest strip
720  if(Mod_On_ && moduleswitchadccooleston && (local_modmes.ADCsCoolestStrip != NULL))
721  (local_modmes.ADCsCoolestStrip)->Fill(static_cast<float>(smallest_adc));
722 
723  }//end of loop over DetIds
724 
726  fillME(local_layermes.LayerNumberOfDigis,ndigi_layer);
727  if (createTrendMEs) fillTrend(local_layermes.LayerNumberOfDigisTrend, ndigi_layer, iOrbitSec);
728  }
730  fillME(local_layermes.LayerADCsHottestStrip,largest_adc_layer);
731  if (createTrendMEs) fillTrend(local_layermes.LayerADCsHottestStripTrend, largest_adc_layer, iOrbitSec);
732  }
734  fillME(local_layermes.LayerADCsCoolestStrip ,smallest_adc_layer);
735  if (createTrendMEs) fillTrend(local_layermes.LayerADCsCoolestStripTrend, smallest_adc_layer, iOrbitSec);
736  }
737 
738  std::map<std::string, SubDetMEs>::iterator iSubdet = SubDetMEsMap.find(subdet_label);
739  if(iSubdet != SubDetMEsMap.end()) {
740  iSubdet->second.totNDigis += ndigi_layer;
741  //std::cout << " totDigis" << iSubdet->second.totNDigis << " in " << subdet_label << std::endl;
742  }
743  }
744 
746 
747  //check Stable beams bit
749  // iEvent.getByLabel("gtEvmDigis", gtEvm_handle);
750  iEvent.getByToken( gtEvmToken_, gtEvm_handle );
751  L1GlobalTriggerEvmReadoutRecord const* gtevm = gtEvm_handle.product();
752 
753  L1GtfeExtWord gtfeEvmExtWord;
754  if (gtevm)
755  {
756  gtfeEvmExtWord = gtevm->gtfeWord();
757  }
758  else
759  edm::LogInfo("DQMProvInfo") << " gtfeEvmWord inaccessible" ;
760 
761  /* mia: is there not a smarter way !?!?!?!? */
762  if ( gtfeEvmExtWord.beamMode() == 11 )
763  isStableBeams = true;
764  }
765 
766  for (std::map<std::string, SubDetMEs>::iterator it = SubDetMEsMap.begin();
767  it != SubDetMEsMap.end(); it++) {
768 
769  // if (subdetswitchtotdigiproflson) {
771  if (strcmp(it->first.c_str(),"TEC__MINUS")==0){
772  digiFailureMEs.SubDetTotDigiProfLS->Fill(1, it->second.totNDigis);
773  }else if (strcmp(it->first.c_str(),"TEC__PLUS")==0){
774  digiFailureMEs.SubDetTotDigiProfLS->Fill(2, it->second.totNDigis);
775  }else if (strcmp(it->first.c_str(),"TIB")==0){
776  digiFailureMEs.SubDetTotDigiProfLS->Fill(3, it->second.totNDigis);
777  }else if (strcmp(it->first.c_str(),"TID__MINUS")==0){
778  digiFailureMEs.SubDetTotDigiProfLS->Fill(4, it->second.totNDigis);
779  }else if (strcmp(it->first.c_str(),"TID__PLUS")==0){
780  digiFailureMEs.SubDetTotDigiProfLS->Fill(5, it->second.totNDigis);
781  }else if (strcmp(it->first.c_str(),"TOB")==0){
782  digiFailureMEs.SubDetTotDigiProfLS->Fill(6, it->second.totNDigis);
783  }
784  }
785 
787  if (strcmp(it->first.c_str(),"TEC__MINUS")==0){
788  NApvShotsGlobalProf->Fill(1,it->second.SubDetApvShots.size());
789  }else if (strcmp(it->first.c_str(),"TEC__PLUS")==0){
790  NApvShotsGlobalProf->Fill(2,it->second.SubDetApvShots.size());
791  }else if (strcmp(it->first.c_str(),"TIB")==0){
792  NApvShotsGlobalProf->Fill(3,it->second.SubDetApvShots.size());
793  }else if (strcmp(it->first.c_str(),"TID__MINUS")==0){
794  NApvShotsGlobalProf->Fill(4,it->second.SubDetApvShots.size());
795  }else if (strcmp(it->first.c_str(),"TID__PLUS")==0){
796  NApvShotsGlobalProf->Fill(5,it->second.SubDetApvShots.size());
797  }else if (strcmp(it->first.c_str(),"TOB")==0){
798  NApvShotsGlobalProf->Fill(6,it->second.SubDetApvShots.size());
799  }
800  }
801 
802  SubDetMEs subdetmes= it->second;
803  std::string subdet = it->first;
804 
805  // Fill APV shots histograms for SubDet
806 
807  uint ShotsSize=subdetmes.SubDetApvShots.size();
808  TotalNShots+=ShotsSize; //Counter for total Shots in the SiStrip Tracker
809 
810  if (subdetswitchnapvshotson ) subdetmes.SubDetNApvShotsTH1->Fill(ShotsSize);// N shots
811  if (subdetswitchapvshotsonprof) subdetmes.SubDetNApvShotsProf ->Fill(iOrbitSec,ShotsSize); //N shots vs time
812 
813  for (uint i=0; i< ShotsSize; ++i){ // Strip multiplicity, charge median and APV number distributions for APV shots
814 
815  if (subdetswitchapvshotsApvon) subdetmes.SubDetNApvShotsNApvTH1->Fill((subdetmes.SubDetApvShots[i].apvNumber()+1));//APV are defined by 0 to 5 I want 1 to 6
816  if (globalswitchapvshotsApvon) NApvApvShotsGlobal->Fill((subdetmes.SubDetApvShots[i].apvNumber()+1));
817 
818  if (subdetswitchnstripsapvshotson) subdetmes.SubDetNStripsApvShotsTH1->Fill(subdetmes.SubDetApvShots[i].nStrips());
819  if (globalswitchnstripsapvshotson) StripMultiplicityApvShotsGlobal->Fill(subdetmes.SubDetApvShots[i].nStrips());
820 
821  if (subdetswitchchargemedianapvshotson) subdetmes.SubDetChargeMedianApvShotsTH1->Fill(subdetmes.SubDetApvShots[i].median());
822  if (globalswitchchargemedianapvshotson) MedianChargeApvShotsGlobal->Fill(subdetmes.SubDetApvShots[i].median());
823 
824  }
825 
826  if (subdetswitchtotdigiprofon)subdetmes.SubDetTotDigiProf->Fill(iOrbitSec,subdetmes.totNDigis);
827  }
828 
831 
832  // get EventHistory
833 
834  edm::Handle<EventWithHistory> event_history;
835  // iEvent.getByLabel(historyProducer_,event_history);
836  iEvent.getByToken(historyProducerToken_,event_history);
837 
838  // get Phase of APV
839  edm::Handle<APVCyclePhaseCollection> apv_phase_collection;
840  // iEvent.getByLabel(apvPhaseProducer_,apv_phase_collection);
841  iEvent.getByToken(apvPhaseProducerToken_,apv_phase_collection);
842 
843  if (event_history.isValid()
844  && !event_history.failedToGet()
845  && apv_phase_collection.isValid()
846  && !apv_phase_collection.failedToGet()) {
847 
848 
849  long long tbx = event_history->absoluteBX();
850 
851 
852  for (std::map<std::string, SubDetMEs>::iterator it = SubDetMEsMap.begin();
853  it != SubDetMEsMap.end(); it++) {
854 
855  SubDetMEs subdetmes;
856  std::string subdet = it->first;
857  subdetmes = it->second;
858 
859  int the_phase = APVCyclePhaseCollection::invalid;
860  long long tbx_corr = tbx;
861 
862  if (SubDetPhasePartMap.find(subdet) != SubDetPhasePartMap.end()) the_phase = apv_phase_collection->getPhase(SubDetPhasePartMap[subdet]);
863  if(the_phase==APVCyclePhaseCollection::nopartition ||
865  the_phase==APVCyclePhaseCollection::invalid) the_phase=30;
866  tbx_corr -= the_phase;
867 
868  if (subdetswitchapvcycleprofon)subdetmes.SubDetDigiApvProf->Fill(tbx_corr%70,subdetmes.totNDigis);
869  if (subdetswitchapvcycleth2on) subdetmes.SubDetDigiApvTH2->Fill(tbx_corr%70,subdetmes.totNDigis);
870  }
871  }
872 }//end of method analyze
int adc(sample_type sample)
get the ADC sample (12 bits)
RunNumber_t run() const
Definition: EventID.h:42
int i
Definition: DBlmapReader.cc:9
std::map< std::string, LayerMEs > LayerMEsMap
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:434
const L1GtfeExtWord gtfeWord() const
get / set GTFE word (record) in the GT readout record
MonitorElement * NApvShotsGlobalProf
std::map< uint32_t, ModMEs > DigiMEs
#define NULL
Definition: scimark2.h:8
std::map< std::string, std::string > SubDetPhasePartMap
MonitorElement * MedianChargeApvShotsGlobal
MonitorElement * StripMultiplicityApvShotsGlobal
TkHistoMap * tkmapNstripApvshot
void Fill(long long x)
bool getStatus(edm::Event const &e, edm::EventSetup const &eSetup)
const std::vector< APVShot > & getShots() const
SiStripDCSStatus * dcsStatus_
const double NORBITS_PER_SECOND
edm::ESHandle< SiStripDetCabling > SiStripDetCabling_
void Fill(HcalDetId &id, double val, std::vector< TH2F > &depth)
DigiFailureMEs digiFailureMEs
void fill(uint32_t &detid, float value)
Definition: TkHistoMap.cc:133
edm::EDGetTokenT< EventWithHistory > historyProducerToken_
void fillME(MonitorElement *ME, float value1)
MonitorElement * NApvApvShotsGlobal
std::vector< const edm::DetSetVector< SiStripDigi > * > digi_detset_handles
int orbitNumber() const
Definition: EventBase.h:63
std::map< std::string, SubDetMEs > SubDetMEsMap
bool isValid() const
Definition: HandleBase.h:76
void fillTrend(MonitorElement *me, float value, float timeinorbit)
edm::EDGetTokenT< L1GlobalTriggerEvmReadoutRecord > gtEvmToken_
MonitorElement * NApvShotsGlobal
std::vector< edm::EDGetTokenT< edm::DetSetVector< SiStripDigi > > > digiProducerTokenList
bool failedToGet() const
Definition: HandleBase.h:80
int getDigiSourceIndex(uint32_t id)
std::map< std::string, std::vector< uint32_t > > LayerDetMap
const T & get() const
Definition: EventSetup.h:55
T const * product() const
Definition: ESHandle.h:62
T const * product() const
Definition: Handle.h:81
std::pair< std::string, std::string > getSubDetFolderAndTag(const uint32_t &detid, const TrackerTopology *tTopo)
std::vector< edm::InputTag > digiProducerList
TkHistoMap * tkmapMedianChargeApvshots
edm::EDGetTokenT< APVCyclePhaseCollection > apvPhaseProducerToken_
edm::EventID id() const
Definition: EventBase.h:56
collection_type data
Definition: DetSet.h:78
TkHistoMap * tkmapNApvshots
void AddApvShotsToSubDet(const std::vector< APVShot > &, std::vector< APVShot > &)
SiStripFolderOrganizer folder_organizer
MonitorElement * ShotsVsTimeApvShotsGlobal
collection_type::const_iterator const_iterator
Definition: DetSet.h:33
const cms_uint16_t beamMode() const
void FillApvShotsMap(TkHistoMap *, const std::vector< APVShot > &, uint32_t id, int)
void SiStripMonitorDigi::beginJob ( void  )
virtual

Reimplemented from edm::EDAnalyzer.

Definition at line 316 of file SiStripMonitorDigi.cc.

316  {
317 }
void SiStripMonitorDigi::beginLuminosityBlock ( const edm::LuminosityBlock lb,
const edm::EventSetup es 
)
virtual

Reimplemented from edm::EDAnalyzer.

Definition at line 265 of file SiStripMonitorDigi.cc.

References digiFailureMEs, edm::LuminosityBlockBase::id(), integrateNLumisections_, isStableBeams, edm::LuminosityBlockID::luminosityBlock(), MonitorElement::Reset(), subdetswitchtotdigifailureon, subdetswitchtotdigiproflson, and SiStripMonitorDigi::DigiFailureMEs::SubDetTotDigiProfLS.

265  {
267  // if (digiFailureMEs.SubDetTotDigiProfLS) digiFailureMEs.SubDetTotDigiProfLS->Reset();
268  }
270  isStableBeams = false;
271  //integrate stats over several LS to prevent eventual low trigger rates
273  }
274 }
LuminosityBlockID id() const
DigiFailureMEs digiFailureMEs
LuminosityBlockNumber_t luminosityBlock() const
void Reset(void)
reset ME (ie. contents, errors, etc)
void SiStripMonitorDigi::beginRun ( const edm::Run run,
const edm::EventSetup es 
)
virtual

Reimplemented from edm::EDAnalyzer.

Definition at line 196 of file SiStripMonitorDigi.cc.

References createMEs(), DigiMEs, edm::EventSetup::find(), edm::eventsetup::heterocontainer::HCTypeTag::findType(), edm::EventSetup::get(), edm::ESHandleBase::isValid(), m_cacheID_, nFedTECm, nFedTECp, nFedTIB, nFedTIDm, nFedTIDp, nFedTOB, reset_each_run, ResetModuleMEs(), show_mechanical_structure_view, and subdetswitchtotdigifailureon.

196  {
197 
199  unsigned long long cacheID = es.get<SiStripDetCablingRcd>().cacheIdentifier();
200  if (m_cacheID_ != cacheID) {
201  m_cacheID_ = cacheID;
202  edm::LogInfo("SiStripMonitorDigi") <<"SiStripMonitorDigi::beginRun: "
203  << " Creating MEs for new Cabling ";
204  createMEs(es);
205  }
206  } else if (reset_each_run) {
207  edm::LogInfo("SiStripMonitorDigi") <<"SiStripMonitorDigi::beginRun: "
208  << " Resetting MEs ";
209  for (std::map<uint32_t, ModMEs >::const_iterator idet = DigiMEs.begin() ; idet!=DigiMEs.end() ; idet++) {
210  ResetModuleMEs(idet->first);
211  }
212  }
213 
215  //get FED cabling to know if SiStrip is in DAQ or no
216  unsigned long long cacheID = es.get<SiStripDetCablingRcd>().cacheIdentifier();
217  if (m_cacheID_ != cacheID) {
218  m_cacheID_ = cacheID;
219  }
221  es.get<SiStripDetCablingRcd>().get(detCabling_);
222 
223  //nFEDConnected = 0;
224  nFedTIB = 0;
225  nFedTIDm = 0;
226  nFedTIDp = 0;
227  nFedTECm = 0;
228  nFedTECp = 0;
229  nFedTOB = 0;
230 
231  //const int siStripFedIdMin = FEDNumbering::MINSiStripFEDID;
232  //const int siStripFedIdMax = FEDNumbering::MAXSiStripFEDID;
233 
235  if( es.find( recordKey ) != 0) {
236 
237  edm::ESHandle<RunInfo> sumFED;
238  es.get<RunInfoRcd>().get(sumFED);
239 
240  if ( sumFED.isValid() ) {
241  std::vector<int> FedsInIds= sumFED->m_fed_in;
242  for(unsigned int it = 0; it < FedsInIds.size(); ++it) {
243  int fedID = FedsInIds[it];
244  // if(fedID>=siStripFedIdMin && fedID<=siStripFedIdMax) ++nFEDConnected;
245  /* mia: but is there not a smarter way !?!?!? */
246  if ( fedID >= 50 && fedID <= 133 ) ++nFedTIB;
247  if ( fedID >= 134 && fedID <= 148 ) ++nFedTIDm;
248  if ( fedID >= 149 && fedID <= 163 ) ++nFedTIDp;
249  if ( fedID >= 164 && fedID <= 259 ) ++nFedTECm;
250  if ( fedID >= 260 && fedID <= 355 ) ++nFedTECp;
251  if ( fedID >= 356 && fedID <= 489 ) ++nFedTOB;
252 
253  }
254  }
255  }
256  }
257 
258 }
void ResetModuleMEs(uint32_t idet)
std::map< uint32_t, ModMEs > DigiMEs
const eventsetup::EventSetupRecord * find(const eventsetup::EventSetupRecordKey &) const
Definition: EventSetup.cc:90
unsigned long long m_cacheID_
const T & get() const
Definition: EventSetup.h:55
void createMEs(const edm::EventSetup &es)
bool isValid() const
Definition: ESHandle.h:37
static HCTypeTag findType(char const *iTypeName)
find a type based on the types name, if not found will return default HCTypeTag
Definition: HCTypeTag.cc:125
void SiStripMonitorDigi::bookLayer ( )
private
MonitorElement * SiStripMonitorDigi::bookME1D ( const char *  ParameterSetLabel,
const char *  HistoName 
)
private

Definition at line 918 of file SiStripMonitorDigi.cc.

References DQMStore::book1D(), conf_, dqmStore_, and edm::ParameterSet::getParameter().

Referenced by createLayerMEs(), and createModuleMEs().

919 {
922  Parameters.getParameter<int32_t>("Nbinx"),
923  Parameters.getParameter<double>("xmin"),
924  Parameters.getParameter<double>("xmax")
925  );
926 }
T getParameter(std::string const &) const
MonitorElement * book1D(const char *name, const char *title, int nchX, double lowX, double highX)
Book 1D histogram.
Definition: DQMStore.cc:872
vector< ParameterSet > Parameters
edm::ParameterSet conf_
std::string HistoName
MonitorElement * SiStripMonitorDigi::bookMETrend ( const char *  ParameterSetLabel,
const char *  HistoName 
)
private

Definition at line 897 of file SiStripMonitorDigi.cc.

References DQMStore::bookProfile(), conf_, MonitorElement::DQM_KIND_TPROFILE, dqmStore_, edm::ParameterSet::getParameter(), and MonitorElement::setAxisTitle().

Referenced by createLayerMEs().

898 {
899  edm::ParameterSet ParametersTrend = conf_.getParameter<edm::ParameterSet>("Trending");
901  ParametersTrend.getParameter<int32_t>("Nbins"),
902  // 0,
903  ParametersTrend.getParameter<double>("xmin"),
904  ParametersTrend.getParameter<double>("xmax"),
905  // ParametersTrend.getParameter<int32_t>("Nbins"),
906  100, //that parameter should not be there !?
907  ParametersTrend.getParameter<double>("ymin"),
908  ParametersTrend.getParameter<double>("ymax"),
909  "" );
910  if(!me) return me;
911 
912  me->setAxisTitle("Event Time in Seconds",1);
913  if (me->kind() == MonitorElement::DQM_KIND_TPROFILE) me->getTH1()->SetBit(TH1::kCanRebin);
914  return me;
915 }
T getParameter(std::string const &) const
MonitorElement * bookProfile(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, const char *option="s")
Definition: DQMStore.cc:1186
edm::ParameterSet conf_
std::string HistoName
void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
void SiStripMonitorDigi::bookTrendMEs ( const TString &  name,
int32_t  layer,
uint32_t  id,
std::string  flag 
)
private
void SiStripMonitorDigi::createLayerMEs ( std::string  label,
int  ndet 
)
private

Definition at line 1000 of file SiStripMonitorDigi.cc.

References bookME1D(), bookMETrend(), DQMStore::bookProfile(), SiStripHistoId::createHistoLayer(), createTrendMEs, dqmStore_, diffTwoXMLs::label, SiStripMonitorDigi::LayerMEs::LayerADCsCoolestStrip, SiStripMonitorDigi::LayerMEs::LayerADCsCoolestStripTrend, SiStripMonitorDigi::LayerMEs::LayerADCsHottestStrip, SiStripMonitorDigi::LayerMEs::LayerADCsHottestStripTrend, SiStripMonitorDigi::LayerMEs::LayerDigiADCProfile, SiStripMonitorDigi::LayerMEs::LayerDigiADCs, SiStripMonitorDigi::LayerMEs::LayerDigiADCsTrend, LayerMEsMap, SiStripMonitorDigi::LayerMEs::LayerNumberOfDigis, SiStripMonitorDigi::LayerMEs::LayerNumberOfDigisProfile, SiStripMonitorDigi::LayerMEs::LayerNumberOfDigisTrend, SiStripMonitorDigi::LayerMEs::LayerStripOccupancy, SiStripMonitorDigi::LayerMEs::LayerStripOccupancyTrend, layerswitchadccooleston, layerswitchadchotteston, layerswitchdigiadcprofon, layerswitchdigiadcson, layerswitchnumdigison, layerswitchnumdigisprofon, layerswitchstripoccupancyon, and AlCaHLTBitMon_QueryRunRegistry::string.

Referenced by createMEs().

1000  {
1001 
1002  std::map<std::string, LayerMEs>::iterator iLayerME = LayerMEsMap.find(label);
1003  if(iLayerME==LayerMEsMap.end()){
1004  SiStripHistoId hidmanager;
1005  LayerMEs layerMEs;
1006  layerMEs.LayerNumberOfDigis = 0;
1007  layerMEs.LayerNumberOfDigisTrend = 0;
1008  layerMEs.LayerADCsHottestStrip = 0;
1009  layerMEs.LayerADCsHottestStripTrend = 0;
1010  layerMEs.LayerADCsCoolestStrip = 0;
1011  layerMEs.LayerADCsCoolestStripTrend = 0;
1012  layerMEs.LayerDigiADCs = 0;
1013  layerMEs.LayerDigiADCsTrend = 0;
1014  layerMEs.LayerStripOccupancy = 0;
1015  layerMEs.LayerStripOccupancyTrend = 0;
1016  layerMEs.LayerNumberOfDigisProfile = 0;
1017  layerMEs.LayerDigiADCProfile = 0;
1018 
1019 
1020  //#Digis
1021  if(layerswitchnumdigison) {
1022  layerMEs.LayerNumberOfDigis=bookME1D("TH1NumberOfDigis", hidmanager.createHistoLayer("Summary_TotalNumberOfDigis","layer",label,"").c_str());
1023  if (createTrendMEs) layerMEs.LayerNumberOfDigisTrend=bookMETrend("TH1NumberOfDigis", hidmanager.createHistoLayer("Trend_NumberOfDigis","layer",label,"").c_str());
1024  }
1025 
1026  //#ADCs for hottest strip
1028  layerMEs.LayerADCsHottestStrip=bookME1D("TH1ADCsHottestStrip", hidmanager.createHistoLayer("Summary_ADCsHottestStrip","layer",label,"").c_str());
1029  if (createTrendMEs) layerMEs.LayerADCsHottestStripTrend=bookMETrend("TH1ADCsHottestStrip", hidmanager.createHistoLayer("Trend_ADCsHottestStrip","layer",label,"").c_str());
1030  }
1031 
1032  //#ADCs for coolest strip
1034  layerMEs.LayerADCsCoolestStrip=bookME1D("TH1ADCsCoolestStrip", hidmanager.createHistoLayer("Summary_ADCsCoolestStrip","layer",label,"").c_str());
1035  if (createTrendMEs) layerMEs.LayerADCsCoolestStripTrend=bookMETrend("TH1ADCsCoolestStrip", hidmanager.createHistoLayer("Trend_ADCsCoolestStrip","layer",label,"").c_str());
1036  }
1037 
1038  //#ADCs for each digi
1039  if(layerswitchdigiadcson) {
1040  layerMEs.LayerDigiADCs=bookME1D("TH1DigiADCs", hidmanager.createHistoLayer("Summary_DigiADCs","layer",label,"").c_str());
1041  if (createTrendMEs) layerMEs.LayerDigiADCsTrend=bookMETrend("TH1DigiADCs", hidmanager.createHistoLayer("Trend_DigiADCs","layer",label,"").c_str());
1042  }
1043 
1044  //Strip Occupancy
1046  layerMEs.LayerStripOccupancy=bookME1D("TH1StripOccupancy", hidmanager.createHistoLayer("Summary_StripOccupancy","layer",label,"").c_str());
1047  if (createTrendMEs) layerMEs.LayerStripOccupancyTrend=bookMETrend("TH1StripOccupancy", hidmanager.createHistoLayer("Trend_StripOccupancy","layer",label,"").c_str());
1048 
1049  }
1050  // # of Digis
1052  std::string hid = hidmanager.createHistoLayer("NumberOfDigiProfile","layer",label,"");
1053  layerMEs.LayerNumberOfDigisProfile = dqmStore_->bookProfile(hid, hid, ndets, 0.5, ndets+0.5,21, -0.5, 200.5);
1054  }
1055 
1056  // # of Digis
1058  std::string hid = hidmanager.createHistoLayer("DigiADCProfile","layer",label,"");
1059  layerMEs.LayerDigiADCProfile = dqmStore_->bookProfile(hid, hid, ndets, 0.5, ndets+0.5, 64, -0.5, 255.5);
1060  }
1061 
1062  LayerMEsMap[label]=layerMEs;
1063  }
1064 }
std::map< std::string, LayerMEs > LayerMEsMap
MonitorElement * bookMETrend(const char *ParameterSetLabel, const char *HistoName)
MonitorElement * bookProfile(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, const char *option="s")
Definition: DQMStore.cc:1186
std::string createHistoLayer(std::string description, std::string id_type, std::string path, std::string flag)
MonitorElement * bookME1D(const char *ParameterSetLabel, const char *HistoName)
void SiStripMonitorDigi::createMEs ( const edm::EventSetup es)
private

Definition at line 321 of file SiStripMonitorDigi.cc.

References funct::abs(), SiStripMonitorDigi::ModMEs::ADCsCoolestStrip, SiStripMonitorDigi::ModMEs::ADCsHottestStrip, DQMStore::book1D(), DQMStore::book2D(), DQMStore::bookProfile(), conf_, createLayerMEs(), createModuleMEs(), createSubDetMEs(), cond::rpcobgas::detid, SiStripMonitorDigi::ModMEs::DigiADCs, digiFailureMEs, DigiMEs, digitkhistomapon, MonitorElement::DQM_KIND_TPROFILE, dqmStore_, folder_organizer, edm::EventSetup::get(), SiStripFolderOrganizer::getLayerFolderName(), edm::ParameterSet::getParameter(), SiStripFolderOrganizer::GetSubDetAndLayer(), SiStripFolderOrganizer::getSubDetFolderAndTag(), SiStripHistoId::getSubdetid(), SiStripSubStructure::getTECDetectors(), MonitorElement::getTH1(), SiStripSubStructure::getTIBDetectors(), SiStripSubStructure::getTIDDetectors(), SiStripSubStructure::getTOBDetectors(), globalsummaryapvshotson, globalswitchapvshotsApvon, globalswitchapvshotsonprof, globalswitchchargemedianapvshotson, globalswitchnapvshotson, globalswitchnstripsapvshotson, MonitorElement::kind(), diffTwoXMLs::label, LayerDetMap, LayerMEsMap, MedianChargeApvShotsGlobal, Mod_On_, NApvApvShotsGlobal, NApvShotsGlobal, NApvShotsGlobalProf, SiStripMonitorDigi::ModMEs::NumberOfDigis, SiStripMonitorDigi::ModMEs::NumberOfDigisPerStrip, edm::ESHandle< class >::product(), reset_each_run, ResetModuleMEs(), MonitorElement::setAxisTitle(), MonitorElement::setBinLabel(), DQMStore::setCurrentFolder(), SiStripFolderOrganizer::setDetectorFolder(), SiStripFolderOrganizer::setLayerFolder(), shotschargehistomapon, shotshistomapon, shotsstripshistomapon, ShotsVsTimeApvShotsGlobal, show_mechanical_structure_view, SiStripDetCabling_, AlCaHLTBitMon_QueryRunRegistry::string, StripMultiplicityApvShotsGlobal, SiStripMonitorDigi::ModMEs::StripOccupancy, SiStripMonitorDigi::DigiFailureMEs::SubDetDigiFailures2D, SubDetMEsMap, subdetswitchtotdigifailureon, SiStripMonitorDigi::DigiFailureMEs::SubDetTotDigiProfLS, tkmapdigi, tkmapMedianChargeApvshots, tkmapNApvshots, tkmapNstripApvshot, and topFolderName_.

Referenced by beginRun().

321  {
322 
324 
325  //Retrieve tracker topology from geometry
326  edm::ESHandle<TrackerTopology> tTopoHandle;
327  es.get<IdealGeometryRecord>().get(tTopoHandle);
328  const TrackerTopology* const tTopo = tTopoHandle.product();
329 
330  // take from eventSetup the SiStripDetCabling object - here will use SiStripDetControl later on
332 
333  // get list of active detectors from SiStripDetCabling
334  std::vector<uint32_t> activeDets;
335  activeDets.clear(); // just in case
336  SiStripDetCabling_->addActiveDetectorsRawIds(activeDets);
337 
338  SiStripSubStructure substructure;
339 
340  // remove any eventual zero elements - there should be none, but just in case
341  for(std::vector<uint32_t>::iterator idets = activeDets.begin(); idets != activeDets.end(); idets++){
342  if(*idets == 0) activeDets.erase(idets);
343  }
344 
345  // create SiStripFolderOrganizer
347 
348  // Create TkHistoMap for Digi and APV shots properies
349 
350  if (digitkhistomapon) tkmapdigi = new TkHistoMap(topFolderName_,"TkHMap_NumberOfDigi", 0.0,true);
351  if (shotshistomapon) tkmapNApvshots = new TkHistoMap(topFolderName_,"TkHMap_NApvShots", 0.0,true);
352  if (shotsstripshistomapon) tkmapNstripApvshot = new TkHistoMap(topFolderName_,"TkHMap_NStripApvShots", 0.0,true);
353  if (shotschargehistomapon) tkmapMedianChargeApvshots= new TkHistoMap(topFolderName_,"TkHMap_MedianChargeApvShots",0.0,true);
354 
355  std::vector<uint32_t> tibDetIds;
356 
357  // loop over detectors and book MEs
358  edm::LogInfo("SiStripTkDQM|SiStripMonitorDigi")<<"nr. of activeDets: "<<activeDets.size();
359  for(std::vector<uint32_t>::const_iterator detid_iterator = activeDets.begin(); detid_iterator!=activeDets.end(); detid_iterator++){
360 
361  uint32_t detid = (*detid_iterator);
362 
363  ModMEs local_modmes;
364 
365  local_modmes.NumberOfDigis = 0;
366  local_modmes.NumberOfDigisPerStrip = 0;
367  local_modmes.ADCsHottestStrip = 0;
368  local_modmes.ADCsCoolestStrip = 0;
369  local_modmes.DigiADCs = 0;
370  local_modmes.StripOccupancy = 0;
371 
372  if (Mod_On_) {
373 
374  // set appropriate folder using SiStripFolderOrganizer
375  folder_organizer.setDetectorFolder(detid, tTopo); // pass the detid to this method
376  if (reset_each_run) ResetModuleMEs(detid);
377  createModuleMEs(local_modmes, detid);
378 
379  // append to DigiMEs
380  DigiMEs.insert( std::make_pair(detid, local_modmes));
381  }
382 
383  // Create Layer Level MEs if they are not created already
384  std::pair<std::string,int32_t> det_layer_pair = folder_organizer.GetSubDetAndLayer(detid, tTopo);
385  SiStripHistoId hidmanager;
386  std::string label = hidmanager.getSubdetid(detid,tTopo,false);
387 
388  // get detids for the layer
389  std::map<std::string, LayerMEs>::iterator iLayerME = LayerMEsMap.find(label);
390 
391  if(iLayerME==LayerMEsMap.end()) {
392  int32_t lnumber = det_layer_pair.second;
393  std::vector<uint32_t> layerDetIds;
394  if (det_layer_pair.first == "TIB") {
395  substructure.getTIBDetectors(activeDets,layerDetIds,lnumber,0,0,0);
396  } else if (det_layer_pair.first == "TOB") {
397  substructure.getTOBDetectors(activeDets,layerDetIds,lnumber,0,0);
398  } else if (det_layer_pair.first == "TID" && lnumber > 0) {
399  substructure.getTIDDetectors(activeDets,layerDetIds,2,abs(lnumber),0,0);
400  } else if (det_layer_pair.first == "TID" && lnumber < 0) {
401  substructure.getTIDDetectors(activeDets,layerDetIds,1,abs(lnumber),0,0);
402  } else if (det_layer_pair.first == "TEC" && lnumber > 0) {
403  substructure.getTECDetectors(activeDets,layerDetIds,2,abs(lnumber),0,0,0,0);
404  } else if (det_layer_pair.first == "TEC" && lnumber < 0) {
405  substructure.getTECDetectors(activeDets,layerDetIds,1,abs(lnumber),0,0,0,0);
406  }
407 
408  LayerDetMap[label] = layerDetIds;
409 
410  // book Layer plots
411  folder_organizer.setLayerFolder(detid,tTopo,det_layer_pair.second);
412  createLayerMEs(label, layerDetIds.size());
413  }
414 
415  // book sub-detector plots
416  std::pair<std::string,std::string> sdet_pair = folder_organizer.getSubDetFolderAndTag(detid, tTopo);
417  if (SubDetMEsMap.find(sdet_pair.second) == SubDetMEsMap.end()){
418  dqmStore_->setCurrentFolder(sdet_pair.first);
419  createSubDetMEs(sdet_pair.second);
420  }
421 
422  }//end of loop over detectors
423 
424  //book some Summary histograms on APV shots in the MechanicalView
425 
426  dqmStore_->setCurrentFolder(topFolderName_+"/MechanicalView/");
427 
429  const char* HistoName = "Summary Mean Apv shots for SubDets";
430  NApvShotsGlobalProf= dqmStore_->bookProfile(HistoName, HistoName,
431  6,0.5,6.5,
432  100, 0., 0., "" );
439  NApvShotsGlobalProf->setAxisTitle(" mean APV shots # / evt",2);
440  }
441 
442  //cumulative number of APV shots Vs Time
445  const char* HistoName = "NApv_Shots_vs_Time";
446  ShotsVsTimeApvShotsGlobal=dqmStore_->bookProfile(HistoName,HistoName,
447  Parameters.getParameter<int32_t>("Nbins"),
448  Parameters.getParameter<double>("xmin"),
449  Parameters.getParameter<double>("xmax"),
450  200, //that parameter should not be there !?
451  Parameters.getParameter<double>("ymin"),
452  Parameters.getParameter<double>("ymax"),
453  "" );
455  ShotsVsTimeApvShotsGlobal->setAxisTitle("# Apv Shots",2);
457  }
458 
459  //cumulative number of Strips in APV shots
461  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("TH1NStripsApvShots");
462  const char* HistoName = "Number_of_Strips_in_Apv_Shots";
463  StripMultiplicityApvShotsGlobal=dqmStore_->book1D(HistoName,HistoName,
464  Parameters.getParameter<int32_t>("Nbins"),
465  Parameters.getParameter<double>("xmin"),
466  Parameters.getParameter<double>("xmax"));
467  StripMultiplicityApvShotsGlobal->setAxisTitle("# strips in Apv Shots",1);
468  }
469 
470  //cumulative number of APV shots
472  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("TH1NApvShots");
473  const char* HistoName = "Number_of_Apv_Shots";
474  NApvShotsGlobal=dqmStore_->book1D(HistoName,HistoName,
475  Parameters.getParameter<int32_t>("Nbins"),
476  Parameters.getParameter<double>("xmin"),
477  Parameters.getParameter<double>("xmax"));
478  NApvShotsGlobal->setAxisTitle("# Apv Shots",1);
479  }
480 
481  //cumulative Median Charge in APV shots
483  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("TH1ChargeMedianApvShots");
484  //dqmStore_->setCurrentFolder("SiStrip/MechanicalView/"+label);
485  const char* HistoName = "Apv_Shots_Charge_Median";
486  MedianChargeApvShotsGlobal=dqmStore_->book1D(HistoName,HistoName,
487  Parameters.getParameter<int32_t>("Nbins"),
488  Parameters.getParameter<double>("xmin"),
489  Parameters.getParameter<double>("xmax"));
490  MedianChargeApvShotsGlobal->setAxisTitle("Apv Shots Charge Median (ADC)",1);
491  }
492 
493  //cmulative APV number with shots
495  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("TH1ApvNumApvShots");
496  //dqmStore_->setCurrentFolder("SiStrip/MechanicalView/"+label);
497  const char* HistoName = "Apv_Shots_Apv_Number";
498  NApvApvShotsGlobal=dqmStore_->book1D(HistoName,HistoName,
499  Parameters.getParameter<int32_t>("Nbins"),
500  Parameters.getParameter<double>("xmin"),
501  Parameters.getParameter<double>("xmax"));
502  NApvApvShotsGlobal->setAxisTitle("Apv Number",1);
503  }
504 
505  //
506  // Book new histogram to monitor digi in last LS
507  //
508 
511 
512  std::stringstream ss;
513 
514  folder_organizer.getLayerFolderName(ss, 0, tTopo);
515  dqmStore_->setCurrentFolder(ss.str().c_str());
516 
517  // if (subdetswitchtotdigiproflson) {
519  const char* HistoName = "NumberOfDigisInLastLS";
521  6,0.5,6.5,
522  0., 0., "" );
529  }
530 
532  std::string HistoName = "DataPresentInLS";
533  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("TotalNumberOfDigisFailure");
534 
535  digiFailureMEs.SubDetDigiFailures2D = dqmStore_->book2D(HistoName,HistoName,
536  Parameters.getParameter<int32_t>("Nbins"), //bins X
537  1, //xmin
538  Parameters.getParameter<int32_t>("Nbins") + 1, //xmax
539  6, //bins Y
540  0, //ymin
541  6); //ymax
542 
549  digiFailureMEs.SubDetDigiFailures2D->setAxisTitle("Luminosity Section");
550  }
551  }//end of if
552 
553 }//end of method
void ResetModuleMEs(uint32_t idet)
void createSubDetMEs(std::string label)
T getParameter(std::string const &) const
std::map< std::string, LayerMEs > LayerMEsMap
MonitorElement * book1D(const char *name, const char *title, int nchX, double lowX, double highX)
Book 1D histogram.
Definition: DQMStore.cc:872
void createModuleMEs(ModMEs &mod_single, uint32_t detid)
void getLayerFolderName(std::stringstream &ss, uint32_t rawdetid, const TrackerTopology *tTopo, bool ring_flag=0)
void setBinLabel(int bin, const std::string &label, int axis=1)
set bin label for x, y or z axis (axis=1, 2, 3 respectively)
MonitorElement * NApvShotsGlobalProf
std::pair< std::string, int32_t > GetSubDetAndLayer(const uint32_t &detid, const TrackerTopology *tTopo, bool ring_flag=0)
std::map< uint32_t, ModMEs > DigiMEs
MonitorElement * MedianChargeApvShotsGlobal
MonitorElement * StripMultiplicityApvShotsGlobal
TkHistoMap * tkmapNstripApvshot
void setDetectorFolder(uint32_t rawdetid, const TrackerTopology *tTopo)
vector< ParameterSet > Parameters
edm::ESHandle< SiStripDetCabling > SiStripDetCabling_
void getTOBDetectors(const std::vector< uint32_t > &inputDetRawIds, std::vector< uint32_t > &tobDetRawIds, uint32_t layer=0, uint32_t bkw_frw=0, uint32_t rod=0) const
DigiFailureMEs digiFailureMEs
MonitorElement * NApvApvShotsGlobal
void createLayerMEs(std::string label, int ndet)
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
TH1 * getTH1(void) const
MonitorElement * bookProfile(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, const char *option="s")
Definition: DQMStore.cc:1186
Kind kind(void) const
Get the type of the monitor element.
std::map< std::string, SubDetMEs > SubDetMEsMap
std::string getSubdetid(uint32_t id, const TrackerTopology *tTopo, bool flag_ring)
MonitorElement * NApvShotsGlobal
void setLayerFolder(uint32_t rawdetid, const TrackerTopology *tTopo, int32_t layer=0, bool ring_flag=0)
std::map< std::string, std::vector< uint32_t > > LayerDetMap
const T & get() const
Definition: EventSetup.h:55
T const * product() const
Definition: ESHandle.h:62
std::string topFolderName_
edm::ParameterSet conf_
std::pair< std::string, std::string > getSubDetFolderAndTag(const uint32_t &detid, const TrackerTopology *tTopo)
std::string HistoName
void getTECDetectors(const std::vector< uint32_t > &inputDetRawIds, std::vector< uint32_t > &tecDetRawIds, uint32_t side=0, uint32_t wheel=0, uint32_t petal_bkw_frw=0, uint32_t petal=0, uint32_t ring=0, uint32_t ster=0) const
TkHistoMap * tkmapMedianChargeApvshots
TkHistoMap * tkmapNApvshots
void getTIBDetectors(const std::vector< uint32_t > &inputDetRawIds, std::vector< uint32_t > &tibDetRawIds, uint32_t layer=0, uint32_t bkw_frw=0, uint32_t int_ext=0, uint32_t string=0) const
SiStripFolderOrganizer folder_organizer
void getTIDDetectors(const std::vector< uint32_t > &inputDetRawIds, std::vector< uint32_t > &tidDetRawIds, uint32_t side=0, uint32_t wheel=0, uint32_t ring=0, uint32_t ster=0) const
MonitorElement * ShotsVsTimeApvShotsGlobal
MonitorElement * book2D(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY)
Book 2D histogram.
Definition: DQMStore.cc:1000
void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
void setCurrentFolder(const std::string &fullpath)
Definition: DQMStore.cc:584
void SiStripMonitorDigi::createModuleMEs ( ModMEs mod_single,
uint32_t  detid 
)
private

Definition at line 938 of file SiStripMonitorDigi.cc.

References SiStripMonitorDigi::ModMEs::ADCsCoolestStrip, SiStripMonitorDigi::ModMEs::ADCsHottestStrip, DQMStore::book1D(), bookME1D(), SiStripHistoId::createHistoId(), SiStripMonitorDigi::ModMEs::DigiADCs, dqmStore_, MonitorElement::getTH1(), moduleswitchadccooleston, moduleswitchadchotteston, moduleswitchdigiadcson, moduleswitchnumdigison, moduleswitchnumdigispstripon, moduleswitchstripoccupancyon, SiStripMonitorDigi::ModMEs::NumberOfDigis, SiStripMonitorDigi::ModMEs::NumberOfDigisPerStrip, MonitorElement::setAxisTitle(), SiStripDetCabling_, AlCaHLTBitMon_QueryRunRegistry::string, SiStripMonitorDigi::ModMEs::StripOccupancy, and DQMStore::tag().

Referenced by createMEs().

938  {
939 
940  // use SistripHistoId for producing histogram id (and title)
941  SiStripHistoId hidmanager;
942  std::string hid;
943 
944  //nr. of digis per module
946  hid = hidmanager.createHistoId("NumberOfDigis","det",detid);
947  mod_single.NumberOfDigis = dqmStore_->book1D(hid, hid, 21, -0.5, 20.5);
948  dqmStore_->tag(mod_single.NumberOfDigis, detid);
949  mod_single.NumberOfDigis->setAxisTitle("number of digis in one detector module");
950  mod_single.NumberOfDigis->getTH1()->StatOverflows(kTRUE); // over/underflows in Mean calculation
951  }
952 
953  //nr. of digis per strip in module
955  hid = hidmanager.createHistoId("NumberOfDigisPerStrip","det",detid);
956  short nstrips = SiStripDetCabling_->nApvPairs(detid) * 2 * 128;
957  mod_single.NumberOfDigisPerStrip = dqmStore_->book1D(hid, hid, nstrips, -0.5, nstrips+0.5);
958  dqmStore_->tag(mod_single.NumberOfDigisPerStrip, detid);
959  mod_single.NumberOfDigisPerStrip->setAxisTitle("number of (digis > 0) per strip");
960  mod_single.NumberOfDigisPerStrip->getTH1()->StatOverflows(kTRUE); // over/underflows in Mean calculation
961  }
962  //#ADCs for hottest strip
964  hid = hidmanager.createHistoId("ADCsHottestStrip","det",detid);
965  mod_single.ADCsHottestStrip = bookME1D("TH1ADCsHottestStrip", hid.c_str());
966  dqmStore_->tag(mod_single.ADCsHottestStrip, detid); // 6 APVs -> 768 strips
967  mod_single.ADCsHottestStrip->setAxisTitle("number of ADCs for hottest strip");
968  }
969 
970  //#ADCs for coolest strip
972  hid = hidmanager.createHistoId("ADCsCoolestStrip","det",detid);
973  mod_single.ADCsCoolestStrip = bookME1D("TH1ADCsCoolestStrip", hid.c_str());
974  dqmStore_->tag(mod_single.ADCsCoolestStrip, detid);
975  mod_single.ADCsCoolestStrip->setAxisTitle("number of ADCs for coolest strip");
976  }
977 
978  //#ADCs for each digi
980  hid = hidmanager.createHistoId("DigiADCs","det",detid);
981  mod_single.DigiADCs = bookME1D("TH1DigiADCs", hid.c_str());
982  dqmStore_->tag(mod_single.DigiADCs, detid);
983  mod_single.DigiADCs->setAxisTitle("number of ADCs for each digi");
984  }
985 
986  //Strip occupancy
988  hid = hidmanager.createHistoId("StripOccupancy","det",detid);
989  mod_single.StripOccupancy = bookME1D("TH1StripOccupancy", hid.c_str());
990  dqmStore_->tag(mod_single.StripOccupancy, detid);
991  mod_single.StripOccupancy->setAxisTitle("strip occupancy");
992  }
993 
994 }
MonitorElement * book1D(const char *name, const char *title, int nchX, double lowX, double highX)
Book 1D histogram.
Definition: DQMStore.cc:872
void tag(MonitorElement *me, unsigned int myTag)
Definition: DQMStore.cc:1509
edm::ESHandle< SiStripDetCabling > SiStripDetCabling_
std::string createHistoId(std::string description, std::string id_type, uint32_t component_id)
MonitorElement * bookME1D(const char *ParameterSetLabel, const char *HistoName)
void SiStripMonitorDigi::createSubDetMEs ( std::string  label)
private

Definition at line 1068 of file SiStripMonitorDigi.cc.

References DQMStore::book1D(), DQMStore::book2D(), DQMStore::bookProfile(), conf_, MonitorElement::DQM_KIND_TPROFILE, dqmStore_, edm::ParameterSet::getParameter(), MonitorElement::getTH1(), MonitorElement::kind(), diffTwoXMLs::label, MonitorElement::setAxisTitle(), AlCaHLTBitMon_QueryRunRegistry::string, SiStripMonitorDigi::SubDetMEs::SubDetApvShots, SiStripMonitorDigi::SubDetMEs::SubDetChargeMedianApvShotsTH1, SiStripMonitorDigi::SubDetMEs::SubDetDigiApvProf, SiStripMonitorDigi::SubDetMEs::SubDetDigiApvTH2, SubDetMEsMap, SiStripMonitorDigi::SubDetMEs::SubDetNApvShotsNApvTH1, SiStripMonitorDigi::SubDetMEs::SubDetNApvShotsProf, SiStripMonitorDigi::SubDetMEs::SubDetNApvShotsTH1, SiStripMonitorDigi::SubDetMEs::SubDetNStripsApvShotsTH1, subdetswitchapvcycleprofon, subdetswitchapvcycleth2on, subdetswitchapvshotsonprof, subdetswitchchargemedianapvshotson, subdetswitchnapvshotson, subdetswitchnstripsapvshotson, subdetswitchtotdigiprofon, SiStripMonitorDigi::SubDetMEs::SubDetTotDigiProf, and SiStripMonitorDigi::SubDetMEs::totNDigis.

Referenced by createMEs().

1068  {
1069 
1070  SubDetMEs subdetMEs;
1071  subdetMEs.totNDigis = 0;
1072  subdetMEs.SubDetTotDigiProf = 0;
1073  subdetMEs.SubDetDigiApvProf = 0;
1074  subdetMEs.SubDetDigiApvTH2 = 0;
1075 
1076  subdetMEs.SubDetApvShots.clear();
1077  subdetMEs.SubDetNApvShotsTH1 = 0;
1078  subdetMEs.SubDetChargeMedianApvShotsTH1 = 0;
1079  subdetMEs.SubDetNStripsApvShotsTH1 = 0;
1080  subdetMEs.SubDetNApvShotsProf = 0;
1081 
1083 
1084  // Total Number of Digi - Profile
1086  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("TProfTotalNumberOfDigis");
1087  HistoName = "TotalNumberOfDigiProfile__" + label;
1088  subdetMEs.SubDetTotDigiProf=dqmStore_->bookProfile(HistoName,HistoName,
1089  Parameters.getParameter<int32_t>("Nbins"),
1090  Parameters.getParameter<double>("xmin"),
1091  Parameters.getParameter<double>("xmax"),
1092  100, //that parameter should not be there !?
1093  Parameters.getParameter<double>("ymin"),
1094  Parameters.getParameter<double>("ymax"),
1095  "" );
1096  subdetMEs.SubDetTotDigiProf->setAxisTitle("Event Time in Seconds",1);
1097  if (subdetMEs.SubDetTotDigiProf->kind() == MonitorElement::DQM_KIND_TPROFILE) subdetMEs.SubDetTotDigiProf->getTH1()->SetBit(TH1::kCanRebin);
1098  }
1099 
1100  // Number of Digi vs Bx - Profile
1102  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("TProfDigiApvCycle");
1103  HistoName = "Digi_vs_ApvCycle__" + label;
1104  subdetMEs.SubDetDigiApvProf=dqmStore_->bookProfile(HistoName,HistoName,
1105  Parameters.getParameter<int32_t>("Nbins"),
1106  Parameters.getParameter<double>("xmin"),
1107  Parameters.getParameter<double>("xmax"),
1108  200, //that parameter should not be there !?
1109  Parameters.getParameter<double>("ymin"),
1110  Parameters.getParameter<double>("ymax"),
1111  "" );
1112  subdetMEs.SubDetDigiApvProf->setAxisTitle("ApvCycle (Corrected Absolute Bx % 70)",1);
1113  }
1114 
1115  // Number of Digi vs Bx - TH2
1117  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("TH2DigiApvCycle");
1118  //dqmStore_->setCurrentFolder("SiStrip/MechanicalView/"+label);
1119  HistoName = "Digi_vs_ApvCycle_2D__" + label;
1120  // Adjusting the scale for 2D histogram
1121  double h2ymax = 9999.0;
1122  double yfact = Parameters.getParameter<double>("yfactor");
1123  if(label.find("TIB") != std::string::npos) h2ymax = (6984.*256.)*yfact;
1124  else if (label.find("TID") != std::string::npos) h2ymax = (2208.*256.)*yfact;
1125  else if (label.find("TOB") != std::string::npos) h2ymax = (12906.*256.)*yfact;
1126  else if (label.find("TEC") != std::string::npos) h2ymax = (7552.*2.*256.)*yfact;
1127  subdetMEs.SubDetDigiApvTH2=dqmStore_->book2D(HistoName,HistoName,
1128  Parameters.getParameter<int32_t>("Nbins"),
1129  Parameters.getParameter<double>("xmin"),
1130  Parameters.getParameter<double>("xmax"),
1131  Parameters.getParameter<int32_t>("Nbinsy"), //it was 100 that parameter should not be there !?
1132  Parameters.getParameter<double>("ymin"),
1133  h2ymax);
1134  subdetMEs.SubDetDigiApvTH2->setAxisTitle("absolute Bx mod(70)",1);
1135  }
1136 
1137  //Number of APV Shots
1139  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("TH1NApvShots");
1140  //dqmStore_->setCurrentFolder("SiStrip/MechanicalView/"+label);
1141  HistoName = "Number_of_Apv_Shots_" + label;
1142  subdetMEs.SubDetNApvShotsTH1=dqmStore_->book1D(HistoName,HistoName,
1143  Parameters.getParameter<int32_t>("Nbins"),
1144  Parameters.getParameter<double>("xmin"),
1145  Parameters.getParameter<double>("xmax"));
1146  subdetMEs.SubDetNApvShotsTH1->setAxisTitle("# Apv Shots",1);
1147  }
1148 
1149  //Strip multiplicity of APV Shots
1151  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("TH1NStripsApvShots");
1152  //dqmStore_->setCurrentFolder("SiStrip/MechanicalView/"+label);
1153  HistoName = "Number_of_Strips_in_Apv_Shots_" + label;
1154  subdetMEs.SubDetNStripsApvShotsTH1=dqmStore_->book1D(HistoName,HistoName,
1155  Parameters.getParameter<int32_t>("Nbins"),
1156  Parameters.getParameter<double>("xmin"),
1157  Parameters.getParameter<double>("xmax"));
1158  subdetMEs.SubDetNStripsApvShotsTH1->setAxisTitle("# strips in Apv Shots",1);
1159  }
1160 
1161  //Charge median of APV Shots
1163  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("TH1ChargeMedianApvShots");
1164  //dqmStore_->setCurrentFolder("SiStrip/MechanicalView/"+label);
1165  HistoName = "Apv_Shots_Charge_Median_" + label;
1166  subdetMEs.SubDetChargeMedianApvShotsTH1=dqmStore_->book1D(HistoName,HistoName,
1167  Parameters.getParameter<int32_t>("Nbins"),
1168  Parameters.getParameter<double>("xmin"),
1169  Parameters.getParameter<double>("xmax"));
1170  subdetMEs.SubDetChargeMedianApvShotsTH1->setAxisTitle("Apv Shots Charge Median (ADC)",1);
1171  }
1172 
1173 
1175  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("TH1ApvNumApvShots");
1176  //dqmStore_->setCurrentFolder("SiStrip/MechanicalView/"+label);
1177  HistoName = "Apv_Shots_Apv_Number_" + label;
1178  subdetMEs.SubDetNApvShotsNApvTH1=dqmStore_->book1D(HistoName,HistoName,
1179  Parameters.getParameter<int32_t>("Nbins"),
1180  Parameters.getParameter<double>("xmin"),
1181  Parameters.getParameter<double>("xmax"));
1182  subdetMEs.SubDetNApvShotsNApvTH1->setAxisTitle("Apv Number",1);
1183  }
1184 
1185 
1186 
1187 
1188 
1189  //APV Shots number Vs time
1191  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("TProfNShotsVsTime");
1192  HistoName = "NApv_Shots_vs_Time_" + label;
1193  subdetMEs.SubDetNApvShotsProf=dqmStore_->bookProfile(HistoName,HistoName,
1194  Parameters.getParameter<int32_t>("Nbins"),
1195  Parameters.getParameter<double>("xmin"),
1196  Parameters.getParameter<double>("xmax"),
1197  200, //that parameter should not be there !?
1198  Parameters.getParameter<double>("ymin"),
1199  Parameters.getParameter<double>("ymax"),
1200  "" );
1201  subdetMEs.SubDetNApvShotsProf->setAxisTitle("Time (s)",1);
1202  subdetMEs.SubDetNApvShotsProf->setAxisTitle("# Apv Shots",2);
1203  if (subdetMEs.SubDetNApvShotsProf->kind() == MonitorElement::DQM_KIND_TPROFILE) subdetMEs.SubDetNApvShotsProf->getTH1()->SetBit(TH1::kCanRebin);
1204  }
1205 
1206 
1207 
1208 
1209 
1210 
1211 
1212  SubDetMEsMap[label]=subdetMEs;
1213 }
T getParameter(std::string const &) const
MonitorElement * book1D(const char *name, const char *title, int nchX, double lowX, double highX)
Book 1D histogram.
Definition: DQMStore.cc:872
vector< ParameterSet > Parameters
MonitorElement * bookProfile(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, const char *option="s")
Definition: DQMStore.cc:1186
std::map< std::string, SubDetMEs > SubDetMEsMap
edm::ParameterSet conf_
std::string HistoName
MonitorElement * book2D(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY)
Book 2D histogram.
Definition: DQMStore.cc:1000
void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
void SiStripMonitorDigi::createSubDetTH2 ( std::string  label)
private
void SiStripMonitorDigi::endJob ( void  )
virtual

Reimplemented from edm::EDAnalyzer.

Definition at line 875 of file SiStripMonitorDigi.cc.

References conf_, dqmStore_, edm::ParameterSet::getParameter(), dumpDBToFile_GT_ttrig_cfg::outputFileName, DQMStore::save(), and AlCaHLTBitMon_QueryRunRegistry::string.

875  {
876  bool outputMEsInRootFile = conf_.getParameter<bool>("OutputMEsInRootFile");
878 
879  // save histograms in a file
880  if(outputMEsInRootFile) dqmStore_->save(outputFileName);
881 
882 }//end of method
T getParameter(std::string const &) const
void save(const std::string &filename, const std::string &path="", const std::string &pattern="", const std::string &rewrite="", const uint32_t run=0, SaveReferenceTag ref=SaveWithReference, int minStatus=dqm::qstatus::STATUS_OK, const std::string &fileupdate="RECREATE")
Definition: DQMStore.cc:2296
edm::ParameterSet conf_
void SiStripMonitorDigi::endLuminosityBlock ( const edm::LuminosityBlock lb,
const edm::EventSetup es 
)
virtual

Reimplemented from edm::EDAnalyzer.

Definition at line 277 of file SiStripMonitorDigi.cc.

References digiFailureMEs, dqmStore_, HcalObjRepresent::Fill(), DQMStore::get(), MonitorElement::getBinContent(), edm::LuminosityBlockBase::id(), ignoreFirstNLumisections_, integrateNLumisections_, isStableBeams, edm::LuminosityBlockID::luminosityBlock(), nFedTECm, nFedTECp, nFedTIB, nFedTIDm, nFedTIDp, nFedTOB, SBDeclaredAt, SBTransitionDone, SiStripMonitorDigi::DigiFailureMEs::SubDetDigiFailures2D, subdetswitchtotdigifailureon, topFolderName_, and relativeConstraints::value.

277  {
278 
280  {
281  SBDeclaredAt = (int)lb.id().luminosityBlock();
282  SBTransitionDone = true;
283  }
284 
286 
287  int nFeds [6] = { 96 , 96 , 84 , 15 , 15 , 134 }; // tec- , tec+ , tib , tid- , tid+ , tob
288  int nFedsConnected [6] = { nFedTECm , nFedTECp , nFedTIB , nFedTIDm , nFedTIDp , nFedTOB };
289 
290  MonitorElement * me = dqmStore_->get(topFolderName_+"/MechanicalView/NumberOfDigisInLastLS");
291  if (me) {
292 
293  for (int ibin = 1; ibin<7;ibin++){
294 
295  float value = me->getBinContent(ibin);
296 
297  float fillvalue = 2;
298  if ( isStableBeams
299  // && (int)lb.id().luminosityBlock() > ignoreFirstNLumisections_ //ignore first X lumisections for HV rampup
301  && (float)nFedsConnected[ibin-1] / nFeds[ibin-1] > 0.5
302  && value < 50. ){
303 
304  fillvalue = 1.01;
305  }
306 
307  //account for integrated LS: fill previous bins as well
308  for ( int fillbin = (int)lb.id().luminosityBlock() - integrateNLumisections_ + 1 ; fillbin <= (int)lb.id().luminosityBlock() ; fillbin++ )
309  digiFailureMEs.SubDetDigiFailures2D -> Fill( fillbin , ibin-1 , fillvalue );
310  }
311  }
312  }
313 
314 }
LuminosityBlockID id() const
void Fill(HcalDetId &id, double val, std::vector< TH2F > &depth)
DigiFailureMEs digiFailureMEs
MonitorElement * get(const std::string &path) const
get ME from full pathname (e.g. &quot;my/long/dir/my_histo&quot;)
Definition: DQMStore.cc:1623
LuminosityBlockNumber_t luminosityBlock() const
std::string topFolderName_
double getBinContent(int binx) const
get content of bin (1-D)
void SiStripMonitorDigi::endRun ( const edm::Run ,
const edm::EventSetup  
)
virtual

Reimplemented from edm::EDAnalyzer.

Definition at line 261 of file SiStripMonitorDigi.cc.

261  {
262 }
void SiStripMonitorDigi::FillApvShotsMap ( TkHistoMap the_map,
const std::vector< APVShot > &  shots,
uint32_t  id,
int  mode 
)
private

Definition at line 1236 of file SiStripMonitorDigi.cc.

References TkHistoMap::fill(), and i.

Referenced by analyze().

1236  {
1237 
1238  for (uint i=0; i<shots.size(); i++){
1239  if (mode==1) the_map->fill(id,shots[i].nStrips()); //mode == 1 fill with strip multiplicity
1240  if (mode==2) the_map->fill(id,shots[i].median()); // mode == 2 fill with charge median
1241  }
1242 }
int i
Definition: DBlmapReader.cc:9
void fill(uint32_t &detid, float value)
Definition: TkHistoMap.cc:133
void SiStripMonitorDigi::fillDigiADCsMEs ( int  value,
std::string  name 
)
private
void SiStripMonitorDigi::fillME ( MonitorElement ME,
float  value1 
)
inlineprivate

Definition at line 103 of file SiStripMonitorDigi.h.

References MonitorElement::Fill().

Referenced by analyze().

103 {if (ME!=0)ME->Fill(value1);}
void Fill(long long x)
void SiStripMonitorDigi::fillME ( MonitorElement ME,
float  value1,
float  value2 
)
inlineprivate

Definition at line 104 of file SiStripMonitorDigi.h.

References MonitorElement::Fill().

104 {if (ME!=0)ME->Fill(value1,value2);}
void Fill(long long x)
void SiStripMonitorDigi::fillME ( MonitorElement ME,
float  value1,
float  value2,
float  value3 
)
inlineprivate

Definition at line 105 of file SiStripMonitorDigi.h.

References MonitorElement::Fill().

105 {if (ME!=0)ME->Fill(value1,value2,value3);}
void Fill(long long x)
void SiStripMonitorDigi::fillME ( MonitorElement ME,
float  value1,
float  value2,
float  value3,
float  value4 
)
inlineprivate

Definition at line 106 of file SiStripMonitorDigi.h.

References MonitorElement::Fill().

106 {if (ME!=0)ME->Fill(value1,value2,value3,value4);}
void Fill(long long x)
void SiStripMonitorDigi::fillTrend ( MonitorElement me,
float  value,
float  timeinorbit 
)
private

Definition at line 929 of file SiStripMonitorDigi.cc.

References MonitorElement::Fill().

Referenced by analyze().

930 {
931  if(!me) return;
932  me->Fill(timeinorbit,value);
933 }
void Fill(long long x)
int SiStripMonitorDigi::getDigiSourceIndex ( uint32_t  id)
private

Definition at line 1217 of file SiStripMonitorDigi.cc.

References digi_detset_handles, and end.

Referenced by analyze().

1217  {
1218  int location = -1;
1219  for (unsigned int ival = 0; ival < digi_detset_handles.size(); ++ival){
1221  if(isearch != digi_detset_handles[ival]->end()) {
1222  location = ival;
1223  break;
1224  }
1225  }
1226  return location;
1227 }
std::vector< const edm::DetSetVector< SiStripDigi > * > digi_detset_handles
#define end
Definition: vmac.h:37
collection_type::const_iterator const_iterator
Definition: DetSetVector.h:106
void SiStripMonitorDigi::ResetModuleMEs ( uint32_t  idet)
private

Definition at line 884 of file SiStripMonitorDigi.cc.

References SiStripMonitorDigi::ModMEs::ADCsCoolestStrip, SiStripMonitorDigi::ModMEs::ADCsHottestStrip, SiStripMonitorDigi::ModMEs::DigiADCs, DigiMEs, Mod_On_, moduleswitchadccooleston, moduleswitchadchotteston, moduleswitchdigiadcson, moduleswitchnumdigison, moduleswitchnumdigispstripon, moduleswitchstripoccupancyon, SiStripMonitorDigi::ModMEs::NumberOfDigis, SiStripMonitorDigi::ModMEs::NumberOfDigisPerStrip, MonitorElement::Reset(), and SiStripMonitorDigi::ModMEs::StripOccupancy.

Referenced by beginRun(), and createMEs().

884  {
885  std::map<uint32_t, ModMEs >::iterator pos = DigiMEs.find(idet);
886  ModMEs mod_me = pos->second;
887 
888  if(Mod_On_ && moduleswitchnumdigison) mod_me.NumberOfDigis->Reset();
889  if(Mod_On_ && moduleswitchnumdigispstripon) mod_me.NumberOfDigisPerStrip ->Reset();
890  if(Mod_On_ && moduleswitchadchotteston) mod_me.ADCsHottestStrip->Reset();
891  if(Mod_On_ && moduleswitchadccooleston) mod_me.ADCsCoolestStrip->Reset();
892  if(Mod_On_ && moduleswitchdigiadcson) mod_me.DigiADCs->Reset();
893  if(Mod_On_ && moduleswitchstripoccupancyon) mod_me.StripOccupancy->Reset();
894 
895 }
std::map< uint32_t, ModMEs > DigiMEs

Member Data Documentation

edm::InputTag SiStripMonitorDigi::apvPhaseProducer_
private

Definition at line 213 of file SiStripMonitorDigi.h.

Referenced by SiStripMonitorDigi().

edm::EDGetTokenT<APVCyclePhaseCollection> SiStripMonitorDigi::apvPhaseProducerToken_
private

Definition at line 216 of file SiStripMonitorDigi.h.

Referenced by analyze(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::calculate_strip_occupancy
private

Definition at line 125 of file SiStripMonitorDigi.h.

edm::ParameterSet SiStripMonitorDigi::conf_
private
bool SiStripMonitorDigi::createTrendMEs
private

Definition at line 210 of file SiStripMonitorDigi.h.

Referenced by analyze(), createLayerMEs(), and SiStripMonitorDigi().

SiStripDCSStatus* SiStripMonitorDigi::dcsStatus_
private

Definition at line 219 of file SiStripMonitorDigi.h.

Referenced by analyze(), SiStripMonitorDigi(), and ~SiStripMonitorDigi().

std::map<std::pair<std::string,int32_t>,bool> SiStripMonitorDigi::DetectedLayers
private

Definition at line 135 of file SiStripMonitorDigi.h.

std::vector<const edm::DetSetVector<SiStripDigi> *> SiStripMonitorDigi::digi_detset_handles
private

Definition at line 136 of file SiStripMonitorDigi.h.

Referenced by analyze(), and getDigiSourceIndex().

DigiFailureMEs SiStripMonitorDigi::digiFailureMEs
private

Definition at line 131 of file SiStripMonitorDigi.h.

Referenced by analyze(), beginLuminosityBlock(), createMEs(), and endLuminosityBlock().

std::map<uint32_t, ModMEs> SiStripMonitorDigi::DigiMEs
private

Definition at line 124 of file SiStripMonitorDigi.h.

Referenced by analyze(), beginRun(), createMEs(), and ResetModuleMEs().

std::vector<edm::InputTag> SiStripMonitorDigi::digiProducerList
private

Definition at line 123 of file SiStripMonitorDigi.h.

Referenced by analyze(), and SiStripMonitorDigi().

std::vector<edm::EDGetTokenT<edm::DetSetVector<SiStripDigi> > > SiStripMonitorDigi::digiProducerTokenList
private

Definition at line 122 of file SiStripMonitorDigi.h.

Referenced by analyze(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::digitkhistomapon
private

Definition at line 205 of file SiStripMonitorDigi.h.

Referenced by analyze(), createMEs(), and SiStripMonitorDigi().

DQMStore* SiStripMonitorDigi::dqmStore_
private
int SiStripMonitorDigi::eventNb
private

Definition at line 147 of file SiStripMonitorDigi.h.

Referenced by analyze(), and SiStripMonitorDigi().

int SiStripMonitorDigi::firstEvent
private

Definition at line 148 of file SiStripMonitorDigi.h.

Referenced by SiStripMonitorDigi().

SiStripFolderOrganizer SiStripMonitorDigi::folder_organizer
private

Definition at line 134 of file SiStripMonitorDigi.h.

Referenced by analyze(), and createMEs().

bool SiStripMonitorDigi::globalsummaryapvshotson
private

Definition at line 151 of file SiStripMonitorDigi.h.

Referenced by analyze(), createMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::globalswitchapvshotsApvon
private

Definition at line 186 of file SiStripMonitorDigi.h.

Referenced by analyze(), createMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::globalswitchapvshotsonprof
private

Definition at line 184 of file SiStripMonitorDigi.h.

Referenced by analyze(), createMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::globalswitchchargemedianapvshotson
private

Definition at line 185 of file SiStripMonitorDigi.h.

Referenced by analyze(), createMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::globalswitchnapvshotson
private

Definition at line 182 of file SiStripMonitorDigi.h.

Referenced by analyze(), createMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::globalswitchnstripsapvshotson
private

Definition at line 183 of file SiStripMonitorDigi.h.

Referenced by analyze(), createMEs(), and SiStripMonitorDigi().

edm::EDGetTokenT<L1GlobalTriggerEvmReadoutRecord> SiStripMonitorDigi::gtEvmToken_
private

Definition at line 217 of file SiStripMonitorDigi.h.

Referenced by analyze(), and SiStripMonitorDigi().

edm::InputTag SiStripMonitorDigi::historyProducer_
private

Definition at line 212 of file SiStripMonitorDigi.h.

Referenced by SiStripMonitorDigi().

edm::EDGetTokenT<EventWithHistory> SiStripMonitorDigi::historyProducerToken_
private

Definition at line 215 of file SiStripMonitorDigi.h.

Referenced by analyze(), and SiStripMonitorDigi().

int SiStripMonitorDigi::ignoreFirstNLumisections_
private

Definition at line 191 of file SiStripMonitorDigi.h.

Referenced by endLuminosityBlock(), and SiStripMonitorDigi().

int SiStripMonitorDigi::integrateNLumisections_
private
bool SiStripMonitorDigi::isStableBeams
private
std::map<std::string, std::vector< uint32_t > > SiStripMonitorDigi::LayerDetMap
private

Definition at line 127 of file SiStripMonitorDigi.h.

Referenced by analyze(), and createMEs().

std::map<std::string, LayerMEs> SiStripMonitorDigi::LayerMEsMap
private

Definition at line 128 of file SiStripMonitorDigi.h.

Referenced by analyze(), createLayerMEs(), and createMEs().

bool SiStripMonitorDigi::layerswitchadccooleston
private

Definition at line 156 of file SiStripMonitorDigi.h.

Referenced by analyze(), createLayerMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::layerswitchadchotteston
private

Definition at line 155 of file SiStripMonitorDigi.h.

Referenced by analyze(), createLayerMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::layerswitchdigiadcprofon
private

Definition at line 160 of file SiStripMonitorDigi.h.

Referenced by analyze(), createLayerMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::layerswitchdigiadcson
private

Definition at line 157 of file SiStripMonitorDigi.h.

Referenced by analyze(), createLayerMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::layerswitchnumdigisapvon
private

Definition at line 154 of file SiStripMonitorDigi.h.

bool SiStripMonitorDigi::layerswitchnumdigison
private

Definition at line 153 of file SiStripMonitorDigi.h.

Referenced by analyze(), createLayerMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::layerswitchnumdigisprofon
private

Definition at line 159 of file SiStripMonitorDigi.h.

Referenced by analyze(), createLayerMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::layerswitchstripoccupancyon
private

Definition at line 158 of file SiStripMonitorDigi.h.

Referenced by analyze(), createLayerMEs(), and SiStripMonitorDigi().

unsigned long long SiStripMonitorDigi::m_cacheID_
private

Definition at line 138 of file SiStripMonitorDigi.h.

Referenced by beginRun().

MonitorElement * SiStripMonitorDigi::MedianChargeApvShotsGlobal
private

Definition at line 143 of file SiStripMonitorDigi.h.

Referenced by analyze(), and createMEs().

bool SiStripMonitorDigi::Mod_On_
private

Definition at line 203 of file SiStripMonitorDigi.h.

Referenced by analyze(), createMEs(), ResetModuleMEs(), and SiStripMonitorDigi().

std::vector<uint32_t> SiStripMonitorDigi::ModulesToBeExcluded_
private

Definition at line 140 of file SiStripMonitorDigi.h.

bool SiStripMonitorDigi::moduleswitchadccooleston
private

Definition at line 165 of file SiStripMonitorDigi.h.

Referenced by analyze(), createModuleMEs(), ResetModuleMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::moduleswitchadchotteston
private

Definition at line 164 of file SiStripMonitorDigi.h.

Referenced by analyze(), createModuleMEs(), ResetModuleMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::moduleswitchdigiadcson
private

Definition at line 166 of file SiStripMonitorDigi.h.

Referenced by analyze(), createModuleMEs(), ResetModuleMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::moduleswitchnumdigison
private

Definition at line 162 of file SiStripMonitorDigi.h.

Referenced by analyze(), createModuleMEs(), ResetModuleMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::moduleswitchnumdigispstripon
private

Definition at line 163 of file SiStripMonitorDigi.h.

Referenced by analyze(), createModuleMEs(), ResetModuleMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::moduleswitchstripoccupancyon
private

Definition at line 167 of file SiStripMonitorDigi.h.

Referenced by analyze(), createModuleMEs(), ResetModuleMEs(), and SiStripMonitorDigi().

TString SiStripMonitorDigi::name
private
MonitorElement * SiStripMonitorDigi::NApvApvShotsGlobal
private

Definition at line 143 of file SiStripMonitorDigi.h.

Referenced by analyze(), and createMEs().

MonitorElement* SiStripMonitorDigi::NApvShotsGlobal
private

Definition at line 143 of file SiStripMonitorDigi.h.

Referenced by analyze(), and createMEs().

MonitorElement * SiStripMonitorDigi::NApvShotsGlobalProf
private

Definition at line 143 of file SiStripMonitorDigi.h.

Referenced by analyze(), and createMEs().

int SiStripMonitorDigi::nFedTECm
private

Definition at line 199 of file SiStripMonitorDigi.h.

Referenced by beginRun(), and endLuminosityBlock().

int SiStripMonitorDigi::nFedTECp
private

Definition at line 198 of file SiStripMonitorDigi.h.

Referenced by beginRun(), and endLuminosityBlock().

int SiStripMonitorDigi::nFedTIB
private

Definition at line 195 of file SiStripMonitorDigi.h.

Referenced by beginRun(), and endLuminosityBlock().

int SiStripMonitorDigi::nFedTIDm
private

Definition at line 197 of file SiStripMonitorDigi.h.

Referenced by beginRun(), and endLuminosityBlock().

int SiStripMonitorDigi::nFedTIDp
private

Definition at line 196 of file SiStripMonitorDigi.h.

Referenced by beginRun(), and endLuminosityBlock().

int SiStripMonitorDigi::nFedTOB
private

Definition at line 200 of file SiStripMonitorDigi.h.

Referenced by beginRun(), and endLuminosityBlock().

bool SiStripMonitorDigi::reset_each_run
private

Definition at line 125 of file SiStripMonitorDigi.h.

Referenced by beginRun(), and createMEs().

int SiStripMonitorDigi::runNb
private

Definition at line 147 of file SiStripMonitorDigi.h.

Referenced by analyze().

int SiStripMonitorDigi::SBDeclaredAt
private

Definition at line 193 of file SiStripMonitorDigi.h.

Referenced by endLuminosityBlock(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::SBTransitionDone
private

Definition at line 194 of file SiStripMonitorDigi.h.

Referenced by endLuminosityBlock(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::select_all_detectors
private

Definition at line 125 of file SiStripMonitorDigi.h.

bool SiStripMonitorDigi::shotschargehistomapon
private

Definition at line 208 of file SiStripMonitorDigi.h.

Referenced by analyze(), createMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::shotshistomapon
private

Definition at line 206 of file SiStripMonitorDigi.h.

Referenced by analyze(), createMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::shotsstripshistomapon
private

Definition at line 207 of file SiStripMonitorDigi.h.

Referenced by analyze(), createMEs(), and SiStripMonitorDigi().

MonitorElement * SiStripMonitorDigi::ShotsVsTimeApvShotsGlobal
private

Definition at line 143 of file SiStripMonitorDigi.h.

Referenced by analyze(), and createMEs().

bool SiStripMonitorDigi::show_control_view
private

Definition at line 125 of file SiStripMonitorDigi.h.

bool SiStripMonitorDigi::show_mechanical_structure_view
private

Definition at line 125 of file SiStripMonitorDigi.h.

Referenced by beginRun(), and createMEs().

bool SiStripMonitorDigi::show_readout_view
private

Definition at line 125 of file SiStripMonitorDigi.h.

edm::ESHandle<SiStripDetCabling> SiStripMonitorDigi::SiStripDetCabling_
private

Definition at line 139 of file SiStripMonitorDigi.h.

Referenced by analyze(), createMEs(), and createModuleMEs().

MonitorElement * SiStripMonitorDigi::StripMultiplicityApvShotsGlobal
private

Definition at line 143 of file SiStripMonitorDigi.h.

Referenced by analyze(), and createMEs().

std::map<std::string, SubDetMEs> SiStripMonitorDigi::SubDetMEsMap
private

Definition at line 129 of file SiStripMonitorDigi.h.

Referenced by analyze(), createMEs(), and createSubDetMEs().

std::map<std::string, std::string> SiStripMonitorDigi::SubDetPhasePartMap
private

Definition at line 130 of file SiStripMonitorDigi.h.

Referenced by analyze(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::subdetswitchapvcycleprofon
private

Definition at line 170 of file SiStripMonitorDigi.h.

Referenced by analyze(), createSubDetMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::subdetswitchapvcycleth2on
private

Definition at line 171 of file SiStripMonitorDigi.h.

Referenced by analyze(), createSubDetMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::subdetswitchapvshotsApvon
private

Definition at line 180 of file SiStripMonitorDigi.h.

Referenced by analyze(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::subdetswitchapvshotsonprof
private

Definition at line 178 of file SiStripMonitorDigi.h.

Referenced by analyze(), createSubDetMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::subdetswitchchargemedianapvshotson
private

Definition at line 179 of file SiStripMonitorDigi.h.

Referenced by analyze(), createSubDetMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::subdetswitchnapvshotson
private

Definition at line 176 of file SiStripMonitorDigi.h.

Referenced by analyze(), createSubDetMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::subdetswitchnstripsapvshotson
private

Definition at line 177 of file SiStripMonitorDigi.h.

Referenced by analyze(), createSubDetMEs(), and SiStripMonitorDigi().

bool SiStripMonitorDigi::subdetswitchtotdigifailureon
private
bool SiStripMonitorDigi::subdetswitchtotdigiproflson
private

Definition at line 173 of file SiStripMonitorDigi.h.

Referenced by beginLuminosityBlock().

bool SiStripMonitorDigi::subdetswitchtotdigiprofon
private

Definition at line 169 of file SiStripMonitorDigi.h.

Referenced by analyze(), createSubDetMEs(), and SiStripMonitorDigi().

TkHistoMap* SiStripMonitorDigi::tkmapdigi
private

Definition at line 145 of file SiStripMonitorDigi.h.

Referenced by analyze(), and createMEs().

TkHistoMap * SiStripMonitorDigi::tkmapMedianChargeApvshots
private

Definition at line 145 of file SiStripMonitorDigi.h.

Referenced by analyze(), and createMEs().

TkHistoMap * SiStripMonitorDigi::tkmapNApvshots
private

Definition at line 145 of file SiStripMonitorDigi.h.

Referenced by analyze(), and createMEs().

TkHistoMap * SiStripMonitorDigi::tkmapNstripApvshot
private

Definition at line 145 of file SiStripMonitorDigi.h.

Referenced by analyze(), and createMEs().

std::string SiStripMonitorDigi::topFolderName_

Definition at line 44 of file SiStripMonitorDigi.h.

Referenced by createMEs(), endLuminosityBlock(), and SiStripMonitorDigi().

int SiStripMonitorDigi::TotalNShots
private

Definition at line 149 of file SiStripMonitorDigi.h.

Referenced by analyze().