Definition at line 628 of file pTools.py.
◆ __init__()
def GaudiMP.pTools.Syncer.__init__ |
( |
|
self, |
|
|
|
nWorkers, |
|
|
|
log, |
|
|
|
manyEvents = False , |
|
|
|
limit = None , |
|
|
|
step = None , |
|
|
|
firstEvent = None |
|
) |
| |
Definition at line 629 of file pTools.py.
630 self, nWorkers, log, manyEvents=False, limit=None, step=None, firstEvent=None
636 self.manyEvents = manyEvents
638 for i
in range(-2, nWorkers):
639 self.d[i] = SyncMini(Event(), lastEvent=Event())
641 self.limitFirst = firstEvent
643 self.keys = list(self.d.
keys())
644 self.nWorkers = nWorkers
◆ checkAll()
def GaudiMP.pTools.Syncer.checkAll |
( |
|
self | ) |
|
Definition at line 735 of file pTools.py.
738 currentStatus = [mini.check()
for mini
in self.d.values()]
739 return all(currentStatus)
◆ checkLastEvents()
def GaudiMP.pTools.Syncer.checkLastEvents |
( |
|
self | ) |
|
Definition at line 741 of file pTools.py.
741 def checkLastEvents(self):
743 stat = [sMini.checkLast()
for sMini
in self.d.values()]
◆ processHang()
def GaudiMP.pTools.Syncer.processHang |
( |
|
self | ) |
|
Definition at line 729 of file pTools.py.
729 def processHang(self):
730 self.log.critical(
"Some proc is hanging during Event processing!")
732 self.log.critical(
"Proc/Stat : %i / %s" % (k, self.d[k].
check()))
◆ syncAll()
def GaudiMP.pTools.Syncer.syncAll |
( |
|
self, |
|
|
|
step = "Not specified" |
|
) |
| |
Definition at line 647 of file pTools.py.
647 def syncAll(self, step="Not specified"):
652 sc = self.syncAllRolling()
656 for i
in range(0, self.limit, self.step):
658 self.log.info(
"%s : All procs done @ %i s" % (step, i))
661 time.sleep(self.step)
665 self.log.info(
"All processes : %s ok." % (step))
668 self.log.critical(
"Some process is hanging on : %s" % (step))
670 hangString =
"%s : Proc/Stat : %i/%s" % (step, k, self.d[k].
check())
671 self.log.critical(hangString)
◆ syncAllRolling()
def GaudiMP.pTools.Syncer.syncAllRolling |
( |
|
self | ) |
|
Definition at line 674 of file pTools.py.
674 def syncAllRolling(self):
696 if sMini.check()
or sMini.checkLast():
697 if sMini.checkLast()
and sMini.check():
700 alive = time.time() - begin
701 self.log.info(
"Audit : Node %i alive for %5.2f" % (k, alive))
707 wait = time.time() - sMini.getTime()
708 cond = wait > self.limit
710 cond = wait > self.limitFirst
714 self.log.critical(
"Single event wait : %5.2f" % (wait))
719 if self.checkLastEvents():
720 self.log.info(
"TC met for event loop")
724 time.sleep(self.step)
726 self.log.info(
"All processes Completed all Events ok")
◆ keys
GaudiMP.pTools.Syncer.keys |
◆ limit
GaudiMP.pTools.Syncer.limit |
◆ limitFirst
GaudiMP.pTools.Syncer.limitFirst |
◆ log
GaudiMP.pTools.Syncer.log |
◆ manyEvents
GaudiMP.pTools.Syncer.manyEvents |
◆ nWorkers
GaudiMP.pTools.Syncer.nWorkers |
◆ step
GaudiMP.pTools.Syncer.step |
The documentation for this class was generated from the following file: