Skip to content

pleiszenburg/bewegung

Repository files navigation

bewegung_logo

BEWEGUNG

/bəˈveːɡʊŋ/ (German, noun, feminine: motion/movement/animation)

docs_master license status pypi_version conda_version pypi_versions chat mailing_list

Synopsis

bewegung is a versatile video renderer, primarily targeting scientific visualizations of large quantities of data. Its core concepts are sequences and layers. Sequences describe a certain time span within a video and can overlap. Each sequence can hold multiple layers. Layers can be generated with cairo, Pillow, datashader, matplotlib and bewegung's internal drawing system DrawingBoard. Final compositing of every video frame and video effects are implemented via Pillow. Video encoding is handled by ffmpeg. bewegung also includes a simple vector algebra system and a "camera" for 3D to 2D projections. bewegung is developed with ease of use, compute time and memory efficiency in mind.

Installation

bewegung can be installed both via conda and via pip.

Via conda

An almost complete installation can be triggered by running:

conda install -c conda-forge bewegung

Please note that mplcairo, a dependency of bewegung and alternative backend for matplotlib, is currently not available via conda and must be installed manually. bewegung does also work without mplcairo present and falls back to the cairo backend of matplotlib.

Via pip

A bare minimum of bewegung can be installed with Python's package manager pip:

pip install -vU bewegung

A complete installation of all optional Python components and development tools can be triggered by running:

pip install -vU bewegung[all]

Certain non-Python prerequisites must installed separately and before invoking the above command. For detailed instructions, see documentation. Most notably, ffmpeg should be installed for producing actual video files instead of video frames as individual files. See download section of the ffmpeg project website for further instructions.

Example

See demo.py.

You can directly test it by running:

curl https://raw.githubusercontent.com/pleiszenburg/bewegung/master/demo/demo.py | python3

This resulting video.mp4 file should look like this:

bewegung standard demo

Usage

See documentation.

bewegung's development status is "well-tested alpha". Its API should not be considered stable until the project is labeled "beta" or better.

bewegung can be drastically accelerated by deactivating debugging features. See relevant section in the documentation.