Automatic video chapterization.
usage: app.py [-h] [--word-count WORD_COUNT] [--chapters CHAPTERS]
Chapterize a YouTube video.
optional arguments:
-h, --help show this help message and exit
--word-count WORD_COUNT, -w WORD_COUNT
Number of words in the summary for each section.
--chapters CHAPTERS, -c CHAPTERS
Number of chapters to return.
The following describes how to run the app in a Docker container by first building the image from the Dockerfile.
-
Build the container
cd path/to/chappy docker build -t chappy .
-
Run the container and run the app
docker run -it chappy bash # Inside the container $ poetry run python3 src/app.py
You can re-use the above container and simply mount your locally checked-out repository.
-
Build the container.
docker build -t chappy . -
Download the punctuator model locally, since it will be mounted in the next step:
./download_models.sh
-
Run the container in the background and mount the local repo.
docker run -dit -v /path/to/chappy:/app/chappy chappy:latest bash
-
Get into the container's shell.
docker exec -it <container-name> bash
-
Run it or run the tests.
poetry run python3 src/app.py
poetry run pytest
Use poetry for this. Example:
poetry add pandas