CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
CSCOfflineMonitor.h
Go to the documentation of this file.
1 #ifndef RecoLocalMuon_CSCOfflineMonitor_H
2 #define RecoLocalMuon_CSCOfflineMonitor_H
3 
16 // user include files
29 
42 
48 
54 
56 
59 
65 
73 
75 public:
78 
80  virtual ~CSCOfflineMonitor();
81 
82  // Operations
83  void beginJob(void);
84  void finalize();
85  virtual void endRun( edm::Run const &, edm::EventSetup const & ) ; // call finialize()
86  virtual void endJob() ; // call finalize()
87 
88 
90  void analyze(const edm::Event & event, const edm::EventSetup& eventSetup);
91 
92 
93 protected:
94 
95 private:
96 
98 
107 
108  // some useful functions
109 
110  // modules:
125 
126 
127  // used by modules:
128  float fitX(CLHEP::HepMatrix sp, CLHEP::HepMatrix ep);
129  float getSignal(const CSCStripDigiCollection& stripdigis, CSCDetId idRH, int centerStrip);
130  int typeIndex(CSCDetId id, int flag = 1);
131  int chamberSerial(CSCDetId id);
132  void applyCSClabels(MonitorElement *meHisto);
133 
134  // for efficiency calculation
135  // these functions handle Stoyan's efficiency code
136  void fillEfficiencyHistos(int bin, int flag);
137  void getEfficiency(float bin, float Norm, std::vector<float> &eff);
138  void histoEfficiency(TH1F *readHisto, MonitorElement *writeHisto);
139  double lineParametrization(double z1Position, double z2Position, double z1Direction){
140  double parameterLine = (z2Position-z1Position)/z1Direction;
141  return parameterLine;
142  }
143  double extrapolate1D(double initPosition, double initDirection, double parameterOfTheLine){
144  double extrapolatedPosition = initPosition + initDirection*parameterOfTheLine;
145  return extrapolatedPosition;
146  }
147  bool withinSensitiveRegion(LocalPoint localPos, const std::vector<float> layerBounds,
148  int station, int ring, float shiftFromEdge, float shiftFromDeadZone);
149 
150  // for BX monitor plots
151  void harvestChamberMeans(MonitorElement* meMean1D, MonitorElement *meMean2D, TH2F *hNum, MonitorElement *meDenom);
152  void normalize(MonitorElement* me);
153 
154  // DQM
156 
157  // Wire digis
159  std::vector<MonitorElement*> hWireTBin;
160  std::vector<MonitorElement*> hWireNumber;
161 
162  // Strip Digis
164  std::vector<MonitorElement*> hStripNumber;
165  std::vector<MonitorElement*> hStripPed;
166 
167  // recHits
169  std::vector<MonitorElement*> hRHGlobal;
170  std::vector<MonitorElement*> hRHSumQ;
171  std::vector<MonitorElement*> hRHTiming;
172  std::vector<MonitorElement*> hRHTimingAnode;
173  std::vector<MonitorElement*> hRHRatioQ;
174  std::vector<MonitorElement*> hRHstpos;
175  std::vector<MonitorElement*> hRHsterr;
176 
177  // Segments
180  std::vector<MonitorElement*> hSnhits;
182  std::vector<MonitorElement*> hSChiSq;
184  std::vector<MonitorElement*> hSChiSqProb;
191 
192  // Resolution
193  std::vector<MonitorElement*> hSResid;
194 
195  // occupancy histos
207 
208  // Efficiency
209  TH1F *hSSTE;
210  TH1F *hRHSTE;
213  TH2F *hSSTE2;
214  TH2F *hRHSTE2;
215  TH2F *hStripSTE2;
216  TH2F *hWireSTE2;
224 
225  // BX monitor
232 
239 
246 
247 
248 };
249 #endif
MonitorElement * hOSegmentsSerial
void doPedestalNoise(edm::Handle< CSCStripDigiCollection > strips)
MonitorElement * hOWireSerial
long int flag
Definition: mlp_lapack.h:47
MonitorElement * hSensitiveAreaEvt
MonitorElement * hOStrips
int chamberSerial(CSCDetId id)
MonitorElement * hWireEff2
MonitorElement * hORecHits
void histoEfficiency(TH1F *readHisto, MonitorElement *writeHisto)
MonitorElement * hStripReadoutEff2
void doResolution(edm::Handle< CSCSegmentCollection > cscSegments, edm::ESHandle< CSCGeometry > cscGeom)
MonitorElement * hRHEff
std::vector< MonitorElement * > hRHGlobal
MonitorElement * hORecHitsSerial
std::vector< MonitorElement * > hSChiSq
float getSignal(const CSCStripDigiCollection &stripdigis, CSCDetId idRH, int centerStrip)
edm::InputTag alctDigiTag_
edm::InputTag clctDigiTag_
MonitorElement * hWirenGroupsTotal
MonitorElement * hCLCTL1ASerial
MonitorElement * hOStripSerial
edm::ParameterSet param
std::vector< MonitorElement * > hWireNumber
MonitorElement * hALCTgetBXChamberMeans
MonitorElement * hALCTMatch2DMeans
edm::InputTag cscSegTag_
virtual void endRun(edm::Run const &, edm::EventSetup const &)
MonitorElement * hSGlobalPhi
std::vector< MonitorElement * > hSnhits
CSCOfflineMonitor(const edm::ParameterSet &pset)
Constructor.
MonitorElement * hOWires
MonitorElement * hSnSegments
std::vector< MonitorElement * > hRHSumQ
edm::InputTag FEDRawDataCollectionTag_
MonitorElement * hOStripsAndWiresAndCLCT
void normalize(MonitorElement *me)
MonitorElement * hOSegments
std::vector< MonitorElement * > hStripPed
MonitorElement * hALCTMatchSerial
int typeIndex(CSCDetId id, int flag=1)
MonitorElement * hSnhitsAll
MonitorElement * hCLCTL1AChamberMeans
std::vector< MonitorElement * > hRHTiming
MonitorElement * hALCTgetBX
MonitorElement * hALCTMatch
MonitorElement * hSGlobalTheta
MonitorElement * hSTimeCombined
MonitorElement * hOWiresAndCLCT
std::vector< MonitorElement * > hRHsterr
void fillEfficiencyHistos(int bin, int flag)
MonitorElement * hCLCTL1A2Denominator
MonitorElement * hALCTgetBX2Denominator
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
void applyCSClabels(MonitorElement *meHisto)
void getEfficiency(float bin, float Norm, std::vector< float > &eff)
bool withinSensitiveRegion(LocalPoint localPos, const std::vector< float > layerBounds, int station, int ring, float shiftFromEdge, float shiftFromDeadZone)
MonitorElement * hSTimeVsZ
void doSegments(edm::Handle< CSCSegmentCollection > cscSegments, edm::ESHandle< CSCGeometry > cscGeom)
void analyze(const edm::Event &event, const edm::EventSetup &eventSetup)
Perform the real analysis.
MonitorElement * hALCTgetBX2DMeans
MonitorElement * hSEff2
MonitorElement * hSChiSqAll
MonitorElement * hCSCOccupancy
virtual void endJob()
void doWireDigis(edm::Handle< CSCWireDigiCollection > wires)
edm::InputTag stripDigiTag_
void harvestChamberMeans(MonitorElement *meMean1D, MonitorElement *meMean2D, TH2F *hNum, MonitorElement *meDenom)
MonitorElement * hSEff
std::vector< MonitorElement * > hStripNumber
MonitorElement * hALCTMatch2Denominator
MonitorElement * hRHEff2
float fitX(CLHEP::HepMatrix sp, CLHEP::HepMatrix ep)
MonitorElement * hALCTMatchChamberMeans
std::vector< MonitorElement * > hWireTBin
MonitorElement * hCLCTL1A
void doBXMonitor(edm::Handle< CSCALCTDigiCollection > alcts, edm::Handle< CSCCLCTDigiCollection > clcts, const edm::Event &event, const edm::EventSetup &eventSetup)
MonitorElement * hSTimeCathode
std::vector< MonitorElement * > hRHstpos
void doStripDigis(edm::Handle< CSCStripDigiCollection > strips)
MonitorElement * hStripNFired
edm::InputTag wireDigiTag_
std::vector< MonitorElement * > hSResid
MonitorElement * hStripEff2
MonitorElement * hALCTgetBXSerial
MonitorElement * hSTimeVsTOF
MonitorElement * hRHnrechits
edm::InputTag cscRecHitTag_
double extrapolate1D(double initPosition, double initDirection, double parameterOfTheLine)
std::vector< MonitorElement * > hSChiSqProb
std::vector< MonitorElement * > hRHTimingAnode
double lineParametrization(double z1Position, double z2Position, double z1Direction)
void doEfficiencies(edm::Handle< CSCWireDigiCollection > wires, edm::Handle< CSCStripDigiCollection > strips, edm::Handle< CSCRecHit2DCollection > recHits, edm::Handle< CSCSegmentCollection > cscSegments, edm::ESHandle< CSCGeometry > cscGeom)
MonitorElement * hCLCTL1A2DMeans
void doOccupancies(edm::Handle< CSCStripDigiCollection > strips, edm::Handle< CSCWireDigiCollection > wires, edm::Handle< CSCRecHit2DCollection > recHits, edm::Handle< CSCSegmentCollection > cscSegments, edm::Handle< CSCCLCTDigiCollection > clcts)
virtual ~CSCOfflineMonitor()
Destructor.
Definition: Run.h:33
MonitorElement * hSChiSqProbAll
void doRecHits(edm::Handle< CSCRecHit2DCollection > recHits, edm::Handle< CSCStripDigiCollection > strips, edm::ESHandle< CSCGeometry > cscGeom)
std::vector< MonitorElement * > hRHRatioQ