          """ Number of faces or frames """
          if self._count is not None:
              return self._count
          if self.is_video:
              self._count = int(count_frames_and_secs(self.folder)[0])
          else:
              self._count = len(self.file_list_sorted)
          return self._count
  
      def check_input_folder(self):
 
</s> remove     attempts = 3
    for attempt in range(attempts):
        try:
            logger.debug("attempt: %s of %s", attempt + 1, attempts)
            out = subprocess.check_output(cmd,
                                          stderr=subprocess.STDOUT,
                                          shell=iswin,
                                          timeout=timeout)
            logger.debug("Succesfully communicated with FFMPEG")
 </s> add     process = subprocess.Popen(cmd,
                               stderr=subprocess.STDOUT,
                               stdout=subprocess.PIPE,
                               universal_newlines=True)
    pbar = None
    duration = None
    init_tqdm = False
    update = 0
    frames = 0
    while True:
        output = process.stdout.readline().strip()
        if output == "" and process.poll() is not None: </s> remove     # https://stackoverflow.com/questions/2017843/fetch-frame-count-with-ffmpeg

 </s> add 
            self._count = int(count_frames(self.folder))
          """ Number of faces or frames """
          if self._count is not None:
              return self._count
          if self.is_video:
            self._count = int(count_frames(self.folder))
          else:
              self._count = len(self.file_list_sorted)
          return self._count
  
      def check_input_folder(self):
keep keep keep keep replace keep keep keep keep keep
 bugfix: lib.image - Ensure video frame count is always read correctly 
tools/lib_alignments/media.py