This algorithm shows how to create an optical flow on a constant video stream. Optical flow, in simple terms, shows how the pixels in the stream are changing their location when the stream is moving.
python3 pi.py
python3 optical_flow.py
or you can optical_flow_dense.py