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;
86 timetrace.reserve(nSamples);
87 adctrace.reserve(nSamples);
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.
#define DEFINE_FWK_MODULE(type)
const_iterator begin() const
The iterator returned can not safely be used across threads.
void setJitterError(float jitterErr)
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
const edm::EDGetTokenT< EBDigiCollectionPh2 > ebDigiCollectionToken_
static constexpr float gains[NGAINS]
EcalUncalibRecHitPhase2WeightsProducer(const edm::ParameterSet &ps)
bool get(ProductID const &oid, Handle< PROD > &result) const
void setAmplitudeError(float amplitudeerror)
ParameterDescriptionBase * add(U const &iLabel, T const &value)
constexpr size_t nSamples
const std::vector< double > weights_
int adc() const
get the ADC sample (12 bits)
const_iterator end() const
void setFlagBit(Flags flag)
const edm::EDPutTokenT< EBUncalibratedRecHitCollection > ebUncalibRecHitCollectionToken_
void produce(edm::Event &evt, const edm::EventSetup &es) override
int gainId() const
get the gainId (2 bits)