70 using namespace edm;
using namespace std;
using namespace reco;
80 auto outTks = std::make_unique<std::vector<reco::Track>>();
81 std::map<unsigned int, std::vector<unsigned int> > asso;
82 std::map<unsigned int, unsigned int> trackKeys;
84 for(
unsigned int i=0;
i<cands->size();
i++) {
88 for(
size_t ipv=0;ipv< pvs->size(); ++ipv) {
90 asso[ipv].push_back(j);
98 for(
unsigned int i = 0;
i < addTracks->size();
i++) {
99 outTks->push_back((*addTracks)[
i].pseudoTrack());
100 for(
size_t ipv=0;ipv< pvs->size(); ++ipv) {
102 asso[ipv].push_back(j);
109 auto outPv = std::make_unique<std::vector<reco::Vertex>>();
111 for(
size_t ipv=0;ipv< pvs->size(); ++ipv) {
113 for(
unsigned int i=0;
i<asso[ipv].size();
i++)
119 outPv->push_back(pv);
123 auto outSv = std::make_unique<std::vector<reco::Vertex>>();
124 for(
size_t i=0;
i< svs->size();
i++) {
136 outSv->back().add(
rr);
const edm::EDGetTokenT< reco::VertexCollection > PVs_
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
virtual double vertexChi2() const
chi-squares
CandidatePtr daughterPtr(size_type i) const
reference to daughter at given position
bool getByToken(EDGetToken token, Handle< PROD > &result) const
virtual const Point & vertex() const
vertex position (overwritten by PF...)
const edm::EDGetTokenT< std::vector< pat::PackedCandidate > > Cands_
virtual double vertexCovariance(int i, int j) const
(i, j)-th element of error matrix, i, j = 0, ... 2
virtual size_t numberOfDaughters() const
number of daughters
const PVAssoc fromPV(size_t ipv=0) const
virtual int charge() const
electric charge
virtual const reco::Track & pseudoTrack() const
Return reference to a pseudo track made with candidate kinematics, parameterized error for eta...
const edm::EDGetTokenT< std::vector< pat::PackedCandidate > > AdditionalTracks_
void add(const TrackBaseRef &r, float w=1.0)
add a reference to a Track
virtual double vertexNdof() const
const edm::EDGetTokenT< reco::VertexCompositePtrCandidateCollection > SVs_
edm::Ref< TrackCollection > TrackRef
persistent reference to a Track
ProductID id() const
Accessor for product ID.