code: def testInitFromCheckpoint(self, distribution, in_replica_mode):
      checkpoint_dir, v1_value, v2_value = self._get_test_object()
  
      def init_and_verify(g):
          v1 = variable_scope.get_variable("new_var1", [1, 10])
          v2 = variable_scope.get_variable(
              "new_var2",
              [10, 10],
              synchronization=variable_scope.VariableSynchronization.ON_READ,
              aggregation=variable_scope.VariableAggregation.MEAN,
          )
          checkpoint_utils.init_from_checkpoint(
              checkpoint_dir, {"var1": "new_var1", "var2": "new_var2"}
          )
          with self.session(graph=g) as session:
              session.run(variables.global_variables_initializer())
              self.assertAllEqual(v1_value, self.evaluate(v1))
              self.assertAllEqual(v2_value, self.evaluate(v2))
  
      with ops.Graph().as_default() as g, distribution.scope():
          if in_replica_mode:
              distribution.extended.call_for_each_replica(
                  init_and_verify, args=[g]
              )
          else:
              init_and_verify(g)
  
file_path: tensorflow/tensorflow/python/distribute/checkpoint_utils_test.py
imports: import os
  from absl.testing import parameterized
  from tensorflow.python.distribute import combinations
  from tensorflow.python.distribute import strategy_combinations
  from tensorflow.python.framework import 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
label_desc: Use image node_id 2 for calling the CheckpointUtilsWithDistributionStrategyTest obj's underlying member method code with example usage: obj.testInitFromCheckpoint(distribution, in_replica_mode) without return types