|
sipm-characterisation 0.1.0
SiPM characterisation for ePIC — IV/DCR/gain, laser, readout, irradiation
|
#include "analysis_utils.h"Go to the source code of this file.
Typedefs | |
| typedef std::tuple< double, double, double > | kFineTuneParamsType |
| Data Structures ------------------------------------------------------------------------------------------------------—. | |
Data Structures ------------------------------------------------------------------------------------------------------—.
| TH2_Type * build_fine_tune_raw_histogram | ( | std::vector< TString > | kInputFileNames, |
| TString | kRunTag, | ||
| TString | kOutputFileName, | ||
| bool | kRecalculate | ||
| ) |
Functions ------------------------------------------------------------------------------------------------------— — Declaration — — Fine tune.
— Implementation — — Fine tune
Check the output has already been produced
(Re)Calculate if requested
histogram with fine distribution
Loop on filenames
Load File
Load Tree
Get Entries and loop to fill histogram
Save custom output
| TH2_Type * build_fine_tune_raw_histogram | ( | TString | kRunTag, |
| TString | kOutputFileName, | ||
| bool | kRecalculate | ||
| ) |
| double calculate_calibrated_phase | ( | int | kFineParameter, |
| double | kCalibrationMin, | ||
| double | kCalibrationMax, | ||
| double | kCalibrationOffset | ||
| ) |
— — Calibration function
Base calibration function implementation
Checking the parameter given is within calibration range
Calculate the fine tune calibration from MAX and MIN values
TODO: This is a TEMPORARY FIX to avoid overlap regions
Correct by offset calibration
| double calculate_calibrated_phase | ( | int | kFineParameter, |
| global_identifier_t | kFilters | ||
| ) |
| void check_fine_tune_effect | ( | TString | kRunTag, |
| TH3_Type & | hFine_Check_Tune_Phas, | ||
| TH3_Type & | hFine_Check_Tune_Fine, | ||
| TH3_Type & | hFine_Check_TRaw_Phas, | ||
| TH3_Type & | hFine_Check_TRaw_Fine | ||
| ) |
NEW THINGS TO INTEGRATE ------—.
Loop on data
Taking first hit w/ assumption of coincidence
Second loop
Taking first hit w/ assumption of coincidence
| kFineTuneParamsType get_fine_calibration | ( | global_identifier_t | kFilters | ) |
— — Getter & Setters
Cache the fine tune parameters if they are not stored
| double get_fine_calibration_max | ( | global_identifier_t | kFilters | ) |
| double get_fine_calibration_min | ( | global_identifier_t | kFilters | ) |
| double get_fine_calibration_offset | ( | global_identifier_t | kFilters | ) |
Get stored fine tune parameters from calibration file.
Check the output has already been produced
Return calibration
| TH1D * get_fine_tune_raw_histogram | ( | global_identifier_t | kFilters | ) |
Get the raw histograms for calibration.
Loop on data
Selecting timing chips
Taking first hit w/ assumption of coincidence
Second loop
Channel Selection
| TH2_Type * run_fine_tune_analysis | ( | TString | kRunTag, |
| TString | kOutputFileName, | ||
| TString | kOutputGraphics, | ||
| bool | kRecalculate | ||
| ) |
Check the output has already been produced
(Re)Calculate if requested
Run in Batch mode
Load Files
Create output
Loop on found infos
Save custom output
Run in Batch mode
| TH2_Type * run_fine_tune_offset_analysis | ( | TString | kRunTag, |
| TString | kOutputFileName, | ||
| TString | kOutputGraphics, | ||
| bool | kRecalculate | ||
| ) |
Check the output has already been produced
(Re)Calculate if requested
(Re)Calculate if requested
Run in Batch mode
histogram with delta time distribution
Blank calibration
Load data & loop on found infos
Recover basic info
Re-assign mean correction
Check iteration limit conidtion
Plot check
Save custom output
Run in Batch mode
| void set_fine_analysis_fit_function | ( | TH1D * | histo, |
| int | riseThreshold = 1, |
||
| int | dropThreshold = 1, |
||
| int | max_step = -3, |
||
| int | min_step = 3 |
||
| ) |
@Chiara Fraticelli
| void set_fine_calibration | ( | global_identifier_t | kFilters | ) |
Recover calibration from saved file.
| void set_fine_calibration | ( | global_identifier_t | kFilters, |
| double | kCalibrationMin, | ||
| double | kCalibrationMax, | ||
| double | kCalibrationOffset | ||
| ) |
| void set_fine_calibration_max | ( | global_identifier_t | kFilters, |
| double | kCalibrationMax | ||
| ) |
| void set_fine_calibration_min | ( | global_identifier_t | kFilters, |
| double | kCalibrationMin | ||
| ) |
| void set_fine_calibration_offset | ( | global_identifier_t | kFilters, |
| double | kCalibrationOffset | ||
| ) |
| void set_fine_tune_raw_histogram | ( | global_identifier_t | kFilters | ) |
| void set_fine_tune_raw_histogram | ( | global_identifier_t | kFilters, |
| TH2_Type * | kFineTuneRawHistogram | ||
| ) |
| TF1* fine_analysis_fit_function = new TF1("fine_analysis_fit_function", "[0]*(1./(exp((x-[1])/[2])+1))*(1./(exp(([3]-x)/[4])+1))", 20., 150.) |
| std::map<global_identifier_t,kFineTuneParamsType> kFineTuneParameters |
Variables ------------------------------------------------------------------------------------------------------— — General.
| const TString output_preprocess_fine_analysis_directory = output_preprocess_directory + TString("/FineAnalysis/") |
| const TString output_preprocess_fine_analysis_file_check = output_preprocess_fine_analysis_directory + TString("/%s/FineTuneResultsCheck.root") |
| const TString output_preprocess_fine_analysis_file_offset_raw = output_preprocess_fine_analysis_directory + TString("/%s/FineTuneOffsetRaw.root") |
| const TString output_preprocess_fine_analysis_file_offset_rslt = output_preprocess_fine_analysis_directory + TString("/%s/FineTuneOffsetResults.root") |
| const TString output_preprocess_fine_analysis_file_raw = output_preprocess_fine_analysis_directory + TString("/%s/FineTuneRaw.root") |
| const TString output_preprocess_fine_analysis_file_rslt = output_preprocess_fine_analysis_directory + TString("/%s/FineTuneResults.root") |
| const TString output_preprocess_fine_analysis_graphics_dir = output_preprocess_fine_analysis_directory + TString("/%s/FitCheck/") |