diff options
author | Jiri Simsa <jsimsa@google.com> | 2018-10-03 12:32:57 -0700 |
---|---|---|
committer | TensorFlower Gardener <gardener@tensorflow.org> | 2018-10-03 12:41:53 -0700 |
commit | d4e9282dc53697432178a68940634612c4ab2baa (patch) | |
tree | 7a9a07b42bb028b8bec0804e33113363585547c6 /tensorflow/python/data | |
parent | 295b3c80555cc82d8d70faf96a47681e1d904b9c (diff) |
[tf.data] Fix noisy warning.
PiperOrigin-RevId: 215607171
Diffstat (limited to 'tensorflow/python/data')
-rw-r--r-- | tensorflow/python/data/ops/dataset_ops.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/tensorflow/python/data/ops/dataset_ops.py b/tensorflow/python/data/ops/dataset_ops.py index 46ce191f7b..b7e19055f2 100644 --- a/tensorflow/python/data/ops/dataset_ops.py +++ b/tensorflow/python/data/ops/dataset_ops.py @@ -1831,9 +1831,10 @@ class StructuredFunctionWrapper(object): flat_classes.append(component) flat_shapes.append(component) flat_types.append(component) - if t.options() is not None: # pylint: disable=protected-access - warnings.warn("Encountered a nested dataset with options. These " - "options will not be applied to the outer dataset.") + if t.options() != Options(): + warnings.warn("Encountered a nested dataset with non-default " + "options. These options will not be propagated to " + "the outer dataset.") else: try: t = ops.convert_to_tensor(t) |