code: def image_to_float32(image: np.ndarray) -> np.ndarray:
      """Convert the image to a float32 array and scale values appropriately."""
      if image.dtype == np.float32:
          return image
  
      dtype = image.dtype
      image = image.astype(np.float32)
      if dtype == np.uint8:
          return image / UINT8_MAX
      elif dtype == np.uint16:
          return image / UINT16_MAX
      elif dtype == np.float64:
          return image
      elif dtype == np.float16:
          return image
  
      raise ValueError(f"Not sure how to handle dtype {dtype}")
  
imports: import math
  from typing import Tuple
  from absl import logging
  import cv2
  import imageio
  import numpy
  from PIL import Image
  from nerfies import gpath
  from nerfies import types
label_desc: Use image node_id 9 for calling a global function with example usage: image_to_float32(image) and returns: image, unknown, unknown, image, image