code: def test_load_v1_in_v2(self):
      save_dir = self._create_save_v1_model()
      read_v1_count = metrics.GetRead(write_version="1")
      read_v2_count = metrics.GetRead(write_version="2")
      load_v2_count = metrics.GetReadApi(load._LOAD_V2_LABEL)
      load_v1_v2_count = metrics.GetReadApi(
          load_v1_in_v2._LOAD_V1_V2_LABEL
      )
      load.load(save_dir)
  
      # Check that `load_v2` was *not* incremented.
      self.assertEqual(
          metrics.GetReadApi(load._LOAD_V2_LABEL), load_v2_count
      )
      self.assertEqual(
          metrics.GetRead(write_version="2"), read_v2_count
      )
  
      self.assertEqual(
          metrics.GetReadApi(load_v1_in_v2._LOAD_V1_V2_LABEL),
          load_v1_v2_count + 1,
      )
      self.assertEqual(
          metrics.GetRead(write_version="1"), read_v1_count + 1
      )
  
imports: import os
  from google.protobuf import json_format
  from tensorflow.python.eager import test
  from tensorflow.python.framework import constant_op
  from tensorflow.python.framework import ops
  from tensorflow.python.saved_model import builder
  from tensorflow.python.saved_model import builder_impl
  from tensorflow.python.saved_model import fingerprinting
  from tensorflow.python.saved_model import load
  from tensorflow.python.saved_model import load_v1_in_v2
  from tensorflow.python.saved_model import loader_impl
  from tensorflow.python.saved_model import save
  from tensorflow.python.saved_model.pywrap_saved_model import metrics
  from tensorflow.python.trackable import autotrackable
label_desc: Use image node_id 6 for calling the MetricsTests obj's underlying member method code with example usage: obj.test_load_v1_in_v2() without return types