118 def __init__(self, flags, name, monGroups, cpart, tool=None):
120 self.
__log = logging.getLogger(
'TrigEgammaFastCaloHypoTool')
124 self.
__sel =
'ion' if 'ion' in cpart[
'extra']
else (cpart[
'addInfo'][0]
if cpart[
'addInfo']
else cpart[
'IDinfo'])
125 self.
__gsfinfo = cpart[
'gsfInfo']
if cpart[
'trigType']==
'e' and cpart[
'gsfInfo']
else ''
126 self.
__idperfinfo = cpart[
'idperfInfo']
if cpart[
'trigType']==
'e' and cpart[
'idperfInfo']
else ''
133 tool = CompFactory.TrigEgammaFastCaloHypoTool( name )
135 tool.AcceptAll =
False
136 tool.UseRinger =
False
137 tool.EtaBins = [0.0, 0.6, 0.8, 1.15, 1.37, 1.52, 1.81, 2.01, 2.37, 2.47]
139 tool.dETACLUSTERthr = 0.1
140 tool.dPHICLUSTERthr = 0.1
141 tool.F1thr =
same( 0.005 , tool)
142 tool.ET2thr =
same( 90.0*GeV, tool )
143 tool.HADET2thr =
same( 999.0 , tool)
144 tool.HADETthr =
same( 0.058 , tool)
145 tool.WETA2thr =
same( 99999. , tool)
146 tool.WSTOTthr =
same( 99999. , tool)
147 tool.F3thr =
same( 99999. , tool)
148 tool.CARCOREthr =
same( -9999. , tool)
149 tool.CAERATIOthr =
same( -9999. , tool)
219 from TrigEgammaHypo.TrigEgammaFastCutDefs
import TrigFastCaloElectronCutMaps
220 self.
tool().UseRinger =
False
222 self.
tool().HADETthr = TrigFastCaloElectronCutMaps( self.
etthr() ).MapsHADETthr[self.
pidname()]
223 self.
tool().CARCOREthr = TrigFastCaloElectronCutMaps( self.
etthr() ).MapsCARCOREthr[self.
pidname()]
224 self.
tool().CAERATIOthr = TrigFastCaloElectronCutMaps( self.
etthr() ).MapsCAERATIOthr[self.
pidname()]
273 if self.
tool().UseRinger:
275 monTool.defineHistogram(
'Eta', type=
'TH1F', path=
'EXPERT',title=
"#eta of Clusters; #eta; number of RoIs", xbins=50,xmin=-2.5,xmax=2.5)
276 monTool.defineHistogram(
'Phi',type=
'TH1F', path=
'EXPERT',title=
"#phi of Clusters; #phi; number of RoIs", xbins=64,xmin=-3.2,xmax=3.2)
277 monTool.defineHistogram(
'Et',type=
'TH1F', path=
'EXPERT',title=
"E_{T} of Clusters; E_{T} [MeV]; number of RoIs", xbins=60,xmin=0,xmax=5e4)
278 monTool.defineHistogram(
'NNOutput',type=
'TH1F', path=
'EXPERT',title=
"NN Output; NN; Count", xbins=17,xmin=-8,xmax=+8)
280 monTool.HistPath=
'FastCaloL2EgammaHypo/'+self.
__name
281 self.
tool().MonTool=monTool
286 HistPath =
'FastCaloL2EgammaHypo/'+self.
__name)
287 monTool.defineHistogram(
'dEta', type=
'TH1F', path=
'EXPERT', title=
"L2Calo Hypo #Delta#eta_{L2 L1}; #Delta#eta_{L2 L1}",
288 xbins=80, xmin=-0.01, xmax=0.01)
289 monTool.defineHistogram(
'dPhi', type=
'TH1F', path=
'EXPERT', title=
"L2Calo Hypo #Delta#phi_{L2 L1}; #Delta#phi_{L2 L1}",
290 xbins=80, xmin=-0.01, xmax=0.01)
291 monTool.defineHistogram(
'Et_em', type=
'TH1F', path=
'EXPERT', title=
"L2Calo Hypo cluster E_{T}^{EM};E_{T}^{EM} [MeV]",
292 xbins=50, xmin=-2000, xmax=100000)
293 monTool.defineHistogram(
'Eta', type=
'TH1F', path=
'EXPERT', title=
"L2Calo Hypo entries per Eta;Eta", xbins=100, xmin=-2.5, xmax=2.5)
294 monTool.defineHistogram(
'Phi', type=
'TH1F', path=
'EXPERT', title=
"L2Calo Hypo entries per Phi;Phi", xbins=128, xmin=-3.2, xmax=3.2)
296 cuts=[
'Input',
'has one TrigEMCluster',
'#Delta #eta L2-L1',
'#Delta #phi L2-L1',
'eta',
'rCore',
297 'eRatio',
'E_{T}^{EM}',
'E_{T}^{Had}',
'f_{1}',
'Weta2',
'Wstot',
'F3']
299 monTool.defineHistogram(
'CutCounter', type=
'TH1I', path=
'EXPERT', title=
"L2Calo Hypo Passed Cuts;Cut",
300 xbins=13, xmin=-1.5, xmax=12.5, opt=
"kCumulative", xlabels=cuts)
302 if flags.Trigger.doValidationMonitoring:
303 monTool.defineHistogram(
'Et_had', type=
'TH1F', path=
'EXPERT', title=
"L2Calo Hypo E_{T}^{had} in first layer;E_{T}^{had} [MeV]",
304 xbins=50, xmin=-2000, xmax=100000)
305 monTool.defineHistogram(
'RCore', type=
'TH1F', path=
'EXPERT', title=
"L2Calo Hypo R_{core};E^{3x7}/E^{7x7} in sampling 2",
306 xbins=48, xmin=-0.1, xmax=1.1)
307 monTool.defineHistogram(
'Eratio', type=
'TH1F', path=
'EXPERT',
308 title=
"L2Calo Hypo E_{ratio};E^{max1}-E^{max2}/E^{max1}+E^{max2} in sampling 1 (excl.crack)",
309 xbins=64, xmin=-0.1, xmax=1.5)
310 monTool.defineHistogram(
'EtaBin', type=
'TH1I', path=
'EXPERT', title=
"L2Calo Hypo entries per Eta bin;Eta bin no.",
311 xbins=11, xmin=-0.5, xmax=10.5)
312 monTool.defineHistogram(
'F1', type=
'TH1F', path=
'EXPERT', title=
"L2Calo Hypo f_{1};f_{1}", xbins=34, xmin=-0.5, xmax=1.2)
313 monTool.defineHistogram(
'Weta2', type=
'TH1F', path=
'EXPERT', title=
"L2Calo Hypo Weta2; E Width in sampling 2",
314 xbins=96, xmin=-0.1, xmax=0.61)
315 monTool.defineHistogram(
'Wstot', type=
'TH1F', path=
'EXPERT', title=
"L2Calo Hypo Wstot; E Width in sampling 1",
316 xbins=48, xmin=-0.1, xmax=11.)
317 monTool.defineHistogram(
'F3', type=
'TH1F', path=
'EXPERT', title=
"L2Calo Hypo F3; E3/(E0+E1+E2+E3)",
318 xbins=96, xmin=-0.1, xmax=1.1)
321 self.
tool().MonTool = monTool