          else:
              retval = read_image(filename, raise_error=True)
          return retval
  
      def load_one_video_frame(self, frame_no):
          """ Load a single frame from a video file """
          logger.trace("Loading video frame: %s", frame_no)
          reader = imageio.get_reader(self.args.input_dir, "ffmpeg")
          reader.set_image_index(frame_no - 1)
          frame = reader.get_next_data()[:, :, ::-1]
          reader.close()
 
</s> remove         reader = imageio.get_reader(self.args.input_dir, "ffmpeg")
 </s> add         reader = imageio.get_reader(self._args.input_dir, "ffmpeg") </s> remove         vidname = os.path.splitext(os.path.basename(self.args.input_dir))[0]
        reader = imageio.get_reader(self.args.input_dir, "ffmpeg")
 </s> add         vidname = os.path.splitext(os.path.basename(self._args.input_dir))[0]
        reader = imageio.get_reader(self._args.input_dir, "ffmpeg") </s> remove             retval = self.load_one_video_frame(int(frame_no))
 </s> add             retval = self._load_one_video_frame(int(frame_no)) </s> remove     def load_video_frames(self):
        """ Return frames from a video file """
 </s> add     def _load_video_frames(self):
        """ Generator to load frames from a video file.

        Yields
        ------
        filename: str
            The filename of the current frame
        image: :class:`numpy.ndarray`
            A single frame
        """ </s> remove     def count_images(self):
        """ Number of images or frames """
        if self.is_video:
            retval = int(count_frames(self.args.input_dir, fast=True))
 </s> add     @property
    def is_video(self):
        """bool: ``True`` if the input is a video file otherwise ``False``. """
        return self._is_video

    @property
    def input_images(self):
        """str or list: Path to the video file if the input is a video otherwise list of
        image paths. """
        return self._input_images

    @property
    def images_found(self):
        """int: The number of frames that exist in the video file, or the folder of images. """
        return self._images_found

    def _count_images(self):
        """ Get the number of Frames from a video file or folder of images.

        Returns
        -------
        int
            The number of frames in the image source
        """
        if self._is_video:
            retval = int(count_frames(self._args.input_dir, fast=True))
    def _load_one_video_frame(self, frame_no):
        """ Obtain a single frame from a video file.

        Parameters
        ----------
        frame_no: int
            The frame index for the required frame

        Returns
        ------
        :class:`numpy.ndarray`
            The image for the requested frame index,
        """
          else:
              retval = read_image(filename, raise_error=True)
          return retval
  
    def _load_one_video_frame(self, frame_no):
        """ Obtain a single frame from a video file.

        Parameters
        ----------
        frame_no: int
            The frame index for the required frame

        Returns
        ------
        :class:`numpy.ndarray`
            The image for the requested frame index,
        """
    def _load_one_video_frame(self, frame_no):
        """ Obtain a single frame from a video file.

        Parameters
        ----------
        frame_no: int
            The frame index for the required frame

        Returns
        ------
        :class:`numpy.ndarray`
            The image for the requested frame index,
        """
          logger.trace("Loading video frame: %s", frame_no)
          reader = imageio.get_reader(self.args.input_dir, "ffmpeg")
          reader.set_image_index(frame_no - 1)
          frame = reader.get_next_data()[:, :, ::-1]
          reader.close()
keep keep keep keep replace replace keep keep keep keep keep
 Smart Masks to Convert (#957)

- scripts.convert - Use Smart Masks for Convert
    * Make on-the-fly conversion an explicit option

- Move BlurMask to lib.faces_detect

- tools.preview - Fix for smart masks
    * Subclass from tk.Tk
    * Options to lib.gui.control_helper
    *variable cleanup

- lib.logger - Demote more tensorflow deprecation messages

- Documentation:
    * lib.faces_detect.BlurMask
    * plugins.convert.mask
    * lib.convert
    * scripts.convert
    * scripts.fsmedia
    * tools.preview 
scripts/fsmedia.py