CMS 3D CMS Logo

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)
 

Private Attributes

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

Detailed Description

Definition at line 79 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

Member Function Documentation

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

Definition at line 93 of file BPHHistoSpecificDecay.cc.

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

Referenced by Vispa.Gui.BoxContentDialog.BoxContentDialog::apply(), Vispa.Plugins.ConfigEditor.ToolDialog.ToolDialog::apply(), and esMonitoring.FDJsonServer::handle_accept().

94  {
95  const pat::Muon* p = reinterpret_cast<const pat::Muon*>( &cand );
96  if ( p == 0 ) return false;
97  if ( gM &&
98  !muon::isGoodMuon( *p, muon::TMOneStationTight ) ) return false;
99  if ( p->innerTrack()->hitPattern().trackerLayersWithMeasurement() <= cutTL )
100  return false;
101  if ( p->innerTrack()->hitPattern(). pixelLayersWithMeasurement() <= cutPL )
102  return false;
103  if ( hP &&
104  !p->innerTrack()->quality( reco::TrackBase::highPurity ) )
105  return false;
106  if ( pv == 0 ) return true;
107  const reco::Vertex::Point& pos = pv->position();
108  if ( fabs( p->innerTrack()->dxy( pos ) ) >= maxXY )
109  return false;
110  if ( fabs( p->innerTrack()->dz ( pos ) ) >= maxZ )
111  return false;
112  return true;
113  }
const Point & position() const
position
Definition: Vertex.h:109
reco::TrackRef innerTrack() const override
reference to Track reconstructed in the tracker only (reimplemented from reco::Muon) ...
Definition: Muon.h:73
math::XYZPoint Point
point in the space
Definition: Vertex.h:39
bool isGoodMuon(const reco::Muon &muon, SelectionType type, reco::Muon::ArbitrationType arbitrationType=reco::Muon::SegmentAndTrackArbitration)
main GoodMuon wrapper call
Analysis-level muon class.
Definition: Muon.h:50

Member Data Documentation

int BPHSoftMuonSelect::cutPL
private

Definition at line 117 of file BPHHistoSpecificDecay.cc.

int BPHSoftMuonSelect::cutTL
private

Definition at line 116 of file BPHHistoSpecificDecay.cc.

bool BPHSoftMuonSelect::gM
private

Definition at line 120 of file BPHHistoSpecificDecay.cc.

bool BPHSoftMuonSelect::hP
private

Definition at line 121 of file BPHHistoSpecificDecay.cc.

float BPHSoftMuonSelect::maxXY
private

Definition at line 118 of file BPHHistoSpecificDecay.cc.

float BPHSoftMuonSelect::maxZ
private

Definition at line 119 of file BPHHistoSpecificDecay.cc.

const reco::Vertex* BPHSoftMuonSelect::pv
private

Definition at line 115 of file BPHHistoSpecificDecay.cc.