          for rawface in faces:
              face = DetectedFace(**rawface)
              # Rotate the image if necessary
              if face.r != 0:
                  image = Utils.rotate_image_by_angle(image, face.r)
              face.image = image[face.y: face.y + face.h,
                                 face.x: face.x + face.w]
              if self.filter and not self.filter.check(face):
                  if self.args.verbose:
                      print("Skipping not recognized face!")
 
</s> remove                 process_faces = [(idx, face) for idx, face in faces]
                if process_faces and angle != 0 and self.args.verbose:
 </s> add                 process_faces = [[idx, face] for idx, face in faces]
                if not process_faces:
                    continue

                if angle != 0 and self.args.verbose: </s> remove         if rotation != 0:
            if not reverse:
                self.rotation_height, self.rotation_width = image.shape[:2]
                image = Utils.rotate_image_by_angle(image, rotation)
            else:
                image = Utils.rotate_image_by_angle(
                    image,
                    rotation * -1,
                    rotated_width=self.rotation_width,
                    rotated_height=self.rotation_height)
 </s> add         if rotation == 0:
            return image
        if not reverse:
            self.rotation_height, self.rotation_width = image.shape[:2]
            image, _ = rotate_image_by_angle(image, rotation)
        else:
            image, _ = rotate_image_by_angle(
                image,
                rotation * -1,
                rotated_width=self.rotation_width,
                rotated_height=self.rotation_height) </s> remove                 currentimage = Utils.rotate_image_by_angle(image, angle)
 </s> add                 currentimage, rotation_matrix = rotate_image_by_angle(image,
                                                                      angle)
                image, _ = rotate_image_by_angle(image, face.r)
          for rawface in faces:
              face = DetectedFace(**rawface)
              # Rotate the image if necessary
              if face.r != 0:
                image, _ = rotate_image_by_angle(image, face.r)
              face.image = image[face.y: face.y + face.h,
                                 face.x: face.x + face.w]
              if self.filter and not self.filter.check(face):
                  if self.args.verbose:
                      print("Skipping not recognized face!")
keep keep keep keep replace keep keep keep keep keep
 Alignments Tool - Manual (#503)

* Initial alignment tool implementation

* Add face processing. Fix helptext formatting for cli and gui

* Extract faces from alignments file

* Add draw landmarks

* fix analysis hours past 24 bug

* Remove tools flag. Enlarge GUI tooltips

* Add filename extension check for image folders

* Fix folder nonetype bug and linting

* Bugfix renaming of faces

* Import alignments from DeepFaceLab

* Remove frames requirement for dfl

* Alignments Tool: Add remove frames

* Alignments: Add remove frames (#492)

* Alignments Tool: Add remove frames

* Implement Frame display for manual extract

* Alignments refactor

* Further navigation improvements

* Further navigation improvements

* Alignment Tool: Refactor

* Move rotate_image_by_angle() to utils

* Further refactoring improvements

* Reduce key bindings. Add skip to has faces, Add resize frame binding

* More navigation options. Delete faces added. Save alignments added

* Add: Reload alignments. Add extra api calls. Better redraw handling.

* Manual Alignments - Alpha Build

* Rotate landmarks for rotated images

* Rebase to remove OriginalHiRes changes 
scripts/fsmedia.py