                                      rotate_images=self._args.rotate_images,
                                      min_size=self._args.min_size,
                                      normalize_method=normalization,
                                      re_feed=self._args.re_feed)
          self._threads = []
          self._verify_output = False
          logger.debug("Initialized %s", self.__class__.__name__)
  
      @property
      def _save_interval(self) -> Optional[int]:
 
</s> remove                                      self._config.get("preview_images", 14),
 </s> add                                      int(self._config.get("preview_images", 14)), </s> remove     def __init__(self, filenames, config):
        self._lock = Lock()
        self._cache = {os.path.basename(filename): dict(cached=False) for filename in filenames}
        self._aligned_landmarks = None
        self._partial_load = False
        self._cache_full = False
        self._extract_version = None
        self._has_reset = False
        self._size = None

        self._centering = config["centering"]
 </s> add     def __init__(self,
                 config: ConfigType,
                 model: "ModelBase",
                 side: Literal["a", "b"],
                 images: List[str],
                 batch_size: int) -> None:
        logger.debug("Initializing %s: (model: %s, side: %s, images: %s , "  # type: ignore
                     "batch_size: %s, config: %s)", self.__class__.__name__, model.name, side,
                     len(images), batch_size, config) </s> remove     def _setup(self, input_a=None, input_b=None, output=None):
 </s> add     def _setup(self, input_a: str, input_b: str, output: str) -> None: </s> remove     def minibatch_ab(self, images, batchsize, side,
                     do_shuffle=True, is_preview=False, is_timelapse=False):
        """ A Background iterator to return augmented images, samples and targets.
 </s> add         if self._warp_to_landmarks:
            self._face_cache.pre_fill(images, side)
        self._processing = ImageAugmentation(batch_size,
                                             self._process_size,
                                             self._config)
        self._nearest_landmarks: Dict[str, Tuple[str, ...]] = {}
        logger.debug("Initialized %s", self.__class__.__name__)
        self._threads: List[MultiThread] = []
                                      rotate_images=self._args.rotate_images,
                                      min_size=self._args.min_size,
                                      normalize_method=normalization,
                                      re_feed=self._args.re_feed)
        self._threads: List[MultiThread] = []
          self._verify_output = False
          logger.debug("Initialized %s", self.__class__.__name__)
  
      @property
      def _save_interval(self) -> Optional[int]:
keep keep keep keep replace keep keep keep keep keep
 Data Augmentation update (#1263)

- lib.detected_face
    - Subclass Masks for Landmark based masks
    - Add training mask propery + methods to DetectedFace
  - lib.training_training
    - subclass TrainingDataGenerator for training and preview data
    - Split cache into own module
    - Reduce thread count to 1 to prevent image corruption + data re-use
    - Process on largest model input/output size rather than stored image size
    - Size and crop masks during caching stage
    - Implement ring buffer for data flow
    - Fix preview reload bug
  - augmentation
    - typing
    - switch color aug order
    - better initialization
    - Fix warp + landmark warp to correctly apply at different image scales
    - Slightly improved warp caching
    - Don't store whether image is_preview. Handle all data as training images implicitly
  - plugins.trainer: Typing and fixes to work with trainingdata refactor 
scripts/extract.py