opencv中cvCalcOpticalFlowFarneback函数所包含参数及其意义

 我来答
N_0_1
高粉答主

2015-10-31 · 关注我不会让你失望
知道大有可为答主
回答量:8628
采纳率:47%
帮助的人:843万
展开全部
cvCalcOpticalFlowFarneback的原型为:void calcOpticalFlowFarneback(InputArray prevImg, InputArray nextImg, InputOutputArray flow, double pyrScale, int levels, int winsize, int iterations, int polyN, double polySigma, int flags)
各个参数的意义:

prevImg – First 8-bit single-channel input image.
nextImg – Second input image of the same size and the same type as prevImg .
flow – Computed flow image that has the same size as prevImg and type CV_32FC2 .
pyrScale – Parameter specifying the image scale (<1) to build pyramids for each image. pyrScale=0.5means a classical pyramid, where each next layer is twice smaller than the previous one.
levels – Number of pyramid layers including the initial image. levels=1 means that no extra layers are created and only the original images are used.
winsize – Averaging window size. Larger values increase the algorithm robustness to image noise and give more chances for fast motion detection, but yield more blurred motion field.
iterations – Number of iterations the algorithm does at each pyramid level.
polyN – Size of the pixel neighborhood used to find polynomial expansion in each pixel. Larger values mean that the image will be approximated with smoother surfaces, yielding more robust algorithm and more blurred motion field. Typically, polyN =5 or 7.
polySigma – Standard deviation of the Gaussian that is used to smooth derivatives used as a basis for the polynomial expansion. For polyN=5 , you can set polySigma=1.1 . For polyN=7 , a good value would bepolySigma=1.5 .
flags –
Operation flags that can be a combination of the following:
OPTFLOW_USE_INITIAL_FLOW Use the input flow as an initial flow approximation.
OPTFLOW_FARNEBACK_GAUSSIAN Use the Gaussian filter instead of a box filter of the same size for optical flow estimation. Usually, this option gives z more accurate flow than with a box filter, at the cost of lower speed. Normally, winsize for a Gaussian window should be set to a larger value to achieve the same level of robustness.
桃李不言教书育人
2012-04-20 · TA获得超过1530个赞
知道小有建树答主
回答量:381
采纳率:0%
帮助的人:301万
本回答被提问者采纳
已赞过 已踩过<
你对这个回答的评价是?
评论 收起
我自己812
2012-04-30
知道答主
回答量:3
采纳率:0%
帮助的人:4847
展开全部
DK不小
已赞过 已踩过<
你对这个回答的评价是?
评论 收起
收起 1条折叠回答
推荐律师服务: 若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询

为你推荐:

下载百度知道APP,抢鲜体验
使用百度知道APP,立即抢鲜体验。你的手机镜头里或许有别人想知道的答案。
扫描二维码下载
×

类别

我们会通过消息、邮箱等方式尽快将举报结果通知您。

说明

0/200

提交
取消

辅 助

模 式