Producer for DisplacedVertices. More...
#include <PFDisplacedVertexCandidateProducer.h>
Public Member Functions | |
virtual void | beginJob () |
virtual void | beginRun (edm::Run &r, const edm::EventSetup &c) |
PFDisplacedVertexCandidateProducer (const edm::ParameterSet &) | |
virtual void | produce (edm::Event &, const edm::EventSetup &) |
~PFDisplacedVertexCandidateProducer () | |
Private Attributes | |
edm::InputTag | inputTagTracks_ |
Reco Tracks used to spot the nuclear interactions. | |
PFDisplacedVertexCandidateFinder | pfDisplacedVertexCandidateFinder_ |
Displaced Vertex Candidates finder. | |
bool | verbose_ |
verbose ? |
Producer for DisplacedVertices.
This producer makes use of DisplacedVertexCandidateFinder. This Finder loop recursively over reco::Tracks to find those which are linked together by the criterion which is by default the minimal approach distance.
Definition at line 25 of file PFDisplacedVertexCandidateProducer.h.
PFDisplacedVertexCandidateProducer::PFDisplacedVertexCandidateProducer | ( | const edm::ParameterSet & | iConfig | ) | [explicit] |
Definition at line 22 of file PFDisplacedVertexCandidateProducer.cc.
References ExpressReco_HICollisions_FallBack::dcaCut, ExpressReco_HICollisions_FallBack::dcaPInnerHitCut, debug, edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameter(), and ExpressReco_HICollisions_FallBack::primaryVertexCut.
{ // --- Setup input collection names --- // inputTagTracks_ = iConfig.getParameter<InputTag>("trackCollection"); verbose_ = iConfig.getUntrackedParameter<bool>("verbose"); bool debug = iConfig.getUntrackedParameter<bool>("debug"); // ------ Algo Parameters ------ // // Distance of minimal approach below which // two tracks are considered as linked together double dcaCut = iConfig.getParameter< double >("dcaCut"); // Do not reconstruct vertices wich are // too close to the beam pipe double primaryVertexCut = iConfig.getParameter< double >("primaryVertexCut"); //maximum distance between the DCA Point and the inner hit of the track double dcaPInnerHitCut = iConfig.getParameter< double >("dcaPInnerHitCut"); edm::ParameterSet ps_trk = iConfig.getParameter<edm::ParameterSet>("tracksSelectorParameters"); // Collection to be produced produces<reco::PFDisplacedVertexCandidateCollection>(); // Vertex Finder parameters ----------------------------------- pfDisplacedVertexCandidateFinder_.setDebug(debug); pfDisplacedVertexCandidateFinder_.setParameters(dcaCut, primaryVertexCut, dcaPInnerHitCut, ps_trk); }
PFDisplacedVertexCandidateProducer::~PFDisplacedVertexCandidateProducer | ( | ) |
Definition at line 63 of file PFDisplacedVertexCandidateProducer.cc.
{ }
void PFDisplacedVertexCandidateProducer::beginJob | ( | void | ) | [virtual] |
Reimplemented from edm::EDProducer.
Definition at line 68 of file PFDisplacedVertexCandidateProducer.cc.
{ }
void PFDisplacedVertexCandidateProducer::beginRun | ( | edm::Run & | r, |
const edm::EventSetup & | c | ||
) | [virtual] |
Reimplemented from edm::EDProducer.
Definition at line 71 of file PFDisplacedVertexCandidateProducer.cc.
{ }
void PFDisplacedVertexCandidateProducer::produce | ( | edm::Event & | iEvent, |
const edm::EventSetup & | iSetup | ||
) | [virtual] |
Implements edm::EDProducer.
Definition at line 76 of file PFDisplacedVertexCandidateProducer.cc.
References gather_cfg::cout, edm::EventID::event(), edm::EventSetup::get(), edm::Event::getByLabel(), edm::EventBase::id(), LogDebug, edm::ESHandle< T >::product(), edm::Event::put(), edm::EventID::run(), and ExpressReco_HICollisions_FallBack::trackCollection.
{ LogDebug("PFDisplacedVertexCandidateProducer")<<"START event: "<<iEvent.id().event() <<" in run "<<iEvent.id().run()<<endl; // Prepare and fill useful event information for the Finder edm::ESHandle<MagneticField> magField; iSetup.get<IdealMagneticFieldRecord>().get(magField); const MagneticField* theMagField = magField.product(); Handle <reco::TrackCollection> trackCollection; iEvent.getByLabel(inputTagTracks_, trackCollection); pfDisplacedVertexCandidateFinder_.setInput( trackCollection, theMagField ); // Run the finder pfDisplacedVertexCandidateFinder_.findDisplacedVertexCandidates(); if(verbose_) { ostringstream str; str<<pfDisplacedVertexCandidateFinder_<<endl; cout << pfDisplacedVertexCandidateFinder_<<endl; LogInfo("PFDisplacedVertexCandidateProducer") << str.str()<<endl; } auto_ptr< reco::PFDisplacedVertexCandidateCollection > pOutputDisplacedVertexCandidateCollection( pfDisplacedVertexCandidateFinder_.transferVertexCandidates() ); iEvent.put(pOutputDisplacedVertexCandidateCollection); LogDebug("PFDisplacedVertexCandidateProducer")<<"STOP event: "<<iEvent.id().event() <<" in run "<<iEvent.id().run()<<endl; }
Reco Tracks used to spot the nuclear interactions.
Definition at line 41 of file PFDisplacedVertexCandidateProducer.h.
PFDisplacedVertexCandidateFinder PFDisplacedVertexCandidateProducer::pfDisplacedVertexCandidateFinder_ [private] |
Displaced Vertex Candidates finder.
Definition at line 47 of file PFDisplacedVertexCandidateProducer.h.
bool PFDisplacedVertexCandidateProducer::verbose_ [private] |
verbose ?
Definition at line 44 of file PFDisplacedVertexCandidateProducer.h.