8#include "TGraphAsymmErrors.h"
52 for (
int i = 0; i < 3; i++) {
54 for (
int j = 0; j < 2; j++)
73 return StatusCode::SUCCESS;
82 float corrected_isolation = input.isolationValue(isol) -
GetPtCorrection(input, isol);
83 return corrected_isolation;
106 float isolation_ptcorrection = 0;
110 if (input.caloCluster() ==
nullptr) {
111 ATH_MSG_WARNING(
"The associated cluster of the object does not exist ! Maybe the thinning was too agressive... No leakage correction computed.");
115 energy = input.caloCluster()->energyBE(1) + input.caloCluster()->energyBE(2) + input.caloCluster()->energyBE(3);
117 energy = input.caloCluster()->e();
121 bool convFlag =
false;
123 float etaS2 = input.caloCluster()->etaBE(2);
124 float etaS1 = input.caloCluster()->etaBE(1);
125 float etaCluster = input.caloCluster()->eta();
126 float phiCluster = input.caloCluster()->phi();
131 if(fabs(etaS1) > 2.5)
return 0.;
132 if(fabs(phiCluster) >
float(
M_PI))
return 0.;
135 ATH_MSG_VERBOSE(
"Electron ? " << (part_type ==
IsolationCorrection::ELECTRON) <<
" Input E = " << input.caloCluster()->e() <<
" E used " << energy <<
" author = " << input.author() <<
" pT = " << input.pt() <<
" phi = " << input.phi());
137 int convFlag_int = 0;
138 float conv_radius = 0.;
139 float conv_ratio = 0.;
145 if(convFlag_int == 3 ) convFlag_int = 2;
146 else if(convFlag_int != 0) convFlag_int = 1;
148 if(convFlag_int != 0) convFlag =
true;
151 if(convFlag_int == 2){
159 float pt1conv{}, pt2conv{};
161 pt1conv = accPt1(*phVertex);
162 pt2conv = accPt2(*phVertex);
168 const auto [numerator, denominator] = std::minmax(pt1conv,pt2conv);
174 conv_ratio = numerator/denominator;
177 int author = input.author();
188 auto etaPointing =
m_shower->getCaloPointingEta(etaS1, etaS2, phiCluster, is_mc);
189 if (!etaPointing.has_value())
return 0.;
220 return isolation_ptcorrection;
236 ATH_MSG_WARNING(
"IsolationCorrection::GetDDCorrection " << year <<
", unknown correction file name.\nNo correction is applied.\n");
237 return StatusCode::FAILURE;
240 int ii = year ==
"2017" ? 2 : (year ==
"2015_2016" ? 1 : 0);
244 return StatusCode::SUCCESS;
246 ATH_MSG_VERBOSE(
"Will setup the tool to retrieve " << year <<
" DD corrections");
249 if (year ==
"2015") {
256 }
else if (year ==
"2015_2016") {
263 }
else if (year ==
"2017") {
271 ATH_MSG_WARNING(
"Year " << year <<
" is not known in IsolationCorrection ! Check your input ! No correction is applied");
272 return StatusCode::FAILURE;
277 ATH_MSG_VERBOSE(
"DD corrections for year " << year <<
" not loaded yet. Doing it know");
279 std::unique_ptr< TFile > file_ptleakagecorr( TFile::Open(
m_corr_ddshift_file.c_str(),
"READ" ) );
280 if (!file_ptleakagecorr) {
282 return StatusCode::FAILURE;
284 TString baseN = year +
"/" + (
m_AFII_corr ?
"AF2/" :
"FullSim/");
285 TVector *veta = (TVector*)file_ptleakagecorr->Get(baseN+
"/etaBinning");
287 for (
int ieta = 0; ieta < veta->GetNrows(); ieta++)
m_feta_bins_dd->at(ieta) = (*veta)[ieta];
288 TTree *tbinLabel = (TTree*)file_ptleakagecorr->Get(baseN+
"tbinLabel");
289 TBranch *bbinLabel(
nullptr);
290 TString *binLabel(
nullptr); tbinLabel->SetBranchAddress(
"binLabel",&binLabel,&bbinLabel);
291 for (
unsigned int ieta = 0; ieta <
m_feta_bins_dd->size()-2; ieta++) {
292 tbinLabel->GetEntry(ieta);
293 TString gN =
"topoETcone40_DataDriven_unconverted_photon_eta_";
296 gN =
"topoETcone40_DataDriven_converted_photon_eta_";
299 gN =
"topoETcone20_DataDriven_unconverted_photon_eta_";
302 gN =
"topoETcone20_DataDriven_converted_photon_eta_";
315 return StatusCode::SUCCESS;
321 if (
setupDD(year) == StatusCode::FAILURE) {
331 bool converted =
false;
332 if(convFlag_int > 0) converted =
true;
334 float etaS2 = input.eta();
337 double feta = fabs(etaS2);
339 if (feta >=
m_feta_bins_dd->at(i) && feta < m_feta_bins_dd->at(i+1))
348 ATH_MSG_WARNING(
"Strange cluster S2 eta for photon isolation DD correction ! eta = " << etaS2 <<
". No correction");
352 if (input.pt() > 25e3)
354 <<
" eta: " << etaS2 <<
" etabin: " << eta_bin);
356 float pt_gev = input.pt()*0.001;
357 if (pt_gev > 999.) pt_gev = 999. ;
359 float isolation_ddcorrection = 0;
362 isolation_ddcorrection = 1e3*(*m_graph_dd_cone40_unconv_photon_shift)[eta_bin]->Eval(pt_gev);
364 isolation_ddcorrection = 1e3*(*m_graph_dd_cone40_conv_photon_shift)[eta_bin]->Eval(pt_gev);
367 isolation_ddcorrection = 1e3*(*m_graph_dd_cone20_unconv_photon_shift)[eta_bin]->Eval(pt_gev);
369 isolation_ddcorrection = 1e3*(*m_graph_dd_cone20_conv_photon_shift)[eta_bin]->Eval(pt_gev);
372 return isolation_ddcorrection;
376 if (input->caloCluster() ==
nullptr) {
377 ATH_MSG_WARNING(
"The associated cluster of the object does not exist ! Maybe the thinning was too agressive... use object eta for eta (instead of etaS2 or pointing).");
380 float etaS1 = input->caloCluster()->etaBE(1);
381 float etaS2 = input->caloCluster()->etaBE(2);
382 float phiCluster = input->caloCluster()->phi();
387 if(fabs(etaS1) > 2.5)
return 0.;
388 if(fabs(phiCluster) > 3.2)
return 0.;
390 auto etaPointing =
m_shower->getCaloPointingEta(etaS1, etaS2, phiCluster);
392 return etaPointing.value_or(0.);
426 m_eta_bins_fine = {0.0, 0.10, 0.60, 0.80, 1.15, 1.37, 1.52, 1.81, 2.01, 2.37, 2.47};
495 ATH_MSG_WARNING(
"Correction file for 2017 data/mc not specified, tool not initialized for 2017 corrections\n");
500 std::unique_ptr<TFile> file_ptleakagecorr(TFile::Open(
m_corr_file.c_str(),
"READ"));
501 if(!file_ptleakagecorr){
502 ATH_MSG_WARNING(
"Correction file for 2012 data/mc not found, tool not initialized for 2012 corrections\n");
528 m_graph_cone40_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone40_electron_etabin0_extrap") );
529 m_graph_cone40_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone40_electron_etabin1_extrap") );
530 m_graph_cone40_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone40_electron_etabin2_extrap") );
531 m_graph_cone40_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone40_electron_etabin3_extrap") );
532 m_graph_cone40_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone40_electron_etabin4_extrap") );
533 m_graph_cone40_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone40_electron_etabin5_extrap") );
534 m_graph_cone40_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone40_electron_etabin6_extrap") );
535 m_graph_cone40_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone40_electron_etabin7_extrap") );
536 m_graph_cone40_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone40_electron_etabin8_extrap") );
537 m_graph_cone40_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone40_electron_etabin9_extrap") );
561 m_graph_cone30_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone30_electron_etabin0_extrap") );
562 m_graph_cone30_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone30_electron_etabin1_extrap") );
563 m_graph_cone30_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone30_electron_etabin2_extrap") );
564 m_graph_cone30_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone30_electron_etabin3_extrap") );
565 m_graph_cone30_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone30_electron_etabin4_extrap") );
566 m_graph_cone30_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone30_electron_etabin5_extrap") );
567 m_graph_cone30_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone30_electron_etabin6_extrap") );
568 m_graph_cone30_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone30_electron_etabin7_extrap") );
569 m_graph_cone30_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone30_electron_etabin8_extrap") );
570 m_graph_cone30_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone30_electron_etabin9_extrap") );
594 m_graph_cone20_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone20_electron_etabin0_extrap") );
595 m_graph_cone20_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone20_electron_etabin1_extrap") );
596 m_graph_cone20_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone20_electron_etabin2_extrap") );
597 m_graph_cone20_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone20_electron_etabin3_extrap") );
598 m_graph_cone20_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone20_electron_etabin4_extrap") );
599 m_graph_cone20_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone20_electron_etabin5_extrap") );
600 m_graph_cone20_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone20_electron_etabin6_extrap") );
601 m_graph_cone20_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone20_electron_etabin7_extrap") );
602 m_graph_cone20_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone20_electron_etabin8_extrap") );
603 m_graph_cone20_electron.push_back( (TGraph*) file_ptleakagecorr->Get(
"graph_cone20_electron_etabin9_extrap") );
611 ATH_MSG_WARNING(
"Correction file for 2015 data/mc not specified, tool not initialized for 2015 corrections\n");
616 std::unique_ptr<TFile> file_ptleakagecorr(TFile::Open(
m_corr_file.c_str(),
"READ"));
617 if(!file_ptleakagecorr){
618 ATH_MSG_WARNING(
"Correction file for 2015 data/mc not found, "<<
m_corr_file<<
". tool not initialized for 2015 corrections\n");
621 if(!file_ptleakagecorr->GetListOfKeys()->Contains(
"mean_f_topoetcone40_eta_1.15_1.37_converted_ok")){
622 ATH_MSG_ERROR(
"Correction file for 2015 data/mc is not right, "<<
m_corr_file<<
". Tool not initialized for 2015 corrections\n");
630 static const int nEta = 10;
631 static const TString etaLab[nEta] = {
"0.0_0.1",
"0.1_0.6",
"0.6_0.8",
"0.8_1.15",
"1.15_1.37",
"1.37_1.52",
"1.52_1.81",
"1.81_2.01",
"2.01_2.37",
"2.37_2.47" };
632 static const TString pLab[5] = {
"_unconverted",
"_converted_ok",
"_converted_trouble",
"_author_1_electron",
"_author_16_electron" };
633 static const TString dRLab[3] = {
"20",
"30",
"40" };
662 for (
int iPart = 0; iPart < 5; iPart++) {
667 if (iPart < 3 && (
iEta == 5 ||
iEta == 9))
670 for (
int idR = 0; idR < 3; idR++) {
672 TString fN = (
m_useLogLogFit && iPart < 2) ?
"mean_flog_histo_topoetcone" :
"mean_f_topoetcone";
673 fN += dRLab[idR]; fN +=
"_eta_"; fN += etaLab[
iEta]; fN += pLab[iPart];
678 gN =
"mean_g_histo_topoetcone"; gN += dRLab[idR]; gN +=
"_eta_"; gN += etaLab[
iEta]; gN += pLab[iPart];
684 }
else if (iPart == 1) {
687 }
else if (iPart == 2) {
694 }
else if (iPart == 3) {
697 }
else if (iPart == 4) {
706 }
else if (idR == 1) {
710 }
else if (iPart == 1) {
713 }
else if (iPart == 2) {
720 }
else if (iPart == 3) {
723 }
else if (iPart == 4) {
736 }
else if (iPart == 1) {
739 }
else if (iPart == 2) {
746 }
else if (iPart == 3) {
749 }
else if (iPart == 4) {
773 ATH_MSG_WARNING(
"Data-driven correction files not specified, tool not initialized for data-driven corrections\n");
778 std::unique_ptr< TFile > file_ddshift_corr( TFile::Open(
m_corr_ddshift_file.c_str(),
"READ" ) );
781 if(!file_ddshift_corr || !file_ddsmearingcorr){
782 ATH_MSG_WARNING(
"Correction file for data-driven corrections not found, tool not initialized for data-driven corrections\n");
793 std::vector< std::shared_ptr<TGraphAsymmErrors> > graph_shift;
795 std::vector< std::shared_ptr<TGraphAsymmErrors> > graph_smearing;
796 for (
int ig = 0; ig <= 13; ig++) {
797 graph_shift.emplace_back(
dynamic_cast<TGraphAsymmErrors*
>(file_ddshift_corr->Get(Form(
"graph_%i",ig))) );
798 graph_smearing.emplace_back(
dynamic_cast<TGraphAsymmErrors*
>(file_ddsmearingcorr->Get(Form(
"graph_%i",ig))) );
800 for (
int ig = 0; ig <= 13; ig++) {
808 for (
const auto&
gr : graph_shift) {
810 ATH_MSG_ERROR(
"Null pointer for one of the DD correction graphs");
812 for (
const auto&
gr : graph_smearing) {
814 ATH_MSG_ERROR(
"Null pointer for one of the smearing graphs");
821 for (
typename T::iterator it = cntr.begin();
822 it != cntr.end(); ++it ) {
825 ATH_MSG_DEBUG(
"Deleting " << *it <<
" " <<
typeid(*it).name());
969 float pt_correction =
GetPtCorrection(energy, etaS2, etaPointing, etaCluster, radius, is_mc, isConversion, parttype);
970 return Etcone_value - pt_correction;
989 float pt_correction =
GetPtCorrectionTopo(energy, etaS2, etaPointing, etaCluster, radius, is_mc, isConversion, parttype, ver);
990 return Etcone_value - pt_correction;
1006 float etaS2,
float etaPointing,
float etaCluster,
1012 std::vector<float> mc_correction_slopes_ptr;
1013 std::vector<float> mc_correction_offsets_ptr;
1014 std::vector<float> data_correction_slopes_ptr;
1020 if (parttype ==
PHOTON) {
1038 if (parttype ==
PHOTON) {
1056 if (parttype ==
PHOTON) {
1074 ATH_MSG_WARNING(
"Unable to retrieve leakage correction for topoIso cone with radius = " << radius <<
".\n--- Radii must be one of {.20, .30, .40} OR {20, 30, 40}.\n");
1078 float scale_factor =
GetPtCorrectionFactor(etaS2, mc_correction_slopes_ptr, data_correction_slopes_ptr);
1080 if (!mc_correction_offsets_ptr.empty()) offset =
GetPtCorrectionFactor(etaS2, mc_correction_offsets_ptr);
1083 if(is_mc) is_mc =
true;
1094 float etaS2,
float etaPointing,
float etaCluster,
1098 int convFlag_int,
int author,
float conv_radius,
float conv_ratio)
const {
1099 double correction_value = 0.;
1106 return correction_value;
1117 if(radius < 1) newrad = (
int)(radius * 100 + 0.1);
1118 else newrad = (
int)radius;
1130 float fabs_eta = fabs(
eta);
1148 float fabs_eta = fabs(
eta);
1164 const std::vector<float>& mc_leakage_corrections_ptr,
1165 const std::vector<float>& data_leakage_corrections_ptr)
const {
1166 if(mc_leakage_corrections_ptr.empty() && data_leakage_corrections_ptr.empty())
1172 float correction = 0.;
1173 if (!mc_leakage_corrections_ptr.empty() && (eta_bin_fine >= 0)) correction += mc_leakage_corrections_ptr[eta_bin_fine];
1174 if (!data_leakage_corrections_ptr.empty() && (eta_bin_coarse >= 0)) correction += data_leakage_corrections_ptr[eta_bin_coarse];
1185 double etaForPt = ((fabs(etaPointing - etaCluster) < 0.15) ? etaPointing : etaCluster);
1186 double et = (fabs(etaForPt)<99.) ? energy/cosh(etaForPt) : 0.;
1188 return scale_factor *
et;
1200 double etaForPt = ((fabs(etaPointing - etaCluster) < 0.15) ? etaPointing : etaCluster);
1201 double et = (fabs(etaForPt)<99.) ? energy/cosh(etaForPt) : 0.;
1204 ATH_MSG_WARNING(
"IsolationCorrection::GetPtCorrection_FromGraph: the file containing the isolation leakage corrections is not initialized.\nNo correction is applied.\n");
1207 if (etabin < 0)
return 0;
1209 if( (etabin == 9 || etabin == 5) && parttype ==
PHOTON ){
1213 double correction_value_mev = -1e6;
1237 ATH_MSG_WARNING(
"Unable to retrieve leakage correction for topoIso cone with radius = " << radius <<
".\n--- Radii must be one of {.20, .30, .40} OR {20, 30, 40}.\n");
1240 return correction_value_mev;
1251 if(conversion_flag == 0)
return 0;
1253 if( (conversion_flag == 1) || ((conversion_flag == 2 && conv_ratio > 0.3) || (conversion_flag == 2 && conv_ratio < 0.3 && conv_radius > 140.)) )
return 1;
1255 if(conversion_flag == 2 && conv_radius < 140.)
return 2;
1261 double etaForPt = etaS2;
1262 double et = energy/cosh(etaForPt);
1265 int conversion_type = 0;
1269 if (
m_forcePartType && parttype ==
PHOTON) conversion_type = conv_radius > 800 ? 0 : (conv_radius > 140 ? 1 : 2);
1272 ATH_MSG_WARNING(
"In IsolationCorrection::GetPtCorrection_FromGraph_2015: the file containing the isolation leakage corrections is not initialized.\nNo correction is applied.\n");
1276 if (etabin < 0)
return 0;
1277 if(parttype ==
PHOTON)
if( (etabin == 9 || etabin == 5) )
return 0;
1279 double correction_value_mev = 0;
1281 float pt_threshold = 250000.;
1297 if(conversion_type == 2){
1313 if(conversion_type == 2){
1329 if(conversion_type == 2){
1336 ATH_MSG_WARNING(
"Unable to retrieve leakage correction for topoIso cone with radius = " << radius <<
".\n--- Radii must be one of {.20, .30, .40} OR {20, 30, 40}.\n");
1341 ATH_MSG_VERBOSE(
"Electron ? " << (parttype ==
ELECTRON) <<
" author / conversion type = " << (parttype ==
ELECTRON ? author : conversion_type) <<
" et = " <<
et <<
" eta = " << etaS2 <<
" etabin = " << etabin <<
" correction: "<< correction_value_mev);
1342 return correction_value_mev;
1346 ATH_MSG_INFO(
"Print properties of the parametrisation");
Scalar eta() const
pseudorapidity method
#define ATH_MSG_DEBUG(x,...)
#define ATH_MSG_ERROR(x,...)
#define ATH_MSG_WARNING(x,...)
#define ATH_MSG_VERBOSE(x,...)
#define ATH_MSG_INFO(x,...)
std::string PathResolverFindCalibFile(const std::string &logical_file_name)
std::vector< TF1 * > m_function_2015_cone40_photon_unconverted
void SetDataMC(bool is_mc)
void SetTroubleCategories(bool trouble_categories)
std::vector< TF1 * > m_function_2015_cone30_author_1_electron
std::vector< TF1 * > m_graph_dd_cone40_photon_shift
std::vector< TGraph * > * m_graph_dd_cone40_unconv_photon_shift
std::vector< TGraph * > * m_graph_dd_cone20_conv_photon_shift
std::vector< TGraph * > m_graph_cone40_photon_unconverted
std::vector< float > m_feta_bins_dd_2015
float GetPtCorrection(const xAOD::Egamma &, const xAOD::Iso::IsolationType) const
IsolationCorrection(const std::string &name)
float GetPtCorrectionFactor(float eta, const std::vector< float > &mc_leakage_corrections_ptr=std::vector< float >(), const std::vector< float > &data_leakage_corrections_ptr=std::vector< float >()) const
std::vector< float > m_mc_rel17_leakage_correction_offsets_photon_converted_35
std::vector< float > m_mc_rel17_leakage_correction_slopes_photon_converted_30
std::vector< float > m_mc_rel17_leakage_correction_slopes_photon_converted_20
std::vector< TF1 * > m_function_2015_cone40_author_16_electron
std::vector< TGraph * > m_graph_histoMean_2015_cone20_author_16_electron
std::vector< TGraph * > m_graph_dd_2015_2016_cone40_unconv_photon_shift
std::vector< float > m_mc_rel17_leakage_correction_slopes_photon_converted_15
float GetPtCorrectionTopo(float energy, float etaS2, float etaPointing, float etaCluster, float radius, bool is_mc=true, bool isConversion=false, ParticleType parttype=ELECTRON, Version ver=REL17_2, int convFlag_int=0, int author=0, float conv_radius=0., float conv_ratio=0.) const
std::vector< float > m_mc_rel17_leakage_correction_offsets_electron_40
std::string m_previousYear
std::vector< float > m_mc_rel17_leakage_correction_offsets_electron_35
std::vector< TGraph * > m_graph_dd_2015_cone40_unconv_photon_shift
void SetToolVer(CP::IsolationCorrection::Version)
static int GetConversionType(int conversion_flag, float conv_radius, float conv_ratio)
void SetAFII(bool AFII_corr)
std::vector< float > m_mc_rel17_leakage_correction_offsets_electron_20
std::vector< TGraph * > m_graph_afIIdd_2015_2016_cone40_unconv_photon_shift
std::vector< TGraph * > m_graph_dd_2017_cone40_conv_photon_shift
std::vector< float > m_mc_rel17_leakage_correction_slopes_photon_converted_25
std::vector< float > m_mc_rel17_leakage_correction_offsets_photon_converted_30
std::vector< TF1 * > m_function_2015_cone40_author_1_electron
std::vector< float > m_mc_rel17_leakage_correction_slopes_photon_unconverted_15
std::vector< float > m_mc_rel17_leakage_correction_slopes_photon_unconverted_20
std::vector< float > m_mc_rel17_leakage_correction_offsets_photon_converted_20
std::vector< float > m_mc_rel17_leakage_correction_offsets_photon_unconverted_25
float GetPtCorrectedTopoIsolation(float energy, float etaS2, float etaPointing, float etaCluster, float radius, bool is_mc, float Etcone_value, bool isConversion=false, ParticleType parttype=ELECTRON, Version ver=REL17_2)
std::vector< float > m_mc_rel17_leakage_correction_offsets_photon_unconverted_35
std::vector< TGraph * > m_graph_cone30_photon_converted
std::vector< TGraph * > * m_graph_dd_cone20_unconv_photon_shift
std::vector< TGraph * > m_graph_histoMean_2015_cone30_photon_converted_trouble
std::vector< TGraph * > m_graph_histoMean_2015_cone30_author_16_electron
std::vector< float > m_mc_rel17_leakage_correction_slopes_photon_unconverted_35
std::vector< TGraph * > m_graph_afIIdd_2015_2016_cone20_conv_photon_shift
std::vector< TGraph * > m_graph_cone40_photon_converted
std::vector< TGraph * > m_graph_dd_2015_cone20_unconv_photon_shift
StatusCode setupDD(const std::string &year)
std::vector< TGraph * > m_graph_afIIdd_2015_2016_cone40_conv_photon_shift
std::vector< float > m_mc_rel17_leakage_correction_offsets_electron_15
std::vector< TF1 * > m_function_2015_cone40_photon_converted_ok
std::vector< float > m_mc_rel17_leakage_correction_slopes_photon_unconverted_25
std::vector< TF1 * > m_function_2015_cone30_photon_unconverted
std::vector< float > m_mc_rel17_leakage_correction_slopes_photon_converted_40
std::vector< float > m_mc_rel17_leakage_correction_offsets_photon_unconverted_40
std::vector< float > m_mc_rel17_leakage_correction_slopes_electron_30
std::vector< float > m_mc_rel17_leakage_correction_slopes_electron_25
std::vector< float > m_mc_rel17_leakage_correction_slopes_electron_15
const unsigned int m_nBinsEtaCoarse
std::vector< TGraph * > m_graph_dd_2017_cone40_unconv_photon_shift
std::vector< TF1 * > m_function_2015_cone40_photon_converted_trouble
std::vector< float > m_eta_bins_fine
std::vector< TGraph * > m_graph_cone40_electron
std::vector< TGraph * > m_graph_dd_2015_2016_cone20_unconv_photon_shift
std::vector< TGraph * > m_graph_cone30_electron
std::vector< TGraph * > m_graph_afIIdd_2015_2016_cone20_unconv_photon_shift
std::vector< TF1 * > m_function_2015_cone20_photon_converted_ok
std::vector< float > m_mc_rel17_leakage_correction_slopes_electron_20
int GetEtaBinFine(float eta) const
std::vector< TF1 * > m_function_2015_cone30_photon_converted_trouble
std::vector< TGraph * > m_graph_dd_2015_2016_cone40_conv_photon_shift
std::vector< TF1 * > m_function_2015_cone30_author_16_electron
std::vector< TGraph * > m_graph_histoMean_2015_cone40_photon_converted_trouble
std::vector< float > m_mc_rel17_leakage_correction_offsets_photon_converted_40
std::vector< float > m_mc_rel17_leakage_correction_offsets_photon_unconverted_20
std::string m_corr_ddshift_file
std::vector< float > m_mc_rel17_leakage_correction_offsets_photon_converted_15
const unsigned int m_nBinsEtaFine
float GetPtCorrectedIsolation(const xAOD::Egamma &, const xAOD::Iso::IsolationType) const
std::vector< TGraph * > m_graph_dd_2015_cone40_conv_photon_shift
std::vector< TGraph * > m_graph_afIIdd_2017_cone20_conv_photon_shift
std::vector< TGraph * > m_graph_dd_2017_cone20_conv_photon_shift
std::vector< TGraph * > * m_graph_dd_cone40_conv_photon_shift
std::vector< float > m_mc_rel17_leakage_correction_offsets_photon_converted_25
std::vector< float > m_mc_rel17_leakage_correction_slopes_photon_unconverted_40
std::vector< float > m_mc_rel17_leakage_correction_slopes_photon_unconverted_30
std::vector< TF1 * > m_graph_dd_cone40_photon_smearing
void SetCorrectionFile(const std::string &corr_file, const std::string &corr_ddshift_file, const std::string &corr_ddsmearing_file)
std::vector< TF1 * > m_function_2015_cone20_photon_converted_trouble
float GetDDCorrection(const xAOD::Egamma &, const xAOD::Iso::IsolationType, const std::string &year)
std::vector< TGraph * > m_graph_dd_2015_2016_cone20_conv_photon_shift
std::vector< TGraph * > m_graph_cone20_photon_unconverted
std::vector< TGraph * > m_graph_afIIdd_2017_cone40_conv_photon_shift
void SetCorrectEtcone(bool correct_etcone)
int GetEtaBinCoarse(float eta) const
bool m_corrInitialized[3][2]
std::vector< float > m_feta_bins_dd_2017
std::vector< TGraph * > m_graph_dd_2015_cone20_conv_photon_shift
std::vector< TGraph * > m_graph_afIIdd_2017_cone40_unconv_photon_shift
std::string m_corr_ddsmearing_file
std::vector< float > m_eta_bins_coarse
std::vector< float > m_mc_rel17_leakage_correction_slopes_photon_converted_35
float GetPtCorrection_FromGraph(float energy, float etaS2, float etaPointing, float etaCluster, float radius, bool isConversion, ParticleType parttype) const
float GetEtaPointing(const xAOD::Egamma *)
std::vector< TGraph * > m_graph_afIIdd_2017_cone20_unconv_photon_shift
std::vector< float > m_mc_rel17_leakage_correction_slopes_electron_40
std::vector< TGraph * > m_graph_cone20_electron
std::vector< TF1 * > m_function_2015_cone30_photon_converted_ok
std::vector< TF1 * > m_function_2015_cone20_author_1_electron
static float getPtAtFirstMeasurement(const xAOD::TrackParticle *tp)
CP::ShowerDepthUtil * m_shower
std::vector< float > m_mc_rel17_leakage_correction_offsets_photon_unconverted_15
static int GetRadius(float radius)
std::vector< TGraph * > m_graph_cone30_photon_unconverted
CP::IsolationCorrection::Version m_tool_ver
bool m_trouble_categories
std::vector< TGraph * > m_graph_dd_2017_cone20_unconv_photon_shift
std::vector< float > m_mc_rel17_leakage_correction_offsets_electron_30
std::vector< TF1 * > m_function_2015_cone20_author_16_electron
static float GetPtCorrectionValue(float energy, float etaPointing, float etaCluster, float scale_factor)
float GetPtCorrection_FromGraph_2015(float energy, float etaS2, float radius, int conversion_flag, int author, float conv_radius, float conv_ratio, ParticleType parttype) const
std::vector< TGraph * > m_graph_histoMean_2015_cone20_photon_converted_trouble
std::vector< float > m_mc_rel17_leakage_correction_slopes_electron_35
std::vector< TGraph * > m_graph_cone20_photon_converted
std::vector< float > m_mc_rel17_leakage_correction_offsets_photon_unconverted_30
std::vector< float > m_mc_rel17_leakage_correction_offsets_electron_25
std::vector< TF1 * > m_function_2015_cone20_photon_unconverted
std::vector< float > * m_feta_bins_dd
std::vector< TGraph * > m_graph_histoMean_2015_cone40_author_16_electron
Helper class to provide type-safe access to aux data.
bool isAvailable(const ELT &e) const
Test to see if this variable exists in the store.
AsgMessaging(const std::string &name)
Constructor with a name.
bool msgLvl(const MSG::Level lvl) const
Test the output level of the object.
bool eventType(EventType type) const
Check for one particular bitmask value.
@ IS_SIMULATION
true: simulation, false: data
const xAOD::Vertex * vertex(size_t index=0) const
Pointer to the xAOD::Vertex/es that match the photon candidate.
float parameterPX(unsigned int index) const
Returns the parameter x momentum component, for 'index'.
float parameterPY(unsigned int index) const
Returns the parameter y momentum component, for 'index'.
xAOD::ParameterPosition parameterPosition(unsigned int index) const
Return the ParameterPosition of the parameters at 'index'.
size_t numberOfParameters() const
Returns the number of additional parameters stored in the TrackParticle.
virtual double pt() const override final
The transverse momentum ( ) of the particle.
const TrackParticle * trackParticle(size_t i) const
Get the pointer to a given track that was used in vertex reco.
Select isolated Photons, Electrons and Muons.
@ Electron
The object is an electron.
xAOD::EgammaParameters::ConversionType conversionType(const xAOD::Photon *ph)
return the photon conversion type (see EgammaEnums)
float conversionRadius(const xAOD::Vertex *vx)
return the conversion radius or 9999.
IsolationFlavour isolationFlavour(IsolationType type)
convert Isolation Type into Isolation Flavour
IsolationType
Overall enumeration for isolation types in xAOD files.
@ topoetcone20
Topo-cluster ET-sum.
@ topoetcone
Topo-cluster ET-sum.
float coneSize(IsolationConeSize type)
convert Isolation Size into cone size
setScale setgFexType iEta
EventInfo_v1 EventInfo
Definition of the latest event info version.
TrackParticle_v1 TrackParticle
Reference the current persistent version:
Vertex_v1 Vertex
Define the latest version of the vertex class.
Egamma_v1 Egamma
Definition of the current "egamma version".
Photon_v1 Photon
Definition of the current "egamma version".
@ FirstMeasurement
Parameter defined at the position of the 1st measurement.