  
      def sort_hist(self):
          input_dir = self.args.input_dir
  
          print("Sorting by histogram similarity...")
  
          img_list = [
 
</s> remove 
 </s> add         """ Sort by dlib CNN similarity """ </s> remove         img_list = [[x, face_recognition.face_encodings(cv2.imread(x))]
                    for x in
 </s> add         img_list = [[img, face_recognition.face_encodings(cv2.imread(img))]
                    for img in </s> remove             [x, cv2.calcHist([cv2.imread(x)], [0], None, [256], [0, 256])]
            for x in
 </s> add             [img, cv2.calcHist([cv2.imread(img)], [0], None, [256], [0, 256])]
            for img in
        """ Sort by histogram of face similarity """
  
      def sort_hist(self):
        """ Sort by histogram of face similarity """
          input_dir = self.args.input_dir
  
          print("Sorting by histogram similarity...")
  
          img_list = [
keep add keep keep keep keep keep
 Sort tool bugfixes and linting 
tools/sort.py