77 std::vector<reco::Candidate>::const_iterator cand;
86 if (ptr.ptr().id() == cands.
id()) {
88 }
else if (ptr.backPtr().id() == cands.
id()) {
91 throw cms::Exception(
"Configuration",
"The elements from 'inputCollectionFromPVLoose' don't point to 'inputCollection'\n");
95 if (ptr.ptr().id() == cands.
id()) {
97 }
else if (ptr.backPtr().id() == cands.
id()) {
100 throw cms::Exception(
"Configuration",
"The elements from 'inputCollectionFromPVTight' don't point to 'inputCollection'\n");
113 PVpos = PV->position();
119 std::auto_ptr< std::vector<pat::PackedCandidate> > outPtrP(
new std::vector<pat::PackedCandidate> );
120 std::vector<int> mapping(cands->size());
121 std::vector<int> mappingTk(TKOrigs->size(), -1);
123 std::vector<int> jetOrder;
124 std::vector<int> jetOrderReverse;
125 for(
unsigned int i=0;
i<cands->size();
i++) jetOrderReverse.push_back(-1);
129 for(
unsigned int i=0;
i<dau.size();
i++)
132 jetOrder.push_back(dau[
i].
key());
133 jetOrderReverse[jetOrder.back()]=jetOrder.size()-1;
136 for(
unsigned int i=0;
i<dau.size();
i++)
139 jetOrder.push_back(dau[
i].
key());
140 jetOrderReverse[jetOrder.back()]=jetOrder.size()-1;
145 for(
unsigned int ic=0, nc = cands->size(); ic < nc; ++ic) {
148 jetOrder.push_back(ic);
149 jetOrderReverse[jetOrder.back()]=jetOrder.size()-1;
154 for(
unsigned int ic=0, nc = cands->size(); ic < nc; ++ic) {
155 if(jetOrderReverse[ic]==-1)
157 jetOrder.push_back(ic);
158 jetOrderReverse[jetOrder.back()]=jetOrder.size()-1;
165 for(
unsigned int ic=0, nc = cands->size(); ic < nc; ++ic) {
171 float phiAtVtx = cand.
phi();
182 phiAtVtx = ctrack->
phi();
194 outPtrP->back().setLostInnerHits( lostHits );
196 outPtrP->back().setTrackProperties(*ctrack);
203 outPtrP->back().setFromPV( fromPV[ic] );
207 outPtrP->back().setMuonID(cand.
muonRef()->isStandAloneMuon(), cand.
muonRef()->isGlobalMuon());
211 outPtrP->back().setFromPV( fromPV[ic] );
230 pf2pcFiller.insert(cands, jetOrderReverse.begin(), jetOrderReverse.end());
231 pc2pfFiller.insert(oh , jetOrder.begin(), jetOrder.end());
233 pf2pcFiller.insert(cands, mapping.begin(), mapping.end());
234 pc2pfFiller.insert(oh , mapping.begin(), mapping.end());
237 pf2pcFiller.insert(TKOrigs, mappingTk.begin(), mappingTk.end());
edm::EDGetTokenT< reco::PFCandidateFwdPtrVector > CandsFromPVLoose_
boost::indirect_iterator< typename seq_t::const_iterator > const_iterator
bool getByToken(EDGetToken token, Handle< PROD > &result) const
virtual int pdgId() const GCC11_FINAL
PDG identifier.
int numberOfLostHits() const
double phi() const
azimuthal angle of momentum vector
const Point & referencePoint() const
Reference point on the track.
edm::EDGetTokenT< reco::TrackCollection > TKOrigs_
reco::TrackRef trackRef() const
bool isNonnull() const
Checks for non-null.
virtual float phi() const GCC11_FINAL
momentum azimuthal angle
edm::EDGetTokenT< reco::PFCandidateCollection > Cands_
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
float trackWeight(const TrackBaseRef &r) const
returns the weight with which a Track has contributed to the vertex-fit.
Abs< T >::type abs(const T &t)
virtual const Point & vertex() const
vertex position (overwritten by PF...)
const HitPattern & trackerExpectedHitsInner() const
Access the hit pattern counting (in the Tracker) the number of expected crossed layers before the fir...
edm::EDGetTokenT< reco::VertexCollection > PVs_
edm::EDGetTokenT< reco::PFCandidateFwdPtrVector > CandsFromPVTight_
const HitPattern & hitPattern() const
Access the hit pattern, indicating in which Tracker layers the track has hits.
edm::Ref< VertexCollection > VertexRef
persistent reference to a Vertex
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
reco::MuonRef muonRef() const
LostInnerHits
Enumerator specifying the.
std::vector< CandidatePtr > daughters
collection of references to daughters
virtual const PolarLorentzVector & polarP4() const GCC11_FINAL
four-momentum Lorentz vector
XYZPointD XYZPoint
point in space with cartesian internal representation
key_type key() const
Accessor for product key.
Analysis-level calorimeter jet class.
Particle reconstructed by the particle flow algorithm.
reco::GsfTrackRef gsfTrackRef() const
const daughters & daughterPtrVector() const
references to daughtes
double minPtForTrackProperties_
ProductID id() const
Accessor for product ID.
bool hasValidHitInFirstPixelBarrel() const
edm::EDGetTokenT< reco::VertexCollection > PVOrigs_