CMS 3D CMS Logo

MuonCosmicCompatibilityFiller.h
Go to the documentation of this file.
1 
14 #ifndef MuonIdentification_MuonCosmicCompatibilityFiller_h
15 #define MuonIdentification_MuonCosmicCompatibilityFiller_h
16 
17 #include <vector>
18 
21 
26 
35 
36 namespace edm {
37  class ParameterSet;
38  class Event;
39  class EventSetup;
40 } // namespace edm
41 class GlobalMuonRefitter;
42 
44 public:
47 
50 
51 private:
53  float muonTiming(const edm::Event& iEvent, const reco::Muon& muon, bool isLoose) const;
54 
56  unsigned int backToBack2LegCosmic(const edm::Event&, const reco::Muon&) const;
57 
59  unsigned int pvMatches(const edm::Event&, const reco::Muon&, bool) const;
60 
62  bool isOverlappingMuon(const edm::Event&, const edm::EventSetup& iSetup, const reco::Muon&) const;
63 
65  unsigned int nMuons(const edm::Event&) const;
66 
68  unsigned int eventActivity(const edm::Event&, const reco::Muon&) const;
69 
71  float combinedCosmicID(
72  const edm::Event&, const edm::EventSetup& iSetup, const reco::Muon&, bool CheckMuonID, bool checkVertex) const;
73 
75  bool checkMuonID(const reco::Muon&) const;
76 
78  bool checkMuonSegments(const reco::Muon& muon) const;
79 
80 private:
81  std::vector<edm::InputTag> inputMuonCollections_;
82  std::vector<edm::InputTag> inputTrackCollections_;
85 
86  std::vector<edm::EDGetTokenT<reco::MuonCollection> > muonTokens_;
87  std::vector<edm::EDGetTokenT<reco::TrackCollection> > trackTokens_;
91 
92  double maxdxyLoose_;
93  double maxdzLoose_;
94  double maxdxyTight_;
95  double maxdzTight_;
101  double largedxy_;
102  double hIpTrdxy_;
103  double hIpTrvProb_;
104  double minvProb_;
105  double maxvertZ_;
106  double maxvertRho_;
107  unsigned int nTrackThreshold_;
116  double corrTimePos_;
117  double corrTimeNeg_;
118  double deltaPt_;
121  double sharedFrac_;
122  double ipThreshold_;
124  double segmentComp_;
125 };
126 #endif
float combinedCosmicID(const edm::Event &, const edm::EventSetup &iSetup, const reco::Muon &, bool CheckMuonID, bool checkVertex) const
combined cosmic-likeness: 0 == not cosmic-like
edm::ESGetToken< GlobalTrackingGeometry, GlobalTrackingGeometryRecord > geometryToken_
bool isOverlappingMuon(const edm::Event &, const edm::EventSetup &iSetup, const reco::Muon &) const
returns cosmic-likeness based on overlap with traversing cosmic muon (only muon/STA hits are used) ...
std::vector< edm::EDGetTokenT< reco::TrackCollection > > trackTokens_
int iEvent
Definition: GenABIO.cc:224
edm::EDGetTokenT< reco::MuonCollection > cosmicToken_
std::vector< edm::EDGetTokenT< reco::MuonCollection > > muonTokens_
unsigned int nMuons(const edm::Event &) const
get number of muons in the vent
reco::MuonCosmicCompatibility fillCompatibility(const reco::Muon &muon, edm::Event &, const edm::EventSetup &)
fill cosmic compatibility variables
unsigned int pvMatches(const edm::Event &, const reco::Muon &, bool) const
return cosmic-likeness based on the 2D impact parameters (dxy, dz wrt to PV). 0 == cosmic-like ...
bool checkMuonID(const reco::Muon &) const
tag a muon as cosmic based on the muonID information
unsigned int backToBack2LegCosmic(const edm::Event &, const reco::Muon &) const
return cosmic-likeness based on presence of a track in opp side: 0 == no matching opp tracks ...
unsigned int eventActivity(const edm::Event &, const reco::Muon &) const
returns cosmic-likeness based on the event activity information: tracker track multiplicity and verte...
edm::EDGetTokenT< reco::VertexCollection > vertexToken_
MuonCosmicCompatibilityFiller(const edm::ParameterSet &, edm::ConsumesCollector &)
HLT enums.
std::vector< edm::InputTag > inputTrackCollections_
bool checkMuonSegments(const reco::Muon &muon) const
tag a muon as cosmic based on segment compatibility and the number of segment matches ...
std::vector< edm::InputTag > inputMuonCollections_
float muonTiming(const edm::Event &iEvent, const reco::Muon &muon, bool isLoose) const
check muon time (DT and CSC) information: 0 == prompt-like