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

Method BuildWhile

tensorflow/python/kernel_tests/while_v2_test.py:100–106  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

98
99 @def_function.function
100 def BuildWhile():
101 x = constant_op.constant(1., dtypes.float32)
102
103 def Body(x):
104 return math_ops.cast(x, dtypes.float16) + 1
105
106 while_loop_v2(lambda x: x < 10, Body, [x])
107
108 with self.assertRaisesRegexp(
109 TypeError,

Callers

nothing calls this directly

Calls 2

while_loop_v2Function · 0.85
constantMethod · 0.45

Tested by

no test coverage detected