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 183 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 186 of file L1TrackSelectionProducer.cc.

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

Member Function Documentation

◆ operator()()

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

Definition at line 188 of file L1TrackSelectionProducer.cc.

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

188  {
189  int nPSStubs = 0;
190  for (const auto& stub : t.getStubRefs()) {
191  DetId detId(stub->getDetId());
192  if (detId.det() == DetId::Detector::Tracker) {
193  if ((detId.subdetId() == StripSubdetector::TOB && tTopo_.tobLayer(detId) <= 3) ||
194  (detId.subdetId() == StripSubdetector::TID && tTopo_.tidRing(detId) <= 9))
195  nPSStubs++;
196  }
197  }
198  return nPSStubs >= nPSStubsMin_;
199  }
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 202 of file L1TrackSelectionProducer.cc.

Referenced by operator()().

◆ tTopo_

const TrackerTopology& L1TrackSelectionProducer::TTTrackNPSStubsMinSelector::tTopo_
private

Definition at line 203 of file L1TrackSelectionProducer.cc.

Referenced by operator()().