Class to store relative quantum efficiency of channels w.r.t initial one measured in PMT QA QE is expected to decrease during the experiment due to aging induced by acuumulated charge.
More...
#include <TOPCalChannelRQE.h>
|
| TOPCalChannelRQE () |
| Default constructor.
|
|
void | setRQE (int moduleID, unsigned channel, double relQE) |
| Sets the relative QE for a single channel and switches status to calibrated.
|
|
void | setUnusable (int moduleID, unsigned channel) |
| Switches calibration status to unusable to flag badly calibrated constant.
|
|
double | getRQE (int moduleID, unsigned channel) const |
| Returns the relative QE for a single channel (1.0 if status is c_Default)
|
|
bool | isCalibrated (int moduleID, unsigned channel) const |
| Returns calibration status.
|
|
bool | isDefault (int moduleID, unsigned channel) const |
| Returns calibration status.
|
|
bool | isUnusable (int moduleID, unsigned channel) const |
| Returns calibration status.
|
|
Class to store relative quantum efficiency of channels w.r.t initial one measured in PMT QA QE is expected to decrease during the experiment due to aging induced by acuumulated charge.
Definition at line 24 of file TOPCalChannelRQE.h.
◆ anonymous enum
Sizes.
Enumerator |
---|
c_numModules | number of modules
|
c_numChannels | number of channels per module
|
Definition at line 149 of file TOPCalChannelRQE.h.
149 {
150 c_numModules = 16,
151 c_numChannels = 512
152 };
◆ EStatus
Calibration status of a constant.
Enumerator |
---|
c_Default | uncalibrated default value
|
c_Calibrated | good calibrated value
|
c_Unusable | bad calibrated value
|
Definition at line 30 of file TOPCalChannelRQE.h.
30 {
31 c_Default = 0,
32 c_Calibrated = 1,
33 c_Unusable = 2
34 };
◆ TOPCalChannelRQE()
◆ getRQE()
double getRQE |
( |
int | moduleID, |
|
|
unsigned | channel ) const |
|
inline |
Returns the relative QE for a single channel (1.0 if status is c_Default)
- Parameters
-
moduleID | module ID (1-based) |
channel | hardware channel number (0-based) |
- Returns
- relative quantum efficieny (absolute value, not in %)
Definition at line 87 of file TOPCalChannelRQE.h.
88 {
89 unsigned module = moduleID - 1;
90 if (module >= c_numModules) {
91 B2WARNING("Invalid module number, returning 0 (" << ClassName() << ")");
92 return 0;
93 }
94 if (channel >= c_numChannels) {
95 B2WARNING("Invalid channel number, returning 0 (" << ClassName() << ")");
96 return 0;
97 }
98 if (m_status[module][channel] == c_Default) return 1.0;
99 return m_relQE[module][channel];
100 }
◆ isCalibrated()
bool isCalibrated |
( |
int | moduleID, |
|
|
unsigned | channel ) const |
|
inline |
Returns calibration status.
- Parameters
-
moduleID | module ID (1-based) |
channel | hardware channel number (0-based) |
- Returns
- true, if good calibrated
Definition at line 108 of file TOPCalChannelRQE.h.
109 {
110 unsigned module = moduleID - 1;
111 if (module >= c_numModules) return false;
112 if (channel >= c_numChannels) return false;
113 return m_status[module][channel] == c_Calibrated;
114 }
◆ isDefault()
bool isDefault |
( |
int | moduleID, |
|
|
unsigned | channel ) const |
|
inline |
Returns calibration status.
- Parameters
-
moduleID | module ID (1-based) |
channel | hardware channel number (0-based) |
- Returns
- true, if default (not calibrated)
Definition at line 122 of file TOPCalChannelRQE.h.
123 {
124 unsigned module = moduleID - 1;
125 if (module >= c_numModules) return false;
126 if (channel >= c_numChannels) return false;
127 return m_status[module][channel] == c_Default;
128 }
◆ isUnusable()
bool isUnusable |
( |
int | moduleID, |
|
|
unsigned | channel ) const |
|
inline |
Returns calibration status.
- Parameters
-
moduleID | module ID (1-based) |
channel | hardware channel number (0-based) |
- Returns
- true, if bad calibrated
Definition at line 136 of file TOPCalChannelRQE.h.
137 {
138 unsigned module = moduleID - 1;
139 if (module >= c_numModules) return false;
140 if (channel >= c_numChannels) return false;
141 return m_status[module][channel] == c_Unusable;
142 }
◆ setRQE()
void setRQE |
( |
int | moduleID, |
|
|
unsigned | channel, |
|
|
double | relQE ) |
|
inline |
Sets the relative QE for a single channel and switches status to calibrated.
- Parameters
-
moduleID | module ID (1-based) |
channel | hardware channel number (0-based) |
relQE | relative quantum efficiency w.r.t initial one (absolute value, not in %) |
Definition at line 47 of file TOPCalChannelRQE.h.
48 {
49 unsigned module = moduleID - 1;
50 if (module >= c_numModules) {
51 B2ERROR("Invalid module number, constant not set (" << ClassName() << ")");
52 return;
53 }
54 if (channel >= c_numChannels) {
55 B2ERROR("Invalid channel number, constant not set (" << ClassName() << ")");
56 return;
57 }
58 m_relQE[module][channel] = relQE;
59 m_status[module][channel] = c_Calibrated;
60 }
◆ setUnusable()
void setUnusable |
( |
int | moduleID, |
|
|
unsigned | channel ) |
|
inline |
Switches calibration status to unusable to flag badly calibrated constant.
- Parameters
-
moduleID | module ID (1-based) |
channel | hardware channel number (0-based) |
Definition at line 67 of file TOPCalChannelRQE.h.
68 {
69 unsigned module = moduleID - 1;
70 if (module >= c_numModules) {
71 B2ERROR("Invalid module number, status not set (" << ClassName() << ")");
72 return;
73 }
74 if (channel >= c_numChannels) {
75 B2ERROR("Invalid channel number, status not set (" << ClassName() << ")");
76 return;
77 }
78 m_status[module][channel] = c_Unusable;
79 }
◆ m_relQE
◆ m_status
The documentation for this class was generated from the following file: