|
def | __init__ (self, workerID, queues, events, params, subworkers) |
|
def | processConfiguration (self) |
|
def | Engine (self) |
|
def | getCheckAlgs (self) |
|
def | checkExecutedPassed (self, algName) |
|
def | isEventPassed (self) |
|
def | __init__ (self, nodeType, nodeID, queues, events, params, subworkers) |
|
def | Start (self) |
|
def | Engine (self) |
|
def | processConfiguration (self) |
|
def | SetupGaudiPython (self) |
|
def | StartGaudiPython (self) |
|
def | LoadTES (self, tbufferfile) |
|
def | getEventNumber (self) |
|
def | IdentifyWriters (self) |
|
def | dumpHistograms (self) |
|
def | Initialize (self) |
|
def | Finalize (self) |
|
def | Report (self) |
|
Definition at line 939 of file GMPBase.py.
def GaudiMP.GMPBase.Worker.__init__ |
( |
|
self, |
|
|
|
workerID, |
|
|
|
queues, |
|
|
|
events, |
|
|
|
params, |
|
|
|
subworkers |
|
) |
| |
Definition at line 940 of file GMPBase.py.
940 def __init__( self, workerID, queues, events, params , subworkers ) :
941 GMPComponent.__init__(self,
'Worker', workerID, queues, events, params, subworkers )
946 self.log.name =
"Worker-%i"%(self.
nodeID)
947 self.log.info(
"Worker-%i Created OK"%(self.
nodeID))
def IdentifyWriters(self)
def __init__(self, workerID, queues, events, params, subworkers)
def GaudiMP.GMPBase.Worker.checkExecutedPassed |
( |
|
self, |
|
|
|
algName |
|
) |
| |
Definition at line 1122 of file GMPBase.py.
1123 if self.a.algorithm( algName )._ialg.isExecuted()\
1124 and self.a.algorithm( algName )._ialg.filterPassed() :
def checkExecutedPassed(self, algName)
def GaudiMP.GMPBase.Worker.Engine |
( |
|
self | ) |
|
Definition at line 990 of file GMPBase.py.
995 libc = ctypes.CDLL(
'libc.so.6')
997 libc.prctl(15,name,0,0,0)
999 startEngine = time.time()
1000 self.log.info(
"Worker %i starting Engine"%(self.
nodeID))
1005 self.log.info(
'EVT WRITERS ON WORKER : %i'\
1008 nEventWriters = len( self.
writerDict[
"events" ] )
1013 for item
in m.ItemList :
1014 hsh = item.find(
'#' )
1017 itemList.add( item )
1018 for item
in m.OptItemList :
1019 hsh = item.find(
'#' )
1022 optItemList.add( item )
1024 itemList -= optItemList
1025 for item
in sorted( itemList ):
1026 self.log.info(
' adding ItemList Item to ts : %s' % ( item ) )
1027 self.ts.addItem( item )
1028 for item
in sorted( optItemList ):
1029 self.log.info(
' adding Optional Item to ts : %s' % ( item ) )
1030 self.ts.addOptItem( item )
1032 self.log.info(
'There is no Event Output for this app' )
1038 packet = self.evcom.receive( )
1041 if packet ==
'FINISHED' :
break 1042 evtNumber, tbin = packet
1043 if self.
cntr !=
None:
1044 self.cntr.setEventCounter( evtNumber )
1051 self.log.info(
"Fork new subworkers and disconnect from CondDB")
1052 condDB = self.a.service(
'CondDBCnvSvc', gbl.ICondDBReader)
1061 self.TS.Load( tbin )
1064 sc = self.a.executeEvent()
1068 self.
rTime += (time.time()-t)
1072 self.log.warning(
'Did not Execute Event')
1073 self.evt.clearStore()
1078 self.log.warning(
'Event did not pass : %i'%(evtNumber) )
1079 self.evt.clearStore()
1085 tb = self.TS.Dump( )
1088 self.inc.fireIncident(gbl.Incident(
'Worker',
'EndEvent'))
1089 self.eventLoopSyncer.set()
1090 self.evt.clearStore( )
1091 self.log.info(
'Setting <Last> Event')
1092 self.lastEvent.set()
1094 self.evcom.finalize()
1095 self.log.info(
'Worker-%i Finished Processing Events'%(self.
nodeID) )
1097 self.filerecordsAgent.SendFileRecords()
1103 self.log.info(
'Join subworkers')
def GaudiMP.GMPBase.Worker.getCheckAlgs |
( |
|
self | ) |
|
For some output writers, a check is performed to see if the event has
executed certain algorithms.
These reside in the AcceptAlgs property for those writers
Definition at line 1106 of file GMPBase.py.
1108 For some output writers, a check is performed to see if the event has 1109 executed certain algorithms. 1110 These reside in the AcceptAlgs property for those writers 1116 if hasattr(m.w,
'AcceptAlgs') : acc += m.w.AcceptAlgs
1117 if hasattr(m.w,
'RequireAlgs') : req += m.w.RequireAlgs
1118 if hasattr(m.w,
'VetoAlgs') : vet += m.w.VetoAlgs
1119 return (acc, req, vet)
def GaudiMP.GMPBase.Worker.isEventPassed |
( |
|
self | ) |
|
Check the algorithm status for an event.
Depending on output writer settings, the event
may be declined based on various criteria.
This is a transcript of the check that occurs in GaudiSvc::OutputStream
Definition at line 1129 of file GMPBase.py.
1131 Check the algorithm status for an event. 1132 Depending on output writer settings, the event 1133 may be declined based on various criteria. 1134 This is a transcript of the check that occurs in GaudiSvc::OutputStream 1138 self.log.debug(
'self.acceptAlgs is %s'%(str(self.acceptAlgs)))
1139 if self.acceptAlgs :
1140 for name
in self.acceptAlgs :
1147 self.log.debug(
'self.requireAlgs is %s'%(str(self.requireAlgs)))
1148 for name
in self.requireAlgs :
1152 self.log.info(
'Evt declined (requireAlgs) : %s'%(name) )
1155 self.log.debug(
'self.vetoAlgs is %s'%(str(self.
vetoAlgs)))
1160 self.log.info(
'Evt declined : (vetoAlgs) : %s'%(name) )
def checkExecutedPassed(self, algName)
def GaudiMP.GMPBase.Worker.processConfiguration |
( |
|
self | ) |
|
Definition at line 950 of file GMPBase.py.
956 self.config[
'EventSelector' ].Input = []
957 self.config[
'ApplicationMgr' ].OutStream = []
958 if "HistogramPersistencySvc" in self.config.keys() :
959 self.config[
'HistogramPersistencySvc' ].OutputFile =
'' 960 formatHead =
'[Worker-%i] '%(self.
nodeID)
961 self.config[
'MessageSvc'].Format = formatHead+
'% F%18W%S%7W%R%T %0W%M' 963 for key, lst
in self.writerDict.iteritems() :
964 self.log.info(
'Writer Type : %s\t : %i'%(key, len(lst)) )
969 newName = m.getNewName(
'.',
'.w%i.'%(self.
nodeID) )
970 self.config[ m.key ].Output = newName
980 if "ToolSvc.EvtCounter" not in self.config:
981 from Configurables
import EvtCounter
982 counter = EvtCounter()
984 counter = self.config[
"ToolSvc.EvtCounter"]
985 counter.UseIncident =
False 988 self.log.warning(
'Cannot configure EvtCounter')
def processConfiguration(self)
GaudiMP.GMPBase.Worker.app |
GaudiMP.GMPBase.Worker.currentEvent |
GaudiMP.GMPBase.Worker.eventOutput |
GaudiMP.GMPBase.Worker.filerecordsAgent |
GaudiMP.GMPBase.Worker.firstEvTime |
GaudiMP.GMPBase.Worker.nIn |
GaudiMP.GMPBase.Worker.tTime |
GaudiMP.GMPBase.Worker.vetoAlgs |
GaudiMP.GMPBase.Worker.writerDict |
The documentation for this class was generated from the following file: