      """
      def __init__(self, image=None, x=None, w=None, y=None, h=None,
                   landmarks_xy=None, mask=None, filename=None):
          logger.trace("Initializing %s: (image: %s, x: %s, w: %s, y: %s, h:%s, "
                       "landmarks_xy: %s, filename: %s)",
                       self.__class__.__name__,
                       image.shape if image is not None and image.any() else image,
                       x, w, y, h, landmarks_xy,
                       {k: v.shape for k, v in mask} if mask is not None else mask,
                       filename)
 
</s> remove         dict of `{name (str): mask (numpy.ndarray)}
 </s> add         dict of {**name** (`str`): :class:`Mask`}. </s> remove         # 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)]
 </s> add         # 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) </s> remove         masks = masks if masks is not None else self.masks
        samples = samples if samples is not None else self.samples
        retval = [samples[0:num_images], images[0:num_images], masks[0:num_images]]
 </s> add         retval = [samples[0:num_images]] if samples is not None else [self.samples[0:num_images]]
        if self.use_mask:
            retval.extend(tgt[0:num_images] for tgt in images)
        else:
            retval.extend(images[0:num_images]) </s> remove             elif self.config["penalized_mask_loss"]:
 </s> add             elif self.mask_input is not None and self.config.get("penalized_mask_loss", False): </s> remove                      [tgt_images.shape[1:] for tgt_images in target_batch])
 </s> add                      [tgt.shape for tgt_images in target_batch for tgt in tgt_images])
                     "landmarks_xy: %s, mask: %s, filename: %s)",
      """
      def __init__(self, image=None, x=None, w=None, y=None, h=None,
                   landmarks_xy=None, mask=None, filename=None):
          logger.trace("Initializing %s: (image: %s, x: %s, w: %s, y: %s, h:%s, "
                     "landmarks_xy: %s, mask: %s, filename: %s)",
                       self.__class__.__name__,
                       image.shape if image is not None and image.any() else image,
                       x, w, y, h, landmarks_xy,
                       {k: v.shape for k, v in mask} if mask is not None else mask,
                       filename)
keep keep keep keep replace keep keep keep keep keep
 Serialize masks to alignments file

- Add new serializers (npy + compressed)
- Remove Serializer option from cli
- Revert get_aligned call in scripts/extract
- Default alignments to compressed
- Size masks to 128px and compress
- Remove mask thresholding/blur from generation code
- Add Mask class to lib/faces_detect
- Revert debug landmarks to aligned face
- Revert non-extraction code to staging version 
lib/faces_detect.py