CMS 3D CMS Logo

CosmicLayerTriplets Class Reference

find all (resonable) pairs of pixel layers More...

#include <RecoPixelVertexing/PixelTriplets/interface/CosmicLayerTriplets.h>

List of all members.

Public Types

typedef std::pair
< SeedLayerPairs::LayerPair,
std::vector< const
LayerWithHits * > > 
LayerPairAndLayers

Public Member Functions

 CosmicLayerTriplets ()
void init (const SiStripRecHit2DCollection &collstereo, const SiStripRecHit2DCollection &collrphi, const SiStripMatchedRecHit2DCollection &collmatched, std::string geometry, const edm::EventSetup &iSetup)
std::vector< LayerPairAndLayerslayers ()
 ~CosmicLayerTriplets ()

Private Attributes

std::string _geometry
TrackerLayerIdAccessor acc
std::vector< LayerWithHits * > allLayersWithHits
std::vector< BarrelDetLayer * > bl
std::vector< ForwardDetLayer * > fneg
std::vector< ForwardDetLayer * > fpos
bool isFirstCall
LayerWithHitslh1
LayerWithHitslh2
LayerWithHitslh3
LayerWithHitslh4
SiStripMatchedRecHit2DCollection::range match_range1
SiStripMatchedRecHit2DCollection::range match_range2
SiStripRecHit2DCollection::range rphi_range1
SiStripRecHit2DCollection::range rphi_range2
SiStripRecHit2DCollection::range rphi_range3
SiStripRecHit2DCollection::range rphi_range4
SiStripRecHit2DCollection::range stereo_range1
SiStripRecHit2DCollection::range stereo_range2
SiStripRecHit2DCollection::range stereo_range3


Detailed Description

find all (resonable) pairs of pixel layers

Definition at line 25 of file CosmicLayerTriplets.h.


Member Typedef Documentation

typedef std::pair<SeedLayerPairs::LayerPair, std::vector<const LayerWithHits*> > CosmicLayerTriplets::LayerPairAndLayers

Definition at line 30 of file CosmicLayerTriplets.h.


Constructor & Destructor Documentation

CosmicLayerTriplets::CosmicLayerTriplets (  )  [inline]

Definition at line 27 of file CosmicLayerTriplets.h.

00027 :isFirstCall(true){};

CosmicLayerTriplets::~CosmicLayerTriplets (  ) 

Definition at line 51 of file CosmicLayerTriplets.cc.

References allLayersWithHits, and it.

00052 {
00053   for(vector<LayerWithHits*>::const_iterator it=allLayersWithHits.begin(); it!=allLayersWithHits.end();it++){
00054     delete *it;
00055   }
00056 }


Member Function Documentation

void CosmicLayerTriplets::init ( const SiStripRecHit2DCollection collstereo,
const SiStripRecHit2DCollection collrphi,
const SiStripMatchedRecHit2DCollection collmatched,
std::string  geometry,
const edm::EventSetup iSetup 
)

Definition at line 60 of file CosmicLayerTriplets.cc.

References _geometry, acc, allLayersWithHits, bl, edm::EventSetup::get(), edm::RangeMap< ID, C, P >::get(), isFirstCall, it, lh1, lh2, lh3, lh4, LogDebug, rphi_range1, rphi_range2, rphi_range3, rphi_range4, TrackerLayerIdAccessor::stripTIBLayer(), TrackerLayerIdAccessor::stripTOBLayer(), and track.

Referenced by SeedGeneratorForCosmics::init().

00064                                                            {
00065 
00066   _geometry=geometry;
00067   if(isFirstCall){
00068     edm::ESHandle<GeometricSearchTracker> track;
00069     iSetup.get<TrackerRecoGeometryRecord>().get( track ); 
00070     bl=track->barrelLayers(); 
00071     isFirstCall=false;
00072   }
00073   for(vector<LayerWithHits*>::const_iterator it=allLayersWithHits.begin(); 
00074       it!=allLayersWithHits.end();it++){
00075     delete *it;
00076   }
00077 
00078   allLayersWithHits.clear();
00079   LogDebug("CosmicSeedFinder") <<"Reconstruction for geometry  "<<_geometry;
00080   if (_geometry=="STANDARD"  || _geometry=="TECPAIRS_TOBTRIPLETS"){
00081     rphi_range1=collrphi.get(acc.stripTOBLayer(4));
00082     rphi_range2=collrphi.get(acc.stripTOBLayer(5));
00083     rphi_range3=collrphi.get(acc.stripTOBLayer(6));
00084     
00085     const TOBLayer*  bl1=dynamic_cast<TOBLayer*>(bl[10]);
00086     const TOBLayer*  bl2=dynamic_cast<TOBLayer*>(bl[11]);
00087     const TOBLayer*  bl3=dynamic_cast<TOBLayer*>(bl[12]);
00088     
00089   
00090 
00091     //   //LayersWithHits
00092     lh1=new  LayerWithHits(bl1,rphi_range1);   allLayersWithHits.push_back(lh1);
00093     lh2=new  LayerWithHits(bl2,rphi_range2);   allLayersWithHits.push_back(lh2);
00094     lh3=new  LayerWithHits(bl3,rphi_range3);   allLayersWithHits.push_back(lh3);
00095   }
00096   if(_geometry=="MTCC"){ 
00097 
00098     const TIBLayer*  bl1=dynamic_cast<TIBLayer*>(bl[0]);
00099     const TIBLayer*  bl2=dynamic_cast<TIBLayer*>(bl[1]);
00100     const TOBLayer*  bl3=dynamic_cast<TOBLayer*>(bl[2]);
00101     const TOBLayer*  bl4=dynamic_cast<TOBLayer*>(bl[3]);
00102     rphi_range1=collrphi.get(acc.stripTIBLayer(1));
00103     rphi_range2=collrphi.get(acc.stripTIBLayer(2));
00104     rphi_range3=collrphi.get(acc.stripTOBLayer(1));
00105     rphi_range4=collrphi.get(acc.stripTOBLayer(2));
00106 
00107     lh1=new  LayerWithHits(bl1,rphi_range1); allLayersWithHits.push_back(lh1);
00108     lh2=new  LayerWithHits(bl2,rphi_range2); allLayersWithHits.push_back(lh2);
00109     lh3=new  LayerWithHits(bl3,rphi_range3); allLayersWithHits.push_back(lh3);
00110     lh4=new  LayerWithHits(bl4,rphi_range4); allLayersWithHits.push_back(lh4);
00111   }
00112 }

vector< CosmicLayerTriplets::LayerPairAndLayers > CosmicLayerTriplets::layers (  ) 

Definition at line 18 of file CosmicLayerTriplets.cc.

References _geometry, lh1, lh2, lh3, lh4, and HLT_VtxMuL3::result.

Referenced by CosmicHitTripletGenerator::CosmicHitTripletGenerator().

00019 {
00020   vector<LayerPairAndLayers> result;
00021 
00022   if (_geometry=="STANDARD"){
00023     vector<const LayerWithHits*> third;
00024     third.push_back(lh3);
00025     result.push_back(LayerPairAndLayers(SeedLayerPairs::LayerPair(lh1,lh2),third));
00026   
00027   }
00028   if (_geometry=="TECPAIRS_TOBTRIPLETS"){
00029     vector<const LayerWithHits*> third;
00030     third.push_back(lh3);
00031     result.push_back(LayerPairAndLayers(SeedLayerPairs::LayerPair(lh1,lh2),third));
00032   
00033   }
00034   if (_geometry=="MTCC"){
00035     vector<const LayerWithHits*> third1;
00036     vector<const LayerWithHits*> third2;
00037     vector<const LayerWithHits*> third3;
00038     vector<const LayerWithHits*> third4;
00039     third1.clear();third2.clear();third3.clear();third4.clear();
00040     third1.push_back(lh1);
00041     result.push_back(LayerPairAndLayers(SeedLayerPairs::LayerPair(lh3,lh2),third1));
00042     third2.push_back(lh1);
00043     result.push_back(LayerPairAndLayers(SeedLayerPairs::LayerPair(lh2,lh1),third2));
00044     third3.push_back(lh2);
00045     result.push_back(LayerPairAndLayers(SeedLayerPairs::LayerPair(lh3,lh2),third3));
00046     third4.push_back(lh4);
00047     result.push_back(LayerPairAndLayers(SeedLayerPairs::LayerPair(lh2,lh3),third4));
00048   }
00049   return result;
00050 }


Member Data Documentation

std::string CosmicLayerTriplets::_geometry [private]

Definition at line 75 of file CosmicLayerTriplets.h.

Referenced by init(), and layers().

TrackerLayerIdAccessor CosmicLayerTriplets::acc [private]

Definition at line 53 of file CosmicLayerTriplets.h.

Referenced by init().

std::vector<LayerWithHits*> CosmicLayerTriplets::allLayersWithHits [private]

Definition at line 64 of file CosmicLayerTriplets.h.

Referenced by init(), and ~CosmicLayerTriplets().

std::vector<BarrelDetLayer*> CosmicLayerTriplets::bl [private]

Definition at line 60 of file CosmicLayerTriplets.h.

Referenced by init().

std::vector<ForwardDetLayer*> CosmicLayerTriplets::fneg [private]

Definition at line 62 of file CosmicLayerTriplets.h.

std::vector<ForwardDetLayer*> CosmicLayerTriplets::fpos [private]

Definition at line 61 of file CosmicLayerTriplets.h.

bool CosmicLayerTriplets::isFirstCall [private]

Definition at line 65 of file CosmicLayerTriplets.h.

Referenced by init().

LayerWithHits* CosmicLayerTriplets::lh1 [private]

Definition at line 55 of file CosmicLayerTriplets.h.

Referenced by init(), and layers().

LayerWithHits* CosmicLayerTriplets::lh2 [private]

Definition at line 56 of file CosmicLayerTriplets.h.

Referenced by init(), and layers().

LayerWithHits* CosmicLayerTriplets::lh3 [private]

Definition at line 57 of file CosmicLayerTriplets.h.

Referenced by init(), and layers().

LayerWithHits* CosmicLayerTriplets::lh4 [private]

Definition at line 58 of file CosmicLayerTriplets.h.

Referenced by init(), and layers().

SiStripMatchedRecHit2DCollection::range CosmicLayerTriplets::match_range1 [private]

Definition at line 51 of file CosmicLayerTriplets.h.

SiStripMatchedRecHit2DCollection::range CosmicLayerTriplets::match_range2 [private]

Definition at line 52 of file CosmicLayerTriplets.h.

SiStripRecHit2DCollection::range CosmicLayerTriplets::rphi_range1 [private]

Definition at line 42 of file CosmicLayerTriplets.h.

Referenced by init().

SiStripRecHit2DCollection::range CosmicLayerTriplets::rphi_range2 [private]

Definition at line 43 of file CosmicLayerTriplets.h.

Referenced by init().

SiStripRecHit2DCollection::range CosmicLayerTriplets::rphi_range3 [private]

Definition at line 44 of file CosmicLayerTriplets.h.

Referenced by init().

SiStripRecHit2DCollection::range CosmicLayerTriplets::rphi_range4 [private]

Definition at line 45 of file CosmicLayerTriplets.h.

Referenced by init().

SiStripRecHit2DCollection::range CosmicLayerTriplets::stereo_range1 [private]

Definition at line 47 of file CosmicLayerTriplets.h.

SiStripRecHit2DCollection::range CosmicLayerTriplets::stereo_range2 [private]

Definition at line 48 of file CosmicLayerTriplets.h.

SiStripRecHit2DCollection::range CosmicLayerTriplets::stereo_range3 [private]

Definition at line 49 of file CosmicLayerTriplets.h.


The documentation for this class was generated from the following files:
Generated on Tue Jun 9 18:16:52 2009 for CMSSW by  doxygen 1.5.4