  
          # Get Targets
          processed.update(self._processing.get_targets(batch))
  
          # Random Warp
          if to_landmarks:
              warp_kwargs = dict(batch_src_points=batch_src_pts,
                                 batch_dst_points=self._get_closest_match(filenames,
                                                                          side,
                                                                          batch_src_pts))
          else:
              warp_kwargs = dict()
          processed["feed"] = self._processing.warp(batch[..., :3], to_landmarks, **warp_kwargs)
  
          logger.trace("Processed batch: (filenames: %s, side: '%s', processed: %s)",
                       filenames,
                       side,
                       {k: v.shape if isinstance(v, np.ndarray) else[i.shape for i in v]
 
</s> remove         to_landmarks = self._training_opts["warp_to_landmarks"]
 </s> add  </s> remove                      [tgt.shape for tgt_images in target_batch for tgt in tgt_images])
 </s> add                      [tgt_images.shape[1:] for tgt_images in target_batch]) </s> remove                 padding)
 </s> add                 self.aligned["padding"]) </s> remove         config item ``warp_to_landmarks`` is ``True`` or if :attr:`mask_type` is not ``None``. If
        the landmarks for an image cannot be found, then an error is raised. """
 </s> add         config item ``warp_to_landmarks`` is ``True``. If the landmarks for an image cannot be
        found, then an error is raised. """
        # Random Warp # TODO change masks to have a input mask and a warped target mask
        processed["feed"] = [self._processing.warp(batch[..., :3],
                                                   self._training_opts["warp_to_landmarks"],
                                                   **warp_kwargs)]
  
          # Get Targets
          processed.update(self._processing.get_targets(batch))
  
        # Random Warp # TODO change masks to have a input mask and a warped target mask
        processed["feed"] = [self._processing.warp(batch[..., :3],
                                                   self._training_opts["warp_to_landmarks"],
                                                   **warp_kwargs)]
        # Random Warp # TODO change masks to have a input mask and a warped target mask
        processed["feed"] = [self._processing.warp(batch[..., :3],
                                                   self._training_opts["warp_to_landmarks"],
                                                   **warp_kwargs)]
        # Random Warp # TODO change masks to have a input mask and a warped target mask
        processed["feed"] = [self._processing.warp(batch[..., :3],
                                                   self._training_opts["warp_to_landmarks"],
                                                   **warp_kwargs)]
        # Random Warp # TODO change masks to have a input mask and a warped target mask
        processed["feed"] = [self._processing.warp(batch[..., :3],
                                                   self._training_opts["warp_to_landmarks"],
                                                   **warp_kwargs)]
        # Random Warp # TODO change masks to have a input mask and a warped target mask
        processed["feed"] = [self._processing.warp(batch[..., :3],
                                                   self._training_opts["warp_to_landmarks"],
                                                   **warp_kwargs)]
        # Random Warp # TODO change masks to have a input mask and a warped target mask
        processed["feed"] = [self._processing.warp(batch[..., :3],
                                                   self._training_opts["warp_to_landmarks"],
                                                   **warp_kwargs)]
        # Random Warp # TODO change masks to have a input mask and a warped target mask
        processed["feed"] = [self._processing.warp(batch[..., :3],
                                                   self._training_opts["warp_to_landmarks"],
                                                   **warp_kwargs)]
        # Random Warp # TODO change masks to have a input mask and a warped target mask
        processed["feed"] = [self._processing.warp(batch[..., :3],
                                                   self._training_opts["warp_to_landmarks"],
                                                   **warp_kwargs)]
        # Random Warp # TODO change masks to have a input mask and a warped target mask
        processed["feed"] = [self._processing.warp(batch[..., :3],
                                                   self._training_opts["warp_to_landmarks"],
                                                   **warp_kwargs)]
  
          logger.trace("Processed batch: (filenames: %s, side: '%s', processed: %s)",
                       filenames,
                       side,
                       {k: v.shape if isinstance(v, np.ndarray) else[i.shape for i in v]
keep keep keep keep replace replace replace replace replace replace replace replace replace keep keep keep keep keep
 Smart Mask Exposure for Extraction & Training (#831)

Smart Masks - Initial Commit 
lib/training_data.py