code: def _dtype_from_json(domain):
      """Translate a JSON domain dict into a tf.DType."""
      if domain.get("ints") is not None:
          return tf.int64
      if domain.get("floats") is not None:
          return tf.float32
      if domain.get("strings") is not None:
          return tf.string
      raise ValueError("Unknown domain: {}".format(domain))
  
file_path: transform/tensorflow_transform/tf_metadata/metadata_io.py
imports: import json
  import os
  import tensorflow
  from tensorflow_transform.tf_metadata import dataset_metadata
  from tensorflow_transform.tf_metadata import schema_utils
  from google.protobuf import text_format
  from tensorflow.python.lib.io import file_io
  from tensorflow_metadata.proto.v0 import schema_pb2
label_desc: Use image node_id 5 for calling a global function with example usage: _dtype_from_json(domain) and returns: tf, tf, tf