17 for (
auto const & it : conf.
getParameter<std::vector<std::string> >(
"inputClassifiers")) {
18 srcMVAs.push_back(consumes<MVACollection>(
edm::InputTag(it,
"MVAValues")));
19 srcQuals.push_back(consumes<QualityMaskCollection>(
edm::InputTag(it,
"QualityMasks")));
22 produces<MVACollection>(
"MVAValues");
23 produces<QualityMaskCollection>(
"QualityMasks");
29 desc.
add<std::vector<std::string> >(
"inputClassifiers",std::vector<std::string>());
30 descriptions.add(
"ClassifierMerger", desc);
35 using MVACollection = std::vector<float>;
36 using QualityMaskCollection = std::vector<unsigned char>;
43 auto size = (*hmva).size();
50 auto mvas = std::make_unique<MVACollection>(*hmva);
51 auto quals = std::make_unique<QualityMaskCollection>(*hqual);
53 for (
auto i=1
U;
i<srcQuals.size(); ++
i) {
55 auto const & iq = *hqual;
56 assert(iq.size()==
size);
57 for (
auto j=0
U; j!=
size; ++j) (*quals)[j] |= iq[j];
65 std::vector<edm::EDGetTokenT<MVACollection>> srcMVAs;
66 std::vector<edm::EDGetTokenT<QualityMaskCollection>> srcQuals;
T getParameter(std::string const &) const
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
bool getByToken(EDGetToken token, Handle< PROD > &result) const
#define DEFINE_FWK_MODULE(type)
virtual void produce(StreamID, Event &, EventSetup const &) const =0
ParameterDescriptionBase * add(U const &iLabel, T const &value)
static void fillDescriptions(ConfigurationDescriptions &descriptions)