27 def __init__(self):
28 super(DiTauMassBlock, self).__init__()
29 self.addOption('algName', '', type=str,
30 info='optional name to distinguish between multiple instances of the algorithm. The default is `''` (empty string).')
31 self.addOption('electrons', '', type=str,
32 info='the input electron container, with a possible selection, in the format `container` or `container.selection`. The default is `''` (empty string).')
33 self.addOption('muons', '', type=str,
34 info='the input muon container, with a possible selection, in the format `container` or `container.selection`. The default is `''` (empty string).')
35 self.addOption('jets', '', type=str,
36 info='the input jet container, with a possible selection, in the format `container` or `container.selection`. The default is `''` (empty string).')
37 self.addOption('taus', '', type=str,
38 info='the input tau-jet container, with a possible selection, in the format `container` or `container.selection`. The default is `''` (empty string).')
39 self.addOption('met', '', type=str,
40 info='the input MET container. The default is `''` (empty string).')
41 self.addOption('eventSelection', '', type=str,
42 info='optional event filter to run on. The default is `''` (empty string), i.e. all events.')
43 self.addOption('saveExtraVariables', False, type=bool,
44 info='whether to save additional output information from the MMC. The default is `False`.')
45 self.addOption('floatStopCriterion', True, type=bool,
46 info='whether to activate the floating stopping criterion. The default is `True`.')
47 self.addOption('floatStopCriterionMinIter', 10000, type=int,
48 info='minimum number of iteration to activate the floating stopping criterion. The default is 10000.')
49 self.addOption('floatStopCriterionCheckFreq', 1000, type=int,
50 info='event frequency for floating stopping criterion to be checked after minimum number of iteration. The default is 1000.')
51 self.addOption('floatStopCriterionComp', 0.05, type=float,
52 info='percentage used to assess compatibility for floating stopping criterion to be applied. The default is 5%.')
53 self.addOption('calibration', '2024', type=str,
54 info='the calibration set (string) to use. The default is `2024` (recommended).')
55 self.addOption('nSigmaMet', -1, type=int,
56 info='the number (int) of sigmas for the MET resolution scan. The default is `-1` (no scan).')
57 self.addOption('useTailCleanup', -1, type=int,
58 info='whether to activate the tail cleanup feature. The default is -1.')
59 self.addOption('niterFit2', -1, type=int,
60 info='the number of iterations for each MET scan loop. The default is -1.')
61 self.addOption('niterFit3', -1, type=int,
62 info='the number of iterations for each Mnu loop. The default is -1.')
63 self.addOption('useTauProbability', 1, type=int,
64 info='whether to apply tau probability (additional PDF term corresponding to the ratio of the neutrino momentum to the reconstructed tau momentum). The default is 1.')
65 self.addOption('useMnuProbability', False, type=bool,
66 info='whether to apply $m_\nu$ probability (additional PDF term corresponding to the mass of the neutrino system per tau decay, only applied to leptonic tau decays). The default is `False`.')
67 self.addOption('useDefaultSettings', -1, type=int,
68 info='whether to take all default options from the tool itself. The default is -1.')
69 self.addOption('useEfficiencyRecovery', -1, type=int,
70 info='whether to enable refitting for failed events, to improve efficiency. The default is -1.')
71 self.addOption('useMETdphiLL', False, type=bool,
72 info='whether to parameterise the MET resolution using sumET and dphiLL (only for the lep-lep case). The default is `False`.')
73 self.addOption('paramFilePath', 'MMC_params_v051224_angle_noLikelihoodFit.root', type=str,
74 info='path (string) to the ROOT file used with `calibSet` ≥ 2024, containing the PDFs for the likelihood. The default is `MMC_params_v051224_angle_noLikelihoodFit.root` (recommended).')
75 self.addOption('doMLNU3P', False, type=bool,
76 info='save information about the reconstruction with the best-fit neutrino kinematics.')
77 self.addOption('doMAXW', False, type=bool,
78 info='save information about the reconstruction with the maximum-weight estimator.')
79 self.addOption('saveLlhHisto', False, type=bool,
80 info='save likelihood histograms for debugging purpose. If enabled, it can slow down MMC running time.')
81
82 def instanceName (self) :
83 """Return the instance name for this block"""
84 if self.algName:
85 return self.taus.
replace(
'.',
'_') + self.algName
86 else:
87 return self.taus.
replace(
'.',
'_')
88
std::string replace(std::string s, const std::string &s2, const std::string &s3)