51 iConfig.getParameter<
edm::
InputTag>(
"slimmedSecondaryVertices"))),
54 produces<reco::TrackCollection>();
55 produces<reco::VertexCollection>();
56 produces<reco::VertexCollection>(
"secondary");
74 auto outTks = std::make_unique<std::vector<reco::Track>>();
75 std::map<unsigned int, std::vector<unsigned int>> asso;
76 std::map<unsigned int, unsigned int> trackKeys;
78 for (
unsigned int i = 0;
i <
cands->size();
i++) {
80 if (
c.hasTrackDetails() &&
c.charge() != 0 &&
c.numberOfHits() > 0) {
81 outTks->push_back(
c.pseudoTrack());
82 for (
size_t ipv = 0; ipv <
pvs->size(); ++ipv) {
92 for (
unsigned int i = 0;
i < addTracks->size();
i++) {
93 if ((*addTracks)[
i].hasTrackDetails()) {
94 outTks->push_back((*addTracks)[
i].pseudoTrack());
95 for (
size_t ipv = 0; ipv <
pvs->size(); ++ipv) {
105 auto outPv = std::make_unique<std::vector<reco::Vertex>>();
107 for (
size_t ipv = 0; ipv <
pvs->size(); ++ipv) {
109 for (
unsigned int i = 0;
i < asso[ipv].size();
i++) {
114 outPv->push_back(
pv);
118 auto outSv = std::make_unique<std::vector<reco::Vertex>>();
119 for (
size_t i = 0;
i < svs->size();
i++) {
121 outSv->push_back(
reco::Vertex(
sv.vertex(),
sv.vertexCovariance(),
sv.vertexChi2(),
sv.vertexNdof(), 0));
122 for (
size_t j = 0;
j <
sv.numberOfDaughters();
j++) {
124 if (
sv.daughterPtr(
j).id() ==
cands.id()) {
132 outSv->back().add(
rr);
const edm::EDGetTokenT< reco::VertexCollection > PVs_
void produce(edm::StreamID, edm::Event &iEvent, const edm::EventSetup &iSetup) const override
#define DEFINE_FWK_MODULE(type)
const edm::EDGetTokenT< std::vector< pat::PackedCandidate > > Cands_
std::vector< pat::PackedCandidate > PackedCandidateCollection
std::vector< Vertex > VertexCollection
std::vector< VertexCompositePtrCandidate > VertexCompositePtrCandidateCollection
collection of Candidate objects
~PATTrackAndVertexUnpacker() override
const edm::EDGetTokenT< std::vector< pat::PackedCandidate > > AdditionalTracks_
const edm::EDGetTokenT< reco::VertexCompositePtrCandidateCollection > SVs_
edm::Ref< TrackCollection > TrackRef
persistent reference to a Track
deadvectors [0] push_back({0.0175431, 0.538005, 6.80997, 13.29})
std::vector< edm::InputTag > VInputTag
PATTrackAndVertexUnpacker(const edm::ParameterSet &iConfig)