PMTCALIB: A PMT Calibration Utility for D0 Muon Scintillation Counter System
Shashi Dugad & Satyanarayana Bheesette
Tata Institute of Fundamental Research,
Mumbai, INDIA
August 24, 2001
This document describes salient features, usage and output file format of PMTCALIB, a calibration utility for the photo multiplier tubes(PMTs) used in the upgraded D0 muon detector.
Introduction
The D0 muon scintillation counter systems have approximately 5500 PMT's. It is important to monitor the absolute gain of these tubes, as it can be used to adjust the discriminator threshold for each channel in order to maintain the best efficiency of the scintillation counters during the runs. Since the scintillation counters will also be used to reject out-of-time background events, gain monitoring is also required to ensure proper timing.
The muon scintillation counters have a light emitting diode(LED) calibration system[1, 2], which provides pulsed light from LED's for monitoring the PMT gains. The light output from these LED's is monitored by PIN diodes, whose signals are measured in the same scintillation counter electronics as the phototube signals[3]. A procedure to estimate the number of photoelectrons emitted by the photocathode of the PMT due to light from the calibration LED's, the correction needed to be applied due to the variations in LED light intensity and finally absolute gain of the PMT's is discussed in [4]. PMTCALIB package essentially implements this scheme.
General features
PMTCALIB works on the pedestal and LED calibration runs collected by the daq_local software. This software produces histograms in ROOT formatted files. The names of these files go as input to PMTCALIB. Crate number and run numbers information is extracted from the file names supplied. In addition, the PMTCALIB also uses three configuration or look-up table files for decoding all the required information for all SFE's modules and channels within the crate. The information contained in these files is compiled from [5,6,7]. It is to be noted that these files should be located in the same area as that of PMTCALIB package itself. Following is a brief discussion about these configuration files. Details about the format of the configuration files as well as the entries therein are given at the beginning of the files as comments.
scintinfo.dat: This file encodes information specific to physical scintillation counter and their readout channels. Mapping of each electronic readout channel to its PDT identification as well as scintillation counter number is obtained by information stored in this file. The fields under which the information is classified in this file are crate number, slot number, serial number and address of SFE, PDT identification, start and last scintillation counter numbers, start and last scintillation counter readout channel numbers and number of PMT's readout per scintillation counter.
pmtcalib.cfg: This file encodes crate-wise information on the number of PIN diodes and their locations. In order to facilitate changes to the number as well as locations of these PIN diodes in future, validity of a specific PIN configuration for a given crate is implemented in terms of start and end run numbers. Thus, if changes are made in the number of PIN diodes or their locations, this file needs to be modified to add one or more of new lines with changed configuration, validated by the new start and end run numbers.
pinroloc.dat: Each LED illuminates a certain range of channels which are grouped PDT-wise in the LED calibration system. This range for each LED is obtained from this file. The file encodes PDT or their group wise information on the start and end readout locations of the PIN diodes under each crate. The readout location is an encapsulated with serial number of the SFE under the crate and the channel number. While in most cases, the locations are in a single group, there are a few cases where in the locations are spread across two independent groups.
How to use
PMTCALIB package and the three configuration files described above are stored at ~shashi/pmtcalib on d0mino. They should first be copied to the working directory where the ROOT formatted input data files reside. PMTCALIB operates under ROOT, so ROOT should be setup and executed using the following commands.
> setup D0RunII
> root
The PMTCALIB can then loaded and executed using the following commands at the ROOT prompt. The syntax shown here is for the third version of PMTCALIB.
root[0] .L pmtcalib_v03.C
root[1] .x pmtcalib_v03.C
Pedestal and LED data filenames should be supplied when prompted to do so by PMTCALIB. The naming convention of these files is,
cr<Crate number in Hex format>_<Run number>.root
PMTCALIB then proceeds with computing the calibration constants and progress of the same is indicated by displaying appropriate messages. On successful completion, it generates an ASCII output file,
cr<Crate number in Hex format>_<Run number>.root.out,
in the working directory, for the LED data filename supplied as above. The file can be treated as pickle file for generating the final calibration database.
Following is a typical display output of a PMTCALIB session, which is grouped into five separate blocks. While in the first block, data filenames are being supplied, in the second block, these as well as the run numbers and crate number extracted from the filenames are displayed. Third block contains progress messages being output by PMTCALIB. Finally, the last block is a summary table on the number of SFE's and PIN's readout in the run. Information in this table include PIN location (Column 2) and two ranges(Columns 3-4 and 5-6) of readout channels which it illuminates. In case of readout channels confined to a single range, then the second range(Columns 5-6) shown is a dummy one. Notation for the data in columns 2-6 is SFE-Channel numbers.
Enter the pedestal data filename: cr56_2259.root
Enter the signal data filename : cr56_2242.root
Error code : 0
Pedestal data filename : cr56_2259.root
Signal data filename : cr56_2242.root
Signal data run number : 2242
Pedestal data run number: 2259
Crate number : 56(hex)
Processing Histograms from channel 0- 0 to 0-15 for PIN no. 0
Processing Histograms from channel 1- 0 to 1-15 for PIN no. 1
Processing Histograms from channel 2- 0 to 2-15 for PIN no. 2
Processing Histograms from channel 2-16 to 2-31 for PIN no. 3
Processing Histograms from channel 2-32 to 2-47 for PIN no. 4
Processing Histograms from channel 3- 0 to 3-15 for PIN no. 5
Processing Histograms from channel 0-16 to 0-31 for PIN no. 0
Processing Histograms from channel 1-16 to 1-31 for PIN no. 1
Error code : 0
Number of SFEs : 5
Number of PINS : 10
PIN PINLoc RoLocFS RoLocFE RoLocSS RoLocSE
No. SFE-Cha SFE-Cha SFE-Cha SFE-Cha SFE-Cha
00 00-31 00-00 00-15 00-16 00-31
01 01-31 01-00 01-15 01-16 01-31
02 00-47 02-00 02-15 -1--1 -1--1
03 01-47 02-16 02-31 -1--1 -1--1
04 03-45 02-32 02-47 -1--1 -1--1
05 03-46 03-00 03-15 -1--1 -1--1
06 03-47 03-16 03-31 -1--1 -1--1
07 04-15 04-00 04-15 -1--1 -1--1
08 04-31 04-16 04-31 -1--1 -1--1
09 04-47 04-32 04-47 -1--1 -1--1
Pickle file data format
First line of the pickle file contains summary of the calibration runs. The data fields stored from the left to right are as follow:
Pedestal run number
LED data number
Crate number (in Hex format)
Total number of PIN's in the crate
Total number of SFE's in the crate
Total number of SFE channels (including all PIN channels) illuminated for the LED run
Second line onwards, contain calibration parameters for each channel - one line per cannel. There are two types of channels viz., PMT channel and PIN channel. Calibration parameters for all the PIN channels which are illuminated during the run are written first, followed by the data for the PMT channels. The data fields stored in each line from the left to right are as follow:
SFE address (in Hex format) of the channel. This is unique irrespective of the crate number.
Serial number of the SFE in the crate (Starting with 0)
SFE channel number in the SFE (Starting with 0)
PDT identification of the channel (PIN number prefixed by 'PIN-', if it is a PIN channel)
Scintillation counter number in the PDT(Starting with 1) (Set to 0 for a PIN channel)
Number of triggers in pedestal run
Arithmetic mean of the pedestal data distribution
RMS of the pedestal data distribution
Number of triggers in LED run
Arithmetic mean of LED data distribution
RMS of LED data distribution
Constant for fitted LED data distribution
Fitted mean of LED data distribution
Sigma of fitted the LED data distribution
Pedestal subtracted mean of LED data distribution (13-7)
Effective sigma of the LED data distribution SQRT(11**2 - 8**2)
Error flag. Following error codes are currently defined.
-1: Channel to be ignored for storing purpose
1: PIN correction applied for photoelectron and gain calculation
2: PIN correction cannot be applied for photoelectron and gain calculation. This represents the case where sigma of the LED data is significantly less than the RMS of the pedestal data.
3: The record is for a PIN channel
Photo electron yield of the PMT channel (Set to 0 for PIN channel)
Gain of the PMT channel (Set to 0 for PIN channel)
References
C.Rotolo and T.Fitzpatrick, "D0 Muon Scintillator Electronics LED Pulser Module(SLP) Specification", Revised May 30, 1997, http://www-d0.fnal.gov/muon_electronics/.
P.Hanlet et al, "LED Pulser System for the D0 Muon Upgrade Scintillation Counters", D0 Note 3563.
C.Rotolo and T.Fitzpatrick, "D0 Muon Scintillator Electronics Front End Module(SFE) Specification", Revised July 10, 1997, http://www-d0.fnal.gov/muon_electronics/.
S.Doulas, S.R.Dugad and A.S.Ito, "D0 Muon Scintillator Phototube Gain Determination", D0 Note 3861.
H.T.Diehl et al, "Central Muon Upgrade Scintillator Front-End Crate Addresses", Revised July 29, 2000, D0 Note 3642.
Steven Doulas, Private communication
"Muon Examine Output User's Guide"
Page