              logger.trace("Saved image: '%s'", filename)
          except Exception as err:  # pylint: disable=broad-except
              logger.error("Failed to save image '%s'. Original Error: %s", filename, err)
  
      def save(self, filename, image):
          """ Save the given image in the background thread
  
          Ensure that :func:`close` is called once all save operations are complete.
  
          Parameters
 
</s> remove             logger.trace("Saved image: '%s'", filename)
 </s> add             logger.trace("Saved image: '%s'", filename)  # type:ignore </s> remove         logger.trace("Putting to save queue: '%s'", filename)
        self._queue.put((filename, image))
 </s> add         logger.trace("Putting to save queue: '%s'", filename)  # type:ignore
        self._queue.put((filename, image, sub_folder)) </s> remove     def _save(self, filename, image):
 </s> add     def _save(self, filename: str, image: bytes, sub_folder: Optional[str]) -> None: </s> remove             The filename of the image to be saved
        image: numpy.ndarray
            The image to be saved
 </s> add             The filename of the image to be saved. NB: Any folders passed in with the filename
            will be stripped and replaced with :attr:`location`.
        image: bytes
            The encoded image to be saved
        subfolder: str, optional
            If the file should be saved in a subfolder in the output location, the subfolder should
            be provided here. ``None`` for no subfolder. Default: ``None``
    def save(self, filename: str, image: bytes, sub_folder: Optional[str] = None) -> None:
              logger.trace("Saved image: '%s'", filename)
          except Exception as err:  # pylint: disable=broad-except
              logger.error("Failed to save image '%s'. Original Error: %s", filename, err)
  
    def save(self, filename: str, image: bytes, sub_folder: Optional[str] = None) -> None:
          """ Save the given image in the background thread
  
          Ensure that :func:`close` is called once all save operations are complete.
  
          Parameters
keep keep keep keep replace keep keep keep keep keep
 Extract filter: Allow saving of filtered images 
lib/image.py