3 from AthenaCommon.Logging
import logging
4 from AthenaMonitoringKernel.GenericMonitoringTool
import GenericMonitoringTool
5 from AthenaConfiguration.ComponentFactory
import CompFactory
6 from AthenaConfiguration.ComponentAccumulator
import ComponentAccumulator
7 from AthenaConfiguration.AthConfigFlags
import AthConfigFlags
10 hitDVName =
"HLT_HitDV"
16 theHitDVHypo = CompFactory.TrigHitDVHypoAlg(name)
18 from TrigEDMConfig.TriggerEDM
import recordable
21 theHitDVHypo.isMC = flags.Input.isMC
25 HistPath =
'HitDVHypoAlg')
27 monTool.defineHistogram(
'jet_pt', type=
'TH1F', path=
'EXPERT', title=
"p_{T}^{jet} [GeV];p_{T}^{jet} [GeV];Nevents", xbins=50, xmin=0, xmax=200)
28 monTool.defineHistogram(
'jet_eta', type=
'TH1F', path=
'EXPERT', title=
"#eta^{jet};#eta^{jet};Nevents", xbins=50, xmin=-5.0, xmax=5.0)
30 monTool.defineHistogram(
'n_dvtrks', type=
'TH1F', path=
'EXPERT', title=
"Nr of HitDVTrks;N HitDVTrks size;Nevents", xbins=50, xmin=0, xmax=1000)
31 monTool.defineHistogram(
'n_dvsps', type=
'TH1F', path=
'EXPERT', title=
"Nr of HitDVSPs;N HitDVSPs size;Nevents", xbins=50, xmin=0, xmax=100000)
32 monTool.defineHistogram(
'n_jetseeds', type=
'TH1F', path=
'EXPERT', title=
"Nr of Jet Seeds;N jet seeds;Nevents", xbins=25, xmin=0, xmax=25)
33 monTool.defineHistogram(
'n_jetseedsdel', type=
'TH1F', path=
'EXPERT', title=
"Nr of deleted jet seeds;N jet seeds;Nevents", xbins=25, xmin=0, xmax=25)
34 monTool.defineHistogram(
'n_spseeds', type=
'TH1F', path=
'EXPERT', title=
"Nr of Ly6/Ly7 SP-doublet Seeds;N SP seeds;Nevents", xbins=25, xmin=0, xmax=25)
35 monTool.defineHistogram(
'n_spseedsdel', type=
'TH1F', path=
'EXPERT', title=
"Nr of deleted Ly6/Ly7 SP-doublet seeds;N SP seeds;Nevents", xbins=25, xmin=0, xmax=25)
36 monTool.defineHistogram(
'average_mu', type=
'TH1F', path=
'EXPERT', title=
"Average mu;Average mu;Nevents", xbins=50, xmin=0, xmax=100)
41 monTool.defineHistogram(f
'ly{i}_spfr;eta1_ly{i}_spfr', type=
'TH1F', path=
'EXPERT',
42 title=f
"Layer#{i} hit fraction (|#eta|<1);Hit fraction;Nevents",
43 xbins=50, xmin=0.0, xmax=1.0, cutmask=
'cutEta1')
44 monTool.defineHistogram(f
'ly{i}_spfr;1eta2_ly{i}_spfr', type=
'TH1F', path=
'EXPERT',
45 title=f
"Layer#{i} hit fraction (1<|#eta|<2);Hit fraction;Nevents",
46 xbins=50, xmin=0.0, xmax=1.0, cutmask=
'cut1Eta2')
49 monTool.defineHistogram(
'n_qtrk;eta1_n_qtrk', type=
'TH1F', path=
'EXPERT', title=
"Nr of quality tracks (|#eta|<1);Nr of quality tracks;Nevents", xbins=20, xmin=0, xmax=20, cutmask=
'cutEta1')
50 monTool.defineHistogram(
'bdtscore;eta1_bdtscore', type=
'TH1F', path=
'EXPERT', title=
"BDT score (|#eta|<1);BDT score;Nevents", xbins=50, xmin=-1.0, xmax=1.0, cutmask=
'cutEta1')
53 monTool.defineHistogram(
'n_qtrk;1eta2_n_qtrk', type=
'TH1F', path=
'EXPERT', title=
"Nr of quality tracks (1<|#eta|<2);Nr of quality tracks;Nevents", xbins=20, xmin=0, xmax=20, cutmask=
'cut1Eta2')
54 monTool.defineHistogram(
'bdtscore;1eta2_bdtscore', type=
'TH1F', path=
'EXPERT', title=
"BDT score (1<|#eta|<2);BDT score;Nevents", xbins=50, xmin=-1.0, xmax=1.0, cutmask=
'cut1Eta2')
56 theHitDVHypo.MonTool = monTool
57 theHitDVHypo.jFexSRJetRoI =
"L1_jFexSRJetRoI"
59 useNewLayerNumberScheme =
False
60 from TrigFastTrackFinder.TrigFastTrackFinderConfig
import TrigSpacePointConversionToolCfg
62 UseNewLayerScheme=useNewLayerNumberScheme,
63 DoPhiFiltering =
False,
64 UseBeamTilt =
False, ))
66 theHitDVHypo.SpacePointProviderTool = spTool
68 acc.addEventAlgo(theHitDVHypo)
74 log = logging.getLogger(
'TrigHitDVHypoTool')
76 """ Use menu decoded chain dictionary to configure the tool """
77 cparts = [i
for i
in chainDict[
'chainParts']
if i[
'signature']==
'UnconventionalTracking']
78 thresholds =
sum([ [cpart[
'threshold']]*
int(cpart[
'multiplicity'])
for cpart
in cparts], [])
80 name = chainDict[
'chainName']
81 from AthenaConfiguration.ComponentFactory
import CompFactory
82 tool = CompFactory.TrigHitDVHypoTool(name)
88 thresholds = [
float(THR)
for THR
in thresholds]
90 for THR
in thresholds:
91 strThr +=
str(THR)+
", "
93 log.debug(
"Threshold Values are: %s",strThr)
95 tool.cutJetPtGeV = thresholds
102 if cpart[
'IDinfo'] ==
"loose":
103 log.debug(
"Loose ID working point is set")
105 doSPseed.append(
True)
107 elif cpart[
'IDinfo'] ==
"tight":
108 log.debug(
"Tight ID working point is set")
110 doSPseed.append(
False)
113 if cpart[
'IDinfo'] ==
"medium":
114 log.debug(
"Medium ID working point is set")
116 log.info(
"no working point specificed. setting medium working point")
118 doSPseed.append(
False)
121 tool.cutJetEta = jetEta
122 tool.doSPseed = doSPseed