Calibration tables
In BARS, the values $T_i$, $O_i$, $\alpha^i_{Q}$ and $\alpha^i_{A}$ are called calibration coefficients and are stored in calibration tables. Each calibration table is a plain text file that contains coefficients for channels in a cluster for a specific type of calibration. Here's an example of time calibration table for cluster 0, 2018:
# This is a comment
-486.20 -487.40 -487.10 -491.00 -494.10 -493.00 -489.00 -487.30 -489.60 -491.70 -497.70 -491.50
485.00 484.00 479.00 479.00 473.00 476.00 474.00 481.00 472.00 472.00 475.00 478.00
485.30 487.60 481.80 487.70 485.40 489.80 493.00 494.90 487.20 491.30 496.30 497.10
-170.20 -172.50 -169.30 -165.10 -172.10 -164.10 -168.00 -162.30 -173.30 -173.50 -161.10 -166.20
809.30 809.30 810.90 809.90 810.80 813.80 816.00 818.00 821.50 814.10 816.90 817.00
815.70 808.50 809.70 807.00 808.10 815.60 814.00 814.70 812.30 812.90 814.20 821.80
-256.80 -256.10 -252.40 -250.70 -250.60 -252.50 -254.00 -248.00 -250.20 -254.70 -249.50 -250.40
709.70 705.80 708.50 705.60 701.60 707.70 709.00 705.10 708.40 703.10 710.90 708.90
700.30 699.90 693.30 708.60 708.20 701.10 706.00 705.20 707.00 704.90 708.30 707.20
-263.30 -269.50 -261.10 -254.40 -268.30 -262.10 -255.00 -262.40 -256.20 -260.20 -263.50 -256.60
853.10 855.20 848.50 852.40 856.30 855.30 853.00 854.30 849.20 849.30 853.20 854.90
809.50 809.90 809.80 810.70 811.80 807.30 807.00 809.90 811.20 807.60 809.00 804.60
-205.50 -202.50 -203.50 -200.00 -195.30 -197.20 -203.00 -197.40 -195.30 -199.00 -192.80 -196.70
-10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00
-10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00
-157.00 -157.00 -10164.00 -159.00 -158.00 -159.00 -164.00 -162.00 -162.00 -163.00 -163.00 -160.00
834.50 834.50 832.50 832.50 824.50 828.50 824.50 821.50 824.50 822.50 822.50 821.50
-10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00
-10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00 -10000.00
353.30 358.80 360.80 361.30 363.80 358.40 360.00 362.80 368.00 365.70 367.40 365.80
373.50 369.00 370.00 372.00 374.50 373.00 -10000.00 374.00 379.00 376.50 377.50 373.50
0.00 -8.00 -8.30 -6.30 -3.30 -0.20 0.00 4.60 6.40 6.70 11.20 8.90
964.60 963.70 964.20 963.80 960.40 968.70 968.00 977.40 976.30 976.60 980.00 982.30
981.50 981.50 984.60 982.00 981.70 982.40 985.00 993.20 989.80 988.20 984.40 988.00
The format of calibration tables:
- Each table only has values for one type of calibration.
- Each value corresponds to one channel.
- The calibration table values are read left to right and top to bottom. So in the table above,
-486.20
corresponds to $T_1$,-487.40
to $T_2$ etc. - Each calibration table corresponds to one cluster. This means, that for seasons 2016 and above, each table must have exactly 288 values.
- The values can be separated by any number of whitespace character (space, multiple spaces, tabs etc), or linebreaks.
- Everything between # and the end of a line is a comment.
Where can I find calibration tables?
In BARS, calibration tables are located in the $BARSSYS/config/
directory.
The tables are split between directories according to the cluster and season they were acquired for.
For example, for season 2016 they are stored as follows:
$BARSSYS
└─ config
└─ 2016
└─ calib
└─ cluster0
├─ amplitude
│ ├─ some_amplitude_calibration_table
│ ├─ some_other_amplitude_calibration_table
│ └─ ...
├─ charge
│ ├─ some_charge_calibration_table
│ ├─ some_other_charge_calibration_table
│ └─ ...
├─ offset
│ ├─ some_offset_calibration_table
│ ├─ some_other_offset_calibration_table
│ └─ ...
└─ time
├─ some_time_calibration_table
├─ some_other_time_calibration_table
└─ ...
The name of calibration file in the corresponding directory is called a label of this calibration.
Each calibration has a nocalib
label that corresponds to an empty
calibration.
For time and offset calibrations the nocalib
values are all zeros, for amplitude and charge the values are all ones.
nocalib
is useful for service tasks when you want to deal with uncalibrated values.
For example, acquiring noise charge distributions requires ignoring time calibration.
Getting full path to a calibration table
BARS has a set of utility functions that allow you to get full path of a calibration file from it's name, type, season and cluster #. See here here for further details.