#include <MuonSeedCleaner.h>
Public Types | |
typedef std::deque< bool > | BoolContainer |
typedef MuonTransientTrackingRecHit::MuonRecHitContainer | SegmentContainer |
Public Member Functions | |
MuonSeedCleaner (const edm::ParameterSet &) | |
Constructor. | |
int | NRecHitsFromSegment (MuonTransientTrackingRecHit *rhit) |
int | NRecHitsFromSegment (const TrackingRecHit &rhit) |
std::vector< TrajectorySeed > | seedCleaner (const edm::EventSetup &eventSetup, std::vector< TrajectorySeed > &seeds) |
Cache pointer to geometry. | |
~MuonSeedCleaner () | |
Destructor. | |
Public Attributes | |
std::vector< int > | badSeedLayer |
Private Member Functions | |
TrajectorySeed | BiggerCone (std::vector< TrajectorySeed > &seeds) |
select the seed with bigger projection cone to next layer | |
TrajectorySeed | Chi2LengthSelection (std::vector< TrajectorySeed > &seeds) |
select seed by balance length and chi2 | |
std::vector< SeedContainer > | GroupSeeds (std::vector< TrajectorySeed > &seeds) |
group the seeds | |
TrajectorySeed | LeanHighMomentum (std::vector< TrajectorySeed > &seeds) |
select the highest momentum pt seed | |
SeedContainer | LengthFilter (std::vector< TrajectorySeed > &seeds) |
bool | MomentumFilter (std::vector< TrajectorySeed > &seeds) |
filter out the bad pt seeds, if all are bad pt seeds then keep all | |
TrajectorySeed | MoreRecHits (std::vector< TrajectorySeed > &seeds) |
select the seed with more rechits | |
double | NChi2OfSegment (const TrackingRecHit &rhit) |
retrieve number of rechits& normalized chi2 of associated segments of a seed | |
unsigned int | OverlapSegments (TrajectorySeed seed1, TrajectorySeed seed2) |
check overlapping segment for seeds | |
SeedContainer | SeedCandidates (std::vector< TrajectorySeed > &seeds, bool good) |
pick the seeds w/ 1st layer information and w/ more than 1 segments | |
double | SeedChi2 (TrajectorySeed seed) |
int | SeedLength (TrajectorySeed seed) |
GlobalVector | SeedMomentum (TrajectorySeed seed) |
retrieve seed global momentum | |
GlobalPoint | SeedPosition (TrajectorySeed seed) |
retrieve seed global position | |
Private Attributes | |
const MagneticField * | BField |
bool | debug |
int | NShowerSeg |
std::vector< int > | ShoweringLayers |
SegmentContainer | ShoweringSegments |
MuonServiceProxy * | theService |
Algorith to clean duplicate seeds and select a right one
author: Shih-Chuan Kao - UCR
Definition at line 27 of file MuonSeedCleaner.h.
typedef std::deque<bool> MuonSeedCleaner::BoolContainer |
Definition at line 33 of file MuonSeedCleaner.h.
Definition at line 32 of file MuonSeedCleaner.h.
MuonSeedCleaner::MuonSeedCleaner | ( | const edm::ParameterSet & | pset | ) | [explicit] |
Constructor.
Definition at line 49 of file MuonSeedCleaner.cc.
References debug, edm::ParameterSet::getParameter(), MuonServiceProxy_cff::MuonServiceProxy, and theService.
{ // Local Debug flag debug = pset.getParameter<bool>("DebugMuonSeed"); // muon service edm::ParameterSet serviceParameters = pset.getParameter<edm::ParameterSet>("ServiceParameters"); theService = new MuonServiceProxy(serviceParameters); }
MuonSeedCleaner::~MuonSeedCleaner | ( | ) |
Destructor.
Definition at line 63 of file MuonSeedCleaner.cc.
References theService.
{ if (theService) delete theService; }
TrajectorySeed MuonSeedCleaner::BiggerCone | ( | std::vector< TrajectorySeed > & | seeds | ) | [private] |
select the seed with bigger projection cone to next layer
Definition at line 171 of file MuonSeedCleaner.cc.
References i, NRecHitsFromSegment(), diffTwoXMLs::r1, and mathSSE::sqrt().
Referenced by seedCleaner().
{ if ( seeds.size() == 1 ) return seeds[0]; float biggerProjErr = 9999.; int winner = 0 ; AlgebraicSymMatrix mat(5,0) ; for ( size_t i = 0; i < seeds.size(); i++ ) { edm::OwnVector<TrackingRecHit>::const_iterator r1 = seeds[i].recHits().first ; mat = r1->parametersError().similarityT( r1->projectionMatrix() ); int NRecHits = NRecHitsFromSegment( *r1 ); float ddx = mat[1][1]; float ddy = mat[2][2]; float dxx = mat[3][3]; float dyy = mat[4][4]; float projectErr = sqrt( (ddx*10000.) + (ddy*10000.) + dxx + dyy ) ; if ( NRecHits < 5 ) continue ; if ( projectErr < biggerProjErr ) continue; winner = static_cast<int>(i) ; biggerProjErr = projectErr ; } TrajectorySeed theSeed = seeds[winner]; seeds.erase( seeds.begin()+winner ); return theSeed; }
TrajectorySeed MuonSeedCleaner::Chi2LengthSelection | ( | std::vector< TrajectorySeed > & | seeds | ) | [private] |
select seed by balance length and chi2
Definition at line 131 of file MuonSeedCleaner.cc.
References i, and SeedChi2().
Referenced by seedCleaner().
{ if ( seeds.size() == 1 ) return seeds[0]; int winner = 0 ; int moreHits = 0 ; double bestChi2 = 99999.; for ( size_t i = 0; i < seeds.size(); i++ ) { // 1. fill out the Nchi2 of segments of the seed //GlobalVector mom = SeedMomentum( seeds[i] ); // temporary use for debugging //double pt = sqrt( (mom.x()*mom.x()) + (mom.y()*mom.y()) ); //std::cout<<" > SEED"<<i<<" pt:"<<pt<< std::endl; double theChi2 = SeedChi2( seeds[i] ); double dChi2 = fabs( 1. - (theChi2 / bestChi2)) ; int theHits = seeds[i].nHits() ; int dHits = theHits - moreHits ; //std::cout<<" ----- "<<std::endl; // 2. better chi2 if ( theChi2 < bestChi2 && dChi2 > 0.05 ) { winner = static_cast<int>(i) ; bestChi2 = theChi2 ; moreHits = theHits ; } // 3. if chi2 is not much better, pick more rechits one if ( theChi2 >= bestChi2 && dChi2 < 0.05 && dHits > 0 ) { winner = static_cast<int>(i) ; bestChi2 = theChi2 ; moreHits = theHits ; } } //std::cout<<" Winner is "<< winner <<std::endl; TrajectorySeed theSeed = seeds[winner]; seeds.erase( seeds.begin()+winner ); return theSeed; }
std::vector< SeedContainer > MuonSeedCleaner::GroupSeeds | ( | std::vector< TrajectorySeed > & | seeds | ) | [private] |
group the seeds
Definition at line 345 of file MuonSeedCleaner.cc.
References PV3DBase< T, PVType, FrameType >::eta(), i, j, lengthSorting(), OverlapSegments(), PV3DBase< T, PVType, FrameType >::phi(), SeedPosition(), python::multivaluedict::sort(), mathSSE::sqrt(), and funct::true.
Referenced by seedCleaner().
{ std::vector<SeedContainer> seedCollection; seedCollection.clear(); std::vector<TrajectorySeed> theGroup ; std::vector<bool> usedSeed(seeds.size(),false); // categorize seeds by comparing overlapping segments or a certian eta-phi cone for (size_t i= 0; i<seeds.size(); i++){ if (usedSeed[i]) continue; theGroup.push_back( seeds[i] ); usedSeed[i] = true ; GlobalPoint pos1 = SeedPosition( seeds[i] ); for (size_t j= i+1; j<seeds.size(); j++){ // 1.1 seeds with overlaaping segments will be grouped together unsigned int overlapping = OverlapSegments(seeds[i], seeds[j]) ; if ( !usedSeed[j] && overlapping > 0 ) { // reject the identical seeds if ( seeds[i].nHits() == overlapping && seeds[j].nHits() == overlapping ) { usedSeed[j] = true ; continue; } theGroup.push_back( seeds[j] ); usedSeed[j] = true ; } if (usedSeed[j]) continue; // 1.2 seeds in a certain cone are grouped together GlobalPoint pos2 = SeedPosition( seeds[j]); double dh = pos1.eta() - pos2.eta() ; double df = pos1.phi() - pos2.phi() ; double dR = sqrt( (dh*dh) + (df*df) ); if ( dR > 0.3 && seeds[j].nHits() == 1) continue; if ( dR > 0.2 && seeds[j].nHits() > 1) continue; theGroup.push_back( seeds[j] ); usedSeed[j] = true ; } sort(theGroup.begin(), theGroup.end(), lengthSorting ) ; seedCollection.push_back(theGroup); //std::cout<<" group "<<seedCollection.size() <<" w/"<< theGroup.size() <<" seeds"<<std::endl; theGroup.clear(); } return seedCollection; }
TrajectorySeed MuonSeedCleaner::LeanHighMomentum | ( | std::vector< TrajectorySeed > & | seeds | ) | [private] |
select the highest momentum pt seed
Definition at line 203 of file MuonSeedCleaner.cc.
References i, SeedMomentum(), mathSSE::sqrt(), PV3DBase< T, PVType, FrameType >::x(), and PV3DBase< T, PVType, FrameType >::y().
Referenced by seedCleaner().
{ if ( seeds.size() == 1 ) return seeds[0]; double highestPt = 0. ; int winner = 0 ; for ( size_t i = 0; i < seeds.size(); i++ ) { GlobalVector mom = SeedMomentum( seeds[i] ); double pt = sqrt( (mom.x()*mom.x()) + (mom.y()*mom.y()) ); if ( pt > highestPt ) { winner = static_cast<int>(i) ; highestPt = pt ; } } TrajectorySeed theSeed = seeds[winner]; seeds.erase( seeds.begin()+winner ); return theSeed; }
SeedContainer MuonSeedCleaner::LengthFilter | ( | std::vector< TrajectorySeed > & | seeds | ) | [private] |
pick the seed by better parameter error collect long seeds
Definition at line 256 of file MuonSeedCleaner.cc.
References i.
{ SeedContainer longSeeds; int NSegs = 0; for (size_t i = 0; i< seeds.size(); i++) { int theLength = static_cast<int>( seeds[i].nHits()); if ( theLength > NSegs ) { NSegs = theLength ; longSeeds.clear(); longSeeds.push_back( seeds[i] ); } else if ( theLength == NSegs ) { longSeeds.push_back( seeds[i] ); } else { continue; } } //std::cout<<" final Length :"<<NSegs<<std::endl; return longSeeds ; }
bool MuonSeedCleaner::MomentumFilter | ( | std::vector< TrajectorySeed > & | seeds | ) | [private] |
filter out the bad pt seeds, if all are bad pt seeds then keep all
Definition at line 281 of file MuonSeedCleaner.cc.
References i, SeedMomentum(), mathSSE::sqrt(), PV3DBase< T, PVType, FrameType >::x(), and PV3DBase< T, PVType, FrameType >::y().
Referenced by seedCleaner().
{ bool findgoodMomentum = false; SeedContainer goodMomentumSeeds = seeds; seeds.clear(); for ( size_t i = 0; i < goodMomentumSeeds.size(); i++ ) { GlobalVector mom = SeedMomentum( goodMomentumSeeds[i] ); double pt = sqrt( (mom.x()*mom.x()) + (mom.y()*mom.y()) ); if ( pt < 6. || pt > 2000. ) continue; //if ( pt < 6. ) continue; //std::cout<<" passed momentum :"<< pt <<std::endl; seeds.push_back( goodMomentumSeeds[i] ); findgoodMomentum = true; } if ( seeds.size() == 0 ) seeds = goodMomentumSeeds; return findgoodMomentum; }
TrajectorySeed MuonSeedCleaner::MoreRecHits | ( | std::vector< TrajectorySeed > & | seeds | ) | [private] |
select the seed with more rechits
Definition at line 224 of file MuonSeedCleaner.cc.
References i, NRecHitsFromSegment(), diffTwoXMLs::r1, and SeedChi2().
Referenced by seedCleaner().
{ if ( seeds.size() == 1 ) return seeds[0]; int winner = 0 ; int moreHits = 0 ; double betterChi2 = 99999.; for ( size_t i = 0; i < seeds.size(); i++ ) { int theHits = 0; for (edm::OwnVector<TrackingRecHit>::const_iterator r1 = seeds[i].recHits().first; r1 != seeds[i].recHits().second; r1++){ theHits += NRecHitsFromSegment( *r1 ); } double theChi2 = SeedChi2( seeds[i] ); if ( theHits == moreHits && theChi2 < betterChi2 ) { betterChi2 = theChi2; winner = static_cast<int>(i) ; } if ( theHits > moreHits ) { moreHits = theHits ; betterChi2 = theChi2; winner = static_cast<int>(i) ; } } TrajectorySeed theSeed = seeds[winner]; seeds.erase( seeds.begin()+winner ); return theSeed; }
double MuonSeedCleaner::NChi2OfSegment | ( | const TrackingRecHit & | rhit | ) | [private] |
retrieve number of rechits& normalized chi2 of associated segments of a seed
Definition at line 527 of file MuonSeedCleaner.cc.
References TrackingRecHit::clone(), TrackingRecHit::geographicalId(), MuonTransientTrackingRecHit::specificBuild(), theService, and MuonServiceProxy::trackingGeometry().
Referenced by SeedChi2().
{ double NChi2 = 999999. ; const GeomDet* gdet = theService->trackingGeometry()->idToDet( rhit.geographicalId() ); MuonTransientTrackingRecHit::MuonRecHitPointer theSeg = MuonTransientTrackingRecHit::specificBuild(gdet, rhit.clone() ); double dof = static_cast<double>( theSeg->degreesOfFreedom() ); NChi2 = theSeg->chi2() / dof ; //std::cout<<" Chi2 = "<< NChi2 <<" |" ; return NChi2 ; }
int MuonSeedCleaner::NRecHitsFromSegment | ( | const TrackingRecHit & | rhit | ) |
Definition at line 481 of file MuonSeedCleaner.cc.
References TrackingRecHit::clone(), CSC(), GeomDetEnumerators::DT, TrackingRecHit::geographicalId(), GeomDet::geographicalId(), j, findQualityFiles::size, MuonTransientTrackingRecHit::specificBuild(), theService, and MuonServiceProxy::trackingGeometry().
Referenced by BiggerCone(), MuonSeedBuilder::foundMatchingSegment(), MuonSeedBuilder::IdentifyShowering(), MoreRecHits(), and SeedLength().
{ int NRechits = 0 ; const GeomDet* gdet = theService->trackingGeometry()->idToDet( rhit.geographicalId() ); MuonTransientTrackingRecHit::MuonRecHitPointer theSeg = MuonTransientTrackingRecHit::specificBuild(gdet, rhit.clone() ); DetId geoId = gdet->geographicalId(); if ( geoId.subdetId() == MuonSubdetId::DT ) { DTChamberId DT_Id( rhit.geographicalId() ); std::vector<TrackingRecHit*> DThits = theSeg->recHits(); int dt1DHits = 0; for (size_t j=0; j< DThits.size(); j++) { dt1DHits += (DThits[j]->recHits()).size(); } NRechits = dt1DHits ; } if ( geoId.subdetId() == MuonSubdetId::CSC ) { NRechits = (theSeg->recHits()).size() ; } return NRechits ; }
int MuonSeedCleaner::NRecHitsFromSegment | ( | MuonTransientTrackingRecHit * | rhit | ) |
Definition at line 505 of file MuonSeedCleaner.cc.
References CSC(), GeomDetEnumerators::DT, TrackingRecHit::geographicalId(), j, GenericTransientTrackingRecHit::recHits(), findQualityFiles::size, and DetId::subdetId().
{ int NRechits = 0 ; DetId geoId = rhit->geographicalId(); if ( geoId.subdetId() == MuonSubdetId::DT ) { DTChamberId DT_Id( geoId ); std::vector<TrackingRecHit*> DThits = rhit->recHits(); int dt1DHits = 0; for (size_t j=0; j< DThits.size(); j++) { dt1DHits += (DThits[j]->recHits()).size(); } NRechits = dt1DHits ; //std::cout<<" D_rh("<< dt1DHits <<") " ; } if ( geoId.subdetId() == MuonSubdetId::CSC ) { NRechits = (rhit->recHits()).size() ; //std::cout<<" C_rh("<<(rhit->recHits()).size() <<") " ; } return NRechits; }
unsigned int MuonSeedCleaner::OverlapSegments | ( | TrajectorySeed | seed1, |
TrajectorySeed | seed2 | ||
) | [private] |
check overlapping segment for seeds
Definition at line 396 of file MuonSeedCleaner.cc.
References diffTwoXMLs::r1, diffTwoXMLs::r2, TrajectorySeed::recHits(), mathSSE::sqrt(), theService, GeomDet::toGlobal(), MuonServiceProxy::trackingGeometry(), PV3DBase< T, PVType, FrameType >::x(), PV3DBase< T, PVType, FrameType >::y(), and PV3DBase< T, PVType, FrameType >::z().
Referenced by GroupSeeds().
{ unsigned int overlapping = 0; for (edm::OwnVector<TrackingRecHit>::const_iterator r1 = seed1.recHits().first; r1 != seed1.recHits().second; r1++){ DetId id1 = (*r1).geographicalId(); const GeomDet* gdet1 = theService->trackingGeometry()->idToDet( id1 ); GlobalPoint gp1 = gdet1->toGlobal( (*r1).localPosition() ); for (edm::OwnVector<TrackingRecHit>::const_iterator r2 = seed2.recHits().first; r2 != seed2.recHits().second; r2++){ DetId id2 = (*r2).geographicalId(); if (id1 != id2 ) continue; const GeomDet* gdet2 = theService->trackingGeometry()->idToDet( id2 ); GlobalPoint gp2 = gdet2->toGlobal( (*r2).localPosition() ); double dx = gp1.x() - gp2.x() ; double dy = gp1.y() - gp2.y() ; double dz = gp1.z() - gp2.z() ; double dL = sqrt( dx*dx + dy*dy + dz*dz); if ( dL < 1. ) overlapping ++; } } return overlapping ; }
SeedContainer MuonSeedCleaner::SeedCandidates | ( | std::vector< TrajectorySeed > & | seeds, |
bool | good | ||
) | [private] |
pick the seeds w/ 1st layer information and w/ more than 1 segments
Definition at line 302 of file MuonSeedCleaner.cc.
References CSC(), CSCDetId, GeomDetEnumerators::DT, funct::false, GeomDet::geographicalId(), i, diffTwoXMLs::r1, CSCDetId::station(), DetId::subdetId(), theService, and MuonServiceProxy::trackingGeometry().
Referenced by seedCleaner().
{ SeedContainer theCandidate; theCandidate.clear(); bool longSeed = false; bool withFirstLayer = false ; //std::cout<<"***** Seed Classification *****"<< seeds.size() <<std::endl; for ( size_t i = 0; i < seeds.size(); i++ ) { if (seeds[i].nHits() > 1 ) longSeed = true ; //std::cout<<" Seed: "<<i<<" w/"<<seeds[i].nHits()<<" segs "<<std::endl; // looking for 1st layer segment int idx = 0; for (edm::OwnVector<TrackingRecHit>::const_iterator r1 = seeds[i].recHits().first; r1 != seeds[i].recHits().second; r1++){ idx++; const GeomDet* gdet = theService->trackingGeometry()->idToDet( (*r1).geographicalId() ); DetId geoId = gdet->geographicalId(); if ( geoId.subdetId() == MuonSubdetId::DT ) { DTChamberId DT_Id( (*r1).geographicalId() ); //std::cout<<" ID:"<<DT_Id <<" pos:"<< r1->localPosition() <<std::endl; if (DT_Id.station() != 1) continue; withFirstLayer = true; } if ( geoId.subdetId() == MuonSubdetId::CSC ) { idx++; CSCDetId CSC_Id = CSCDetId( (*r1).geographicalId() ); //std::cout<<" ID:"<<CSC_Id <<" pos:"<< r1->localPosition() <<std::endl; if (CSC_Id.station() != 1) continue; withFirstLayer = true; } } bool goodseed = (longSeed && withFirstLayer) ? true : false ; if ( goodseed == good ) theCandidate.push_back( seeds[i] ); } return theCandidate; }
double MuonSeedCleaner::SeedChi2 | ( | TrajectorySeed | seed | ) | [private] |
Definition at line 426 of file MuonSeedCleaner.cc.
References NChi2OfSegment(), TrajectorySeed::nHits(), diffTwoXMLs::r1, and TrajectorySeed::recHits().
Referenced by Chi2LengthSelection(), and MoreRecHits().
{ double theChi2 = 0.; for (edm::OwnVector<TrackingRecHit>::const_iterator r1 = seed.recHits().first; r1 != seed.recHits().second; r1++){ //std::cout<<" segmet : "<<it <<std::endl; theChi2 += NChi2OfSegment( *r1 ); } theChi2 = theChi2 / seed.nHits() ; //std::cout<<" final Length :"<<NSegs<<std::endl; return theChi2 ; }
std::vector< TrajectorySeed > MuonSeedCleaner::seedCleaner | ( | const edm::EventSetup & | eventSetup, |
std::vector< TrajectorySeed > & | seeds | ||
) |
Cache pointer to geometry.
Cache pointer to Magnetic field cleaning the seeds
Definition at line 74 of file MuonSeedCleaner.cc.
References BiggerCone(), Chi2LengthSelection(), eta(), PV3DBase< T, PVType, FrameType >::eta(), GroupSeeds(), i, LeanHighMomentum(), MomentumFilter(), MoreRecHits(), SeedCandidates(), SeedPosition(), theService, and MuonServiceProxy::update().
Referenced by MuonSeedBuilder::build().
{ theService->update(eventSetup); std::vector<TrajectorySeed> FinalSeeds; // group the seeds std::vector<SeedContainer> theCollection = GroupSeeds(seeds); // ckeck each group and pick the good one for (size_t i=0; i< theCollection.size(); i++ ) { // separate seeds w/ more than 1 segments and w/ 1st layer segment information SeedContainer goodSeeds = SeedCandidates( theCollection[i], true ); SeedContainer otherSeeds = SeedCandidates( theCollection[i], false ); if ( MomentumFilter( goodSeeds ) ) { //std::cout<<" == type1 "<<std::endl; TrajectorySeed bestSeed = Chi2LengthSelection( goodSeeds ); FinalSeeds.push_back( bestSeed ); GlobalPoint seedgp = SeedPosition( bestSeed ); double eta = fabs( seedgp.eta() ); if ( goodSeeds.size() > 2 && eta > 1.5 ) { TrajectorySeed anotherSeed = MoreRecHits( goodSeeds ); FinalSeeds.push_back( anotherSeed ); } } else if( MomentumFilter( otherSeeds ) ) { //std::cout<<" == type2 "<<std::endl; TrajectorySeed bestSeed = MoreRecHits( otherSeeds ); FinalSeeds.push_back( bestSeed ); GlobalPoint seedgp = SeedPosition( bestSeed ); double eta = fabs( seedgp.eta() ); if ( otherSeeds.size() > 2 && eta > 1.5 ) { TrajectorySeed anotherSeed = LeanHighMomentum( otherSeeds ); FinalSeeds.push_back( anotherSeed ); } } else { //std::cout<<" == type3 "<<std::endl; TrajectorySeed bestSeed = LeanHighMomentum( theCollection[i] ); FinalSeeds.push_back( bestSeed ); GlobalPoint seedgp = SeedPosition( bestSeed ); double eta = fabs( seedgp.eta() ); if ( theCollection.size() > 2 && eta > 1.5 ) { TrajectorySeed anotherSeed = BiggerCone( theCollection[i] ); FinalSeeds.push_back( anotherSeed ); } } } return FinalSeeds ; }
int MuonSeedCleaner::SeedLength | ( | TrajectorySeed | seed | ) | [private] |
Definition at line 440 of file MuonSeedCleaner.cc.
References NRecHitsFromSegment(), diffTwoXMLs::r1, and TrajectorySeed::recHits().
{ int theHits = 0; for (edm::OwnVector<TrackingRecHit>::const_iterator r1 = seed.recHits().first; r1 != seed.recHits().second; r1++){ //std::cout<<" segmet : "<<it <<std::endl; theHits += NRecHitsFromSegment( *r1 ); } //std::cout<<" final Length :"<<NSegs<<std::endl; return theHits ; }
GlobalVector MuonSeedCleaner::SeedMomentum | ( | TrajectorySeed | seed | ) | [private] |
retrieve seed global momentum
Definition at line 467 of file MuonSeedCleaner.cc.
References PTrajectoryStateOnDet::detId(), TrajectoryStateOnSurface::globalMomentum(), MuonServiceProxy::magneticField(), TrajectorySeed::startingState(), theService, MuonServiceProxy::trackingGeometry(), and trajectoryStateTransform::transientState().
Referenced by LeanHighMomentum(), and MomentumFilter().
{ PTrajectoryStateOnDet pTSOD = seed.startingState(); DetId SeedDetId(pTSOD.detId()); const GeomDet* geoDet = theService->trackingGeometry()->idToDet( SeedDetId ); TrajectoryStateOnSurface SeedTSOS = trajectoryStateTransform::transientState(pTSOD, &(geoDet->surface()), &*theService->magneticField()); GlobalVector mom = SeedTSOS.globalMomentum(); return mom ; }
GlobalPoint MuonSeedCleaner::SeedPosition | ( | TrajectorySeed | seed | ) | [private] |
retrieve seed global position
Definition at line 453 of file MuonSeedCleaner.cc.
References PTrajectoryStateOnDet::detId(), TrajectoryStateOnSurface::globalPosition(), MuonServiceProxy::magneticField(), pos, TrajectorySeed::startingState(), theService, MuonServiceProxy::trackingGeometry(), and trajectoryStateTransform::transientState().
Referenced by GroupSeeds(), and seedCleaner().
{ PTrajectoryStateOnDet pTSOD = seed.startingState(); DetId SeedDetId(pTSOD.detId()); const GeomDet* geoDet = theService->trackingGeometry()->idToDet( SeedDetId ); TrajectoryStateOnSurface SeedTSOS = trajectoryStateTransform::transientState(pTSOD, &(geoDet->surface()), &*theService->magneticField()); GlobalPoint pos = SeedTSOS.globalPosition(); return pos ; }
std::vector<int> MuonSeedCleaner::badSeedLayer |
Definition at line 56 of file MuonSeedCleaner.h.
const MagneticField* MuonSeedCleaner::BField [private] |
Definition at line 110 of file MuonSeedCleaner.h.
bool MuonSeedCleaner::debug [private] |
Definition at line 99 of file MuonSeedCleaner.h.
Referenced by MuonSeedCleaner().
int MuonSeedCleaner::NShowerSeg [private] |
Definition at line 102 of file MuonSeedCleaner.h.
std::vector<int> MuonSeedCleaner::ShoweringLayers [private] |
Definition at line 104 of file MuonSeedCleaner.h.
Definition at line 103 of file MuonSeedCleaner.h.
MuonServiceProxy* MuonSeedCleaner::theService [private] |
Definition at line 113 of file MuonSeedCleaner.h.
Referenced by MuonSeedCleaner(), NChi2OfSegment(), NRecHitsFromSegment(), OverlapSegments(), SeedCandidates(), seedCleaner(), SeedMomentum(), SeedPosition(), and ~MuonSeedCleaner().