79 mcSel_(iConfig.getParameter<
std::
string>(
"matchedSelector")),
81 produces<edm::Association<std::vector<reco::GenParticle> > >();
82 produces<edm::ValueMap<float> >(
"pulls");
98 typedef std::vector<reco::GenParticle> MCColl;
104 std::vector<uint8_t> candGood(
cands->size(), 1);
108 std::vector<float> pulls(
src->size(), 1e39);
109 for (
size_t i = 0,
n =
src->size();
i <
n; ++
i) {
110 const T& tk = (*src)[
i];
111 std::pair<int, float>
m = algo_.match(tk, *
cands, candGood);
118 MCAsso::Filler matchesFiller(*matchesMap);
120 matchesFiller.fill();
125 pullsFiller.
insert(
src, pulls.begin(), pulls.end());
edm::EDGetTokenT< edm::View< T > > srcToken_
The RECO objects.
#define DEFINE_FWK_MODULE(type)
void insert(const H &h, I begin, I end)
pat::MatcherByPulls< reco::RecoCandidate > MatcherByPulls
StringCutObjectSelector< reco::GenParticle > mcSel_
Preselection cut on MC objects.
edm::EDGetTokenT< std::vector< reco::GenParticle > > matchedToken_
The MC objects to match against.
~MatcherByPulls() override
pat::MatcherByPulls< reco::Track > TrackMatcherByPulls
MatcherByPulls(const edm::ParameterSet &)
void produce(edm::Event &, const edm::EventSetup &) override
MatcherByPullsAlgorithm algo_