code: def _testTypes(self, vals):
      for dtype in [
          np.float16,
          np.float32,
          np.float64,
          np.complex64,
          np.complex128,
          np.int32,
          np.int64,
          dtypes.bfloat16.as_numpy_dtype,
      ]:
          self.setUp()
          x = vals.astype(dtype)
          tftype = _NP_TO_TF[dtype]
          self.assertAllEqual(
              x, self._initFetch(x, tftype, use_gpu=False)
          )
          # NOTE(touts): the GPU test should pass for all types, whether the
          # Variable op has an implementation for that type on GPU as we expect
          # that Variable and Assign have GPU implementations for matching tf.
          self.assertAllEqual(
              x, self._initFetch(x, tftype, use_gpu=True)
          )
  
imports: import numpy
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import errors
  from tensorflow.python.framework import ops
  from tensorflow.python.framework import tensor_shape
  from tensorflow.python.framework import test_util
  from tensorflow.python.ops import array_ops
  from tensorflow.python.ops import array_ops_stack
  from tensorflow.python.ops import gen_state_ops
  from tensorflow.python.ops import math_ops
  from tensorflow.python.ops import state_ops
  from tensorflow.python.ops import variable_v1
  from tensorflow.python.ops import variables
  from tensorflow.python.platform import test
label_desc: Use image node_id 2 for calling the VariableOpTest obj's underlying member method code with example usage: obj._testTypes(vals) without return types