Description
The S-curve analysis is implemented. It takes as input:
- An arbitrary number of ROOT files containing S-curve histograms.
- An optional VFAT calibration constants file (only required if "fC" units are desired).
- An optional VFAT mapping file (only required if "fC" units are desired).
It produces as outputs:
-
A ROOT file containing a
TTree
with the results of the S-curve analysis containing the following branches:- Usual branches of channel identification ("fed", "slot", ..., "channel").
- A boolean flag indicating whether the S-curve fit was successful (based on the
ierr
curve_fit indicator or any RuntimeError that could be thrown). - Computed threshold values.
- Computed noise/ENC values.
- Another boolean flag indicating whether a channel has no data (it is empty).
- (Optional) A
TDirectory
per VFAT with the 2D histogramschanHitvsCalDAC2D
.
-
A directory containing the following plots:
- A summary figure per OH, with 2D histograms for each VFAT.
- A figure per OH containing box plots with the thresholds/activation values, and the box plot with the noise/ENC.
- (Optional) A complete overview of data distribution per VFAT. These plots show the data for each channel and contrast with histogram distributions.
Related Issue
Fixes #15 (closed)
How Has This Been Tested?
usage: gemos analyze scurves [-h] [-p {essentials,full,no-plot}] [-f] [-u {DAC,fC}] [-m MAPPING_FILE] [-c CALIBRATION_FILE]
inputfiles [inputfiles ...] outputdir
positional arguments:
inputfiles Files containing the S-curves histograms ROOT files
outputdir Output directory to save the results of the analysis
optional arguments:
-h, --help show this help message and exit
-p {essentials,full,no-plot}, --plotting {essentials,full,no-plot}
Specify in case summary and/or boxplot scurve plots are desired
-f, --full-output Specify when an output file that includes the input histograms be desired
-u {DAC,fC}, --units {DAC,fC}
Specify in case fC or DAC units are desired
-m MAPPING_FILE, --mapping MAPPING_FILE
File containing the VFAT chip ID to logical address mapping (see cmsgemos gem-dump-vfat-mapping)
-c CALIBRATION_FILE, --calibration CALIBRATION_FILE
File containing the VFAT calibration parameters (see gemos query vfat-calibration)
Types of changes
-
Bug fix (non-breaking change which fixes an issue) -
New feature (non-breaking change which adds functionality) -
Breaking change (fix or feature that would cause existing functionality to change)
Checklist:
-
My code follows the code style of this project. -
My change requires a change to the documentation. -
I have updated the documentation accordingly. -
I have read the CONTRIBUTING document. -
I have added tests to cover my changes. -
All new and existing tests passed.