test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Attributes
pileupParser.pileupParser Class Reference
Inheritance diagram for pileupParser.pileupParser:

Public Member Functions

def __init__
 
def numls
 
def numruns
 
def runs
 
def runsandls
 
def runsandlsStr
 

Private Attributes

 __result
 
 __strresult
 

Detailed Description

Definition at line 3 of file pileupParser.py.

Constructor & Destructor Documentation

def pileupParser.pileupParser.__init__ (   self,
  selectStr 
)

Definition at line 4 of file pileupParser.py.

4 
5  def __init__(self,selectStr):
6  self.__result={}
7  self.__strresult={}
8  strresult=json.loads(selectStr)
9  for k,v in strresult.items():
10 # expandedvalues=[]
11 # print v
12  ldict={}
13  for elems in v:
14  llist = [ elems[1],elems[2],elems[3] ]
15  ldict[int(elems[0])] = llist
16 
17 
18 # for w in v:
19 # if len(w)==0:
20 # self.__result[int(k)]=expandedvalues
21 # self.__strresult[k]=[]
22 # continue
23  ###weed out [10]-like stuff just in case they exist
24 # elif len(w)==1:
25 # expandedvalues.append(w[0])
26  ##weed out [10,10]-like stuff
27 # elif len(w)==2 and w[0]==w[1]:
28 # expandedvalues.append(w[0])
29 # else:
30 # for i in range(w[0],w[1]+1):
31 # expandedvalues.append(i)
32  self.__result[int(k)]=ldict
# self.__strresult[k]=[str(x) for x in expandedvalues]

Member Function Documentation

def pileupParser.pileupParser.numls (   self,
  run 
)

Definition at line 45 of file pileupParser.py.

References pileupParser.pileupParser.__result, csvSelectionParser.csvSelectionParser.__result, csvLumibyLSParser.csvLumibyLSParser.__result, EgammaHLTValidationUtils.EgammaDQMModuleMaker.__result, SequenceTypes._CopyAndExcludeSequenceVisitorOld.__result, and SequenceTypes._MutatingSequenceVisitor.__result.

45 
46  def numls(self,run):
return len(self.__result[run])
def pileupParser.pileupParser.numruns (   self)

Definition at line 43 of file pileupParser.py.

43 
44  def numruns(self):
return len(self.__result.keys())
def pileupParser.pileupParser.runs (   self)

Definition at line 33 of file pileupParser.py.

33 
34  def runs(self):
return self.__result.keys()
def pileupParser.pileupParser.runsandls (   self)
return expanded {run:lslist}

Definition at line 35 of file pileupParser.py.

References pileupParser.pileupParser.__result, csvSelectionParser.csvSelectionParser.__result, csvLumibyLSParser.csvLumibyLSParser.__result, EgammaHLTValidationUtils.EgammaDQMModuleMaker.__result, SequenceTypes._CopyAndExcludeSequenceVisitorOld.__result, and SequenceTypes._MutatingSequenceVisitor.__result.

35 
36  def runsandls(self):
37  '''return expanded {run:lslist}
38  '''
return self.__result
def pileupParser.pileupParser.runsandlsStr (   self)
return expanded {'run':lslist}

Definition at line 39 of file pileupParser.py.

References pileupParser.pileupParser.__strresult, csvSelectionParser.csvSelectionParser.__strresult, and csvLumibyLSParser.csvLumibyLSParser.__strresult.

39 
40  def runsandlsStr(self):
41  '''return expanded {'run':lslist}
42  '''
return self.__strresult

Member Data Documentation

pileupParser.pileupParser.__result
private

Definition at line 5 of file pileupParser.py.

Referenced by selectionParser.selectionParser.numls(), pileupParser.pileupParser.numls(), selectionParser.selectionParser.runsandls(), and pileupParser.pileupParser.runsandls().

pileupParser.pileupParser.__strresult
private

Definition at line 6 of file pileupParser.py.

Referenced by selectionParser.selectionParser.runsandlsStr(), and pileupParser.pileupParser.runsandlsStr().