Skip to content

Commit 1e961cc

Browse files
committed
[release] Release v0.6.5.1 to fix #466
PyPI only release, no changes to Windows builds.
1 parent fbffe4c commit 1e961cc

File tree

5 files changed

+14
-14
lines changed

5 files changed

+14
-14
lines changed

requirements.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
#
22
# PySceneDetect Requirements
33
#
4-
# TODO(#466): Make av work with av >= 14.
5-
av >=9.2, <14.0
4+
av>=9.2
65
click>=8.0
76
numpy
87
opencv-python

requirements_headless.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
#
22
# PySceneDetect Requirements for Headless Machines
33
#
4-
# TODO(#466): Make av work with av >= 14.
5-
av >=9.2, <14.0
4+
av>=9.2
65
click>=8.0
76
numpy
87
opencv-python-headless

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"
59+
__version__ = "0.6.5.1"
6060

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

scenedetect/backends/pyav.py

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,7 @@
2323

2424
logger = getLogger("pyscenedetect")
2525

26-
VALID_THREAD_MODES = [
27-
av.codec.context.ThreadType.NONE,
28-
av.codec.context.ThreadType.SLICE,
29-
av.codec.context.ThreadType.FRAME,
30-
av.codec.context.ThreadType.AUTO,
31-
]
26+
VALID_THREAD_MODES = ["NONE", "SLICE", "FRAME", "AUTO"]
3227

3328

3429
class VideoStreamAv(VideoStream):
@@ -88,9 +83,12 @@ def __init__(
8883
self._reopened = True
8984

9085
if threading_mode:
91-
threading_mode = threading_mode.upper()
92-
if threading_mode not in VALID_THREAD_MODES:
93-
raise ValueError("Invalid threading mode! Must be one of: %s" % VALID_THREAD_MODES)
86+
try:
87+
threading_mode = av.codec.context.ThreadType[threading_mode.upper()]
88+
except KeyError as _:
89+
raise ValueError(
90+
"Invalid threading mode! Must be one of: %s" % VALID_THREAD_MODES
91+
) from None
9492

9593
if not suppress_output:
9694
logger.debug("Restoring default ffmpeg log callbacks.")

website/pages/changelog.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,10 @@ This release brings crop support, performance improvements to save-images, lots
3939
- OpenCV 4.10.0.82 -> 4.10.0.84
4040
- Ffmpeg 6.0 -> 7.1
4141

42+
#### Python Distribution Changes
43+
44+
* *v0.6.5.1* - Fix compatibility issues with PyAV 14+ [#466](https://github.com/Breakthrough/PySceneDetect/issues/466)
45+
4246

4347
### 0.6.4 (June 10, 2024)
4448

0 commit comments

Comments
 (0)