code: def _load_pyfunc(path):
      """
      Load the KerasImageClassifierPyfunc model.
      """
      with open(os.path.join(path, "conf.yaml")) as f:
          conf = yaml.safe_load(f)
      keras_model_path = os.path.join(path, "keras_model")
      domain = conf["domain"].split("/")
      image_dims = np.array(
          [int(x) for x in conf["image_dims"].split("/")],
          dtype=np.int32,
      )
      # NOTE: TensorFlow based models depend on global state (Graph and Session) given by the context.
      # To make sure we score the model in the same session as we loaded it in, we create a new
      # session and a new graph here and store them with the model.
      with tf.Graph().as_default() as g:
          with tf.Session().as_default() as sess:
              keras.backend.set_session(sess)
              keras_model = mlflow.tensorflow.load_model(
                  keras_model_path
              )
      return KerasImageClassifierPyfunc(
          g, sess, keras_model, image_dims, domain=domain
      )
  
imports: import base64
  import os
  from io import BytesIO
  from typing import Any, Dict, Optional
  import keras
  import numpy
  import pandas
  import PIL
  import pip
  import tensorflow
  import yaml
  from PIL import Image
  import mlflow
  from mlflow.utils import PYTHON_VERSION
  from mlflow.utils.file_utils import TempDir
label_desc: Use image node_id 3 for calling a global function with example usage: _load_pyfunc(path) and returns: KerasImageClassifierPyfunc