          was_trained = run_test(
              "Train lightweight model for 5 iterations WITHOUT WTL.",
              train_args(
                  "lightweight", pathjoin(vid_base, "model"),
                  pathjoin(vid_base, "faces"), pathjoin(vid_base, "test_alignments.json")
              )
          )
  
      if was_trained:
          run_test(
 
</s> remove                 pathjoin(vid_base, "faces"), pathjoin(vid_base, "test_alignments.json"),
 </s> add                 pathjoin(vid_base, "faces"), pathjoin(vid_base, "test_alignments.fsa"), </s> remove                 "-a", pathjoin(vid_base, "test_alignments.json"),
 </s> add                 "-a", pathjoin(vid_base, "test_alignments.fsa"), </s> remove 

class Legacy():
    """ Update legacy alignments:
        - Rotate landmarks and bounding boxes on legacy alignments
          and remove the 'r' parameter
        - Add face hashes to alignments file
        """
    def __init__(self, alignments, frames, faces_dir):
        self.alignments = alignments
        self.frames = {os.path.basename(frame): frame
                       for frame in frames}
        self.process(faces_dir)

    def process(self, faces_dir):
        """ Run the rotate alignments process """
        rotated = self.alignments.get_legacy_rotation()
        hashes = self.alignments.get_legacy_no_hashes()
        if not rotated and not hashes:
            return
        if rotated:
            logger.info("Legacy rotated frames found. Converting...")
            self.rotate_landmarks(rotated)
            self.alignments.save()
        if hashes and faces_dir:
            logger.info("Legacy alignments found. Adding Face Hashes...")
            self.add_hashes(hashes, faces_dir)
            self.alignments.save()

    def rotate_landmarks(self, rotated):
        """ Rotate the landmarks """
        for rotate_item in tqdm(rotated, desc="Rotating Landmarks"):
            frame = self.frames.get(rotate_item, None)
            if frame is None:
                logger.debug("Skipping missing frame: '%s'", rotate_item)
                continue
            self.alignments.rotate_existing_landmarks(rotate_item, frame)

    def add_hashes(self, hashes, faces_dir):
        """ Add Face Hashes to the alignments file """
        all_faces = dict()
        face_files = sorted(face for face in os.listdir(faces_dir) if "_" in face)
        for face in face_files:
            filename, extension = os.path.splitext(face)
            index = filename[filename.rfind("_") + 1:]
            if not index.isdigit():
                continue
            orig_frame = filename[:filename.rfind("_")] + extension
            all_faces.setdefault(orig_frame, dict())[int(index)] = os.path.join(faces_dir, face)

        for frame in tqdm(hashes):
            if frame not in all_faces.keys():
                logger.warning("Skipping missing frame: '%s'", frame)
                continue
            hash_faces = all_faces[frame]
            for index, face_path in hash_faces.items():
                hash_faces[index] = read_image_hash(face_path)
            self.alignments.add_face_hashes(frame, hash_faces)
 </s> add  </s> remove         dest_format = self.get_dest_format()
 </s> add  </s> remove             batch_faces = [[self._rotate_rect(face, rotmat) if rotmat.any() else face
 </s> add             batch_faces = [[self._rotate_face(face, rotmat) if rotmat.any() else face
                pathjoin(vid_base, "faces"), pathjoin(vid_base, "test_alignments.fsa")
          was_trained = run_test(
              "Train lightweight model for 5 iterations WITHOUT WTL.",
              train_args(
                  "lightweight", pathjoin(vid_base, "model"),
                pathjoin(vid_base, "faces"), pathjoin(vid_base, "test_alignments.fsa")
              )
          )
  
      if was_trained:
          run_test(
keep keep keep keep replace keep keep keep keep keep
 Legacy alignments update

- Remove legacy update hashes
- Remove legacy job from alignment-tools
- Remove legacy landmark rotation
- Add rotate face method to plugins/extract/detect
- Update travis test for new alignments extension
- Alignments format to .fsa
- Remove serializer option from alignments-tool
- Auto update legacy format alignment files to new format 
_travis/simple_tests.py