MCPcopy Index your code
hub / github.com/tensorpack/tensorpack / _before_run

Method _before_run

tensorpack/callbacks/base.py:123–130  ·  view source on GitHub ↗

It is called before every ``hooked_sess.run()`` call, and it registers some extra op/tensors to run in the next call. This method is the same as ``tf.train.SessionRunHook.before_run``. Refer to TensorFlow docs for more details.

(self, ctx)

Source from the content-addressed store, hash-verified

121 return tf.train.SessionRunArgs(fetches=ret)
122
123 def _before_run(self, ctx):
124 """
125 It is called before every ``hooked_sess.run()`` call, and it
126 registers some extra op/tensors to run in the next call.
127 This method is the same as ``tf.train.SessionRunHook.before_run``.
128 Refer to TensorFlow docs for more details.
129 """
130 return None
131
132 def after_run(self, run_context, run_values):
133 self._after_run(run_context, run_values)

Callers 2

before_runMethod · 0.95
_before_runMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected