27 if (iConfig.
exists(
"checkClosestZVertex")) {
28 checkClosestZVertex_ = iConfig.
getParameter<
bool>(
"checkClosestZVertex");
30 checkClosestZVertex_ =
false;
34 pileUpAlgo_.setVerbose(verbose_);
35 pileUpAlgo_.setCheckClosestZVertex(checkClosestZVertex_);
38 produces<PFCollection>();
74 bool getFromView =
iEvent.getByToken(tokenPFCandidatesView_, pfView);
77 "PFPileUp is misconfigured. This needs to be either vector<FwdPtr<PFCandidate> >, or View<PFCandidate>");
80 viewEnd = pfView->end(),
84 usedIfNoFwdPtrs.push_back(
87 pfCandidatesRef = &usedIfNoFwdPtrs;
90 if (pfCandidatesRef ==
nullptr) {
92 "Something went dreadfully wrong with PFPileUp. pfCandidatesRef should never be zero, so this is a logic "
96 pileUpAlgo_.process(*pfCandidatesRef, *
vertices);
98 pOutput->end(), pileUpAlgo_.getPFCandidatesFromPU().begin(), pileUpAlgo_.getPFCandidatesFromPU().end());