MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / testInitOp

Method testInitOp

tensorflow/python/training/supervisor_test.py:511–518  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

509
510 @test_util.run_v1_only("b/120545219")
511 def testInitOp(self):
512 logdir = self._test_dir("default_init_op")
513 with ops.Graph().as_default():
514 v = variables.VariableV1([1.0, 2.0, 3.0])
515 sv = supervisor.Supervisor(logdir=logdir)
516 sess = sv.prepare_or_wait_for_session("")
517 self.assertAllClose([1.0, 2.0, 3.0], sess.run(v))
518 sv.stop()
519
520 @test_util.run_v1_only("b/120545219")
521 def testInitFn(self):

Callers

nothing calls this directly

Calls 7

_test_dirMethod · 0.95
stopMethod · 0.95
as_defaultMethod · 0.45
GraphMethod · 0.45
assertAllCloseMethod · 0.45
runMethod · 0.45

Tested by

no test coverage detected