code: def load_trial_cis(
      trial_output_dir: str,
  ) -> Dict[metric_types.MetricKey, _CIType]:
      """Loads the CI (lower, upper) for each metric in a TFMA run."""
      trial_cis = {}
      path = os.path.join(trial_output_dir, "metrics")
      for rec in tf.compat.v1.io.tf_record_iterator(path):
          metrics_for_slice = (
              metrics_for_slice_pb2.MetricsForSlice.FromString(rec)
          )
          for kv in metrics_for_slice.metric_keys_and_values:
              if kv.value.WhichOneof("type") != "double_value":
                  continue
              lower = (
                  kv.confidence_interval.lower_bound.double_value.value
              )
              upper = (
                  kv.confidence_interval.upper_bound.double_value.value
              )
              trial_cis[metric_types.MetricKey.from_proto(kv.key)] = (
                  lower,
                  upper,
              )
      return trial_cis
  
imports: import collections
  import os
  from typing import Callable, Dict, Iterable, Iterator, List, Sequence, Tuple
  from absl import app
  from absl import flags
  import apache_beam
  import numpy
  import tensorflow
  from tensorflow_model_analysis import constants
  from tensorflow_model_analysis.api import model_eval_lib
  from tensorflow_model_analysis.eval_saved_model import util
  from tensorflow_model_analysis.metrics import metric_types
  from tensorflow_model_analysis.proto import config_pb2
  from tensorflow_model_analysis.proto import metrics_for_slice_pb2
  from tfx_bsl.tfxio import tf_example_record
  from google.protobuf import text_format
  from tensorflow.core.example import example_pb2
label_desc: Use image node_id 5 for calling a global function with example usage: load_trial_cis(trial_output_dir) and returns: trial_cis