aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/contrib/autograph
diff options
context:
space:
mode:
authorGravatar Dan Moldovan <mdan@google.com>2018-08-06 11:59:27 -0700
committerGravatar TensorFlower Gardener <gardener@tensorflow.org>2018-08-06 12:04:06 -0700
commit1282e2b6fbb5f3ce9745402922a84291786ec62d (patch)
treebfcae759c3848e260fadefbc26d9789355b81f8d /tensorflow/contrib/autograph
parent4325fcc4b8291df72687f3ab83808ed1b3142c90 (diff)
Expose tf_if_stmt to other modules.
PiperOrigin-RevId: 207583781
Diffstat (limited to 'tensorflow/contrib/autograph')
-rw-r--r--tensorflow/contrib/autograph/operators/control_flow.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tensorflow/contrib/autograph/operators/control_flow.py b/tensorflow/contrib/autograph/operators/control_flow.py
index 988df70157..be38d3f534 100644
--- a/tensorflow/contrib/autograph/operators/control_flow.py
+++ b/tensorflow/contrib/autograph/operators/control_flow.py
@@ -212,12 +212,12 @@ def if_stmt(cond, body, orelse):
Tuple containing the statement outputs.
"""
if tensor_util.is_tensor(cond):
- return _tf_if_stmt(cond, body, orelse)
+ return tf_if_stmt(cond, body, orelse)
else:
return _py_if_stmt(cond, body, orelse)
-def _tf_if_stmt(cond, body, orelse):
+def tf_if_stmt(cond, body, orelse):
"""Overload of if_stmt that stages a TF cond."""
return control_flow_ops.cond(cond, body, orelse)