datamoshing

Optical Flow Transfer

Transfer optical flow from one video to an image.

Getting Started

Prerequisites

You’ll need a working installation of Python 3, and FFmpeg. Make sure they are in PATH.

Installation

Download or clone this repository:

git clone https://github.com/ychalier/datamoshing.git
cd datamoshing/optical-flow-transfer/

Install the requirements:

pip -m install requirements.txt

Usage

Simply execute the main script:

python optical_flow_transfer.py <source-video> <source-image> <output-video>

Example

I wrote some details on my blog.

Demo

Here is a web demonstration where you may try different video sources (such as the webcam) and image sources to perform optical flow transfer.