CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
L1TrackSelectionProducer::TTTrackNPSStubsMinSelector Struct Reference

Public Member Functions

bool operator() (const L1Track &t) const
 
 TTTrackNPSStubsMinSelector (double nStubsMin, const TrackerTopology &tTopo)
 
 TTTrackNPSStubsMinSelector (const edm::ParameterSet &cfg, const TrackerTopology &tTopo)
 

Private Attributes

double nPSStubsMin_
 
const TrackerTopologytTopo_
 

Detailed Description

Definition at line 182 of file L1TrackSelectionProducer.cc.

Constructor & Destructor Documentation

◆ TTTrackNPSStubsMinSelector() [1/2]

L1TrackSelectionProducer::TTTrackNPSStubsMinSelector::TTTrackNPSStubsMinSelector ( double  nStubsMin,
const TrackerTopology tTopo 
)
inline

◆ TTTrackNPSStubsMinSelector() [2/2]

L1TrackSelectionProducer::TTTrackNPSStubsMinSelector::TTTrackNPSStubsMinSelector ( const edm::ParameterSet cfg,
const TrackerTopology tTopo 
)
inline

Definition at line 185 of file L1TrackSelectionProducer.cc.

186  : nPSStubsMin_(cfg.template getParameter<double>("nPSStubsMin")), tTopo_(tTopo) {}

Member Function Documentation

◆ operator()()

bool L1TrackSelectionProducer::TTTrackNPSStubsMinSelector::operator() ( const L1Track t) const
inline

Definition at line 187 of file L1TrackSelectionProducer.cc.

References hcalRecHitTable_cff::detId, nPSStubsMin_, submitPVValidationJobs::t, StripSubdetector::TID, TrackerTopology::tidRing(), StripSubdetector::TOB, TrackerTopology::tobLayer(), align::Tracker, and tTopo_.

187  {
188  int nPSStubs = 0;
189  for (const auto& stub : t.getStubRefs()) {
190  DetId detId(stub->getDetId());
191  if (detId.det() == DetId::Detector::Tracker) {
192  if ((detId.subdetId() == StripSubdetector::TOB && tTopo_.tobLayer(detId) <= 3) ||
193  (detId.subdetId() == StripSubdetector::TID && tTopo_.tidRing(detId) <= 9))
194  nPSStubs++;
195  }
196  }
197  return nPSStubs >= nPSStubsMin_;
198  }
unsigned int tobLayer(const DetId &id) const
static constexpr auto TOB
Definition: DetId.h:17
unsigned int tidRing(const DetId &id) const
static constexpr auto TID

Member Data Documentation

◆ nPSStubsMin_

double L1TrackSelectionProducer::TTTrackNPSStubsMinSelector::nPSStubsMin_
private

Definition at line 201 of file L1TrackSelectionProducer.cc.

Referenced by operator()().

◆ tTopo_

const TrackerTopology& L1TrackSelectionProducer::TTTrackNPSStubsMinSelector::tTopo_
private

Definition at line 202 of file L1TrackSelectionProducer.cc.

Referenced by operator()().