This procedure is based on two software packages Extraction_Pedestal and Extraction_MIP found in flcahcalsoftware:  


General Description:

In this section the extraction of the auto-trigger pedestals as well as the MIP constants for the individual AHCAL channels is described.

MIP stands for Minimum Ionizing Particle and the MIP constant is defined as the most probable energy deposition in ADC (Analogue to Digital Counts) of a channel for a incident MIP particle, for example muons.

Besides the other calibration constants, the MIP constant is a crucial constant to convert the ADC value to the energy scale of MIP, showing the energy deposition in the calorimeter in MIP equivalents.

For the pedestals extraction and the MIP Calibration muon test beam runs are used in general.

Step-by-step guide

The MIP calibration consists of 3 main steps:

  1. Steering of the RootTreeGeneratorEUDAQ processor to convert the raw .slcio file to a .root file.
  2. Extraction of the Pedestal constants in auto-trigger mode.
  3. Extraction of the MIP constants, errors and fit-parameters of the Landau-Gaus fit.

Overview of Calibration Procedure

1. RootTreeGeneration

The event building process is already done in the EUDAQ. The basic goal of this step is to convert the raw .slcio muon files to .root tree files for further processing.

For this you need a Marlin steering file which executes the "RootTreeGeneratorEUDAQ2016" as in this example:


Global input parameters: SLCIO file/files

RootTreeGeneratorEUDAQ2016 processor parameters: OutputRootFileName, InputCollectionName (HCAL) and root tree branch prexif (ahcal_)

After executing this Marlin processor (.myMarlin tree_generation.xml) with the initialised corresponding ilc-soft version, you should now have a single root file (n-tuple tree structure) containing all informations.

2. Extraction of the Pedestal constants in AT

This step is done with the Extraction_Pedestal package. To extract the AT Pedestals just execute:

cd YourDestinationFolderName/Extraction_Pedestal 

./bin/pedestal_memcell    InputFilePath(Tree/generated/root/file)      Output/Directory/Path    1(HG/LG(0) or HG/TDC(1))  1(ExternalTrigger(0) or Auto-trigger(1))

The program fills pedestal histograms for each channel (memory cells combined) and for each memory cell of a channel with HitBit = 0 ADC amplitudes ( = 17 histograms per channel). After that a two times range-iteration (range = mean ± 3 · sigma) is applied and in the last step the mean of the histogram is extracted as the pedestal of the memory cell / channel.

The program will produce two output files: at_pedestals.tsv which contains all the individual memory cell, as well as the channel pedestal values. The second file Plots_comp.root contains all corresponding histograms. 

For memory cells 9-15 (partially 8) second pedestal peaks at much higher ADC values were observed, especially in Power Pulsing mode.

To avoid those problematic memory cells only the information of memory cell 0-8 is used in the following. For memory cells 9-15 the average of memory cell 0-8 is used.

In a last step the pedestal information in at_pedestals.tsv has to be converted into data base format. For that, one has to create one file providing the channel pedestal information (calculated for memory cell 0-8) in the following format:

#Module       ChipNumber       Channel        Pedestal        Pedestal_error        status (1 for good, 0 for bad)

In a second file the corresponding pedestal offsets (reference to the channel pedestal) are provided for memory cell 0-8 (offset of memory cell 9-15 is set to 0 to get channel pedestal for those) in the format:

#Module       ChipNumber        Channel        memcell0_offset       memcell0_offset_error         status (1 for good, 0 for bad) .....   memcell15_offset       memcell15_offset_error         status (1 for good, 0 for bad)

This files can then be uploaded to the database.

The at_pedestals.tsv file is used as one of the input files for the MIP extraction procedure.

3. Extraction of MIP constants

This step is done with the Extraction_MIP package. To extract the MIP constants just execute:

cd YourDestinationFolderName/Extraction_MIP 

./bin/mip_extractor    InputFilePath(Tree/generated/root/file)  InputPedestalFilePath(at_pedestals.tsv)    Output/Directory/Path

The program fills histograms for each channel with HitBit = 1 ADC amplitudes from memory cell 0-8 (to avoid any possible ADC jumps in higher memory cells)

The corresponding memory cell pedestal is subtracted for all ADC amplitudes

After that, a 3-step Landau convoluted Gaussian fit is applied (1. step: All Landau-Gaussian fit parameters fixed except for area below graph to determine lower and upper limit of Gaussian and Landau width fit parameters, 2. step: Release all parameters to determine optimal fitting range, 3. step: final fit) from which the maximum (most probable value MPV) is extracted as the MIP constant for each channel

Only MIP constants from channels with at least 1000 hits and a chi2/ndf < 5 are extracted as "good" constants.

The program will produce three output files: fitted_mip_spectra.root with all the fitted MIP spectra, mipfits.tsv with all extracted MIP constants for all "good" channels and  mipfits_bad.tsv with all extracted MIP constants for all "bad" channels.

Systematic studies were performed to check the influence by including or not including the hits from memory cell 8, since in power pulsing mode slight pedestal jumps are also occurring in this memory cell. As shown in the following plot the effect of the additional memory cell 8 is negligible since most of the hits are stored in the previous memory cells and  and only 10% of the memory cell pedestals are jumping in memory cell 8.


Lastly the MIP constants and channel information in mipfits.tsv has to be converted into data base format before being uploaded:

#Module              ChipNumber              Channel                 MPV                     MPV_error status         (status = 0)         status (status = 0)