CMS 3D CMS Logo

DTChamberEfficiencyTask.h
Go to the documentation of this file.
1 #ifndef DTChamberEfficiencyTask_H
2 #define DTChamberEfficiencyTask_H
3 
20 
25 
28 
30 
31 #include <string>
32 #include <map>
33 #include <vector>
34 
35 class DTChamberEfficiencyTask : public DQMOneEDAnalyzer<edm::one::WatchLuminosityBlocks> {
36 public:
39 
41  ~DTChamberEfficiencyTask() override;
42 
44  void dqmBeginRun(const edm::Run& run, const edm::EventSetup& setup) override;
45 
47  void beginLuminosityBlock(edm::LuminosityBlock const& lumiSeg, edm::EventSetup const& context) override;
48  void endLuminosityBlock(edm::LuminosityBlock const& lumiSeg, edm::EventSetup const& context) final {}
49 
50  // Operations
51  void analyze(const edm::Event& event, const edm::EventSetup& setup) override;
52 
53 protected:
54  // Book the histograms
55  void bookHistograms(DQMStore::IBooker&, edm::Run const&, edm::EventSetup const&) override;
56 
57 private:
59  const DTRecSegment4D* getBestSegment(const DTRecSegment4D* s1, const DTRecSegment4D* s2) const;
60  bool isGoodSegment(const DTRecSegment4D& seg) const;
61  LocalPoint interpolate(const DTRecSegment4D& seg1, const DTRecSegment4D& seg3, const DTChamberId& MB2) const;
62 
63  void bookHistos(DQMStore::IBooker& ibooker, DTChamberId chId);
64 
65  // Switch for verbosity
66  bool debug;
67  // The running mode
69  // The analysis mode
71 
72  // Lable of 4D segments in the event
74 
76 
77  std::map<DTChamberId, std::vector<MonitorElement*> > histosPerCh;
78 
79  unsigned int theMinHitsSegment;
82 
85 };
86 #endif
87 
88 /* Local Variables: */
89 /* show-trailing-whitespace: t */
90 /* truncate-lines: t */
91 /* End: */
edm::EDGetTokenT< DTRecSegment4DCollection > recHits4DToken_
std::pair< const_iterator, const_iterator > range
iterator range
Definition: RangeMap.h:50
void endLuminosityBlock(edm::LuminosityBlock const &lumiSeg, edm::EventSetup const &context) final
void dqmBeginRun(const edm::Run &run, const edm::EventSetup &setup) override
BeginRun.
edm::Handle< DTRecSegment4DCollection > segs
~DTChamberEfficiencyTask() override
Destructor.
void beginLuminosityBlock(edm::LuminosityBlock const &lumiSeg, edm::EventSetup const &context) override
To reset the MEs.
void analyze(const edm::Event &event, const edm::EventSetup &setup) override
LocalPoint interpolate(const DTRecSegment4D &seg1, const DTRecSegment4D &seg3, const DTChamberId &MB2) const
DTChamberEfficiencyTask(const edm::ParameterSet &pset)
Constructor.
edm::ESHandle< DTGeometry > dtGeom
bool isGoodSegment(const DTRecSegment4D &seg) const
std::map< DTChamberId, std::vector< MonitorElement * > > histosPerCh
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
const DTRecSegment4D & getBestSegment(const DTRecSegment4DCollection::range &segs) const
void bookHistos(DQMStore::IBooker &ibooker, DTChamberId chId)
Definition: event.py:1
Definition: Run.h:45