      """ Encode the image, get the hash and return the hash with
          encoded image """
      img = cv2.imencode(extension, image)[1]  # pylint: disable=no-member
      f_hash = sha1(
          cv2.imdecode(img, cv2.IMREAD_UNCHANGED)).hexdigest()  # pylint: disable=no-member
      return f_hash, img
  
  
  def backup_file(directory, filename):
      """ Backup a given file by appending .bk to the end """
 
</s> remove     img = cv2.imencode(extension, image)[1]  # pylint: disable=no-member
 </s> add     img = cv2.imencode(extension, image)[1]  # pylint:disable=no-member,c-extension-no-member </s> remove     logger = logging.getLogger(__name__)  # pylint: disable=invalid-name
 </s> add     logger = logging.getLogger(__name__)  # pylint:disable=invalid-name </s> remove     logger = logging.getLogger(__name__)  # pylint: disable=invalid-name
 </s> add     logger = logging.getLogger(__name__)  # pylint:disable=invalid-name </s> remove     logger = logging.getLogger(__name__)  # pylint: disable=invalid-name
 </s> add     logger = logging.getLogger(__name__)  # pylint:disable=invalid-name </s> remove     logger = logging.getLogger(__name__)  # pylint: disable=invalid-name
 </s> add     logger = logging.getLogger(__name__)  # pylint:disable=invalid-name
        cv2.imdecode(  # pylint:disable=no-member,c-extension-no-member
            img,
            cv2.IMREAD_UNCHANGED)).hexdigest()  # pylint:disable=no-member,c-extension-no-member
      """ Encode the image, get the hash and return the hash with
          encoded image """
      img = cv2.imencode(extension, image)[1]  # pylint: disable=no-member
      f_hash = sha1(
        cv2.imdecode(  # pylint:disable=no-member,c-extension-no-member
            img,
            cv2.IMREAD_UNCHANGED)).hexdigest()  # pylint:disable=no-member,c-extension-no-member
      return f_hash, img
  
  
  def backup_file(directory, filename):
      """ Backup a given file by appending .bk to the end """
keep keep keep keep replace keep keep keep keep keep
 FaceswapError Exception. Added to cli and utils 
lib/utils.py