          while idx < self.batchsize:
              item = self._collect_item(queue)
              if item == "EOF":
                  logger.trace("EOF received")  # type:ignore
                  self._filter.output_counts()
                  exhausted = True
                  break
              # Put frames with no faces into the out queue to keep TQDM consistent
              if not item.detected_faces:
                  self._queues["out"].put(item)
 
</s> remove                     if batch:
 </s> add                     # TODO Move all batch items to common dataclass. Currently migrated:
                    # Align
                    if (isinstance(batch, dict) and batch or
                            not isinstance(batch, dict) and batch.filename): </s> remove         if batch:
            logger.trace("Returning batch: %s", {k: v.shape  # type:ignore
                                                 if isinstance(v, np.ndarray) else v
 </s> add         if batch.filename:
            logger.trace("Returning batch: %s", {k: len(v)  # type:ignore
                                                 if isinstance(v, list) else v </s> remove             logger.trace(item)  # type:ignore
 </s> add             logger.debug(item)  # type:ignore

        # TODO Move to end of process not beginning
        self._filter.output_counts()

          while idx < self.batchsize:
              item = self._collect_item(queue)
              if item == "EOF":
                  logger.trace("EOF received")  # type:ignore

                  exhausted = True
                  break
              # Put frames with no faces into the out queue to keep TQDM consistent
              if not item.detected_faces:
                  self._queues["out"].put(item)
keep keep keep keep replace keep keep keep keep keep
 bugfix: Extract - don't put empty batches through aligner 
plugins/extract/align/_base.py