151 Event processor: get data and print to screen
154 event = evtMetaData.obj().getEvent()
155 run = evtMetaData.obj().getRun()
157 for waveform
in waveforms:
158 chan = waveform.getChannel()
161 nInFirstWindow, nNarrowPeaks, nHeight150, nOscillations = 0, 0, 0, 0
164 wins = np.array(waveform.getStorageWindows())
165 if not np.all(wins[:-1] <= wins[1:]):
167 if False and args.plotWaveforms:
168 wf_display(waveform, run, event,
"windowOrder")
171 wf = np.array(waveform.getWaveform())
172 if False and args.plotWaveforms:
173 wf_display(waveform, run, event,
"general")
178 rawDigits = waveform.getRelationsWith(
"TOPRawDigits")
179 nTOPRawDigits = len(rawDigits)
181 if False and args.plotWaveforms
and nTOPRawDigits > 2:
183 wf_display(waveform, run, event,
"manyPeaks")
185 if False and args.plotWaveforms
and nTOPRawDigits > 3:
187 wf_display(waveform, run, event,
"tooManyPeaks")
190 fePeakHt = raw.getValuePeak()
191 fePeakTDC = raw.getSamplePeak()
192 fePeakWd = raw.getSampleFall() - raw.getSampleRise()
193 fePeakIntegral = raw.getIntegral()
197 if 0 < fePeakTDC < 65
and chan % 8 == 0:
200 if False and args.plotWaveforms:
201 wf_display(waveform, run, event,
"calPuls_firstWin")
205 if (140 < fePeakHt < 220)
and chan % 8 == 0:
206 if False and args.plotWaveforms:
207 wf_display(waveform, run, event,
"strangeADCBump_1")
209 if (300 < fePeakHt < 410)
and chan % 8 == 0:
210 if False and args.plotWaveforms:
211 wf_display(waveform, run, event,
"strangeADCBump_2")
218 if nTOPRawDigits > 1:
220 fePeak1Ht = rawDigits[1].getValuePeak()
221 fePeak1TDC = rawDigits[1].getSamplePeak()
222 fePeak1Wd = rawDigits[1].getSampleFall() - rawDigits[1].getSampleRise()
225 if nTOPRawDigits > 1
and fePeak1TDC < 64:
227 if False and args.plotWaveforms:
228 wf_display(waveform, run, event,
"secondPeakInFirstWindow")
231 if fePeakWd < 5
or nTOPRawDigits > 1
and fePeak1Wd < 5:
234 if False and args.plotWaveforms:
235 wf_display(waveform, run, event,
"thinpeak")
238 if 145 < fePeak1Ht < 155
and chan % 8 == 0:
241 if False and args.plotWaveforms:
242 wf_display(waveform, run, event,
"peak1Ht_is_150")
245 if nTOPRawDigits > 5
and (fePeakHt - fePeak1Ht) < 5:
250 if False and args.plotWaveforms:
251 wf_display(waveform, run, event,
"oscillations")
274 evtMetaData.obj().setEndOfData()