code: def test_enqueue_dequeue_apply_gradients_on_cpu(self):
      # Dequeue on CPU.
      mid_level_api = self._create_mid_level()
      with self.assertRaises(RuntimeError):
          mid_level_api.dequeue()
      # Enqueue on CPU.
      features = {
          "watched": sparse_tensor.SparseTensor(
              indices=self.feature_watched_indices,
              values=self.feature_watched_values,
              dense_shape=[2, 2],
          )
      }
      with self.assertRaises(RuntimeError):
          mid_level_api.enqueue(features)
      # Apply gradient on CPU.
      mid_level_api = self._create_mid_level()
      with self.assertRaises(RuntimeError):
          mid_level_api.apply_gradients(None)
  
file_path: tensorflow-upstream/tensorflow/python/tpu/tests/tpu_embedding_v2_initialization_test.py
imports: import numpy
  from tensorflow.python.compat import v2_compat
  from tensorflow.python.framework import constant_op
  from tensorflow.python.framework import sparse_tensor
  from tensorflow.python.framework.tensor_shape import TensorShape
  from tensorflow.python.ops import init_ops_v2
  from tensorflow.python.platform import test
  from tensorflow.python.tpu import tpu_embedding_v2
  from tensorflow.python.tpu import tpu_embedding_v2_utils
  from tensorflow.python.tpu.tests import tpu_embedding_base_test
label_desc: Use image node_id 1 for calling the TPUEmbeddingTest obj's underlying member method code with example usage: obj.test_enqueue_dequeue_apply_gradients_on_cpu() without return types