Skip to content

Commit 69c1922

Browse files
committed
[bugfix] Fix incorrect type hint leading to runtime failures #468
1 parent d7b0972 commit 69c1922

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

scenedetect/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@
5656

5757
# Used for module identification and when printing version & about info
5858
# (e.g. calling `scenedetect version` or `scenedetect about`).
59-
__version__ = "0.6.5.1"
59+
__version__ = "0.6.5.2"
6060

6161
init_logger()
6262
logger = getLogger("pyscenedetect")

scenedetect/scene_manager.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -410,13 +410,13 @@ def write_scene_list_html(
410410

411411

412412
def _scale_image(
413-
image: cv2.Mat,
413+
image: np.ndarray,
414414
aspect_ratio: float,
415415
height: ty.Optional[int],
416416
width: ty.Optional[int],
417417
scale: ty.Optional[float],
418418
interpolation: Interpolation,
419-
) -> cv2.Mat:
419+
) -> np.ndarray:
420420
# TODO: Combine this resize with the ones below.
421421
if aspect_ratio is not None:
422422
image = cv2.resize(
@@ -709,9 +709,9 @@ def generate_timecode_list(self, scene_list: SceneList) -> ty.List[ty.Iterable[F
709709

710710
def resize_image(
711711
self,
712-
image: cv2.Mat,
712+
image: np.ndarray,
713713
aspect_ratio: float,
714-
) -> cv2.Mat:
714+
) -> np.ndarray:
715715
return _scale_image(
716716
image, aspect_ratio, self._height, self._width, self._scale, self._interpolation
717717
)

0 commit comments

Comments
 (0)