|
ATLAS Offline Software
|
Go to the documentation of this file.
16 #include <TObjString.h>
28 template <
typename TargetPtr,
typename SourcePtr>
29 TargetPtr checked_cast(SourcePtr
ptr) {
32 "attempt to cast to no ptr object");
34 "attempt to cast from no ptr object");
38 throw std::runtime_error(
39 "Attempt to cast from nullptr in egammaLayerRecalibTool");
43 TargetPtr
obj =
dynamic_cast<TargetPtr
>(
ptr);
45 throw std::runtime_error(
"failed dynamic cast for " +
46 std::string(
ptr->GetName()) +
47 " in egammaLayerRecalibTool");
159 const double Es1 =
inputs.E1raw;
160 const double Es2 =
inputs.E2raw;
161 if (Es1 == 0 and Es2 == 0) {
166 const double sum = Es1 + Es2;
167 const double alpha = amount;
168 const double den = (alpha * Es1 + Es2);
176 throw std::runtime_error(
"not implemented");
211 if (
"layer1_2012" ==
tune)
return "layer1_2012_v5";
212 if (
"layer1_alt_2012" ==
tune)
return "layer1_alt_2012_v5";
213 if (
"layer1_2011" ==
tune)
return "layer1_2011_v5";
214 if (
"layer1_alt_2011" ==
tune)
return "layer1_alt_2011_v5";
215 if (
"layer1_2010" ==
tune)
return "layer1_2010_v5";
216 if (
"ps_2012" ==
tune)
return "ps_2012_v3";
217 if (
"ps_2011" ==
tune)
return "ps_2011_v3";
218 if (
"ps_2010" ==
tune)
return "ps_2010_v3";
219 if (
"layer1_2012_up" ==
tune)
return "layer1_2012_v5_up";
220 if (
"layer1_2012_down" ==
tune)
return "layer1_2012_v5_down";
221 if (
"layer1_2012_errup" ==
tune)
return "layer1_2012_v5_errup";
222 if (
"layer1_2012_errdown" ==
tune)
return "layer1_2012_v5_errdown";
223 if (
"layer1_2011_up" ==
tune)
return "layer1_2011_v5_up";
224 if (
"layer1_2011_down" ==
tune)
return "layer1_2011_v5_down";
225 if (
"layer1_2011_errup" ==
tune)
return "layer1_2011_v5_errup";
226 if (
"layer1_2011_errdown" ==
tune)
return "layer1_2011_v5_errdown";
227 if (
"layer1_2010_up" ==
tune)
return "layer1_2010_v5_up";
228 if (
"layer1_2010_down" ==
tune)
return "layer1_2010_v5_down";
229 if (
"layer1_2010_errup" ==
tune)
return "layer1_2010_v5_errup";
230 if (
"layer1_2010_errdown" ==
tune)
return "layer1_2010_v5_errdown";
231 if (
"ps_2012_up" ==
tune)
return "ps_2012_v3_up";
232 if (
"ps_2012_down" ==
tune)
return "ps_2012_v3_down";
233 if (
"ps_2012_errup" ==
tune)
return "ps_2012_v3_errup";
234 if (
"ps_2012_errdown" ==
tune)
return "ps_2012_v3_errdown";
235 if (
"ps_2011_up" ==
tune)
return "ps_2011_v3_up";
236 if (
"ps_2011_down" ==
tune)
return "ps_2011_v3_down";
237 if (
"ps_2011_errup" ==
tune)
return "ps_2011_v3_errup";
238 if (
"ps_2011_errdown" ==
tune)
return "ps_2011_v3_errdown";
239 if (
"ps_2010_up" ==
tune)
return "ps_2010_v3_up";
240 if (
"ps_2010_down" ==
tune)
return "ps_2010_v3_down";
241 if (
"ps_2010_errup" ==
tune)
return "ps_2010_v3_errup";
242 if (
"ps_2010_errdown" ==
tune)
return "ps_2010_v3_errdown";
252 if (
tune.empty()) { }
253 else if (
"es2022_22.0_Precision" ==
tune) {
254 add_scale(
"run2_alt_with_layer2_r22_Precision");
256 else if (
"es2018_21.0_v0" ==
tune) {
257 add_scale(
"run2_alt_with_layer2_r21_v1");
259 else if (
"es2017_21.0_v0" ==
tune) {
260 add_scale(
"run2_alt_with_layer2_r21_v0");
262 else if (
"es2017_20.7_final" ==
tune) {
266 else if (
"es2017_20.7_improved" ==
tune) {
271 else if (
"pileup_20.7" ==
tune) {
279 else if (
"run2_alt_with_layer2_r22_Precision"==
tune) {
280 add_scale(
"layer2_alt_el_mu_comb_r21_v0");
284 else if (
"run2_alt_with_layer2_r21_v1"==
tune) {
288 else if (
"run2_alt_with_layer2_r21_v0"==
tune) {
292 else if(
"run2_alt_with_layer2_modif" ==
tune) {
298 else if (
"2012" ==
tune) {
303 else if(
"2012_with_layer2" ==
tune) {
308 else if (
"2012_alt" ==
tune) {
313 else if(
"2012_alt_with_layer2" ==
tune) {
318 else if(
"2012_alt_with_layer2_modif" ==
tune) {
324 else if(
"2010_with_layer2" ==
tune) {
328 else if (
"2012_layer1_up" ==
tune) {
333 else if (
"2012_layer1_down" ==
tune) {
338 else if (
"2012_layer1_errup" ==
tune) {
341 else if (
"2012_layer1_errdown" ==
tune) {
344 else if (
"2012_ps_down" ==
tune) {
349 else if (
"2012_ps_up" ==
tune) {
354 else if (
"2012_ps_errdown" ==
tune) {
357 else if (
"2012_ps_errup" ==
tune) {
360 else if (
"2012_up" ==
tune) {
365 else if (
"2012_down" ==
tune) {
370 else if (
"2012_errup" ==
tune) {
374 else if (
"2012_errdown" ==
tune) {
379 else if (
"2011" ==
tune) {
383 else if(
"2011_with_layer2" ==
tune) {
387 else if (
"2011_alt" ==
tune) {
391 else if(
"2011_alt_with_layer2" ==
tune) {
395 else if (
"2011_layer1_up" ==
tune) {
399 else if (
"2011_layer1_down" ==
tune) {
403 else if (
"2011_layer1_errup" ==
tune) {
406 else if (
"2011_layer1_errdown" ==
tune) {
409 else if (
"2011_ps_down" ==
tune) {
413 else if (
"2011_ps_up" ==
tune) {
417 else if (
"2011_ps_errdown" ==
tune) {
420 else if (
"2011_ps_errup" ==
tune) {
423 else if (
"2011_up" ==
tune) {
427 else if (
"2011_down" ==
tune) {
431 else if (
"2011_errup" ==
tune) {
435 else if (
"2011_errdown" ==
tune) {
440 else if (
"2010" ==
tune) {
444 else if (
"2010_layer1_up" ==
tune) {
448 else if (
"2010_layer1_down" ==
tune) {
452 else if (
"2010_layer1_errup" ==
tune) {
455 else if (
"2010_layer1_errdown" ==
tune) {
458 else if (
"2010_ps_down" ==
tune) {
462 else if (
"2010_ps_up" ==
tune) {
466 else if (
"2010_ps_errdown" ==
tune) {
469 else if (
"2010_ps_errup" ==
tune) {
472 else if (
"2010_up" ==
tune) {
476 else if (
"2010_down" ==
tune) {
480 else if (
"2010_errup" ==
tune) {
484 else if (
"2010_errdown" ==
tune) {
488 else if (
"ps_HV1" ==
tune) {
491 else if (
"ps_EMECHV1" ==
tune) {
494 else if (
"test1" ==
tune) {
495 TH1F h_presampler(
"h_presampler",
"h_presampler", 10, -2.5, 2.5);
498 for (
int ibin = 1; ibin <= 5; ++ibin) {
499 h_presampler.SetBinContent(ibin, -0.1);
500 h_presampler.SetBinContent(ibin + 5, 0.1);
505 else if (
"acc_zee_r22_v0" ==
tune) {
507 TFile
f(
file.c_str());
508 TH2F* histo_acc =
static_cast<TH2F*
>(
f.Get(
"hACC_Zee_rel22"));
513 else if (
"layer1_1" ==
tune) {
514 TFormula
f(
"formula_layer1_1",
"(abs(x)<1.425) ? 0.97 : 1");
517 else if (
"layer1_2" ==
tune) {
518 TFormula
f(
"formula_layer1_2",
"(abs(x)<1.425) ? 0.97 : 1.05");
521 else if (
"layer1_alt_2012_v5" ==
tune) {
523 TFile
f(
file.c_str());
524 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_alt_2012"));
528 else if (
"layer1_2012_v5" ==
tune) {
530 TFile
f(
file.c_str());
531 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2012"));
535 else if (
"layer1_2012_v5_down" ==
tune) {
537 TFile
f(
file.c_str());
538 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2012"));
542 else if (
"layer1_2012_v5_up" ==
tune) {
544 TFile
f(
file.c_str());
545 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2012"));
549 else if (
"layer1_2012_v5_errdown" ==
tune) {
551 TFile
f(
file.c_str());
552 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2012"));
556 else if (
"layer1_2012_v5_errup" ==
tune) {
558 TFile
f(
file.c_str());
559 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2012"));
563 else if (
"layer1_alt_2011_v5" ==
tune) {
565 TFile
f(
file.c_str());
566 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_alt_2011"));
570 else if (
"layer1_2011_v5" ==
tune) {
572 TFile
f(
file.c_str());
573 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2011"));
577 else if (
"layer1_2011_v5_down" ==
tune) {
579 TFile
f(
file.c_str());
580 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2011"));
584 else if (
"layer1_2011_v5_up" ==
tune) {
586 TFile
f(
file.c_str());
587 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2011"));
591 else if (
"layer1_2011_v5_errdown" ==
tune) {
593 TFile
f(
file.c_str());
594 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2011"));
598 else if (
"layer1_2011_v5_errup" ==
tune) {
600 TFile
f(
file.c_str());
601 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2011"));
605 else if (
"layer1_2010_v5" ==
tune) {
607 TFile
f(
file.c_str());
608 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2010"));
612 else if (
"layer1_2010_v5_down" ==
tune) {
614 TFile
f(
file.c_str());
615 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2010"));
619 else if (
"layer1_2010_v5_up" ==
tune) {
621 TFile
f(
file.c_str());
622 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2010"));
626 else if (
"layer1_2010_v5_errdown" ==
tune) {
628 TFile
f(
file.c_str());
629 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2010"));
633 else if (
"layer1_2010_v5_errup" ==
tune) {
635 TFile
f(
file.c_str());
636 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2010"));
640 else if(
"layer2_alt_el_mu_comb_r21_v0"==
tune) {
642 TFile
f(
file.c_str());
643 TH1D*
histo =
static_cast<TH1D*
>(
f.Get(
"hE1E2_emu_run2_rel21_v0"));
648 else if(
"layer2_alt_run2_r21_v1"==
tune) {
650 TFile
f(
file.c_str());
651 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2_mu_run2_rel21_v1"));
655 else if(
"layer2_alt_run2_r21_v0"==
tune) {
657 TFile
f(
file.c_str());
658 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2mu_2016_rel21_v1"));
662 else if(
"layer2_alt_run2_v1" ==
tune) {
664 TFile
f(
file.c_str());
665 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2mu_2016_v1"));
669 else if(
"layer2_alt_2012_v5" ==
tune) {
671 TFile
f(
file.c_str());
672 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_alt_2012"));
676 else if(
"layer2_2012_v5" ==
tune) {
678 TFile
f(
file.c_str());
679 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2012"));
683 else if(
"layer2_2012_v5_down" ==
tune) {
685 TFile
f(
file.c_str());
686 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2012"));
690 else if(
"layer2_2012_v5_up" ==
tune) {
692 TFile
f(
file.c_str());
693 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2012"));
697 else if (
"layer2_2012_v5_errdown" ==
tune) {
699 TFile
f(
file.c_str());
700 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2012"));
704 else if (
"layer2_2012_v5_errup" ==
tune) {
706 TFile
f(
file.c_str());
707 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2012"));
711 else if(
"layer2_alt_2011_v5" ==
tune) {
713 TFile
f(
file.c_str());
714 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_alt_2011"));
718 else if(
"layer2_2011_v5" ==
tune) {
720 TFile
f(
file.c_str());
721 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2011"));
725 else if(
"layer2_2011_v5_down" ==
tune) {
727 TFile
f(
file.c_str());
728 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2011"));
732 else if(
"layer2_2011_v5_up" ==
tune) {
734 TFile
f(
file.c_str());
735 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2011"));
739 else if (
"layer2_2011_v5_errdown" ==
tune) {
741 TFile
f(
file.c_str());
742 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2011"));
746 else if (
"layer2_2011_v5_errup" ==
tune) {
748 TFile
f(
file.c_str());
749 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2011"));
753 else if(
"layer2_2010_v5" ==
tune) {
755 TFile
f(
file.c_str());
756 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2010"));
760 else if(
"layer2_2010_v5_down" ==
tune) {
762 TFile
f(
file.c_str());
763 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2010"));
767 else if(
"layer2_2010_v5_up" ==
tune) {
769 TFile
f(
file.c_str());
770 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2010"));
774 else if (
"layer2_2010_v5_errdown" ==
tune) {
776 TFile
f(
file.c_str());
777 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2010"));
781 else if (
"layer2_2010_v5_errup" ==
tune) {
783 TFile
f(
file.c_str());
784 TH1*
histo = checked_cast<TH1*>(
f.Get(
"hE1E2ave_2010"));
788 else if (
"ps_2016_r21_v0" ==
tune) {
790 TFile
f(
file.c_str());
791 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2016_rel21"));
795 else if (
"ps_mu_r21_v0" ==
tune) {
797 TFile
f(
file.c_str());
798 TH1F* histo_ps_tot_error =
static_cast<TH1F*
>(
f.Get(
"hPS_MuonLowMu_rel21"));
799 assert(histo_ps_tot_error);
803 else if (
"ps_2016_v1" ==
tune) {
805 TFile
f(
file.c_str());
806 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2016"));
810 else if (
"ps_2012_v3" ==
tune) {
812 TFile
f(
file.c_str());
813 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2012"));
817 else if (
"ps_2012_v3_down" ==
tune) {
819 TFile
f(
file.c_str());
820 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2012"));
824 else if (
"ps_2012_v3_up" ==
tune){
826 TFile
f(
file.c_str());
827 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2012"));
831 else if (
"ps_2012_v3_errdown" ==
tune){
833 TFile
f(
file.c_str());
834 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2012"));
838 else if (
"ps_2012_v3_errup" ==
tune){
840 TFile
f(
file.c_str());
841 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2012"));
845 else if (
"ps_2011_v3" ==
tune) {
847 TFile
f(
file.c_str());
848 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2011"));
852 else if (
"ps_2011_v3_down" ==
tune) {
854 TFile
f(
file.c_str());
855 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2011"));
859 else if (
"ps_2011_v3_up" ==
tune){
861 TFile
f(
file.c_str());
862 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2011"));
866 else if (
"ps_2011_v3_errdown" ==
tune){
868 TFile
f(
file.c_str());
869 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2011"));
873 else if (
"ps_2011_v3_errup" ==
tune){
875 TFile
f(
file.c_str());
876 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2011"));
881 else if (
"ps_2010_v3" ==
tune) {
883 TFile
f(
file.c_str());
884 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2010"));
888 else if (
"ps_2010_v3_down" ==
tune) {
890 TFile
f(
file.c_str());
891 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2010"));
895 else if (
"ps_2010_v3_up" ==
tune) {
897 TFile
f(
file.c_str());
898 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2010"));
902 else if (
"ps_2010_v3_errdown" ==
tune){
904 TFile
f(
file.c_str());
905 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2010"));
909 else if (
"ps_2010_v3_errup" ==
tune){
911 TFile
f(
file.c_str());
912 TH1* histo_ps_tot_error = checked_cast<TH1*>(
f.Get(
"hPS_2010"));
917 throw std::runtime_error(
tune+
" is not a valid tune");
922 :
asg::AsgMessaging(
name), m_tune(
tune), m_doSaccCorrections(SaccEnable)
959 std::string fixT =
"";
960 double addE2 = 0, addE3 = 0;
963 fixT =
"_egFixForTopoTimingCut";
964 unsigned short stat =
968 " but some layer info is not available,"
969 " from L2 : " <<
stat%2 <<
" from L3 : " <<
stat/2);
976 eta_calo = cluster->
eta();
982 eta_calo = accEtaCalo(*cluster);
985 ATH_MSG_ERROR(
"etaCalo not available as auxilliary variable,"
986 " using cluster eta as eta calo!");
987 eta_calo=cluster->
eta();
1011 deco_layer_correction(
"layer_correction");
1014 ATH_MSG_DEBUG(
"decorating cluster with corrected layer energies");
1023 deco_layer_correction(*cluster) = isData ?
m_tune+fixT : fixT;
1028 " decorating particle with non-corrected layer energies");
1033 deco_E0(*cluster) = cluster->
energyBE(0);
1034 deco_E1(*cluster) = cluster->
energyBE(1);
1035 deco_E2(*cluster) = cluster->
energyBE(2) + addE2;
1036 deco_E3(*cluster) = cluster->
energyBE(3) + addE3;
1037 deco_layer_correction(*cluster) = isData ?
m_tune +
"_Err" + fixT : fixT;
1054 std::map<std::string, std::string>
parse(
const std::string&
list)
1056 std::cout <<
"list: '" <<
list <<
"'" << std::endl;
1057 std::map<std::string, std::string>
result;
1059 while (TObjString* sObj = (TObjString*)
next())
1061 const TString&
item(sObj->GetString());
1062 std::cout <<
"item: '" <<
item <<
"'" << std::endl;
1063 TObjArray* item_list = TString(
item).Tokenize(
":");
1066 if (item_list->GetEntries() == 1) {
1068 value =
static_cast<TObjString*
>(item_list->At(0))->GetString().Data();
1070 else if (item_list->GetEntries() == 2) {
1071 key =
static_cast<TObjString*
>(item_list->At(0))->GetString().Data();
1072 value =
static_cast<TObjString*
>(item_list->At(1))->GetString().Data();
1075 std::cerr <<
"invalid string " <<
item << std::endl;
1078 std::cerr <<
"trying to insert two times key " <<
key << std::endl;
1087 std::pair<std::string, egammaLayerRecalibTool*>
1090 std::map<std::string, std::string> args_map =
parse(
args);
1092 std::string
name =
"";
1093 std::string amount_name =
"";
1094 std::string type_name =
"";
1099 if (args_map.find(
"amount") != args_map.end()) {
1100 std::string amount_str = args_map[
"amount"];
1102 if (amount_str.back()==
'%') {
1104 amount_str.pop_back();
1106 const float amount = TString(amount_str).Atof() * (
perc ? 0.01 : 1);
1109 std::stringstream amount_stream;
1110 amount_stream << amount;
1111 amount_name = amount_stream.str();
1112 std::replace(amount_name.begin(), amount_name.end(),
'-',
'n');
1113 std::replace(amount_name.begin(), amount_name.end(),
'.',
'p');
1115 else if (args_map.find(
"name") != args_map.end()) {
1116 name = args_map[
"name"];
1118 else if (args_map.find(
"histo") != args_map.end()) {
1120 if (args_map.find(
"file") == args_map.end()) {
1121 std::cerr <<
"with histo you must specify file" << std::endl;
1124 if (args_map.find(
"formulax") != args_map.end())
dim = 1;
1128 std::cerr <<
"with histo you must specify formulax" << std::endl;
1132 TFile
f(args_map[
"file"].c_str());
1133 std::cout <<
"opening histo " << args_map[
"histo"] <<
" from file " << args_map[
"file"] << std::endl;
1134 TH1F*
histo =
dynamic_cast<TH1F*
>(
f.Get(args_map[
"histo"].c_str()));
1137 histo->SetDirectory(
nullptr);
1140 else{assert(
false); }
1142 else { assert(
false); }
1145 std::cerr <<
"cannot understand argument " <<
args << std::endl;
1157 if (not type_name.empty() and not amount_name.empty()) {
1158 name = type_name +
"_" + amount_name;
1162 std::cerr <<
"you need to specify a name for the bias with type " <<
type << std::endl;
1173 if(amount_getter)
delete amount_getter;
virtual double phi() const
The azimuthal angle ( ) of the particle.
float getCorr(int run, float eta, float phi) const
get correction factor to apply to raw EMBPS energy : corrected raw EMBPS energy = correction factor *...
std::string replace(std::string s, const std::string &s2, const std::string &s3)
unsigned short energyInMissingCells(const xAOD::Egamma &eg, double &e2, double &e3)
Get the energies in sampling 2 and 3 that are in cells rejected by the topo-cluster timing cut but th...
constexpr ParticleHypothesis particle[PARTICLEHYPOTHESES]
the array of masses
virtual float operator()(const StdCalibrationInputs &input) const
virtual void shift_inputs(StdCalibrationInputs &, float amount) const
Helper class to provide type-safe access to aux data.
virtual float operator()(const StdCalibrationInputs &inputs) const
corr_pileupShift * m_tool
virtual float operator()(const StdCalibrationInputs &input) const
corr_pileupShift * m_tool
virtual void shift_inputs(StdCalibrationInputs &, float amount) const
virtual float operator()(const StdCalibrationInputs &input) const
virtual float operator()(const StdCalibrationInputs &inputs) const
const uint16_t AuthorFwdElectron
Electron reconstructed by the Forward cluster-based algorithm.
virtual float operator()(const StdCalibrationInputs &input) const
Correction for pileup induced energy shit as function of mu per layer for 2016 data.
@ IS_SIMULATION
true: simulation, false: data
def TH2F(name, title, nxbins, bins_par2, bins_par3, bins_par4, bins_par5=None, bins_par6=None, path='', **kwargs)
virtual void scale_inputs(StdCalibrationInputs &, float amount) const
corr_pileupShift * m_tool
uint32_t runNumber() const
The current event's run number.
virtual void shift_inputs(StdCalibrationInputs &, float amount) const
virtual float operator()(const StdCalibrationInputs &input) const
@ OutOfValidityRange
Input object is out of validity range.
@ Error
Some error happened during the object correction.
Description of a calorimeter cluster.
virtual float operator()(const StdCalibrationInputs &input) const
float getCorr(int layer, int run, float mu, float eta) const
get shift to subtract to raw layer energy : corrected layer energy = raw energy - shift
virtual float operator()(const StdCalibrationInputs &inputs) const
Helper class to provide type-safe access to aux data.
virtual double eta() const
The pseudorapidity ( ) of the particle.
corr_pileupShift * m_tool
virtual float operator()(const StdCalibrationInputs &inputs) const
virtual void scale_inputs(StdCalibrationInputs &, float amount) const
bool retrieveMoment(MomentType type, double &value) const
Retrieve individual moment.
float averageInteractionsPerCrossing() const
Average interactions per crossing for all BCIDs - for out-of-time pile-up.
virtual void shift_inputs(StdCalibrationInputs &, float amount) const
virtual void scale_inputs(StdCalibrationInputs &, float amount) const
virtual void scale_inputs(StdCalibrationInputs &, float amount) const
virtual void shift_inputs(StdCalibrationInputs &, float amount) const
void Tokenize(const std::string &str, std::vector< std::string > &tokens, const std::string &delimiters=" ")
virtual float operator()(const StdCalibrationInputs &input) const
virtual float operator()(const StdCalibrationInputs &input) const
Class describing the basic event information.
std::string PathResolverFindCalibFile(const std::string &logical_file_name)
@ Ok
The correction was done successfully.
virtual float operator()(const StdCalibrationInputs &input) const
virtual void scale_inputs(StdCalibrationInputs &, float amount) const
#define ATH_MSG_WARNING(x)
Return value from object correction CP tools.
float energyBE(const unsigned layer) const
Get the energy in one layer of the EM Calo.
virtual void scale_inputs(StdCalibrationInputs &, float amount) const
virtual void shift_inputs(StdCalibrationInputs &, float amount) const
bool isAvailable(const ELT &e) const
Test to see if this variable exists in the store.
float getCorr(int run, float eta, float phi) const
get correction factor to apply to raw EMECPS energy : corrected raw EMECPS energy = correction factor...
def TH1F(name, title, nxbins, bins_par2, bins_par3=None, path='', **kwargs)
virtual void scale_inputs(StdCalibrationInputs &, float amount) const
virtual float operator()(const StdCalibrationInputs &input) const
@ ETACALOFRAME
Eta in the calo frame (for egamma)
corr_HV_EMECPS m_toolEMECPS
virtual void shift_inputs(StdCalibrationInputs &, float amount) const
std::unique_ptr< TH1 > m_histo
bool eventType(EventType type) const
Check for one particular bitmask value.