Definition at line 9 of file AtlCoolTriggerTool.py.
◆ __init__()
def python.AtlCoolTriggerTool.AtlCoolTriggerTool.__init__ |
( |
|
self, |
|
|
|
options = {} |
|
) |
| |
◆ check_options()
def python.AtlCoolTriggerTool.AtlCoolTriggerTool.check_options |
( |
|
self | ) |
|
Definition at line 19 of file AtlCoolTriggerTool.py.
19 def check_options(self):
21 if opt.l1
and not opt.menu:
22 print (
"Option l1 requires option 'menu' to be set")
25 if opt.l2
and not opt.menu:
26 print (
"Option l2 requires option 'menu' to be set")
29 if opt.ef
and not opt.menu:
30 print (
"Option ef requires option 'menu' to be set")
33 if opt.processing
and opt.processing!=
'hlt':
34 print (
"Option p|processing must be set to 'hlt'")
37 if opt.menu
and not (opt.l1
or opt.l2
or opt.ef):
38 opt.l1 = opt.l2 = opt.ef =
True
◆ execute()
def python.AtlCoolTriggerTool.AtlCoolTriggerTool.execute |
( |
|
self | ) |
|
Definition at line 161 of file AtlCoolTriggerTool.py.
162 (runs, configKeys) = self.getConfigKeys()
164 if self.opt.processing==
'hlt':
165 self.printHLTProcessingString(configKeys)
168 self.printConfigKeys(configKeys)
170 self.opt.isSingleRun = len(runs)==1
172 if self.opt.menu
and not self.opt.isSingleRun:
173 print (
"Error: option 'menu' works only for single run")
176 if self.opt.streams
and not self.opt.isSingleRun:
177 print (
"Error: option 'streams' works only for single run")
180 if self.opt.isSingleRun:
181 self.printMenu(runs[0])
182 self.printStreams(runs[0])
◆ getConfigKeys()
def python.AtlCoolTriggerTool.AtlCoolTriggerTool.getConfigKeys |
( |
|
self | ) |
|
Definition at line 76 of file AtlCoolTriggerTool.py.
77 hltkeys = TriggerCoolUtil.getHLTConfigKeys(self.dbconn, self.runlist)
78 hltpskeys = TriggerCoolUtil.getHLTPrescaleKeys(self.dbconn, self.runlist)
79 l1keys = TriggerCoolUtil.getL1ConfigKeys(self.dbconn, self.runlist)
85 runStartTimes = TriggerCoolUtil.getRunStartTime(self.dbconn, self.runlist, runs)
87 allkeys = dict([(r,{})
for r
in runs])
89 if r
in hltkeys: allkeys[r].
update(hltkeys[r])
90 if r
in hltpskeys: allkeys[r].
update(hltpskeys[r])
91 if r
in l1keys: allkeys[r].
update(l1keys[r])
92 if runStartTimes
and r
in runStartTimes: allkeys[r].
update(runStartTimes[r])
94 return (runs, allkeys)
◆ GetRunRanges()
def python.AtlCoolTriggerTool.AtlCoolTriggerTool.GetRunRanges |
( |
|
self, |
|
|
|
runRange |
|
) |
| |
Definition at line 56 of file AtlCoolTriggerTool.py.
56 def GetRunRanges(self, runRange):
58 runRanges = runRange.split(
',')
60 startend = rr.split(
'-')
61 if len(startend)==1: startend += [startend[0]]
62 firstlast = [0, (cool.ValidityKeyMax>>32)-1]
63 if startend[0]: firstlast[0] =
int(startend[0])
64 if startend[1]: firstlast[1] =
int(startend[1])
66 listOfRanges += [firstlast]
68 return self.MergeRanges(listOfRanges)
◆ init()
def python.AtlCoolTriggerTool.AtlCoolTriggerTool.init |
( |
|
self | ) |
|
Definition at line 71 of file AtlCoolTriggerTool.py.
72 self.runlist = self.GetRunRanges(self.opt.runlist)
73 self.dbconn = TriggerCoolUtil.GetConnection(self.opt.db,self.opt.verbosity)
◆ MergeRanges()
def python.AtlCoolTriggerTool.AtlCoolTriggerTool.MergeRanges |
( |
|
self, |
|
|
|
listOfRanges |
|
) |
| |
Definition at line 43 of file AtlCoolTriggerTool.py.
45 for rr
in listOfRanges:
47 newRR.append(copy.deepcopy(rr))
49 if rr[0]-1<=newRR[-1][1]:
50 newRR[-1][1] =
max(rr[1],newRR[-1][1])
52 newRR.append(copy.deepcopy(rr))
◆ printConfigKeys()
def python.AtlCoolTriggerTool.AtlCoolTriggerTool.printConfigKeys |
( |
|
self, |
|
|
|
runKeys |
|
) |
| |
Definition at line 105 of file AtlCoolTriggerTool.py.
105 def printConfigKeys(self, runKeys):
114 try: timestr =
"(%s) " % keys[
"STARTTIME"]
115 except KeyError: timestr =
"(--------unknown---------) "
119 hltpsk =
"%4i (1-)" % keys[
"HLTPSK"]
128 if "HLTPSK2" in keys:
129 for x
in keys[
"HLTPSK2"]:
130 if x[2]<0: hltpsknew +=
"%4i (%i-)" % (x[0],x[1])
131 elif x[2]==x[1]: hltpsknew +=
"%4i (%i) " % (x[0],x[1])
132 else: hltpsknew +=
"%4i (%i-%i) " % (x[0],x[1],x[2])
133 if not hltpsknew: hltpsknew =
"unknown"
136 if "LVL1PSK" in keys:
137 for x
in keys[
"LVL1PSK"]:
138 if x[2]<0: lvl1psk +=
"%4i (%i-)" % (x[0],x[1])
139 elif x[2]==x[1]: lvl1psk +=
"%4i (%i) " % (x[0],x[1])
140 else: lvl1psk +=
"%4i (%i-%i) " % (x[0],x[1],x[2])
141 if not lvl1psk: lvl1psk =
"unknown"
143 print (
"run %6i %srelease %9s smk %4s hltps %s lvl1ps %s" % (r, timestr, rel, smk, hltpsknew, lvl1psk),)
145 if r > 127453
and "HLTPSK2" in keys
and "HLTPSK" in keys
and keys[
"HLTPSK"] != keys[
"HLTPSK2"][0][0]:
146 msg =
"WARNING: Menu folder shows different HLT prescale for SOR: %i" % keys[
"HLTPSK"]
◆ printHLTProcessingString()
def python.AtlCoolTriggerTool.AtlCoolTriggerTool.printHLTProcessingString |
( |
|
self, |
|
|
|
runKeys |
|
) |
| |
Definition at line 96 of file AtlCoolTriggerTool.py.
96 def printHLTProcessingString(self,runKeys):
103 print (
'c'.
join([
"%su%s" % (x[1],x[0])
for x
in keys[
"HLTPSK2"]]))
◆ printMenu()
def python.AtlCoolTriggerTool.AtlCoolTriggerTool.printMenu |
( |
|
self, |
|
|
|
run |
|
) |
| |
Definition at line 150 of file AtlCoolTriggerTool.py.
150 def printMenu(self, run):
151 if not self.opt.menu:
return
153 TriggerCoolUtil.printL1Menu(self.dbconn, run, self.opt.verbosity)
154 if self.opt.l2
or self.opt.ef:
155 TriggerCoolUtil.printHLTMenu(self.dbconn, run, self.opt.verbosity, printL2=self.opt.l2, printEF=self.opt.ef)
◆ printStreams()
def python.AtlCoolTriggerTool.AtlCoolTriggerTool.printStreams |
( |
|
self, |
|
|
|
run |
|
) |
| |
Definition at line 157 of file AtlCoolTriggerTool.py.
157 def printStreams(self,run):
158 if not self.opt.streams:
return
159 TriggerCoolUtil.printStreams(self.dbconn,run,self.opt.verbosity)
◆ dbconn
python.AtlCoolTriggerTool.AtlCoolTriggerTool.dbconn |
◆ opt
python.AtlCoolTriggerTool.AtlCoolTriggerTool.opt |
◆ runlist
python.AtlCoolTriggerTool.AtlCoolTriggerTool.runlist |
The documentation for this class was generated from the following file:
constexpr std::enable_if_t< is_bitmask_v< E >, E & > set(E &lhs, E rhs)
Convenience function to set bits in a class enum bitmask.