63 produces<edm::ValueMap<float> >();
89 for (probe = probes->begin(); probe != endprobes; ++probe) {
90 double dr2min = 10000;
91 for (
unsigned int iObj=0; iObj<objects->size(); iObj++) {
92 const T&
obj = objects->at(iObj);
94 double dr2 =
deltaR2(*probe, obj);
95 if (dr2 < dr2min) { dr2min = dr2; }
97 values.push_back(
sqrt(dr2min));
101 auto valMap = std::make_unique<ValueMap<float>>();
103 filler.insert(probes, values.begin(), values.end());
DeltaRNearestObjectComputer< reco::GsfElectron > DeltaRNearestGsfElectronComputer
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
StringCutObjectSelector< T, true > objCut_
bool getByToken(EDGetToken token, Handle< PROD > &result) const
DeltaRNearestObjectComputer< reco::Muon > DeltaRNearestMuonComputer
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
edm::EDGetTokenT< edm::View< T > > objectsToken_
#define DEFINE_FWK_MODULE(type)
DeltaRNearestObjectComputer< reco::Candidate > DeltaRNearestCandidateComputer
constexpr auto deltaR2(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
DeltaRNearestObjectComputer< reco::Electron > DeltaRNearestElectronComputer
~DeltaRNearestObjectComputer() override
boost::indirect_iterator< typename seq_t::const_iterator > const_iterator
DeltaRNearestObjectComputer< reco::Jet > DeltaRNearestJetComputer
DeltaRNearestObjectComputer(const edm::ParameterSet &iConfig)
void produce(edm::Event &iEvent, const edm::EventSetup &iSetup) override
edm::EDGetTokenT< edm::View< reco::Candidate > > probesToken_
DeltaRNearestObjectComputer< reco::Photon > DeltaRNearestPhotonComputer