41 : srcZCand_{consumes<std::vector<reco::CompositeCandidate>>(
43 produces<std::vector<reco::CompositeCandidate>>();
54 auto bestZ = std::make_unique<std::vector<reco::CompositeCandidate>>();
55 if (!zCandidates->empty()) {
57 double constexpr ZmassPDG{91.18};
59 auto bestZCand = std::min_element(
60 std::cbegin(*zCandidates), std::cend(*zCandidates), [ZmassPDG](
auto const& firstCand,
auto const& secondCand) {
61 return std::abs(firstCand.mass() - ZmassPDG) <
std::abs(secondCand.mass() - ZmassPDG);
63 bestZ->push_back(*bestZCand);
T getParameter(std::string const &) const
void produce(edm::StreamID, edm::Event &, edm::EventSetup const &) const override
Abs< T >::type abs(const T &t)
ZllArbitrator(edm::ParameterSet const &)
#define DEFINE_FWK_MODULE(type)
edm::EDGetTokenT< std::vector< reco::CompositeCandidate > > srcZCand_