4 : linLSB_si_(conf.getParameter<double>(
"linLSB_si")),
5 adcsaturation_si_(conf.getParameter<double>(
"adcsaturation_si")),
6 tdcnBits_si_(conf.getParameter<uint32_t>(
"tdcnBits_si")),
7 tdcOnset_si_(conf.getParameter<double>(
"tdcOnset_si")),
8 adcnBits_si_(conf.getParameter<uint32_t>(
"adcnBits_si")),
9 tdcsaturation_si_(conf.getParameter<double>(
"tdcsaturation_si")),
10 linLSB_sc_(conf.getParameter<double>(
"linLSB_sc")),
11 adcsaturation_sc_(conf.getParameter<double>(
"adcsaturation_sc")),
12 tdcnBits_sc_(conf.getParameter<uint32_t>(
"tdcnBits_sc")),
13 tdcOnset_sc_(conf.getParameter<double>(
"tdcOnset_sc")),
14 adcnBits_sc_(conf.getParameter<uint32_t>(
"adcnBits_sc")),
15 tdcsaturation_sc_(conf.getParameter<double>(
"tdcsaturation_sc")),
16 linnBits_(conf.getParameter<uint32_t>(
"linnBits")) {
25 std::vector<std::pair<DetId, uint32_t>>& linearized_dataframes) {
27 uint32_t amplitude_int = 0;
28 const int kIntimeSample = 2;
30 for (
const auto&
frame : dataframes) {
31 unsigned det =
frame.id().det();
48 amplitude = (floor(tdcOnset / adcLSB) + 1.0) * adcLSB + double(
frame[kIntimeSample].
data()) * tdcLSB;
50 amplitude = double(
frame[kIntimeSample].
data()) * adcLSB;
53 amplitude_int = uint32_t(floor(amplitude / linLSB + 0.5));
57 linearized_dataframes.push_back(std::make_pair(
frame.id(), amplitude_int));
HGCalVFELinearizationImpl(const edm::ParameterSet &conf)
void linearize(const std::vector< HGCDataFrame< DetId, HGCSample >> &, std::vector< std::pair< DetId, uint32_t >> &)
char data[epos_bytes_allocation]
Power< A, B >::type pow(const A &a, const B &b)