Newer
Older
How to calibrate SHMS calorimeter with real electrons.
The calibration code resides in
hallc_replay/CALIBRATION/shms_cal_calib directory. It consists of 3
header files called THcPShHit.h,THcPShTrack.h, THcPShowerCalib.h, and
a steering script pcal_calib.cpp. There is also an input file
input.dat containing threshold parameters and initial gain constants
necessary for calibration.
The scripts work on root files from hcana analysis and make use of
quantities pertained to tracking, gas Cherenkovs, and TOF from
hodoscopes. Hence it is convenient to calibrate on root files from
full SHMS analysis. The root files are assumed to be in a linked
ROOTfiles directory.
Th input file contains thresholds on the quantities used in the
calibration, such as: SHMS delta range, the hodoscope beta range,
thresholds on heavy and noble gas Cherenkov signals, required minimum
number of hits in the calorimeter channels in order to be calibrated,
initial gain constants, and parameters for an auxiliary histogram of
energy deposition calculated with initial gain constants. The gas
Cherenkov signals and beta are used to select good electron events for
calibration. Additional clean up of the electron sample from hadron
contamination (if any) left after PID with gas Cherenkov-s and beta is
done by a rough localization of the electron peak in the auxiliary
histogram. Note that code does not iterate the gain constants. The
user is free to modify cuts in the input file as needed. Caution must
be exercised not to alter the format of the file.
The steering script pcal_calib.cpp takes 3 parameters: prefix of the
root file to be calibrated, last (-1 by default) and the first (0 by
default) events to be used for calibration. The -1 value for last
event number defaults to the number of entries in the root file.
Once your hcana, hallc_replay and Root are set up, you can compile and
run pcal_calib under hcana, by issuing command
where Prefix is the prefix part in the name of root file.
For instance, for calibration with
shms_coin_replay_production_all_4313.root file in ROOTfiles, the
correct command would be
.x pcal_calib.cpp+("shms_coin_replay_production_all_4313") .
Upon calibration, a canvas with representative plots will pop up. The
calibration constants will be written in output file
pcal.param.<Prefix>, in a format suitable for plugging them into your
pcal.param file for subsequent use. The representative canvas is saved
in a pdf file <Prefix>.pdf, and histograms in <Prefix>.root file.