Definition at line 5 of file GoodRunsListConfig.py.
◆ __init__()
def python.GoodRunsListConfig.GoodRunsListConfig.__init__ |
( |
|
self | ) |
|
Definition at line 6 of file GoodRunsListConfig.py.
8 self.name =
"GoodRunsListConfig"
9 self.querytool =
"AtlRunQuery.py"
10 self.listname =
"default.xml"
13 self.dqfolder =
"DEFECTS"
18 self.querydict[
'partition'] = [
"ATLAS"]
19 self.querydict[
'ptag'] = [
"data09*"]
21 self.querydict[
'run'] = [
"140541+"]
23 self.querydict[
'time'] = []
24 self.querydict[
'detector'] = []
25 self.querydict[
'streams'] = []
26 self.querydict[
'mag'] = []
27 self.querydict[
'dq'] = []
28 self.querydict[
'smk'] = []
29 self.querydict[
'trigger'] = []
30 self.querydict[
'release'] = []
32 self.querydict[
'db'] = [
'DATA']
◆ getctag()
def python.GoodRunsListConfig.GoodRunsListConfig.getctag |
( |
|
self | ) |
|
◆ getdqfolder()
def python.GoodRunsListConfig.GoodRunsListConfig.getdqfolder |
( |
|
self | ) |
|
◆ getparseddqflags()
def python.GoodRunsListConfig.GoodRunsListConfig.getparseddqflags |
( |
|
self | ) |
|
Definition at line 76 of file GoodRunsListConfig.py.
76 def getparseddqflags(self):
77 from CoolRunQuery.AtlRunQueryLib
import DQSelector,AtlRunQueryOptions
78 from CoolRunQuery.AtlRunQueryParser
import ArgumentParser
81 query = self.getsearchquery()
83 atlqueryarg = self.querytool +
" " + ap.ParseArgument( query )
84 (options, args) = AtlRunQueryOptions().
parse(atlqueryarg)
87 selector = DQSelector(name =
'dataquality', dq = options.dqchannels)
88 dqfolder = self.getdqfolder()
91 dqconfig = selector.selectors[dqfolder]
92 for flag
in dqconfig.flags:
93 fncName = dqconfig.flagInterpreter[flag][
'passFncName']
94 fncName = fncName.replace(
"\'",
"")
95 funcArr.append(fncName)
100 dqchannels = options.dqchannels
101 for i
in range(len(dqchannels)):
102 dqArr = dqchannels[i].
split()
103 dqArr[1] = funcArr[i]
104 dqchannels[i] =
' '.
join(dqArr)
◆ getsearchquery()
def python.GoodRunsListConfig.GoodRunsListConfig.getsearchquery |
( |
|
self | ) |
|
Definition at line 47 of file GoodRunsListConfig.py.
47 def getsearchquery(self):
50 for key
in self.querydict.
keys():
51 arr = self.querydict[key][:]
53 if len(self.dqignore) > 0:
54 toexclude =
'\\' +
'\\'.
join(self.dqignore)
57 print (
'to exclude', toexclude)
58 for i, q
in enumerate(arr):
61 arr[i] =
' '.
join([qsplit[0] + toexclude] + qsplit[1:])
64 cmd +=
"%s %s and " % (key,selection)
68 cmd +=
" %s" % (self.show)
69 else: cmd +=
" / show run and events / nodef"
71 xmlstring =
'xmlfile %s:%s' % (self.listname,self.name)
72 cmd +=
" , %s" % (xmlstring)
◆ setctag()
def python.GoodRunsListConfig.GoodRunsListConfig.setctag |
( |
|
self, |
|
|
|
ctag |
|
) |
| |
Definition at line 147 of file GoodRunsListConfig.py.
147 def setctag(self,ctag):
148 if len(ctag)>0: self.querydict[
'ctag'] = ctag
◆ setdqctag()
def python.GoodRunsListConfig.GoodRunsListConfig.setdqctag |
( |
|
self, |
|
|
|
dqctag |
|
) |
| |
Definition at line 130 of file GoodRunsListConfig.py.
130 def setdqctag(self,dqctag):
131 if len(dqctag)==0:
return
132 for idx
in range( len(self.querydict[
'dq']) ):
133 dqquery = self.querydict[
'dq'][idx].strip()
134 queryArr = dqquery.split()
137 ctagArr = queryArr[1].
split(
'#')
138 queryArr[1] =
'%s#%s' % (ctagArr[0],dqctag)
140 elif len(queryArr)==2:
141 dqfoldtag =
'%s#%s' % (self.dqfolder,dqctag)
142 queryArr.insert(1,dqfoldtag)
143 dqquery =
'%s %s %s' % (queryArr[0],queryArr[1],queryArr[2])
144 self.querydict[
'dq'][idx] = dqquery
◆ setdqfolder()
def python.GoodRunsListConfig.GoodRunsListConfig.setdqfolder |
( |
|
self, |
|
|
|
dqfolder = '' |
|
) |
| |
Definition at line 112 of file GoodRunsListConfig.py.
112 def setdqfolder(self,dqfolder=''):
113 if len(dqfolder)>0: self.dqfolder = dqfolder
114 for idx
in range( len(self.querydict[
'dq']) ):
115 dqquery = self.querydict[
'dq'][idx].strip()
116 queryArr = dqquery.split()
119 ctagArr = queryArr[1].
split(
'#')
121 queryArr[1] =
'%s#%s' % (self.dqfolder,ctagArr[1])
122 else: queryArr[1] = self.dqfolder
124 elif len(queryArr)==2:
125 queryArr.insert(1,self.dqfolder)
126 dqquery =
'%s %s %s' % (queryArr[0],queryArr[1],queryArr[2])
127 self.querydict[
'dq'][idx] = dqquery
◆ setPrefix()
def python.GoodRunsListConfig.GoodRunsListConfig.setPrefix |
( |
|
self, |
|
|
|
newprefix |
|
) |
| |
Definition at line 153 of file GoodRunsListConfig.py.
153 def setPrefix(self,newprefix):
154 self.prefix = newprefix
155 self.listname = self.prefix+self.listname
◆ Summary()
def python.GoodRunsListConfig.GoodRunsListConfig.Summary |
( |
|
self | ) |
|
Definition at line 36 of file GoodRunsListConfig.py.
37 print (
'Name : %s' % (self.name))
38 print (
'Tool : %s' % (self.querytool))
39 print (
'File : %s' % (self.listname))
40 print (
'Show : %s' % (self.show))
41 print (
'DQ folder : %s' % (self.dqfolder))
43 print (self.getsearchquery())
◆ dqfolder
python.GoodRunsListConfig.GoodRunsListConfig.dqfolder |
◆ dqignore
python.GoodRunsListConfig.GoodRunsListConfig.dqignore |
◆ listname
python.GoodRunsListConfig.GoodRunsListConfig.listname |
◆ name
python.GoodRunsListConfig.GoodRunsListConfig.name |
◆ prefix
python.GoodRunsListConfig.GoodRunsListConfig.prefix |
◆ querydict
python.GoodRunsListConfig.GoodRunsListConfig.querydict |
◆ querytool
python.GoodRunsListConfig.GoodRunsListConfig.querytool |
◆ show
python.GoodRunsListConfig.GoodRunsListConfig.show |
The documentation for this class was generated from the following file: