GaudiMP.GMPBase.TESSerializer Class Reference
Inheritance diagram for GaudiMP.GMPBase.TESSerializer:
Collaboration diagram for GaudiMP.GMPBase.TESSerializer:

Public Member Functions

def __init__ (self, gaudiTESSerializer, evtDataSvc, nodeType, nodeID, log)
 
def Load (self, tbuf)
 
def Dump (self)
 
def Report (self)
 
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.

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

Definition at line 315 of file GMPBase.py.

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
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
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() )
def Load(self, tbuf)
Definition: GMPBase.py:328
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() )
def Load(self, tbuf)
Definition: GMPBase.py:328
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 
double sum(double x, double y, double z)
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 
double sum(double x, double y, double z)

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: