Skip to content

Commit

Permalink
[release] 0.6-dev2
Browse files Browse the repository at this point in the history
  • Loading branch information
Breakthrough committed Mar 7, 2022
1 parent eab349e commit fd455a0
Show file tree
Hide file tree
Showing 14 changed files with 43 additions and 40 deletions.
24 changes: 12 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ Video Scene Cut Detection and Analysis Tool

----------------------------------------------------------

### Version: v0.6-dev (TBD)
### Latest Release: v0.6-dev2 (March 6, 2022)

**Website**: http://www.scenedetect.com

**Getting Started**: [Usage Example](https://pyscenedetect.readthedocs.io/en/latest/examples/usage-example/)
**Getting Started**: [Usage Example](https://scenedetect.com/examples/usage-example/)

**Documentation**: http://manual.scenedetect.com

Expand All @@ -22,11 +22,11 @@ Video Scene Cut Detection and Analysis Tool

**Quick Install**: To install PySceneDetect via `pip` with all dependencies:

pip install scenedetect[opencv]
pip install scenedetect[opencv] --pre

For servers, you can use the headless (non-GUI) version of OpenCV by installing `scenedetect[opencv-headless]`. To enable video splitting support, you will also need to have `mkvmerge` or `ffmpeg` installed - see the documentation on [Video Splitting Support](https://pyscenedetect.readthedocs.io/en/latest/examples/video-splitting/) for details.
For servers, you can use the headless (non-GUI) version of OpenCV by installing `scenedetect[opencv-headless]`. To enable video splitting support, you will also need to have `mkvmerge` or `ffmpeg` installed - see the documentation on [Video Splitting Support](https://scenedetect.com/examples/video-splitting/) for details.

Requires Python modules `click`, `numpy`, OpenCV `cv2`, and (optional) `tqdm` for displaying progress. For details, see the [dependencies on the downloads page](https://pyscenedetect.readthedocs.io/en/latest/download/#dependencies).
Requires Python modules `click`, `numpy`, OpenCV `cv2`, and (optional) `tqdm` for displaying progress. For details, see the [dependencies on the downloads page](https://scenedetect.com/download/#dependencies).

----------------------------------------------------------

Expand All @@ -44,7 +44,7 @@ To show a summary of all other options and commands:

scenedetect help

You can find more examples [on the website](https://pyscenedetect.readthedocs.io/en/latest/examples/usage-example/) or [in the manual](https://pyscenedetect.readthedocs.io/projects/Manual/en/latest/cli/global_options.html).
You can find more examples [on the website](https://scenedetect.com/examples/usage-example/) or [in the manual](https://manual.scenedetect.com/en/v0.6-dev2/cli/global_options.html).

**Quick Start (Python API)**:

Expand Down Expand Up @@ -75,7 +75,7 @@ scene_list = detect('my_video.mp4', ContentDetector())
split_video_ffmpeg('my_video.mp4', scene_list)
```

For more advanced usage, the API is highly configurable, and can easily integrate with any pipeline. This includes using different detection algorithms, splitting the input video, and much more. The following example shows how to implement a function similar to the above, but using [the `scenedetect` API](https://pyscenedetect.readthedocs.io/projects/Manual/en/latest/api.html):
For more advanced usage, the API is highly configurable, and can easily integrate with any pipeline. This includes using different detection algorithms, splitting the input video, and much more. The following example shows how to implement a function similar to the above, but using [the `scenedetect` API](https://manual.scenedetect.com/en/v0.6-dev2/api.html):

```python
from scenedetect import open_video, SceneManager, split_video_ffmpeg
Expand All @@ -93,12 +93,12 @@ def split_video_into_scenes(video_path, threshold=27.0):
split_video_ffmpeg(video_path, scene_list, show_progress=True)
```

See [the manual](https://pyscenedetect.readthedocs.io/projects/Manual/en/latest/api.html) for the
See [the manual](https://manual.scenedetect.com/en/v0.6-dev2/api.html) for the
full PySceneDetect API documentation.

----------------------------------------------------------

PySceneDetect is a command-line tool and Python library, which uses OpenCV to analyze a video to find each shot change (or "cut"/"scene"). If `ffmpeg` or `mkvmerge` is installed, the video can also be split into scenes automatically. A frame-by-frame analysis can also be generated for a video, to help with determining optimal threshold values or detecting patterns/other analysis methods for a particular video. See [the Usage documentation](https://pyscenedetect.readthedocs.io/en/latest/examples/usage/) for details.
PySceneDetect is a command-line tool and Python library, which uses OpenCV to analyze a video to find each shot change (or "cut"/"scene"). If `ffmpeg` or `mkvmerge` is installed, the video can also be split into scenes automatically. A frame-by-frame analysis can also be generated for a video, to help with determining optimal threshold values or detecting patterns/other analysis methods for a particular video. See [the Usage documentation](https://scenedetect.com/examples/usage/) for details.

There are two main detection methods PySceneDetect uses: `detect-threshold` (comparing each frame to a set black level, useful for detecting cuts and fades to/from black), and `detect-content` (compares each frame sequentially looking for changes in content, useful for detecting fast cuts between video scenes, although slower to process). Each mode has slightly different parameters, and is described in detail below.

Expand All @@ -110,9 +110,9 @@ For help or other issues, you can join [the official PySceneDetect Discord Serve
Usage
----------------------------------------------------------

- [Basic Usage](https://pyscenedetect.readthedocs.io/en/latest/examples/usage/)
- [PySceneDetect Manual](https://pyscenedetect-manual.readthedocs.io/en/latest/), covers `scenedetect` command and Python API
- [Example: Detecting and Splitting Scenes in Movie Clip](https://pyscenedetect.readthedocs.io/en/latest/examples/usage-example/)
- [Basic Usage](https://scenedetect.com/en/latest/examples/usage/)
- [PySceneDetect Manual](https://manual.scenedetect.com/io/en/latest/), covers `scenedetect` command and Python API
- [Example: Detecting and Splitting Scenes in Movie Clip](https://scenedetect.com/examples/usage-example/)


Features & Roadmap
Expand Down
4 changes: 3 additions & 1 deletion docs/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,12 @@ PySceneDetect Releases

## PySceneDetect 0.6

### 0.6 (TBD)
### 0.6-dev2 (March 6, 2022)

#### Release Notes

**This is a pre-release of the upcoming PySceneDetect v0.6.**

PySceneDetect v0.6 is a **major breaking change** including better performance, configuration file support, and a more ergonomic API. The new **minimum Python version is now 3.6**. See the [Migration Guide](https://manual.scenedetect.com/v0.6/api/migration_guide.html) for information on how to port existing applications to the new API. Most users will see performance improvements after updating, and changes to the command-line are not expected to break most workflows.

The main goals of v0.6 are reliability and performance. To achieve this required several breaking changes. The video input API was refactored, and *many* technical debt items were addressed. This should help the eventual transition to the first planned stable release (v1.0) where the goal is an improved scene detection API.
Expand Down
16 changes: 8 additions & 8 deletions docs/download.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,27 +11,27 @@ PySceneDetect requires at least Python 3.6 or higher.

<div class="important">
<h4 class="wy-text-neutral"><span class="fa fa-angle-double-down wy-text-info"></span> Including OpenCV (recommended):</h4>
<h3 class="wy-text-neutral"><tt>pip install scenedetect[opencv]</tt></h3>
<h3 class="wy-text-neutral"><tt>pip install --pre scenedetect[opencv]</tt></h3>
<h4 class="wy-text-neutral"><span class="fa fa-angle-down wy-text-info"></span> Including Headless OpenCV :</h4>
<h3 class="wy-text-neutral"><tt>pip install scenedetect[opencv-headless]</tt></h3>
<h3 class="wy-text-neutral"><tt>pip install --pre scenedetect[opencv-headless]</tt></h3>
</div>

PySceneDetect is available via `pip` as [the `scenedetect` package](https://pypi.org/project/scenedetect/). See below for instructions on installing a non-pip version of OpenCV. To ensure you have all the requirements installed, open a `python` interpreter, and ensure you can run `import cv2` without any errors.

### Windows Build (64-bit Only) &nbsp; <span class="wy-text-neutral"><span class="fa fa-windows"></span></span>

<div class="important">
<h3 class="wy-text-neutral"><span class="fa fa-forward wy-text-info"></span> Latest Release: <b class="wy-text-neutral">v0.5.6</b></h3>
<h4 class="wy-text-neutral"><span class="fa fa-calendar wy-text-info"></span>&nbsp; Release Date:&nbsp; <b>August 15, 2021</b></h4>
<a href="https://github.com/Breakthrough/PySceneDetect/releases/download/v0.5.6/PySceneDetect-0.5.6-win64.exe" class="btn btn-info" style="margin-bottom:8px;" role="button"><span class="fa fa-download"></span>&nbsp; <b>Installer</b>&nbsp;&nbsp;(recommended)</a> &nbsp;&nbsp;&nbsp;&nbsp; <a href="https://github.com/Breakthrough/PySceneDetect/releases/download/v0.5.6/PySceneDetect-0.5.6-win64-portable.zip" class="btn btn-info" style="margin-bottom:8px;" role="button"><span class="fa fa-download"></span>&nbsp; <b>Portable .zip</b></a> &nbsp;&nbsp;&nbsp;&nbsp; <a href="../examples/usage/" class="btn btn-success" style="margin-bottom:8px;" role="button"><span class="fa fa-book"></span>&nbsp; <b>Getting Started</b></a>
<h3 class="wy-text-neutral"><span class="fa fa-forward wy-text-info"></span> Latest Release: <b class="wy-text-neutral">v0.6-dev2</b></h3>
<h4 class="wy-text-neutral"><span class="fa fa-calendar wy-text-info"></span>&nbsp; Release Date:&nbsp; <b>March 6, 2022</b></h4>
<a href="https://github.com/Breakthrough/PySceneDetect/releases/download/v0.6-dev2/PySceneDetect-0.6-dev2-win64-portable.zip" class="btn btn-info" style="margin-bottom:8px;" role="button"><span class="fa fa-download"></span>&nbsp; <b>Portable .zip</b></a> &nbsp;&nbsp;&nbsp;&nbsp; <a href="../examples/usage/" class="btn btn-success" style="margin-bottom:8px;" role="button"><span class="fa fa-book"></span>&nbsp; <b>Getting Started</b></a>
</div>

### Python Installer (All Platforms) &nbsp; <span class="wy-text-neutral"><span class="fa fa-windows"></span> &nbsp; <span class="fa fa-linux"></span> &nbsp; <span class="fa fa-apple"></span></span></h3>

<div class="important">
<h4 class="wy-text-neutral"><span class="fa fa-forward wy-text-info"></span> Latest Release: <b class="wy-text-neutral">v0.5.6.1</b></h4>
<h4 class="wy-text-neutral"><span class="fa fa-calendar wy-text-info"></span>&nbsp; Release Date:&nbsp; <b>October 11, 2021</b></h4>
<a href="https://github.com/Breakthrough/PySceneDetect/archive/v0.5.6.1.zip" class="btn btn-info" style="margin-bottom:8px;" role="button"><span class="fa fa-download"></span>&nbsp; <b>Source</b>&nbsp;&nbsp;.zip</a> &nbsp;&nbsp;&nbsp;&nbsp; <a href="https://github.com/Breakthrough/PySceneDetect/archive/v0.5.6.1.tar.gz" class="btn btn-info" style="margin-bottom:8px;" role="button"><span class="fa fa-download"></span>&nbsp; <b>Source</b>&nbsp;&nbsp;.tar.gz</a> &nbsp;&nbsp;&nbsp;&nbsp; <a href="../examples/usage/" class="btn btn-success" style="margin-bottom:8px;" role="button"><span class="fa fa-book"></span>&nbsp; <b>Getting Started</b></a>
<h4 class="wy-text-neutral"><span class="fa fa-forward wy-text-info"></span> Latest Release: <b class="wy-text-neutral">v0.6-dev2</b></h4>
<h4 class="wy-text-neutral"><span class="fa fa-calendar wy-text-info"></span>&nbsp; Release Date:&nbsp; <b>March 6, 2022</b></h4>
<a href="https://github.com/Breakthrough/PySceneDetect/archive/v0.6-dev2.zip" class="btn btn-info" style="margin-bottom:8px;" role="button"><span class="fa fa-download"></span>&nbsp; <b>Source</b>&nbsp;&nbsp;.zip</a> &nbsp;&nbsp;&nbsp;&nbsp; <a href="https://github.com/Breakthrough/PySceneDetect/archive/v0.6-dev2.tar.gz" class="btn btn-info" style="margin-bottom:8px;" role="button"><span class="fa fa-download"></span>&nbsp; <b>Source</b>&nbsp;&nbsp;.tar.gz</a> &nbsp;&nbsp;&nbsp;&nbsp; <a href="../examples/usage/" class="btn btn-success" style="margin-bottom:8px;" role="button"><span class="fa fa-book"></span>&nbsp; <b>Getting Started</b></a>
</div>

To install from source, download and extract the latest release to a location of your choice, and make sure you have the appropriate [system requirements](#dependencies) installed before continuing. PySceneDetect can be installed by running the following command in the location of the extracted files (don't forget `sudo` if you're installing system-wide):
Expand Down
2 changes: 1 addition & 1 deletion docs/examples/usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ scenedetect help
```

<div class="important">
The complete PySceneDetect Command-Line Interface (CLI) Reference <span class="fa fa-book"> can be found in the <a href="http://pyscenedetect-manual.readthedocs.io/" alt="Manual Link">PySceneDetect Manual</a>, located at <a href="http://pyscenedetect-manual.readthedocs.io/" alt="Manual Link">pyscenedetect-manual.readthedocs.io/</a>.
The complete PySceneDetect Command-Line Interface (CLI) Reference <span class="fa fa-book"> can be found in the <a href="http://manual.scenedetect.com/en/0.6-dev2/" alt="Manual Link">PySceneDetect Manual</a>, located at <a href="http://manual.scenedetect.com/0.6-dev2/" alt="Manual Link">manual.scenedetect.com/0.6-dev2/</a>.
</div>


Expand Down
2 changes: 1 addition & 1 deletion docs/faq.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ Unlike calling `pip install opencv-python`, the above commands will download and

#### How can I enable video splitting support?

To enable video splitting support, you will also need to have `mkvmerge` or `ffmpeg` installed on your system. See the documentation on [Video Splitting Support](https://pyscenedetect.readthedocs.io/en/latest/examples/video-splitting/) after installation for details.
To enable video splitting support, you will also need to have `mkvmerge` or `ffmpeg` installed on your system. See the documentation on [Video Splitting Support](https://scenedetect.com/examples/video-splitting/) after installation for details.


#### How can I fix the error `Cannot split video due to too many scenes`?
Expand Down
4 changes: 2 additions & 2 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
<h4 class="wy-text-info">Intelligent scene cut detection and video splitting tool.</h4>

<div class="important">
<h3 class="wy-text-neutral"><span class="fa fa-info-circle wy-text-info"></span>&nbsp; Latest Release: <b>v0.5.6.1</b> (October 11, 2021)</h3>
<a href="download/" class="btn btn-success" style="margin-bottom:8px;" role="button"><span class="fa fa-download"></span>&nbsp; <b>Download</b></a> &nbsp;&nbsp;&nbsp;&nbsp; <a href="changelog/" class="btn btn-info" style="margin-bottom:8px;" role="button"><span class="fa fa-reorder"></span>&nbsp; <b>Changelog</b></a> &nbsp;&nbsp;&nbsp;&nbsp; <a href="http://pyscenedetect-manual.readthedocs.io/" class="btn btn-warning" style="margin-bottom:8px;" role="button"><span class="fa fa-gear"></span>&nbsp; <b>Manual</b></a> &nbsp;&nbsp;&nbsp;&nbsp; <a href="examples/usage-example/" class="btn btn-danger" style="margin-bottom:8px;" role="button"><span class="fa fa-book"></span>&nbsp; <b>Getting Started</b></a>
<h3 class="wy-text-neutral"><span class="fa fa-info-circle wy-text-info"></span>&nbsp; Latest Release: <b>v0.6-dev2</b> (March 6, 2022)</h3>
<a href="download/" class="btn btn-success" style="margin-bottom:8px;" role="button"><span class="fa fa-download"></span>&nbsp; <b>Download</b></a> &nbsp;&nbsp;&nbsp;&nbsp; <a href="changelog/" class="btn btn-info" style="margin-bottom:8px;" role="button"><span class="fa fa-reorder"></span>&nbsp; <b>Changelog</b></a> &nbsp;&nbsp;&nbsp;&nbsp; <a href="http://pyscenedetect-manual.readthedocs.io/en/v0.6-dev2/" class="btn btn-warning" style="margin-bottom:8px;" role="button"><span class="fa fa-gear"></span>&nbsp; <b>Manual</b></a> &nbsp;&nbsp;&nbsp;&nbsp; <a href="examples/usage-example/" class="btn btn-danger" style="margin-bottom:8px;" role="button"><span class="fa fa-book"></span>&nbsp; <b>Getting Started</b></a>
<br/>
See the changelog for the latest release notes and known issues.
</div>
Expand Down
8 changes: 4 additions & 4 deletions docs/reference/command-line.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@

## PySceneDetect CLI Reference

The `scenedetect` command reference is available as part of [the PySceneDetect Manual](http://pyscenedetect-manual.readthedocs.io/):
The `scenedetect` command reference is available as part of [the PySceneDetect Manual](http://manual.scenedetect.com/):

- [`scenedetect` Options](http://pyscenedetect-manual.readthedocs.io/en/latest/cli/global_options.html)
- [Command Reference](http://pyscenedetect-manual.readthedocs.io/en/latest/cli/commands.html)
- [Detector Reference](http://pyscenedetect-manual.readthedocs.io/en/latest/cli/detectors.html)
- [`scenedetect` Options](http://manual.scenedetect.com/en/0.6-dev2/cli/global_options.html)
- [Command Reference](http://manual.scenedetect.com/en/0.6-dev2/cli/commands.html)
- [Detector Reference](http://manual.scenedetect.com/en/0.6-dev2/cli/detectors.html)

You can also run `scenedetect help all` locally for the full `scenedetect command reference.
4 changes: 2 additions & 2 deletions docs/reference/detection-methods.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ The threshold-based scene detector (`detect-threshold`) is how most traditional

# Creating New Detection Algorithms

All scene detection algorithms must inherit from [the base `SceneDetector` class](https://pyscenedetect.readthedocs.io/projects/Manual/en/latest/api/scene_detector.html). Note that the current SceneDetector API is under development and expected to change somewhat before v1.0 is released, so make sure to pin your `scenedetect` dependency to the correct API version (e.g. `scenedetect < 0.6`, `scenedetect < 0.7`, etc...).
All scene detection algorithms must inherit from [the base `SceneDetector` class](https://manual.scenedetect.com/en/v0.6-dev2/api/scene_detector.html). Note that the current SceneDetector API is under development and expected to change somewhat before v1.0 is released, so make sure to pin your `scenedetect` dependency to the correct API version (e.g. `scenedetect < 0.6`, `scenedetect < 0.7`, etc...).

Creating a new scene detection method can be as simple as implementing the `process_frame` function, and optionally `post_process`:

Expand All @@ -45,7 +45,7 @@ class CustomDetector(SceneDetector):

`process_frame` is called on every frame in the input video, which will be called after the final frame of the video is passed to `process_frame`. This may be useful for multi-pass algorithms, or detectors which are waiting on some condition but still wish to output an event on the final frame.

For example, a detector may output at most 1 cuts for every call to `process_frame`, it may output the entire scene list in `post_process`, or a combination of both. Note that the latter will not work in cases where a live video stream or camera input device is being used. See the [API documentation for the `SceneDetector` class](https://pyscenedetect.readthedocs.io/projects/Manual/en/latest/api/scene_detector.html#scenedetect.scene_detector.SceneDetector) for details. Alternatively, you can call `help(SceneDetector)` from a Python REPL. For examples of actual detection algorithm implementations, see the source files in the `scenedetect/detectors/` directory (e.g. `threshold_detector.py`, `content_detector.py`).
For example, a detector may output at most 1 cuts for every call to `process_frame`, it may output the entire scene list in `post_process`, or a combination of both. Note that the latter will not work in cases where a live video stream or camera input device is being used. See the [API documentation for the `SceneDetector` class](https://manual.scenedetect.com/en/v0.6-dev2/api/scene_detector.html#scenedetect.scene_detector.SceneDetector) for details. Alternatively, you can call `help(SceneDetector)` from a Python REPL. For examples of actual detection algorithm implementations, see the source files in the `scenedetect/detectors/` directory (e.g. `threshold_detector.py`, `content_detector.py`).

Processing is done by calling the `process_frame(...)` function for all frames in the video, followed by `post_process(...)` (optional) after the final frame. Scene cuts are detected and added to the passed list object in both cases.

Expand Down
Loading

0 comments on commit fd455a0

Please sign in to comment.