#include <L3MumuTrackingRegion.h>
Public Member Functions | |
L3MumuTrackingRegion (const edm::ParameterSet &cfg) | |
virtual std::vector < TrackingRegion * > | regions (const edm::Event &ev, const edm::EventSetup &es) const |
virtual | ~L3MumuTrackingRegion () |
Private Attributes | |
double | theDeltaEta |
double | theDeltaPhi |
edm::InputTag | theInputTrkSrc |
double | theOriginHalfLength |
double | theOriginRadius |
double | theOriginZPos |
double | thePtMin |
std::string | theVertexSrc |
bool | theVertexZconstrained |
Definition at line 15 of file L3MumuTrackingRegion.h.
L3MumuTrackingRegion::L3MumuTrackingRegion | ( | const edm::ParameterSet & | cfg | ) | [inline] |
Definition at line 19 of file L3MumuTrackingRegion.h.
References edm::ParameterSet::getParameter(), theDeltaEta, theDeltaPhi, theInputTrkSrc, theOriginHalfLength, theOriginRadius, theOriginZPos, thePtMin, and theVertexSrc.
{ edm::ParameterSet regionPSet = cfg.getParameter<edm::ParameterSet>("RegionPSet"); theVertexSrc = regionPSet.getParameter<std::string>("vertexSrc"); theInputTrkSrc = regionPSet.getParameter<edm::InputTag>("TrkSrc"); thePtMin = regionPSet.getParameter<double>("ptMin"); theOriginRadius = regionPSet.getParameter<double>("originRadius"); theOriginHalfLength = regionPSet.getParameter<double>("originHalfLength"); theOriginZPos = regionPSet.getParameter<double>("vertexZDefault"); theDeltaEta = regionPSet.getParameter<double>("deltaEtaRegion"); theDeltaPhi = regionPSet.getParameter<double>("deltaPhiRegion"); }
virtual L3MumuTrackingRegion::~L3MumuTrackingRegion | ( | ) | [inline, virtual] |
Definition at line 35 of file L3MumuTrackingRegion.h.
{}
virtual std::vector<TrackingRegion* > L3MumuTrackingRegion::regions | ( | const edm::Event & | ev, |
const edm::EventSetup & | es | ||
) | const [inline, virtual] |
Implements TrackingRegionProducer.
Definition at line 37 of file L3MumuTrackingRegion.h.
References edm::Event::getByLabel(), edm::Handle< T >::product(), query::result, theDeltaEta, theDeltaPhi, theInputTrkSrc, theOriginHalfLength, theOriginRadius, theOriginZPos, thePtMin, and theVertexSrc.
{ std::vector<TrackingRegion* > result; // optional constraint for vertex // get highest Pt pixel vertex (if existing) double deltaZVertex = theOriginHalfLength; double originz = theOriginZPos; if (theVertexSrc.length()>1) { edm::Handle<reco::VertexCollection> vertices; ev.getByLabel(theVertexSrc,vertices); const reco::VertexCollection vertCollection = *(vertices.product()); reco::VertexCollection::const_iterator ci = vertCollection.begin(); if (vertCollection.size()>0) { originz = ci->z(); } else { originz = theOriginZPos; deltaZVertex = 15.; } } edm::Handle<reco::TrackCollection> trks; ev.getByLabel(theInputTrkSrc, trks); for(reco::TrackCollection::const_iterator iTrk = trks->begin();iTrk != trks->end();iTrk++) { GlobalVector dirVector((iTrk)->px(),(iTrk)->py(),(iTrk)->pz()); result.push_back( new RectangularEtaPhiTrackingRegion( dirVector, GlobalPoint(0,0,float(originz)), thePtMin, theOriginRadius, deltaZVertex, theDeltaEta, theDeltaPhi) ); } return result; }
double L3MumuTrackingRegion::theDeltaEta [private] |
Definition at line 82 of file L3MumuTrackingRegion.h.
Referenced by L3MumuTrackingRegion(), and regions().
double L3MumuTrackingRegion::theDeltaPhi [private] |
Definition at line 83 of file L3MumuTrackingRegion.h.
Referenced by L3MumuTrackingRegion(), and regions().
Definition at line 74 of file L3MumuTrackingRegion.h.
Referenced by L3MumuTrackingRegion(), and regions().
double L3MumuTrackingRegion::theOriginHalfLength [private] |
Definition at line 78 of file L3MumuTrackingRegion.h.
Referenced by L3MumuTrackingRegion(), and regions().
double L3MumuTrackingRegion::theOriginRadius [private] |
Definition at line 77 of file L3MumuTrackingRegion.h.
Referenced by L3MumuTrackingRegion(), and regions().
double L3MumuTrackingRegion::theOriginZPos [private] |
Definition at line 80 of file L3MumuTrackingRegion.h.
Referenced by L3MumuTrackingRegion(), and regions().
double L3MumuTrackingRegion::thePtMin [private] |
Definition at line 76 of file L3MumuTrackingRegion.h.
Referenced by L3MumuTrackingRegion(), and regions().
std::string L3MumuTrackingRegion::theVertexSrc [private] |
Definition at line 73 of file L3MumuTrackingRegion.h.
Referenced by L3MumuTrackingRegion(), and regions().
bool L3MumuTrackingRegion::theVertexZconstrained [private] |
Definition at line 79 of file L3MumuTrackingRegion.h.