17 typedef std::pair<unsigned int, unsigned int>
IntPair;
30 typedef std::vector<edm::ParameterSet>
VPSet;
33 for(
auto const&
dm : decayModes) {
38 dm.getParameter<uint32_t>(
"nCharged"),
39 dm.getParameter<uint32_t>(
"nPiZeros")),
41 dm.getParameter<
double>(
"cut")
54 double disc_result = (*handle_)[
tau];
55 DecayModeCutMap::const_iterator cutIter =
56 decayModeCuts_.find(std::make_pair(tau->signalChargedHadrCands().size(),
57 tau->signalPiZeroCandidates().size()));
64 return disc_result > cutIter->second;
76 vpsd_decayModes.
add<uint32_t>(
"nCharged");
77 vpsd_decayModes.add<uint32_t>(
"nPiZeros");
78 vpsd_decayModes.add<
double>(
"cut");
81 desc.
addVPSet(
"decayModes", vpsd_decayModes);
85 descriptions.
add(
"recoTauDecayModeCutMultiplexer", desc);
edm::InputTag toMultiplex_
T getParameter(std::string const &) const
DecayModeCutMap decayModeCuts_
ParameterDescriptionBase * addVPSet(U const &iLabel, ParameterSetDescription const &validator, std::vector< ParameterSet > const &defaults)
edm::Handle< reco::PFTauDiscriminator > handle_
bool getByToken(EDGetToken token, Handle< PROD > &result) const
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
std::pair< unsigned int, unsigned int > IntPair
#define DEFINE_FWK_MODULE(type)
static void fillProducerDescriptions(edm::ParameterSetDescription &desc)
edm::EDGetTokenT< reco::PFTauDiscriminator > toMultiplex_token
void beginEvent(const edm::Event &event, const edm::EventSetup &eventSetup) override
~RecoTauDecayModeCutMultiplexer() override
RecoTauDecayModeCutMultiplexer(const edm::ParameterSet &pset)
ParameterDescriptionBase * add(U const &iLabel, T const &value)
std::map< IntPair, double > DecayModeCutMap
void add(std::string const &label, ParameterSetDescription const &psetDescription)
double discriminate(const reco::PFTauRef &) const override
double prediscriminantFailValue_