34 desc.add<
double>(
"tRise", 0.2);
35 desc.add<
double>(
"tFall", 2.);
36 desc.add<std::vector<double>>(
"weights",
60 : tRise_(ps.getParameter<double>(
"tRise")),
61 tFall_(ps.getParameter<double>(
"tFall")),
62 weights_(ps.getParameter<
std::
vector<double>>(
"weights")),
64 ebUncalibRecHitCollectionToken_(
72 auto ebUncalibRechits = std::make_unique<EBUncalibratedRecHitCollection>();
74 for (
auto itdg = pdigis->
begin(); itdg != pdigis->
end(); ++itdg) {
81 std::vector<float> timetrace;
82 std::vector<float> adctrace;
95 adctrace.push_back(thisSample.
adc() * gratio);
99 if (thisSample.
gainId() == 1)
102 timetrace.push_back(
sample);
115 ebUncalibRechits->push_back(rhit);
void addWithDefaultLabel(ParameterSetDescription const &psetDescription)
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
bool get(ProductID const &oid, Handle< PROD > &result) const
#define DEFINE_FWK_MODULE(type)
int adc() const
get the ADC sample (12 bits)
void setJitterError(float jitterErr)
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
const edm::EDGetTokenT< EBDigiCollectionPh2 > ebDigiCollectionToken_
EcalUncalibRecHitPhase2WeightsProducer(const edm::ParameterSet &ps)
static constexpr const float * gains
void setAmplitudeError(float amplitudeerror)
const std::vector< double > weights_
const_iterator end() const
int gainId() const
get the gainId (2 bits)
const_iterator begin() const
The iterator returned can not safely be used across threads.
void setFlagBit(Flags flag)
const edm::EDPutTokenT< EBUncalibratedRecHitCollection > ebUncalibRecHitCollectionToken_
void produce(edm::Event &evt, const edm::EventSetup &es) override