              frame_name = os.path.splitext(src_filename)[0]
              progress_queue.put(1)
  
              for face_idx, face in enumerate(self._frame_faces[frame_idx]):
                  output = "{}_{}{}".format(frame_name, str(face_idx), extension)
                  aligned = AlignedFace(face.landmarks_xy,
                                        image=image,
                                        centering="head",
                                        size=512)  # TODO user selectable size
                  meta = dict(alignments=face.to_png_meta(),
 
</s> remove         for frame_idx, (filename, image) in enumerate(loader.load()):
 </s> add         for frame_idx, (filename, image) in enumerate(_io["loader"].load()): </s> remove         saver = ImagesSaver(str(get_folder(output_folder)), as_bytes=True)
        loader = ImagesLoader(self._input_location, count=self._alignments.frames_count)
        extension = ".png"
 </s> add         _io = dict(saver=ImagesSaver(str(get_folder(output_folder)), as_bytes=True),
                   loader=ImagesLoader(self._input_location, count=self._alignments.frames_count)) </s> remove             size = ((roi[1][0] - roi[0][0]) ** 2 + (roi[1][1] - roi[0][1]) ** 2) ** 0.5
 </s> add             size = ((roi[1][0] - roi[0][0]) ** 2 +  # pylint:disable=unsubscriptable-object
                    (roi[1][1] - roi[0][1]) ** 2) ** 0.5  # pylint:disable=unsubscriptable-object </s> remove             landmark = aligned.landmarks[landmark_index]
 </s> add             landmark = aligned.landmarks[landmark_index]  # pylint:disable=unsubscriptable-object
                output = "{}_{}{}".format(frame_name, str(face_idx), ".png")
              frame_name = os.path.splitext(src_filename)[0]
              progress_queue.put(1)
  
              for face_idx, face in enumerate(self._frame_faces[frame_idx]):
                output = "{}_{}{}".format(frame_name, str(face_idx), ".png")
                  aligned = AlignedFace(face.landmarks_xy,
                                        image=image,
                                        centering="head",
                                        size=512)  # TODO user selectable size
                  meta = dict(alignments=face.to_png_meta(),
keep keep keep keep replace keep keep keep keep keep
 Add Misalignment Detection
  - lib.align.AlignedFace - Add average_distance property (distance from mean_face)
  - tools.manual - Add misaligned Faces filter
  - tools.sort - Add sort by distance (misaligned sort)Add "Misaligned Faces" filter to manual tool 
tools/manual/detected_faces.py