37 auto GetAddressName = [&](int32_t address) -> std::string {
41 return format(
"u{}_l{}_m{}", u, l, m);
44 auto GetAddressTitle = [&](int32_t address) -> std::string {
48 return format(
"U{} L{} M{}", u, l, m);
61 for (
int iM = 0; iM < nModules; ++iM) {
64 auto aName = GetAddressName(address);
65 auto aTitl = GetAddressTitle(address);
66 auto cName = format(
"sts_digi/sts_digi_vs_channel_charge_{}", aName);
67 auto cTitl = format(
"STS digis per channel and charge for module {}", aTitl);
71 auto name = format(
"sts_digi_{}_channel", aName);
72 auto titl = format(
"Number of digis per channel for module {};channel;N_{{digis}}", aTitl);
78 canv.AddPadConfig(pad);
82 auto name = format(
"sts_digi_{}_charge", aName);
83 auto titl = format(
"STS digi charge for mudule {};charge [ADS units];N_{{digis}}", aTitl);
86 canv.AddPadConfig(pad);
90 auto name = format(
"sts_digi_{}_channel_charge", aName);
91 auto titl = format(
"STS digi charge for module {};charge [ADS units];channel", aTitl);
94 canv.AddPadConfig(pad);
99 auto name = format(
"sts_digi_{}_channel_elink", aName);
100 auto titl = format(
"STS digi charge for module {};E-link;channel", aTitl);
103 canv.AddPadConfig(pad);
107 auto name = format(
"sts_digi_{}_channel_missed_evt", aName);
109 format(
"STS digi missed event ratio for module {};channel; N_{{w/ missed events}} / N_{{tot.}}", aTitl);
112 canv.AddPadConfig(pad);
116 auto name = format(
"sts_digi_{}_time_missed_evt", aName);
118 format(
"STS digi missed event ratio for module {};time [ms]; N_{{w/ missed events}} / N_{{tot.}}", aTitl);
119 constexpr double timeMin = 0.;
120 constexpr double timeMax = 150.;
121 int timeBins = std::ceil(timeMax - timeMin);
126 canv.AddPadConfig(pad);
146 for (
const auto& digi : (*
fpvDigis)) {
147 int32_t address = digi.GetAddress();
148 double channel = digi.GetChannel();
149 double charge = digi.GetCharge();
154 L_(error) << format(
"sts::DigiQa: found address {:x}, which is not defined in the ReadoutSetup config", address);
158 int iM = itHistID->second;
167 for (
const auto& auxDigi : ms.fQaDigis) {
168 int32_t address = auxDigi.address;
171 L_(error) << format(
"sts::DigiQa: found address {:x}, which is not defined in the ReadoutSetup config",
175 int iM = itHistID->second;
178 static_cast<double>(auxDigi.missedEvent));