| The Gaudi Framework v28r2-patches (bc4ad17a)

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Public Attributes | List of all members
GaudiMP.GMPBase.TESSerializer Class Reference
Inheritance diagram for GaudiMP.GMPBase.TESSerializer:
[legend]
Collaboration diagram for GaudiMP.GMPBase.TESSerializer:
[legend]

## Public Member Functions
def | __init__ (self, gaudiTESSerializer, evtDataSvc, nodeType, nodeID, log)
def | Load (self, tbuf)
def | Dump (self)
def | Report (self)

## Public Attributes
| T
| evt
| buffersIn
| buffersOut
| nIn
| nOut
| tDump
| tLoad
| nodeType
| nodeID
| log

## Detailed Description

Definition at line 313 of file GMPBase.py.

## Constructor & Destructor Documentation

def GaudiMP.GMPBase.TESSerializer.__init__ | ( |  | self,
|  |  | gaudiTESSerializer,
|  |  | evtDataSvc,
|  |  | nodeType,
|  |  | nodeID,
|  |  | log
| ) |  |

Definition at line 315 of file GMPBase.py.

315 nodeType, nodeID, log ) :
316 self.T = gaudiTESSerializer
317 self.evt = evtDataSvc
318 self.buffersIn = []
319 self.buffersOut = []
320 self.nIn = 0
321 self.nOut = 0
322 self.tDump = 0.0
323 self.tLoad = 0.0
324 # logging
325 self.nodeType = nodeType
326 self.nodeID = nodeID
327 self.log = log
GaudiMP.GMPBase.TESSerializer.tLoad
tLoad
Definition: GMPBase.py:323
GaudiMP.GMPBase.TESSerializer.log
log
Definition: GMPBase.py:327
GaudiMP.GMPBase.TESSerializer.buffersOut
buffersOut
Definition: GMPBase.py:319
GaudiMP.GMPBase.TESSerializer.evt
evt
Definition: GMPBase.py:317
GaudiMP.GMPBase.TESSerializer.tDump
tDump
Definition: GMPBase.py:322
GaudiMP.GMPBase.TESSerializer.nodeID
nodeID
Definition: GMPBase.py:326
GaudiMP.GMPBase.TESSerializer.T
T
Definition: GMPBase.py:316
GaudiMP.GMPBase.TESSerializer.nIn
nIn
Definition: GMPBase.py:320
GaudiMP.GMPBase.TESSerializer.nodeType
nodeType
Definition: GMPBase.py:325
GaudiMP.GMPBase.TESSerializer.buffersIn
buffersIn
Definition: GMPBase.py:318
GaudiMP.GMPBase.TESSerializer.nOut
nOut
Definition: GMPBase.py:321

## Member Function Documentation

def GaudiMP.GMPBase.TESSerializer.Dump | ( |  | self | ) |

Definition at line 337 of file GMPBase.py.

337 def Dump( self ) :
338 t = time.time()
339 tb = TBufferFile( TBuffer.kWrite )
340 self.T.dumpBuffer(tb)
341 self.tDump += ( time.time()-t )
342 self.nOut += 1
343 self.buffersOut.append( tb.Length() )
344 return tb
GaudiMP.GMPBase.TESSerializer.tDump
tDump
Definition: GMPBase.py:322
GaudiMP.GMPBase.TESSerializer.Dump
def Dump(self)
Definition: GMPBase.py:337
GaudiMP.GMPBase.TESSerializer.nOut
nOut
Definition: GMPBase.py:321

def GaudiMP.GMPBase.TESSerializer.Load | ( |  | self,
|  |  | tbuf
| ) |  |

Definition at line 328 of file GMPBase.py.

328 def Load( self, tbuf ) :
329 root = gbl.DataObject()
330 setOwnership( root, False )
331 self.evt.setRoot( '/Event', root )
332 t = time.time()
333 self.T.loadBuffer( tbuf )
334 self.tLoad += (time.time() - t)
335 self.nIn += 1
336 self.buffersIn.append( tbuf.Length() )
GaudiMP.GMPBase.TESSerializer.Load
def Load(self, tbuf)
Definition: GMPBase.py:328
GaudiMP.GMPBase.TESSerializer.tLoad
tLoad
Definition: GMPBase.py:323
GaudiMP.GMPBase.TESSerializer.nIn
nIn
Definition: GMPBase.py:320
GaudiPython.Bindings.setOwnership
setOwnership
Definition: Bindings.py:80

def GaudiMP.GMPBase.TESSerializer.Report | ( |  | self | ) |

Definition at line 345 of file GMPBase.py.

345 def Report( self ) :
346 evIn = "Events Loaded : %i"%( self.nIn )
347 evOut = "Events Dumped : %i"%( self.nOut )
348 din = sum( self.buffersIn )
349 dataIn = "Data Loaded : %i"%(din)
350 dataInMb = "Data Loaded (MB) : %5.2f Mb"%(din/MB)
351 if self.nIn :
352 avgIn = "Avg Buf Loaded : %5.2f Mb"\
353 %( din/(self.nIn*MB) )
354 maxIn = "Max Buf Loaded : %5.2f Mb"\
355 %( max(self.buffersIn)/MB )
356 else :
357 avgIn = "Avg Buf Loaded : N/A"
358 maxIn = "Max Buf Loaded : N/A"
359 dout = sum( self.buffersOut )
360 dataOut = "Data Dumped : %i"%(dout)
361 dataOutMb = "Data Dumped (MB) : %5.2f Mb"%(dout/MB)
362 if self.nOut :
363 avgOut = "Avg Buf Dumped : %5.2f Mb"\
364 %( din/(self.nOut*MB) )
365 maxOut = "Max Buf Dumped : %5.2f Mb"\
366 %( max(self.buffersOut)/MB )
367 else :
368 avgOut = "Avg Buf Dumped : N/A"
369 maxOut = "Max Buf Dumped : N/A"
370 dumpTime = "Total Dump Time : %5.2f"%( self.tDump )
371 loadTime = "Total Load Time : %5.2f"%( self.tLoad )
372
373 lines = evIn ,\
374 evOut ,\
375 dataIn ,\
376 dataInMb ,\
377 avgIn ,\
378 maxIn ,\
379 dataOut ,\
380 dataOutMb,\
381 avgOut ,\
382 maxOut ,\
383 dumpTime ,\
384 loadTime
385 self.log.name = "%s-%i TESSerializer"%(self.nodeType, self.nodeID)
386 for line in lines :
387 self.log.info( line )
388 self.log.name = "%s-%i"%(self.nodeType, self.nodeID)
389
390 # =============================================================================
391
GaudiMP.GMPBase.TESSerializer.tLoad
tLoad
Definition: GMPBase.py:323
sum
double sum(double x, double y, double z)
Definition: 3DoubleFuncTest.cpp:25
GaudiMP.GMPBase.TESSerializer.buffersOut
buffersOut
Definition: GMPBase.py:319
GaudiMP.GMPBase.TESSerializer.tDump
tDump
Definition: GMPBase.py:322
GaudiMP.GMPBase.TESSerializer.nodeID
nodeID
Definition: GMPBase.py:326
GaudiMP.GMPBase.TESSerializer.nIn
nIn
Definition: GMPBase.py:320
GaudiMP.GMPBase.TESSerializer.Report
def Report(self)
Definition: GMPBase.py:345
GaudiMP.GMPBase.TESSerializer.nodeType
nodeType
Definition: GMPBase.py:325
GaudiMP.GMPBase.TESSerializer.buffersIn
buffersIn
Definition: GMPBase.py:318
GaudiMP.GMPBase.TESSerializer.nOut
nOut
Definition: GMPBase.py:321

## Member Data Documentation

GaudiMP.GMPBase.TESSerializer.buffersIn

Definition at line 318 of file GMPBase.py.

GaudiMP.GMPBase.TESSerializer.buffersOut

Definition at line 319 of file GMPBase.py.

GaudiMP.GMPBase.TESSerializer.evt

Definition at line 317 of file GMPBase.py.

GaudiMP.GMPBase.TESSerializer.log

Definition at line 327 of file GMPBase.py.

GaudiMP.GMPBase.TESSerializer.nIn

Definition at line 320 of file GMPBase.py.

GaudiMP.GMPBase.TESSerializer.nodeID

Definition at line 326 of file GMPBase.py.

GaudiMP.GMPBase.TESSerializer.nodeType

Definition at line 325 of file GMPBase.py.

GaudiMP.GMPBase.TESSerializer.nOut

Definition at line 321 of file GMPBase.py.

GaudiMP.GMPBase.TESSerializer.T

Definition at line 316 of file GMPBase.py.

GaudiMP.GMPBase.TESSerializer.tDump

Definition at line 322 of file GMPBase.py.

GaudiMP.GMPBase.TESSerializer.tLoad

Definition at line 323 of file GMPBase.py.

The documentation for this class was generated from the following file:

- GaudiMP/python/GaudiMP/GMPBase.py