Optical flow implementation in CUDA (LGLP source aviable) example of computer vision algorithm imple
Hi,
we devellop a (very) fast optical flow estimation aviable here :
[url="http://www.onera.fr/dtim-en/gpu-for-image/folkigpu.php"]onera site[/url]

the compilation need QT, OpenCV and Cuda (toolkit and sdk).
to compile, you need to modify in the src/FolkiGPU.pro
the CUDA_SDK to your cuda sdk installation path (ex : ~/NVIDIA_CUDA_SDK/C , not forget the '/C' for cuda 2.3 sdk)
if you use the 2.3 toolkit and have a 64bit operating system. remplace line 69 :
QMAKE_LIBDIR += $$CUDA_DIR/lib
by :
QMAKE_LIBDIR += $$CUDA_DIR/lib64

This is a [b]demonstration[/b] code (there are some bug, in visualisation for example)

Have fun!

all GPU for Image team
Hi,

we devellop a (very) fast optical flow estimation aviable here :

onera site



the compilation need QT, OpenCV and Cuda (toolkit and sdk).

to compile, you need to modify in the src/FolkiGPU.pro

the CUDA_SDK to your cuda sdk installation path (ex : ~/NVIDIA_CUDA_SDK/C , not forget the '/C' for cuda 2.3 sdk)

if you use the 2.3 toolkit and have a 64bit operating system. remplace line 69 :

QMAKE_LIBDIR += $$CUDA_DIR/lib

by :

QMAKE_LIBDIR += $$CUDA_DIR/lib64



This is a demonstration code (there are some bug, in visualisation for example)



Have fun!



all GPU for Image team

#1
Posted 08/28/2009 05:19 PM   
Is this in some way related to motion estimation that is done in video coding?
What are the fundamental differences?

Is this method fast enough to possibly replace the traditional motion estimation?
You mention it performs on full HD content at up to 30 fps.

Christian
Is this in some way related to motion estimation that is done in video coding?

What are the fundamental differences?



Is this method fast enough to possibly replace the traditional motion estimation?

You mention it performs on full HD content at up to 30 fps.



Christian

#2
Posted 08/29/2009 09:04 AM   
[quote name='cbuchner1' post='583479' date='Aug 29 2009, 11:04 AM']Is this in some way related to motion estimation that is done in video coding?
What are the fundamental differences?

Is this method fast enough to possibly replace the traditional motion estimation?
You mention it performs on full HD content at up to 30 fps.

Christian[/quote]

the fundamental differences between video coding motion estimation is the density, in our optical flow, we compute one motion vector by pixels, and in video coding (in Mpeg 2 for example) we have only one motion vector by blocks (for example 16x16 pixels).

other difference with MPEG 2, is how we compute the motion, in FOLKI we compute with a gradient descent scheme, in MPEG it was a hierachical search (or exaustive).
[quote name='cbuchner1' post='583479' date='Aug 29 2009, 11:04 AM']Is this in some way related to motion estimation that is done in video coding?

What are the fundamental differences?



Is this method fast enough to possibly replace the traditional motion estimation?

You mention it performs on full HD content at up to 30 fps.



Christian



the fundamental differences between video coding motion estimation is the density, in our optical flow, we compute one motion vector by pixels, and in video coding (in Mpeg 2 for example) we have only one motion vector by blocks (for example 16x16 pixels).



other difference with MPEG 2, is how we compute the motion, in FOLKI we compute with a gradient descent scheme, in MPEG it was a hierachical search (or exaustive).

#3
Posted 09/02/2009 11:10 AM   
[quote name='aplyer' post='584565' date='Sep 2 2009, 01:10 PM']the fundamental differences between video coding motion estimation is the density, in our optical flow, we compute one motion vector by pixels[/quote]

Awesome. The person looking for an image stabilization algorithm in this forum might use your code to track both translational AND rotational shaking of the camera.
[quote name='aplyer' post='584565' date='Sep 2 2009, 01:10 PM']the fundamental differences between video coding motion estimation is the density, in our optical flow, we compute one motion vector by pixels



Awesome. The person looking for an image stabilization algorithm in this forum might use your code to track both translational AND rotational shaking of the camera.

#4
Posted 09/02/2009 01:49 PM   
[url="http://www.cuvilib.com"][b]CUVI Lib v0.3[/b][/url] also offers Optical Flow (Lucas and Kanade) and Optical Flow (Horn and Schunk) implementation in CUDA. It's a complete framework so you can use these functions to accelerate your motion estimation, destabilization detection etc. Both algorithms have shown impressive speedups of around 60-70X compared with the OpenCV implementation (on Core 2 Duo with GeForce GTX 470 (Fermi) installed). The library can be freely downloaded. Please leave your comments/suggestions on here or on [b][url="http://www.cuvilib.com/forums"]CUVI Lib forums[/url][/b]

The current version supports[b] 8bit single channel images [/b]as input. Take a look at the images attached (input frames and Optical Flow Horn and Schunk with 10 iterations)

[url="http://www.cuvilib.com/images/2-frames-from-video.gif"]Source frames for Optical Flow HS computation[/url]

[img]http://www.cuvilib.com/images/output-optical-flow-hs.jpg[/img]
CUVI Lib v0.3 also offers Optical Flow (Lucas and Kanade) and Optical Flow (Horn and Schunk) implementation in CUDA. It's a complete framework so you can use these functions to accelerate your motion estimation, destabilization detection etc. Both algorithms have shown impressive speedups of around 60-70X compared with the OpenCV implementation (on Core 2 Duo with GeForce GTX 470 (Fermi) installed). The library can be freely downloaded. Please leave your comments/suggestions on here or on CUVI Lib forums



The current version supports 8bit single channel images as input. Take a look at the images attached (input frames and Optical Flow Horn and Schunk with 10 iterations)



Source frames for Optical Flow HS computation



Image

Best,

Salman Ul Haq,

TunaCode Pvt. Limited

Developers of GPU based Computing solutions

(CUDA for Vision and Imaging Library)

W: www.cuvilib.com

E: salman@tunacode.com



GPU: NVIDIA Tesla C2050

CPU: Core2Duo 2.33GHz 2.5GB DDR2 RAM

CUDA Toolkit v4.0RC

#5
Posted 08/01/2010 02:45 PM   
Yum yum, finally I have an idea how to use one of these optical flow libraries.

I want to hook up my new HD web cam to a telescope in order to take some shots of the moon. Usually the air is quite turbulent, and such an optical flow analyzer could enable me to remove a lot of this turbulence by warping the image in the opposite direction. /wink.gif' class='bbc_emoticon' alt=';)' />

To get an impression of this turbulence, watch this: http://www.youtube.com/watch?v=47F6PODdGF4

Christian
Yum yum, finally I have an idea how to use one of these optical flow libraries.



I want to hook up my new HD web cam to a telescope in order to take some shots of the moon. Usually the air is quite turbulent, and such an optical flow analyzer could enable me to remove a lot of this turbulence by warping the image in the opposite direction. /wink.gif' class='bbc_emoticon' alt=';)' />



To get an impression of this turbulence, watch this: />


Christian

#6
Posted 11/10/2011 09:58 PM   
Scroll To Top