code: def load_img(display=True, key=None, device="cuda"):
      image = get_interactive_image(key=key)
      if image is None:
          return None
      if display:
          st.image(image)
      w, h = image.size
      print(f"loaded input image of size ({w}, {h})")
      width, height = map(
          lambda x: x - x % 64, (w, h)
      )  # resize to integer multiple of 64
      image = image.resize((width, height))
      image = np.array(image.convert("RGB"))
      image = image[None].transpose(0, 3, 1, 2)
      image = (
          torch.from_numpy(image).to(dtype=torch.float32) / 127.5 - 1.0
      )
      return image.to(device)
  
imports: from pytorch_lightning import seed_everything
  from scripts.demo.streamlit_helpers import *
label_desc: Use image node_id 1 for calling a global function with example usage: load_img(display, key, device) and returns: image, None