Public Member Functions | Private Attributes | List of all members
calib::PhotonCalibratorProtoDUNESP Class Reference

#include <PhotonCalibratorProtoDUNESP.h>

Inheritance diagram for calib::PhotonCalibratorProtoDUNESP:
calib::IPhotonCalibrator

Public Member Functions

 PhotonCalibratorProtoDUNESP (fhicl::ParameterSet const &pset, art::ActivityRegistry &reg)
 
double PE (double adcs, int opchannel) const override
 
bool UseArea () const override
 
- Public Member Functions inherited from calib::IPhotonCalibrator
 IPhotonCalibrator (IPhotonCalibrator const &)=delete
 
 IPhotonCalibrator (IPhotonCalibrator &&)=delete
 
IPhotonCalibratoroperator= (IPhotonCalibrator const &)=delete
 
IPhotonCalibratoroperator= (IPhotonCalibrator &&)=delete
 
 IPhotonCalibrator ()
 
virtual ~IPhotonCalibrator ()=default
 
double PE (const recob::OpHit &oh) const
 Convenience. More...
 
double PE (const recob::OpFlash &of) const
 

Private Attributes

std::vector< float > fSPESizes
 
std::vector< float > fSPEShifts
 
std::vector< int > fBadChannels
 

Detailed Description

Definition at line 25 of file PhotonCalibratorProtoDUNESP.h.

Constructor & Destructor Documentation

calib::PhotonCalibratorProtoDUNESP::PhotonCalibratorProtoDUNESP ( fhicl::ParameterSet const &  pset,
art::ActivityRegistry reg 
)

Definition at line 21 of file PhotonCalibratorProtoDUNESP.cc.

22  {
23  // Get the geometry service for getting max number of channels
24  //auto const& geometry(*lar::providerFrom< geo::Geometry >());
25 
26  // Initialize the SPE vectors with default values
27  //for (unsigned int channel = 0; channel < geometry.MaxOpChannel(); channel++) {
28  // fSPESizes.push_back(1.);
29  // fSPEShifts.push_back(0.);
30  //}
31 
32 
33  fBadChannels = pset.get<std::vector<int> >("BadChannels");
34 
35 
36  fSPESizes={
37 
38  //SSP101
39  1411., 1416., 1405., 1436., //Channels 0-3, SensL-A, DS
40  1437., 1442., 1432., 1436., //Channels 4-6, SensL-A, DC
41  1409., 1421., 1423., 1445., //Channels 8-11, SensL-A, DS
42 
43  //SSP102
44  1427., 1400., 1419., 1421., //Channels 12-15, SensL-A, DC
45  1410., 1402., 1451., 1637., //Channels 16-19, SensL-A, DS
46  1418., 1419., 1412., 1406., //Channels 20-23, SensL-A, DC
47 
48  //SSP103
49  1421., 1., 1407., 1387., //Channels 24-27, SensL-A, DS
50  1439., 1434., 1423., 1463., //Channels 28-31, SensL-A, DC
51  1434., 1604., 1407., 1416., //Channels 32-35, SensL-A, DS
52 
53  //SSP104
54  1., 1400., 1392., 1423., //Channels 36-39, SensL-A, DC
55  1., 1., 1., 1., //Channels 40-43 --EMPTY
56  1., 1., 1., 1., //Channels 44-47 --EMPTY
57 
58  //SSP201
59  1410., 1824., 1386., 1841., //Channels 48-51, SensL-A, DS
60  1411., 1439., 1408., 1435., //Channels 52-55, SensL-A, DC
61  1389., 1392., 1., 1368., //Channels 56-59, SensL-A, DS
62 
63  //SSP202
64  1427., 1409., 1., 1459., //Channels 60-63, SensL-A, DC
65  1430., 1., 1401., 1456., //Channels 64-67, SensL-A, DS
66  1419., 1431., 1405., 1437., //Channels 68-71, SensL-A, DC
67 
68  //SSP203
69  1433., 1., 1421., 1., //Channels 72-75, SensL-A, DS
70  1435., 1643., 1425., 1428., //Channels 76-79, SensL-A, DC
71  1378., 1372., 1., 1364., //Channels 80-83, SensL-A, DS
72 
73  //SSP204
74  1417., 1430., 1434., 1432., //Channels 84-87, SensL-A, DC
75  1., 1., 1., 1., //Channels 88-91 --EMPTY
76  1., 1., 1., 1., //Channels 92-95 --EMPTY
77 
78  //SSP301
79  1396., 1432., 1392., 1394., //Channels 96-99, SensL-A, DS
80  1392., 1., 1414., 1413., //Channels 100-103, SensL-A, DC
81  1624., 1399., 1624., 1621., //Channels 104-107, SensL-A, DS
82 
83  //SSP302
84  1387., 1418., 1., 1398., //Channels 108-111, SensL-A, DC
85  1425., 1446., 1421., 1436., //Channels 112-115, SensL-A, DS
86  1446., 1470., 1436., 1., //Channels 116-119, SensL-A, DC
87 
88  //SSP303
89  1643., 1416., 1438., 1414., //Channels 120-123, SensL-A, DC
90  1577., 1848., 1634., 1603., //Channels 124-127, SensL-A, DS
91  1413., 1406., 1418., 1405., //Channels 128-131, SensL-C, DC
92 
93  //SSP304
94  //ARAPUCA
95  782., 750., 780., 783., //Channels 132-135, MPPC, ARAPUCA
96  812., 665., 737., 631., //Channels 136-139, MPPC, ARAPUCA
97  673., 628., 721., 744., //Channels 140-143, MPPC, ARAPUCA
98 
99  //SSP401
100  1398., 1395., 1416., 1397., //Channels 144-147, SensL-C, DC
101  1404., 1432., 1428., 1418., //Channels 148-151, SensL-C, DS
102  1403., 1434., 1417., 1418., //Channels 152-155, SensL-A, DC
103 
104  //SSP402
105  1., 1419., 1443., 1410., //Channels 156-159, SensL-C, DS
106  1., 1430., 1433., 1419., //Channels 160-163, SensL-C, DC
107  1419., 1431., 1405., 1437., //Channels 164-167, SensL-C, DS
108 
109  //SSP403
110  1417., 1445., 1437., 1418., //Channels 168-171, SensL-C, DC
111  1662., 1450., 1424., 1629., //Channels 172-175, SensL-C, DS
112  1815., 1424., 1402., 1428., //Channels 176-179, SensL-C, DS
113 
114  //SSP404
115  1626., 1442., 1413., 1417., //Channels 180-183, SensL-C, DC
116  1., 1., 1., 1., //Channels 184-187 --EMPTY
117  1., 1., 1., 1., //Channels 188-191 --EMPTY
118 
119  //SSP501
120  1433., 1426., 1418., 1418., //Channels 192-195, SensL-C, DC
121  1436., 1427., 1419., 1430., //Channels 196-199, SensL-C, DC
122  1440., 1634., 1436., 1431., //Channels 200-203, SensL-C, DS
123 
124  //SSP502
125  1439., 1469., 1455., 1429., //Channels 204-207, SensL-C DS
126  1., 1., 1., 1., //Channels 208-211, EMPTY
127  1., 1., 1., 1., //Channels 212-215, EMPTY
128 
129 
130  //SSP503
131  908., 950., 891., 876., //Channels 216-219, MPPC, DC
132  890., 871., 876., 908., //Channels 220-223, MPPC, DS
133  1107., 1098., 1131., 946., //Channels 224-227, MPPC, DC
134 
135  //SSP504
136  986., 1267., 1017., 1046., //Channels 228-231, MPPC, DS
137  1012., 1014., 997., 1020., //Channels 232-235, MPPC, DS
138  1029., 996., 992., 1019., //Channels 236-239, MPPC, DC
139 
140 
141  //SSP601
142  945., 977., 990., 924., //Channels 240-243, MPPC, DC
143  963., 983., 980., 974., //Channels 244-247, MPPC, DS
144  1013., 1038., 1023., 1083., //Channels 248-251, MPPC, DC
145 
146  //SSP602
147  1017., 1023., 987., 973., //Channels 252-255, MPPC, DS
148  960., 993., 1021., 992., //Channels 256-259, MPPC, DC
149  1038., 1010., 1015., 1068., //Channels 260-263, MPPC, DC
150 
151  //SSP603
152  //ARAPUCA
153  758., 780., 772., 628., //Channels 264-267, MPPC, ARAPUCA
154  804., 637., 668., 738., //Channels 268-271, MPPC, ARAPUCA
155  638., 755., 709., 831., //Channels 272-275, MPPC, ARAPUCA
156 
157 
158  //SSP604
159  1003., 987., 1009., 1022., //Channels 276-279, MPPC, DS
160  1008., 1032., 981., 1045., //Channels 280-283, MPPC, DC
161  987., 992., 1009., 989. //Channels 284-287, MPPC, DS
162  };
163 
164  fSPEShifts = {
165 
166  //SSP101
167  0.01, 0.00, 0.01, 0.00, //Channels 0-3, SensL-A, DS
168  0.00, -0.02, -0.01, -0.01, //Channels 4-6, SensL-A, DC
169  -0.02, 0.00, 0.01, 0.00, //Channels 8-11, SensL-A, DS
170 
171  //SSP102
172  -0.02, -0.02, -0.02, -0.02, //Channels 12-15, SensL-A, DC
173  -0.02, 0.00, -0.03, -0.01, //Channels 16-19, SensL-A, DS
174  -0.04, -0.00, -0.01, -0.01, //Channels 20-23, SensL-A, DC
175 
176  //SSP103
177  -0.02, 0., -0.03, -0.01, //Channels 24-27, SensL-A, DS
178  0.00, -0.03, -0.02, -0.01, //Channels 28-31, SensL-A, DC
179  -0.01, 0.01, -0.02, -0.04, //Channels 32-35, SensL-A, DS
180 
181  //SSP104
182  0., -0.04, -0.01, -0.03, //Channels 36-39, SensL-A, DC
183  0., 0., 0., 0., //Channels 40-43 --EMPTY
184  0., 0., 0., 0., //Channels 44-47 --EMPTY
185 
186  //SSP201
187  -0.01, 0.00, 0.01, 0.01, //Channels 48-51, SensL-A, DS
188  0.00, -0.02, 0.01, -0.01, //Channels 52-55, SensL-A, DC
189  -0.03, 0.00, 0., 0.00, //Channels 56-59, SensL-A, DS
190 
191  //SSP202
192  -0.02, -0.01, 0., -0.03, //Channels 60-63, SensL-A, DC
193  -0.02, 0., 0.00, -0.03, //Channels 64-67, SensL-A, DS
194  0.02, -0.02, -0.03, -0.01, //Channels 68-71, SensL-A, DC
195 
196  //SSP203
197  -0.03, 0., -0.03, 0., //Channels 72-75, SensL-A, DS
198  -0.01, -0.01, -0.01, -0.01, //Channels 76-79, SensL-A, DC
199  0.03, 0.01, 0., 0.01, //Channels 80-83, SensL-A, DS
200 
201  //SSP204
202  -0.01, -0.02, -0.03, -0.03, //Channels 84-87, SensL-A, DC
203  0., 0., 0., 0., //Channels 88-91 --EMPTY
204  0., 0., 0., 0., //Channels 92-95 --EMPTY
205 
206  //SSP301
207  -0.04, -0.03, 0.00, -0.01, //Channels 96-99, SensL-A, DS
208  -0.00, 0., 0.00, -0.01, //Channels 100-103, SensL-A, DC
209  0.01, 0.00, 0.00, 0.01, //Channels 104-107, SensL-A, DS
210 
211  //SSP302
212  0.00, 0.00, 0., -0.02, //Channels 108-111, SensL-A, DC
213  -0.02, -0.04, -0.02, -0.01, //Channels 112-115, SensL-A, DS
214  -0.05, -0.07, -0.03, 0., //Channels 116-119, SensL-A, DC
215 
216 
217  //SSP303
218  -0.01, -0.03, -0.01, 0.00, //Channels 120-123, SensL-A, DC
219  0.02, 0.01, 0.00, 0.01, //Channels 124-127, SensL-A, DS
220  -0.01, -0.01, -0.02, 0.02, //Channels 128-131, SensL-C, DC
221 
222  //SSP304
223  //ARAPUCA
224  -0.05, -0.05, -0.05, -0.03, //Channels 132-135, MPPC, ARAPUCA
225  -0.07, -0.06, -0.09, -0.02, //Channels 136-139, MPPC, ARAPUCA
226  -0.08, 0.00, 0., 0., //Channels 140-143, MPPC, ARAPUCA
227 
228  //SSP401
229  0.01, 0.00, 0.01, 0.00, //Channels 144-147, SensL-C, DC
230  -0.02, -0.02, -0.01, -0.04, //Channels 148-151, SensL-C, DS
231  -0.01, -0.01, -0.01, -0.03, //Channels 152-155, SensL-A, DC
232 
233  //SSP402
234  0., 0.00, -0.02, -0.00, //Channels 156-159, SensL-C, DS
235  0., -0.04, -0.02, -0.02, //Channels 160-163, SensL-C, DC
236  0.02, -0.02, -0.03, -0.01, //Channels 164-167, SensL-C, DS
237 
238  //SSP403
239  -0.02, -0.02, -0.03, -0.01, //Channels 168-171, SensL-C, DC
240  -0.01, -0.03, -0.02, 0.02, //Channels 172-175, SensL-C, DS
241  0.00, -0.01, -0.02, -0.01, //Channels 176-179, SensL-C, DS
242 
243  //SSP404
244  0.00, -0.01, -0.03, 0.00, //Channels 180-183, SensL-C, DC
245  0., 0., 0., 0., //Channels 184-187 --EMPTY
246  0., 0., 0., 0., //Channels 188-191 --EMPTY
247 
248  //SSP501
249  -0.02, 0.00, -0.01, -0.03, //Channels 192-195, SensL-C, DC
250  0.01, 0.01, -0.03, -0.01, //Channels 196-199, SensL-C, DC
251  -0.01, 0.00, -0.01, -0.03, //Channels 200-203, SensL-C, DS
252 
253  //SSP502
254  -0.02, -0.01, -0.01, -0.01, //Channels 204-207, SensL-C DS
255  0., 0., 0., 0., //Channel 208-211, EMPTY
256  0., 0., 0., 0., //Channel 212-215, EMPTY
257 
258  //SSP503
259  0.15, 0.12, 0.19, 0.19, //Channels 216-219, MPPC, DC
260  0.17, 0.22, 0.20, 0.14, //Channels 220-223, MPPC, DS
261  0.02, 0., 0., 0.23, //Channels 224-227, MPPC, DC
262 
263  //SSP504
264  0.11, 0., 0.06, 0.04, //Channels 228-231, MPPC, DS
265  0., 0., 0., 0., //Channels 232-235, MPPC, DS
266  0., 0., 0., 0., //Channels 236-239, MPPC, DC
267 
268 
269  //SSP601
270  0.12, 0.11, 0.14, 0.19, //Channels 240-243, MPPC, DC
271  0.08, 0.08, 0.13, 0.11, //Channels 244-247, MPPC, DS
272  0., 0., 0., 0., //Channels 248-251, MPPC, DC
273 
274  //SSP602
275  0., 0., 0., 0., //Channels 252-255, MPPC, DS
276  0., 0., 0., 0., //Channels 256-259, MPPC, DC
277  0., 0., 0., 0., //Channels 260-263, MPPC, DC
278 
279  //SSP603
280  //ARAPUCA
281  -0.04, -0.03, -0.05, -0.01, //Channels 264-267, MPPC, ARAPUCA
282  -0.06, -0.06, -0.04, -0.01, //Channels 268-271, MPPC, ARAPUCA
283  -0.08, -0.05, 0., -0.08, //Channels 272-275, MPPC, ARAPUCA
284 
285 
286  //SSP604
287  0., 0., 0., 0., //Channels 276-279, MPPC, DS
288  0., 0., 0., 0., //Channels 280-283, MPPC, DC
289  0., 0., 0., 0. //Channels 284-287, MPPC, DS
290  };
291 
292 
293  }

Member Function Documentation

double calib::PhotonCalibratorProtoDUNESP::PE ( double  adcs,
int  opchannel 
) const
overridevirtual

Implements calib::IPhotonCalibrator.

Definition at line 294 of file PhotonCalibratorProtoDUNESP.cc.

295  {
296  if (std::find(fBadChannels.begin(), fBadChannels.end(), opchannel) != fBadChannels.end()) {
297  mf::LogDebug("PhotonCalibratorProtoDUNESP") << "Skipping bad channel " << opchannel;
298  return 0;
299  }
300 
301  return adcs/fSPESizes[opchannel] + fSPEShifts[opchannel];
302  }
MaybeLogger_< ELseverityLevel::ELsev_success, false > LogDebug
bool calib::PhotonCalibratorProtoDUNESP::UseArea ( ) const
inlineoverridevirtual

Implements calib::IPhotonCalibrator.

Definition at line 32 of file PhotonCalibratorProtoDUNESP.h.

32 { return true; } // ProtoDUNE always uses area

Member Data Documentation

std::vector<int> calib::PhotonCalibratorProtoDUNESP::fBadChannels
private

Definition at line 41 of file PhotonCalibratorProtoDUNESP.h.

std::vector<float> calib::PhotonCalibratorProtoDUNESP::fSPEShifts
private

Definition at line 40 of file PhotonCalibratorProtoDUNESP.h.

std::vector<float> calib::PhotonCalibratorProtoDUNESP::fSPESizes
private

Need a 3D position because result depends on position along length of bar. This is going to be pretty imprecise even so.

Definition at line 39 of file PhotonCalibratorProtoDUNESP.h.


The documentation for this class was generated from the following files: