This package includes all methods to detect and split a given video into the basic shots. (currently focused on Abrupt Transitions).
PDF format: vhh_sbd_pdf
HTML format (only usable if repository is available in local storage): vhh_sbd_html
Requirements:
- Ubuntu 18.04 LTS (also tested on Windows 10)
- python version 3.6.x
Create a virtual environment:
- create a folder to a specified path (e.g. /xxx/vhh_sbd/)
python3 -m venv /xxx/vhh_sbd/
Activate the environment:
source /xxx/vhh_sbd/bin/activate
The VHH Shot Boundary Detection package is available on PyPI and can be installed via pip
.
- Update pip and setuptools (tested using pip==20.2.3 and setuptools==50.3.0)
pip install vhh-sbd
Alternatively, you can also build the package from source.
Checkout vhh_sbd repository to a specified folder:
git clone https://github.com/dahe-cvl/vhh_sbd
Install the sbd package and all dependencies:
- Update
pip
andsetuptools
(tested using pip==20.2.3 and setuptools==50.3.0) - Install the
wheel
package:pip install wheel
- change to the root directory of the repository (includes setup.py)
python setup.py bdist_wheel
- The aforementioned command should create a /dist directory containing a wheel. Install the package using
python -m pip install dist/xxx.whl
NOTE: You can check the success of the installation by using the command pip list. This command should give you a list with all installed python packages and it should include vhh-sbd.
Install a Version of PyTorch depending on your setup. Consult the PyTorch website for detailed instructions.
source /data/dhelm/python_virtenv/vhh_sbd_env/bin/activate
export CUDA_VISIBLE_DEVICES=1
export PYTHONPATH=$PYTHONPATH:/XXX/vhh_sbd/:/XXX/vhh_sbd/Develop/:/XXX/vhh_sbd/Demo/
- change to root directory of the repository
python Demo/vhh_sbd_run_on_single_video.py
NOTE: Do not forget to change paths in demo script!
- Create and checkout release branch: (e.g. v1.1.0):
git checkout -b v1.1.0
- Update version number in setup.py
- Update Sphinx documentation and release version
- Make sure that
pip
andsetuptools
are up to date - Install
wheel
andtwine
- Build Source Archive and Built Distribution using
python setup.py sdist bdist_wheel
- Upload package to PyPI using
twine upload dist/*