75 std::unique_ptr<AbsHFPhase1Algo>
reco_;
79 std::unique_ptr<HcalHF_S9S1algorithm>
hfS9S1_;
80 std::unique_ptr<HcalHF_S9S1algorithm>
hfS8S1_;
81 std::unique_ptr<HcalHF_PETalgorithm>
hfPET_;
99 <<
"Invalid HFPhase1Reconstructor algorithm configuration" 106 hfS9S1_ = std::make_unique<HcalHF_S9S1algorithm>(
107 psS9S1.
getParameter<std::vector<double> >(
"short_optimumSlope"),
108 psS9S1.
getParameter<std::vector<double> >(
"shortEnergyParams"),
109 psS9S1.
getParameter<std::vector<double> >(
"shortETParams"),
110 psS9S1.
getParameter<std::vector<double> >(
"long_optimumSlope"),
111 psS9S1.
getParameter<std::vector<double> >(
"longEnergyParams"),
112 psS9S1.
getParameter<std::vector<double> >(
"longETParams"),
117 hfS8S1_ = std::make_unique<HcalHF_S9S1algorithm>(
118 psS8S1.getParameter<std::vector<double> >(
"short_optimumSlope"),
119 psS8S1.getParameter<std::vector<double> >(
"shortEnergyParams"),
120 psS8S1.getParameter<std::vector<double> >(
"shortETParams"),
121 psS8S1.getParameter<std::vector<double> >(
"long_optimumSlope"),
122 psS8S1.getParameter<std::vector<double> >(
"longEnergyParams"),
123 psS8S1.getParameter<std::vector<double> >(
"longETParams"),
124 psS8S1.getParameter<
int>(
"HcalAcceptSeverityLevel"),
125 psS8S1.getParameter<
bool>(
"isS8S1") );
128 hfPET_ = std::make_unique<HcalHF_PETalgorithm>(
129 psPET.getParameter<std::vector<double> >(
"short_R"),
130 psPET.getParameter<std::vector<double> >(
"shortEnergyParams"),
131 psPET.getParameter<std::vector<double> >(
"shortETParams"),
132 psPET.getParameter<std::vector<double> >(
"long_R"),
133 psPET.getParameter<std::vector<double> >(
"longEnergyParams"),
134 psPET.getParameter<std::vector<double> >(
"longETParams"),
135 psPET.getParameter<
int>(
"HcalAcceptSeverityLevel"),
136 psPET.getParameter<std::vector<double> >(
"short_R_29"),
137 psPET.getParameter<std::vector<double> >(
"long_R_29") );
152 produces<HFRecHitCollection>();
168 if (
reco_->isConfigurable())
173 <<
"Invalid HFPhase1Reconstructor \"algoConfigClass\" parameter value \"" 177 <<
"Failed to configure HFPhase1Reconstructor algorithm from EventSetup" 205 std::unique_ptr<HFRecHitCollection> rec(std::make_unique<HFRecHitCollection>());
206 rec->reserve(preRecHits->
size());
210 it != preRecHits->
end(); ++it)
215 const bool thisIsSingleAnodePMT =
false;
218 bool taggedBadByDb[2] = {
false,
false};
224 anodeIds[0] = it->id();
226 for (
unsigned i=0;
i<2; ++
i)
236 taggedBadByDb[0] =
b;
237 taggedBadByDb[1] =
b;
244 taggedBadByDb, thisIsSingleAnodePMT);
263 int depth=
i->id().depth();
264 int ieta=
i->id().ieta();
266 if (depth==2 ||
abs(ieta)==29 )
267 hfPET_->HFSetFlagFromPET(*
i, *rec, myqual, mySeverity);
273 int depth=
i->id().depth();
274 int ieta=
i->id().ieta();
276 if (depth==2 ||
abs(ieta)==29 )
277 hfS8S1_->HFSetFlagFromS9S1(*
i, *rec, myqual, mySeverity);
283 int depth=
i->id().depth();
284 int ieta=
i->id().ieta();
286 if (depth==1 &&
abs(ieta)!=29 )
287 hfS9S1_->HFSetFlagFromS9S1(*
i, *rec, myqual, mySeverity);
299 #define add_param_set(name) \ 300 edm::ParameterSetDescription name; \ 301 name.setAllowAnything(); \ 302 desc.add<edm::ParameterSetDescription>(#name, name) 312 desc.
add<
bool>(
"setNoiseFlags");
313 desc.
add<
bool>(
"runHFStripFilter",
false);
314 desc.
add<
bool>(
"useChannelQualityFromDB");
315 desc.
add<
bool>(
"checkChannelQualityForDepth3and4");
~HFPhase1Reconstructor() override
T getParameter(std::string const &) const
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
void beginRun(const edm::Run &, const edm::EventSetup &) override
std::string algoConfigClass_
bool getByToken(EDGetToken token, Handle< PROD > &result) const
static edm::ParameterSetDescription fillDescription()
constexpr uint32_t rawId() const
get the raw id
std::vector< T >::const_iterator const_iterator
const Item * getValues(DetId fId, bool throwOnFail=true) const
std::unique_ptr< AbsHcalAlgoData > fetchHcalAlgoData(const std::string &className, const edm::EventSetup &es)
std::unique_ptr< HcalHF_PETalgorithm > hfPET_
#define add_param_set(name)
void produce(edm::Event &, const edm::EventSetup &) override
std::unique_ptr< HFStripFilter > hfStripFilter_
#define DEFINE_FWK_MODULE(type)
void addDefault(ParameterSetDescription const &psetDescription)
std::unique_ptr< AbsHcalAlgoData > recoConfig_
std::unique_ptr< AbsHFPhase1Algo > reco_
std::unique_ptr< AbsHFPhase1Algo > parseHFPhase1AlgoDescription(const edm::ParameterSet &ps)
Abs< T >::type abs(const T &t)
bool dropChannel(const uint32_t &mystatus) const
static std::unique_ptr< HFStripFilter > parseParameterSet(const edm::ParameterSet &ps)
std::unique_ptr< HcalHF_S9S1algorithm > hfS8S1_
ParameterDescriptionBase * add(U const &iLabel, T const &value)
std::vector< T >::iterator iterator
const_iterator end() const
bool useChannelQualityFromDB_
bool checkChannelQualityForDepth3and4_
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
HFPhase1Reconstructor(const edm::ParameterSet &)
edm::ParameterSetDescription fillDescriptionForParseHFPhase1AlgoDescription()
uint32_t getValue() const
const HcalCalibrations & getHcalCalibrations(const HcalGenericDetId &fId) const
edm::EDGetTokenT< HFPreRecHitCollection > tok_PreRecHit_
std::unique_ptr< HcalHF_S9S1algorithm > hfS9S1_
T const * product() const
HcalDetId secondAnodeId() const
second PMT anode detId for HF dual channels
const_iterator begin() const