                  if idx > 0 and self.arguments.verbose:
                      print('- Found more than one face!')
                      self.verify_output = True
  
                  new_face = convert_one_image(cv2.resize(face.image, (256, 256)), self.arguments.model_dir)
                  image[slice(face.y, face.y + face.h), slice(face.x, face.x + face.w)] = cv2.resize(new_face, (face.w, face.h))
                  self.faces_detected = self.faces_detected + 1
              output_file = self.output_dir / Path(filename).name
              cv2.imwrite(str(output_file), image)
          except Exception as e:
 
</s> remove     return superpose(image, new_face, crop)
 </s> add  </s> remove     decoder_A.load_weights(model_dir + "/decoder_A.h5")
    decoder_B.load_weights(model_dir + "/decoder_B.h5")
 </s> add     decoder_A.load_weights(model_dir + face_A)
    decoder_B.load_weights(model_dir + face_B) </s> remove     aligner = Aligner(shapePredictor, humanFaceDetector)
 </s> add     if use_aligner:
        aligner = Aligner(shapePredictor, humanFaceDetector) </s> remove def convert_one_image(image, model_dir="models"):
 </s> add def convert_one_image(image, model_dir="models", swap_model=False, use_aligner=False):

    face_A = '/decoder_A.h5' if not swap_model else '/decoder_B.h5'
    face_B = '/decoder_B.h5' if not swap_model else '/decoder_A.h5' </s> remove     # result = aligner.align(image.copy(), new_face)
    # if result is None:
    #     return superpose(image, new_face, crop)
    # else:
    #     return result
 </s> add     if use_aligner:
        return aligner.align(image.copy(), new_face)
    else:
        return superpose(image, new_face, crop)
                new_face = convert_one_image(cv2.resize(face.image, (256, 256)), self.arguments.model_dir, self.arguments.swap_model)
                  if idx > 0 and self.arguments.verbose:
                      print('- Found more than one face!')
                      self.verify_output = True
  
                new_face = convert_one_image(cv2.resize(face.image, (256, 256)), self.arguments.model_dir, self.arguments.swap_model)
                  image[slice(face.y, face.y + face.h), slice(face.x, face.x + face.w)] = cv2.resize(new_face, (face.w, face.h))
                  self.faces_detected = self.faces_detected + 1
              output_file = self.output_dir / Path(filename).name
              cv2.imwrite(str(output_file), image)
          except Exception as e:
keep keep keep keep replace keep keep keep keep keep
 Allow users to swap the A/B models (#29)

* Allow users to swap the conversion models. 
scripts/convert.py