CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
pileupParser.pileupParser Class Reference
Inheritance diagram for pileupParser.pileupParser:

Public Member Functions

def __init__ (self, selectStr)
 
def numls (self, run)
 
def numruns (self)
 
def runs (self)
 
def runsandls (self)
 
def runsandlsStr (self)
 

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

Member Function Documentation

def pileupParser.pileupParser.numls (   self,
  run 
)
def pileupParser.pileupParser.numruns (   self)

Definition at line 43 of file pileupParser.py.

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

Definition at line 33 of file pileupParser.py.

33  def runs(self):
34  return self.__result.keys()
def pileupParser.pileupParser.runsandls (   self)
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  def runsandlsStr(self):
40  '''return expanded {'run':lslist}
41  '''
42  return self.__strresult

Member Data Documentation

pileupParser.pileupParser.__result
private
pileupParser.pileupParser.__strresult
private