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

Method testSharedName

tensorflow/python/training/input_test.py:772–787  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

770
771 @test_util.run_deprecated_v1
772 def testSharedName(self):
773 with self.cached_session():
774 batch_size = 10
775 num_batches = 3
776 zero64 = constant_op.constant(0, dtype=dtypes.int64)
777 examples = variables.Variable(zero64)
778 counter = examples.count_up_to(num_batches * batch_size)
779 batched = inp.batch(
780 [counter, "string"],
781 batch_size=batch_size,
782 shared_name="SHARED_NAME_XYZ",
783 name="Q")
784
785 self.assertProtoEquals(
786 "s: 'SHARED_NAME_XYZ'",
787 batched[0].op.inputs[0].op.node_def.attr["shared_name"])
788
789 @test_util.run_deprecated_v1
790 def testCannotInferRankError(self):

Callers

nothing calls this directly

Calls 6

count_up_toMethod · 0.95
VariableMethod · 0.80
assertProtoEqualsMethod · 0.80
cached_sessionMethod · 0.45
constantMethod · 0.45
batchMethod · 0.45

Tested by

no test coverage detected