def _transformed_batch_to_instance_dicts(
    transformed_batch: Tuple[pa.RecordBatch, Dict[str, pa.Array]],
    schema: schema_pb2.Schema,
):
  """Converts batch of transformed data to unbatched instance dicts."""
  record_batch, unary_passthrough_features = transformed_batch
  result = impl_helper.record_batch_to_instance_dicts(record_batch, schema)
  # Convert unary passthrough data to Python primitives.
  for key, value in unary_passthrough_features.items():
    value = value.to_pylist()
    value = None if value[0] is None else value[0]
    for instance in result:
      instance[key] = value
  return result
Converts batch of transformed data to unbatched instance dicts.
tensorflow_transform/beam/impl.py