class_docstr: Extract image feature using pretrained CNN network.
class_docstr_tok: ["Extract","image","feature","using","pretrained","CNN","network","."]
docstr: Load from a given path.
docstr_tok: ["Load","from","a","given","path","."]
code: def load(self, path):
      """
      Load from a given path.
      """
      mode = self.opt.get("image_mode", "raw")
      if mode is None or mode == "no_image_model":
          # don't need to load images
          return None
      elif mode == "raw":
          return self._load_image(path)
      elif mode == "ascii":
          # convert images to ascii ¯\_(ツ)_/¯
          return self._img_to_ascii(self._load_image(path))
  
      # otherwise, looks for preprocessed version under 'mode' directory
      prepath, imagefn = self._get_prepath(path)
      dpath = os.path.join(prepath, mode)
      if not PathManager.exists(dpath):
          build_data.make_dir(dpath)
      imagefn = imagefn.split(".")[0]
      new_path = os.path.join(prepath, mode, imagefn)
      if not PathManager.exists(new_path):
          return self.extract(self._load_image(path), new_path)
      else:
          with PathManager.open(new_path, "rb") as f:
              return torch.load(f)
  
imports: import parlai.core.build_data
  import parlai.utils.logging
  from parlai.utils.io import PathManager
  import os
  from PIL import Image
  import torch
  from zipfile import ZipFile
label_desc: Use image node_id 13 for calling the ImageLoader obj's underlying member method code with example usage: obj.load(path) and returns: None, self, self, torch, self