                     "\nYou should lower the number of processes in use by either setting the "
                     "'singleprocess' flag (-sp) or lowering the number of parallel jobs (-j).")
              raise FaceswapError(msg) from err
  
      def _convert_images(self):
          """ Start the multi-threaded patching process, monitor all threads for errors and join on
          completion. """
          logger.debug("Converting images")
          save_queue = queue_manager.get_queue("convert_out")
          patch_queue = queue_manager.get_queue("patch")
 
</s> remove         save_queue = queue_manager.get_queue("convert_out")
        patch_queue = queue_manager.get_queue("patch")
        self._patch_threads = MultiThread(self._converter.process, patch_queue, save_queue,
                                          thread_count=self._pool_processes, name="patch")

 </s> add  </s> remove     def process(self):
 </s> add     def _get_threads(self) -> MultiThread:
        """ Get the threads for patching the converted faces onto the frames.

        Returns
        :class:`lib.multithreading.MultiThread`
            The threads that perform the patching of swapped faces onto the output frames
        """
        # TODO Check if multiple threads actually speeds anything up
        save_queue = queue_manager.get_queue("convert_out")
        patch_queue = queue_manager.get_queue("patch")
        return MultiThread(self._converter.process, patch_queue, save_queue,
                           thread_count=self._pool_processes, name="patch")

    def process(self) -> None: </s> remove     def _check_thread_error(self):
        """ Monitor all running threads for errors, and raise accordingly. """
 </s> add     def _check_thread_error(self) -> None:
        """ Monitor all running threads for errors, and raise accordingly.

        Raises
        ------
        Error
            Re-raises any error encountered within any of the running threads
        """ </s> remove     def _count_images(self):
 </s> add     def _count_images(self) -> int: </s> remove class QueueManager():
    """ Manage queues for availabilty across processes
        Don't import this class directly, instead
        import the variable: queue_manager """
    def __init__(self):
 </s> add class EventQueue(Queue):
    """ Standard Queue object with a separate global shutdown parameter indicating that the main
    process, and by extension this queue, should be shut down.

    Parameters
    ----------
    shutdown_event: :class:`threading.Event`
        The global shutdown event common to all managed queues
    maxsize: int, Optional
        Upperbound limit on the number of items that can be placed in the queue. Default: `0`
    """
    def __init__(self, shutdown_event: threading.Event, maxsize: int = 0) -> None:
        super().__init__(maxsize=maxsize)
        self._shutdown = shutdown_event

    @property
    def shutdown(self) -> threading.Event:
        """ :class:`threading.Event`: The global shutdown event """
        return self._shutdown


class _QueueManager():
    """ Manage :class:`EventQueue` objects for availabilty across processes.

        Notes
        -----
        Don't import this class directly, instead import via :func:`queue_manager` """
    def __init__(self) -> None:
    def _convert_images(self) -> None:
                     "\nYou should lower the number of processes in use by either setting the "
                     "'singleprocess' flag (-sp) or lowering the number of parallel jobs (-j).")
              raise FaceswapError(msg) from err
  
    def _convert_images(self) -> None:
          """ Start the multi-threaded patching process, monitor all threads for errors and join on
          completion. """
          logger.debug("Converting images")
          save_queue = queue_manager.get_queue("convert_out")
          patch_queue = queue_manager.get_queue("patch")
keep keep keep keep replace keep keep keep keep keep
 Bugfix: convert - Gif Writer
  - Fix non-launch error on Gif Writer
  - convert plugins - linting
  - convert/fs_media/preview/queue_manager - typing
  - Change convert items from dict to Dataclass 
scripts/convert.py