code: def testErrorConditions(self):
      x = variable_scope.get_variable(
          "x",
          shape=[4, 1],
          initializer=ones(),
          partitioner=lambda shape, dtype: [2, 1],
      )
  
      # List of PartitionedVariable is invalid type when warm-starting with vocab.
      self.assertRaises(
          TypeError,
          ws_util._warm_start_var_with_vocab,
          [x],
          "/tmp",
          5,
          "/tmp",
          "/tmp",
      )
  
      # Unused variable names raises ValueError.
      with ops.Graph().as_default():
          with self.cached_session() as sess:
              x = variable_scope.get_variable(
                  "x",
                  shape=[4, 1],
                  initializer=ones(),
                  partitioner=lambda shape, dtype: [2, 1],
              )
              self._write_checkpoint(sess)
  
      self.assertRaises(
          ValueError,
          ws_util.warm_start,
          self.get_temp_dir(),
          var_name_to_vocab_info={"y": ws_util.VocabInfo("", 1, 0, "")},
      )
      self.assertRaises(
          ValueError,
          ws_util.warm_start,
          self.get_temp_dir(),
          var_name_to_prev_var_name={"y": "y2"},
      )
  
imports: import os
  import numpy
  from tensorflow.python.checkpoint import checkpoint
  from tensorflow.python.feature_column import feature_column_lib
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import ops
  from tensorflow.python.ops import array_ops
  from tensorflow.python.ops import init_ops
  from tensorflow.python.ops import variable_scope
  from tensorflow.python.ops import variables
  from tensorflow.python.platform import test
  from tensorflow.python.training import checkpoint_utils
  from tensorflow.python.training import saver
  from tensorflow.python.training import warm_starting_util
label_desc: Use image node_id 37 for calling the WarmStartingUtilTest obj's underlying member method code with example usage: obj.testErrorConditions() without return types