MCPcopy Create free account
hub / github.com/alibaba/euler / __init__

Method __init__

tf_euler/python/utils/hooks.py:26–31  ·  view source on GitHub ↗
(self, num_workers)

Source from the content-addressed store, hash-verified

24
25class SyncExitHook(tf.train.SessionRunHook):
26 def __init__(self, num_workers):
27 self._num_workers = num_workers
28 self._num_finished_workers = tf.Variable(
29 0, name="num_finished_workers")
30 self._finish_self = tf.assign_add(
31 self._num_finished_workers, 1, use_locking=True)
32
33 def end(self, session):
34 session.run(self._finish_self)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected