Definition at line 14 of file LArCondDataDumper.py.
◆ __init__()
def python.LArCondDataDumper.LArCondDataDumper.__init__ |
( |
|
self, |
|
|
|
larCablingSvc, |
|
|
|
outputLevel |
|
) |
| |
Definition at line 15 of file LArCondDataDumper.py.
15 def __init__(self, larCablingSvc, outputLevel) :
16 self.larCablingSvc = larCablingSvc
17 self.outputLevel = outputLevel
◆ getDataMembers()
def python.LArCondDataDumper.LArCondDataDumper.getDataMembers |
( |
|
self, |
|
|
|
obj, |
|
|
|
objName, |
|
|
|
tab = " " |
|
) |
| |
Definition at line 202 of file LArCondDataDumper.py.
202 def getDataMembers(self, obj, objName, tab = " "):
204 if operator.isNumberType(obj):
206 print(tab, objName,
" = ", obj)
210 if objType.__name__ ==
'MethodProxy':
220 if operator.isNumberType(obj):
221 print(
"obj type = ",objType.__name__)
223 print(tab, objName,
" = ", obj)
225 print(
"obj type =",objType.__name__)
228 if objType.__name__.find(
'vector') == 0:
230 elif hasattr(obj,
'begin')
and hasattr(obj,
'end')
and hasattr(obj,
'size'):
237 self.getDataMembers(o, objName +
'_' +
str(i), newTab)
244 for attrName
in attrNames:
246 if attrName.find(
"m_") == 0
or attrName.find(
"get") == 0:
248 attr = getattr(obj, attrName)
250 print(
"Could not get attr", attrName)
251 self.getDataMembers(attr, attrName, newTab)
◆ printAllLArCondData()
def python.LArCondDataDumper.LArCondDataDumper.printAllLArCondData |
( |
|
self, |
|
|
|
ListofType, |
|
|
|
ListofKey |
|
) |
| |
Definition at line 129 of file LArCondDataDumper.py.
129 def printAllLArCondData(self, ListofType, ListofKey):
134 if len(ListofType) != len(ListofKey) :
135 print(
" ERROR: Type and Key not the same length")
140 for i
in range(len(ListofType)):
148 print(
"Cannot get ",typ.__name__,
" Container")
151 self.pyroot_typedef_bug_workaround()
153 container = PyKernel.retrieveDet(typ,key)
157 self.onlineID = container.onlineHelper()
161 caliWave = -1!=key.find(
"CaliWave")
164 for gain
in range(container.minGain(), container.minGain()+container.nGains()):
165 print(
" Accessing ",key,
" gain = ", gain)
169 for obj,id
in container.conditionsIter(gain):
170 ft = self.onlineID.feedthrough_name(id)
172 if ( (
not caliWave)
and (
not obj.isEmpty()) )
or (caliWave
and len(obj)!=0):
174 if self.outputLevel <= 2:
175 str_id1 = self.onlineID.print_to_string(id)
177 if self.larCablingSvc.isOnlineConnected(id) :
178 off_id = self.larCablingSvc.cnvToIdentifier(id)
179 str_id2 = self.onlineID.print_to_string(off_id)
182 print(
" disconnected channel" )
183 self.printLarCondObject(obj)
186 print(n,
" ",key,
" accessed" )
187 keys = FeedThroughs.keys()
189 print(
" Feedthroughs ",keys )
192 print(
" accessing ",key,
" failed ")
193 typ, value, traceBack = sys.exc_info()
195 traceback.print_exc()
◆ printLarCondObject()
def python.LArCondDataDumper.LArCondDataDumper.printLarCondObject |
( |
|
self, |
|
|
|
obj |
|
) |
| |
Definition at line 39 of file LArCondDataDumper.py.
39 def printLarCondObject(self, obj):
42 if -1!=t.find(
"LArRampP"):
44 for obj_i
in obj.m_vRamp:
45 obj_str = obj_str+
str(obj_i)+
' '
46 print(
"ramp = ", obj_str)
49 elif -1!=t.find(
"LArShapeP"):
51 for obj_i
in obj.m_vShape :
52 obj_str = obj_str+
str(obj_i)+
' '
53 print(
"LArShape = ", obj_str)
55 for obj_i
in obj.m_vShapeDer :
56 obj_str = obj_str+
str(obj_i)+
' '
57 print(
"LArShapeDer = ", obj_str)
59 elif -1!=t.find(
"LArPedestalP"):
61 for obj_i
in obj.m_vPedestal:
62 obj_str = obj_str+
str(obj_i)+
' '
63 print(
"Pedestal = ", obj_str)
66 for obj_i
in obj.m_vPedestalRMS:
67 obj_str = obj_str+
str(obj_i)+
' '
68 print(
"PedestalRMS = ", obj_str)
70 elif -1!=t.find(
"LArAutoCorrP"):
72 for obj_i
in obj.m_vAutoCorr:
73 obj_str = obj_str+
str(obj_i)+
' '
74 print(
"AutoCorr = ", obj_str)
76 elif -1!=t.find(
"LArDAC2uAP"):
78 print(
"DAC2uA = ", obj.m_DAC2uA)
80 elif -1!=t.find(
"LArfSamplP"):
82 print(
"fSampl = ", obj.m_fSampl)
84 elif -1!=t.find(
"LAruA2MeVP"):
85 print(
"uA2MeV = ", obj.m_uA2MeV)
87 elif -1!=t.find(
"LArNoiseP") :
88 print(
"Noise = ", obj.m_Noise)
90 elif -1!=t.find(
"LArMinBiasP") :
91 print(
"MinBias = ", obj.m_MinBiasRMS)
93 elif -1!=t.find(
"LArMphysOverMcalP") :
94 print(
"MphysOverMcal = ", obj.m_MphysOverMcal)
96 elif -1!=t.find(
"LArOFCP") :
98 for obj_i
in obj.m_vOFC_a:
99 print(
" delay=",delay)
103 obj_str = obj_str +
str(obj_j) +
' '
104 print(
" OFC_a = ", obj_str)
107 for obj_j
in obj.m_vOFC_b[delay]:
108 obj_str = obj_str +
str(obj_j) +
' '
109 print(
" OFC_b = ", obj_str)
113 elif -1!=t.find(
"LArCaliWaveVec") :
115 print(
" DAC_0 = ", wave.getDAC(),
" Dt=", wave.getDt())
119 for obj_i
in wave.getWave():
120 obj_str = obj_str +
str(i) +
' ' +
str(obj_i) +
' '
122 print(
" Wave = ", obj_str)
◆ pyroot_typedef_bug_workaround()
def python.LArCondDataDumper.LArCondDataDumper.pyroot_typedef_bug_workaround |
( |
|
self | ) |
|
Definition at line 20 of file LArCondDataDumper.py.
20 def pyroot_typedef_bug_workaround(self) :
25 del libPyROOT.const_iterator
26 except AttributeError:
30 del libPyROOT.iterator
31 except AttributeError:
◆ larCablingSvc
python.LArCondDataDumper.LArCondDataDumper.larCablingSvc |
◆ onlineID
python.LArCondDataDumper.LArCondDataDumper.onlineID |
◆ outputLevel
python.LArCondDataDumper.LArCondDataDumper.outputLevel |
The documentation for this class was generated from the following file: