class_docstr: Tests for tf.data placement within tf.functions.
  
  Specifically, tf.data dataset tensors cannot be copied between devices. These
  tests verify the ops are placed in a way that avoids this.
class_docstr_tok: ["Tests","for","tf.data","placement","within","tf.functions",".","Specifically",",","tf.data","dataset","tensors","can","not","be","copied","between","devices",".","These","tests","verify","the","ops","are","placed","in","a","way","that","avoids","this","."]
code: def setUp(self):
      super(PlacementTest, self).setUp()
      # Grappler optimizations can affect whether the placement issues occur,
      # since they may inadvertently rewrite nodes and edges in a way that removes
      # cross-device copies.
      config.set_optimizer_experimental_options(
          {"disable_meta_optimizer": True}
      )
  
imports: from absl.testing import parameterized
  from tensorflow.python.data.experimental.ops import prefetching_ops
  from tensorflow.python.data.kernel_tests import test_base
  from tensorflow.python.data.ops import dataset_ops
  from tensorflow.python.eager import def_function
  from tensorflow.python.framework import combinations
  from tensorflow.python.framework import config
  from tensorflow.python.framework import constant_op
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import ops
  from tensorflow.python.framework import test_ops
  from tensorflow.python.framework import test_util
  from tensorflow.python.ops import array_ops
  from tensorflow.python.ops import cond
  from tensorflow.python.ops import gen_dataset_ops
  from tensorflow.python.ops import math_ops
  from tensorflow.python.platform import test
label_desc: Use image node_id 1 for calling the PlacementTest obj's underlying member method code with example usage: obj.setUp() without return types