Skip to content

SHENG-KAI-HUANG/ShowOpticalFlowByLine

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This is python3 code to show optical flow (in npy or pfm) by line. (not arrow yet, maybe when I have more free time)
If there are any bug, please feel free to post an issue.

Coding and testing by Anaconda in Windows 10 with python 3.6.5.

Please make sure already install following package before using this repository:

  1. opencv
  2. numpy
  3. argparse

How to using this code:

In this project will have a sample .pfm and a sample .png to show how to use this code.
These .pfm and .png are download from Monkaa scene flow dataset sample pack
You can also find original code about how to read .pfm by python from the above website.

You can run python3 main.py 0048.pfm 0048.png immediately after you download this repository.
It will save an JPG image named 'output.jpg' and create a windows to show the result.

Run with default augments:
python3 main.py <path/to/pfm> <path/to/image>

Run python3 main.py -h for more help.

Result:

alt text
Those lines length mean optical flow vector magnitude and direction mean optical flow vectore direction.

About

No description or website provided.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages