code: def _raw_value_iterator(
      paths: Iterable[str], output_file_format: str
  ) -> Iterator[Union[pa.Buffer, bytes]]:
      """Returns an iterator of raw per-record values from supported file formats.
  
      When reading parquet format files, values from the column with name
      _SERIALIZED_VALUE_PARQUET_COLUMN_NAME will be read.
  
      Args:
        paths: The paths from which to read records
        output_file_format: The format of the files from which to read records.
  
      Returns:
        An iterator which yields serialized values.
  
      Raises:
        ValueError when the output_file_format is unknown.
      """
      if output_file_format == _PARQUET_FORMAT:
          return _parquet_column_iterator(
              paths, _SERIALIZED_VALUE_PARQUET_COLUMN_NAME
          )
      elif (
          not output_file_format
          or output_file_format == _TFRECORD_FORMAT
      ):
          return itertools.chain(
              *(
                  tf.compat.v1.python_io.tf_record_iterator(path)
                  for path in paths
              )
          )
      raise ValueError(
          'Formats "{}" are currently supported but got '
          "output_file_format={}".format(
              _SUPPORTED_FORMATS, output_file_format
          )
      )
  
imports: import itertools
  import os
  from typing import Any, Dict, Iterable, Iterator, List, Optional, Tuple, Union
  from absl import logging
  import apache_beam
  import numpy
  import pyarrow
  import tensorflow
  from tensorflow_model_analysis import constants
  from tensorflow_model_analysis.api import types
  from tensorflow_model_analysis.evaluators import evaluator
  from tensorflow_model_analysis.evaluators import metrics_validator
  from tensorflow_model_analysis.metrics import calibration_plot
  from tensorflow_model_analysis.metrics import confusion_matrix_plot
  from tensorflow_model_analysis.metrics import metric_specs
  from tensorflow_model_analysis.metrics import metric_types
  from tensorflow_model_analysis.post_export_metrics import metric_keys
  from tensorflow_model_analysis.proto import config_pb2
  from tensorflow_model_analysis.proto import metrics_for_slice_pb2
  from tensorflow_model_analysis.proto import validation_result_pb2
  from tensorflow_model_analysis.slicer import slicer_lib
  from tensorflow_model_analysis.utils import math_util
  from tensorflow_model_analysis.writers import writer
  from google.protobuf import wrappers_pb2
label_desc: Use image node_id 3 for calling a global function with example usage: _raw_value_iterator(paths, output_file_format) and returns: _parquet_column_iterator, itertools