CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
GEMEffByGEMCSCSegmentSource.h
Go to the documentation of this file.
1 #ifndef DQM_GEM_GEMEffByGEMCSCSegmentSource_h
2 #define DQM_GEM_GEMEffByGEMCSCSegmentSource_h
3 
17 
21 
26 
28 public:
32 
33 private:
34  // NOTE
35  using MEMap = std::map<GEMDetId, dqm::impl::MonitorElement*>;
36  bool hasMEKey(const MEMap&, const GEMDetId&);
37  void fillME(dqm::impl::MonitorElement*, const double);
38  void fillME(MEMap& me_map, const GEMDetId& key, const double);
39  void fillMEWithinLimits(dqm::impl::MonitorElement*, const double);
40  void fillMEWithinLimits(MEMap&, const GEMDetId&, const double);
41  template <typename T>
42  inline bool checkRefs(const std::vector<T*>&);
43  inline GEMDetId getReStLaKey(const GEMDetId&);
45 
46  void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override;
47  void analyze(const edm::Event &event, const edm::EventSetup &eventSetup) override;
48 
52 
53  // ME11-GE11 segments
55  void checkCoincidenceGE11(const GEMRecHit *, const GEMRecHit *, const GEMCSCSegment &);
57  bool isME11SegmentMatched(const CSCSegment &);
58 
59  // const member data (mainly parameters)
63  const bool kUseMuon_;
64  const uint32_t kMinCSCRecHits_;
67 
68  // member data
69  std::vector<const CSCSegment *> matched_me11_segment_vector_;
70 
71  // MonitorElement
72  MEMap me_chamber_; // 1D, (region, station, layer)
74  MEMap me_muon_chamber_; // 1D, (region, station, layer)
76  // misc
83 };
84 
85 template <typename T>
86 inline bool GEMEffByGEMCSCSegmentSource::checkRefs(const std::vector<T*>& refs) {
87  if (refs.empty())
88  return false;
89  if (refs.front() == nullptr)
90  return false;
91  return true;
92 }
93 
95  return GEMDetId{id.region(), 1, id.station(), id.layer(), 0, 0};
96 }
97 
98 #endif // DQM_GEM_GEMEffByGEMCSCSegmentSource_h
GEMEffByGEMCSCSegmentSource(const edm::ParameterSet &)
void fillME(dqm::impl::MonitorElement *, const double)
const edm::EDGetTokenT< reco::MuonCollection > kMuonToken_
GEMDetId getReStLaKey(const GEMDetId &)
bool hasMEKey(const MEMap &, const GEMDetId &)
const edm::EDGetTokenT< GEMCSCSegmentCollection > kGEMCSCSegmentToken_
void checkCoincidenceGE11(const GEMRecHit *, const GEMRecHit *, const GEMCSCSegment &)
MonitorElement * bookNumerator1D(DQMStore::IBooker &, MonitorElement *)
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
static void fillDescriptions(edm::ConfigurationDescriptions &)
const edm::ESGetToken< GEMGeometry, MuonGeometryRecord > kGEMTokenBeginRun_
std::vector< Muon > MuonCollection
collection of Muon objects
Definition: MuonFwd.h:9
void findMatchedME11Segments(const reco::MuonCollection *)
void analyzeME11GE11Segment(const GEMCSCSegment &)
constexpr int region() const
Definition: GEMDetId.h:171
tuple key
prepare the HTCondor submission files and eventually submit them
void bookMisc(DQMStore::IBooker &, const edm::ESHandle< GEMGeometry > &)
bool checkRefs(const std::vector< T * > &)
std::map< GEMDetId, dqm::impl::MonitorElement * > MEMap
void bookEfficiencyChamber(DQMStore::IBooker &, const edm::ESHandle< GEMGeometry > &)
bool isME11SegmentMatched(const CSCSegment &)
void analyze(const edm::Event &event, const edm::EventSetup &eventSetup) override
std::vector< const CSCSegment * > matched_me11_segment_vector_
Definition: Run.h:45
void fillMEWithinLimits(dqm::impl::MonitorElement *, const double)