50 : recoEcalCandidateProducer_(consumes(
config.getParameter<
edm::
InputTag>(
"recoEcalCandidateProducer"))),
55 multThresEB_(
config.getParameter<
double>(
"multThresEB")),
56 multThresEE_(
config.getParameter<
double>(
"multThresEE")) {
58 produces<reco::RecoEcalCandidateIsolationMap>();
59 produces<reco::RecoEcalCandidateIsolationMap>(
"sigmaIEtaIEta5x5");
60 produces<reco::RecoEcalCandidateIsolationMap>(
"sigmaIEtaIEta5x5NoiseCleaned");
61 produces<reco::RecoEcalCandidateIsolationMap>(
"sigmaIPhiIPhi");
62 produces<reco::RecoEcalCandidateIsolationMap>(
"sigmaIPhiIPhi5x5");
63 produces<reco::RecoEcalCandidateIsolationMap>(
"sigmaIPhiIPhi5x5NoiseCleaned");
64 produces<reco::RecoEcalCandidateIsolationMap>(
"sMajor");
65 produces<reco::RecoEcalCandidateIsolationMap>(
"sMinor");
66 produces<reco::RecoEcalCandidateIsolationMap>(
"e2x2");
78 descriptions.
add((
"hltEgammaHLTClusterShapeProducer"),
desc);
114 for (
unsigned int iRecoEcalCand = 0; iRecoEcalCand < recoecalcandHandle->size(); iRecoEcalCand++) {
116 if (recoecalcandref->superCluster()->seed()->seed().det() !=
DetId::Ecal) {
117 clshMap.
insert(recoecalcandref, 0);
118 clsh5x5Map.
insert(recoecalcandref, 0);
119 clsh5x5NoiseCleanedMap.
insert(recoecalcandref, 0);
121 clshMap2.
insert(recoecalcandref, 0);
122 clsh5x5Map2.
insert(recoecalcandref, 0);
123 clsh5x5NoiseCleanedMap2.
insert(recoecalcandref, 0);
125 clshSMajorMap.
insert(recoecalcandref, 0);
126 clshSMinorMap.
insert(recoecalcandref, 0);
128 e2x2Map.
insert(recoecalcandref, 0);
136 const auto& vCov = lazyTools.localCovariances(*(recoecalcandref->superCluster()->seed()));
137 sigmaee =
sqrt(vCov[0]);
138 sigmapp =
sqrt(vCov[2]);
141 auto const ecalCandLocalCov = lazyTools5x5.
localCovariances(*(recoecalcandref->superCluster()->seed()));
142 auto const sigmaee5x5 =
sqrt(ecalCandLocalCov[0]);
143 auto const sigmapp5x5 =
sqrt(ecalCandLocalCov[2]);
145 auto const ecalCandLocalCovNoiseCleaned = lazyTools5x5.
localCovariances(*(recoecalcandref->superCluster()->seed()),
150 auto const sigmaee5x5NoiseCleaned =
sqrt(ecalCandLocalCovNoiseCleaned[0]);
151 auto const sigmapp5x5NoiseCleaned =
sqrt(ecalCandLocalCovNoiseCleaned[2]);
153 clshMap.
insert(recoecalcandref, sigmaee);
154 clsh5x5Map.
insert(recoecalcandref, sigmaee5x5);
155 clsh5x5NoiseCleanedMap.
insert(recoecalcandref, sigmaee5x5NoiseCleaned);
157 clshMap2.
insert(recoecalcandref, sigmapp);
158 clsh5x5Map2.
insert(recoecalcandref, sigmapp5x5);
159 clsh5x5NoiseCleanedMap2.
insert(recoecalcandref, sigmapp5x5NoiseCleaned);
170 auto const e2x2 = lazyTools.e2x2(*(recoecalcandref->superCluster()->seed()));
171 e2x2Map.
insert(recoecalcandref, e2x2);
174 iEvent.put(std::make_unique<reco::RecoEcalCandidateIsolationMap>(clshMap));
175 iEvent.put(std::make_unique<reco::RecoEcalCandidateIsolationMap>(clsh5x5Map),
"sigmaIEtaIEta5x5");
176 iEvent.put(std::make_unique<reco::RecoEcalCandidateIsolationMap>(clsh5x5NoiseCleanedMap),
177 "sigmaIEtaIEta5x5NoiseCleaned");
179 iEvent.put(std::make_unique<reco::RecoEcalCandidateIsolationMap>(clshMap2),
"sigmaIPhiIPhi");
180 iEvent.put(std::make_unique<reco::RecoEcalCandidateIsolationMap>(clsh5x5Map2),
"sigmaIPhiIPhi5x5");
181 iEvent.put(std::make_unique<reco::RecoEcalCandidateIsolationMap>(clsh5x5NoiseCleanedMap2),
182 "sigmaIPhiIPhi5x5NoiseCleaned");
184 iEvent.put(std::make_unique<reco::RecoEcalCandidateIsolationMap>(clshSMajorMap),
"sMajor");
185 iEvent.put(std::make_unique<reco::RecoEcalCandidateIsolationMap>(clshSMinorMap),
"sMinor");
187 iEvent.put(std::make_unique<reco::RecoEcalCandidateIsolationMap>(e2x2Map),
"e2x2");
static constexpr float kMultThresEE
T const & getData(const ESGetToken< T, R > &iToken) const noexcept(false)
static constexpr float kRelEnCut
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
T const * product() const
const double multThresEE_
void produce(edm::StreamID sid, edm::Event &, const edm::EventSetup &) const override
EgammaHLTClusterShapeProducer(const edm::ParameterSet &)
const edm::ESGetToken< EcalPFRecHitThresholds, EcalPFRecHitThresholdsRcd > ecalPFRechitThresholdsToken_
const EcalClusterLazyTools::ESGetTokens ecalClusterLazyToolsESGetTokens_
ConsumesCollector consumesCollector()
Use a ConsumesCollector to gather consumes information from helper functions.
Abs< T >::type abs(const T &t)
#define DEFINE_FWK_MODULE(type)
static constexpr float kMultThresEB
const double multThresEB_
void insert(const key_type &k, const data_type &v)
insert an association
const edm::EDGetTokenT< EcalRecHitCollection > ecalRechitEEToken_
void add(std::string const &label, ParameterSetDescription const &psetDescription)
~EgammaHLTClusterShapeProducer() override
const edm::EDGetTokenT< EcalRecHitCollection > ecalRechitEBToken_
const edm::EDGetTokenT< reco::RecoEcalCandidateCollection > recoEcalCandidateProducer_