1 #ifndef RecoEgamma_ElectronIdentification_ElectronIDExternalProducer_h 2 #define RecoEgamma_ElectronIdentification_ElectronIDExternalProducer_h 24 produces<edm::ValueMap<float> >();
37 template<
typename algo>
44 select_.newEvent(iEvent, iSetup);
47 std::vector<float>
values; values.reserve(electrons->size());
48 for ( reco::GsfElectronCollection::const_iterator eleIt = electrons->begin () ;
49 eleIt != electrons->end () ;
51 values.push_back(
float(
select_((*eleIt),iEvent,iSetup) ) );
55 auto out = std::make_unique<edm::ValueMap<float>>();
57 filler.insert(electrons, values.begin(), values.end());
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
bool getByToken(EDGetToken token, Handle< PROD > &result) const
edm::EDGetTokenT< reco::GsfElectronCollection > srcToken_
std::vector< GsfElectron > GsfElectronCollection
collection of GsfElectron objects
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
ConsumesCollector consumesCollector()
Use a ConsumesCollector to gather consumes information from helper functions.
ElectronIDExternalProducer(const edm::ParameterSet &iConfig)
void produce(edm::Event &iEvent, const edm::EventSetup &iSetup) override
~ElectronIDExternalProducer() override