CMS 3D CMS Logo

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

Public Member Functions

bool accept (const reco::Candidate &cand, const reco::Vertex *pv) const
 
 BPHSoftMuonSelect (int cutTrackerLayers=5, int cutPixelLayers=0, float maxDxy=0.3, float maxDz=20.0, bool goodMuon=true, bool highPurity=true)
 
 ~BPHSoftMuonSelect ()
 

Private Attributes

int cutPL
 
int cutTL
 
bool gM
 
bool hP
 
float maxXY
 
float maxZ
 
const reco::Vertexpv
 

Detailed Description

Definition at line 140 of file BPHHistoSpecificDecay.cc.

Constructor & Destructor Documentation

BPHSoftMuonSelect::BPHSoftMuonSelect ( int  cutTrackerLayers = 5,
int  cutPixelLayers = 0,
float  maxDxy = 0.3,
float  maxDz = 20.0,
bool  goodMuon = true,
bool  highPurity = true 
)
inline

Definition at line 142 of file BPHHistoSpecificDecay.cc.

BPHSoftMuonSelect::~BPHSoftMuonSelect ( )
inline

Definition at line 149 of file BPHHistoSpecificDecay.cc.

149 {}

Member Function Documentation

bool BPHSoftMuonSelect::accept ( const reco::Candidate cand,
const reco::Vertex pv 
) const
inline

Definition at line 150 of file BPHHistoSpecificDecay.cc.

References reco::TrackBase::highPurity, pat::Muon::innerTrack(), muon::isGoodMuon(), CosmicsPD_Skims::maxZ, AlCaHLTBitMon_ParallelJobs::p, reco::Vertex::position(), and muon::TMOneStationTight.

Referenced by esMonitoring.FDJsonServer::handle_accept().

150  {
151  const pat::Muon* p = dynamic_cast<const pat::Muon*>(&cand);
152  if (p == nullptr)
153  return false;
155  return false;
156  if (p->innerTrack()->hitPattern().trackerLayersWithMeasurement() <= cutTL)
157  return false;
158  if (p->innerTrack()->hitPattern().pixelLayersWithMeasurement() <= cutPL)
159  return false;
160  if (hP && !p->innerTrack()->quality(reco::TrackBase::highPurity))
161  return false;
162  if (pv == nullptr)
163  return true;
164  const reco::Vertex::Point& pos = pv->position();
165  if (fabs(p->innerTrack()->dxy(pos)) >= maxXY)
166  return false;
167  if (fabs(p->innerTrack()->dz(pos)) >= maxZ)
168  return false;
169  return true;
170  }
const Point & position() const
position
Definition: Vertex.h:127
math::XYZPoint Point
point in the space
Definition: Vertex.h:40
bool isGoodMuon(const reco::Muon &muon, SelectionType type, reco::Muon::ArbitrationType arbitrationType=reco::Muon::SegmentAndTrackArbitration)
main GoodMuon wrapper call
reco::TrackRef innerTrack() const override
reference to Track reconstructed in the tracker only (reimplemented from reco::Muon) ...
Definition: Muon.h:72
Analysis-level muon class.
Definition: Muon.h:51

Member Data Documentation

int BPHSoftMuonSelect::cutPL
private

Definition at line 175 of file BPHHistoSpecificDecay.cc.

int BPHSoftMuonSelect::cutTL
private

Definition at line 174 of file BPHHistoSpecificDecay.cc.

bool BPHSoftMuonSelect::gM
private

Definition at line 178 of file BPHHistoSpecificDecay.cc.

bool BPHSoftMuonSelect::hP
private

Definition at line 179 of file BPHHistoSpecificDecay.cc.

float BPHSoftMuonSelect::maxXY
private

Definition at line 176 of file BPHHistoSpecificDecay.cc.

float BPHSoftMuonSelect::maxZ
private

Definition at line 177 of file BPHHistoSpecificDecay.cc.

const reco::Vertex* BPHSoftMuonSelect::pv
private

Definition at line 173 of file BPHHistoSpecificDecay.cc.