          Loads from a folder of images or from a video and puts to a queue
  
          Parameters
          ----------
          args: tuple
              The arguments to be passed to the load iterator
          """
          queue = args[0]
          io_args = args[1:]
          iterator = self._load_video if self._is_video else self._load_images
          logger.debug("Load iterator: %s", iterator)
 
</s> remove         queue = args[0]
        io_args = args[1:]
        iterator = self._load_video if self._is_video else self._load_images
 </s> add         iterator = self._from_video if self._is_video else self._from_folder </s> remove         for retval in iterator(*io_args):
 </s> add         for retval in iterator():
            filename, image = retval[:2]
            if image is None or (not image.any() and image.ndim not in (2, 3)):
                # All black frames will return not np.any() so check dims too
                logger.warning("Unable to open image. Skipping: '%s'", filename)
                continue </s> remove     # LOADING #
    def _load(self, *args):
 </s> add         logger.debug("count: %s", self.count)
        logger.trace("filelist: %s", self.file_list)

    def _process(self, queue): </s> remove         args: tuple
            The save arguments
 </s> add         queue: queue.Queue()
            The ImageIO Queue </s> remove         queue = args[0]
 </s> add         executor = futures.ThreadPoolExecutor(thread_name_prefix=self.__class__.__name__)
        queue: queue.Queue()
            The ImageIO Queue
          Loads from a folder of images or from a video and puts to a queue
  
          Parameters
          ----------
        queue: queue.Queue()
            The ImageIO Queue
        queue: queue.Queue()
            The ImageIO Queue
          """
          queue = args[0]
          io_args = args[1:]
          iterator = self._load_video if self._is_video else self._load_images
          logger.debug("Load iterator: %s", iterator)
keep keep keep keep replace replace keep keep keep keep keep
 scripts.extract - code optimizations

Limit queue sizes to reduce RAM usage
Rename lib.image.BackgroundIO to ImageIO
Create separate ImagesLoader and ImagesSaver classes
Load/Save images from centralized lib.image.ImageIO
scripts.extract documentation 
lib/image.py