                  placeholder,
                  flags=cv2.WARP_INVERSE_MAP | interpolator,  # pylint: disable=no-member
                  borderMode=cv2.BORDER_TRANSPARENT)  # pylint: disable=no-member
  
              placeholder = np.clip(placeholder, 0.0, 1.0)
          logger.trace("Got filename: '%s'. (placeholders: %s)",
                       predicted["filename"], placeholder.shape)
  
          return placeholder
  
 
</s> remove             placeholder = cv2.warpAffine(  # pylint: disable=no-member
 </s> add             cv2.warpAffine(  # pylint: disable=no-member </s> remove         return placeholder
 </s> add         return placeholder, background </s> remove         return np.clip(frame, 0.0, 1.0)
 </s> add         np.clip(frame, 0.0, 1.0, out=frame)
        return frame </s> remove         placeholder = predicted["image"] / 255.0
        placeholder = np.concatenate((placeholder,
                                      np.zeros((frame_size[1], frame_size[0], 1))),
                                     axis=-1).astype("float32")
 </s> add         placeholder = np.zeros((frame_size[1], frame_size[0], 4), dtype="float32")
        background = predicted["image"] / np.array(255.0, dtype="float32")
        placeholder[:, :, :3] = background
 </s> remove             logger.trace("Patch queue got: '%s'", item["filename"])

            try:
                image = self.patch_image(item)
            except Exception as err:  # pylint: disable=broad-except
                # Log error and output original frame
                logger.error("Failed to convert image: '%s'. Reason: %s",
                             item["filename"], str(err))
                image = item["image"]
                # UNCOMMENT THIS CODE BLOCK TO PRINT TRACEBACK ERRORS
                # import sys
                # import traceback
                # exc_info = sys.exc_info()
                # traceback.print_exception(*exc_info)

            logger.trace("Out queue put: %s", item["filename"])
            out_queue.put((item["filename"], image))
 </s> add             for item in items:
                logger.trace("Patch queue got: '%s'", item["filename"])
                try:
                    image = self.patch_image(item)
                except Exception as err:  # pylint: disable=broad-except
                    # Log error and output original frame
                    logger.error("Failed to convert image: '%s'. Reason: %s",
                                 item["filename"], str(err))
                    image = item["image"]
                    # UNCOMMENT THIS CODE BLOCK TO PRINT TRACEBACK ERRORS
                    # import sys
                    # import traceback
                    # exc_info = sys.exc_info()
                    # traceback.print_exception(*exc_info)

                logger.trace("Out queue put: %s", item["filename"])
                out_queue.put((item["filename"], image))
        np.clip(placeholder, 0.0, 1.0, out=placeholder)
                  placeholder,
                  flags=cv2.WARP_INVERSE_MAP | interpolator,  # pylint: disable=no-member
                  borderMode=cv2.BORDER_TRANSPARENT)  # pylint: disable=no-member
  
        np.clip(placeholder, 0.0, 1.0, out=placeholder)
          logger.trace("Got filename: '%s'. (placeholders: %s)",
                       predicted["filename"], placeholder.shape)
  
          return placeholder
  
keep keep keep keep replace keep keep keep keep keep
 Optimized numpy functions in Converter (#838) 
lib/convert.py