47 theProxyService = service;
57 event.getByLabel(theBeamSpotTag, bsHandle_);
67 if(cleanBySharedHits) theRedundantCleaner->define(seeds);
71 LogDebug(
"TrackerSeedCleaner")<<seeds.size()<<
" trajectory seeds to the events before cleaning"<<endl;
78 std::vector<TrajectorySeed >
result;
83 for(TrajectorySeedCollection::iterator seed = seeds.begin(); seed<seeds.end(); ++seed){
84 if(seed->nHits() < 2)
continue;
90 if (!tsAtClosestApproachSeed.isValid())
continue;
91 GlobalPoint vSeed1 = tsAtClosestApproachSeed.trackStateAtPCA().position();
92 GlobalVector pSeed = tsAtClosestApproachSeed.trackStateAtPCA().momentum();
98 double phiSeed = pSeed.
phi();
105 double etaLimit = (fabs(fabs(etaRange.max()) - fabs(etaRange.mean())) <0.1) ? 0.1 : fabs(fabs(etaRange.max()) - fabs(etaRange.mean())) ;
107 Margin phiMargin = region.phiMargin();
108 double phiLimit = (phiMargin.right() < 0.1 ) ? 0.1 : phiMargin.right();
110 double ptSeed = pSeed.
perp();
111 double ptMin = (region.ptMin()>3.5) ? 3.5: region.ptMin();
113 bool inEtaRange = etaSeed >= (etaRange.mean() - etaLimit) && etaSeed <= (etaRange.mean() + etaLimit) ;
114 bool inPhiRange = (fabs(
deltaPhi(phiSeed,
double(region.direction().phi()))) < phiLimit );
116 bool inPtRange = ptSeed >= ptMin && ptSeed<= 2*(muR->pt());
119 if(seed->nHits()==3) inPtRange =
true;
122 if(inPtRange && usePt_Cleaner && !useDirection_Cleaner) {
124 result.push_back(*seed);
125 LogDebug(
"TrackerSeedCleaner")<<
" Keeping the seed : this seed passed pt selection";
129 if( inEtaRange && inPhiRange && !usePt_Cleaner && useDirection_Cleaner) {
131 result.push_back(*seed);
132 LogDebug(
"TrackerSeedCleaner")<<
" Keeping the seed : this seed passed direction selection";
137 if( inEtaRange && inPhiRange && inPtRange && usePt_Cleaner && useDirection_Cleaner) {
139 result.push_back(*seed);
140 LogDebug(
"TrackerSeedCleaner")<<
" Keeping the seed : this seed passed direction and pt selection";
145 LogDebug(
"TrackerSeedCleaner")<<
" eta for current seed "<<etaSeed<<
"\n"
146 <<
" phi for current seed "<<phiSeed<<
"\n"
147 <<
" eta for L2 track "<<muR->eta()<<
"\n"
148 <<
" phi for L2 track "<<muR->phi()<<
"\n";
154 if(result.size()!=0 && (useDirection_Cleaner || usePt_Cleaner)) seeds.swap(result);
156 LogDebug(
"TrackerSeedCleaner")<<seeds.size()<<
" trajectory seeds to the events after cleaning"<<endl;
double z0() const
z coordinate
Geom::Phi< T > phi() const
virtual void setEvent(const edm::Event &)
setEvent
FreeTrajectoryState * freeState(bool withErrors=true) const
std::vector< TrajectorySeed > tkSeeds
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
PixelRecoRange< float > Range
GlobalVector globalMomentum() const
double y0() const
y coordinate
virtual void init(const MuonServiceProxy *service)
intizialization
virtual void clean(const reco::TrackRef &, const RectangularEtaPhiTrackingRegion ®ion, tkSeeds &)
the cleaner
double x0() const
x coordinate