问题描述
我想根据光流(此答案中的建议)对视频序列中的对象进行细分,我正在使用opencv,并且已经能够使用 calcOpticalFlowFarneback 函数.有人可以解释我如何根据该流场对图像进行分割吗?
Hi I would like to segment objects in a video sequence based on optical flow (as suggested in this answer), I am using opencv and have been able to generate a flow field for two successive frames using the calcOpticalFlowFarneback function. Could someone explain how I would go about segmenting an image based on this flow field?
推荐答案
由于您要使用光学流"对物体进行分段,因此您的决策将基于物体进行运动的类型...观看在youtube上观看此视频.您可以在两个连续的帧中测量每个目标像素经历的位移的方向和大小,以了解它们的运动模式.在视频的链接中,根据光流"将汽车从背景中分割出来了.
Since you want to use Optical Flow to segment object so your decision making will be based on the type of motion your objects under go...You can have a look at this video on youtube. You can measure the direction and the magnitude of the displacement each pixel of interest undergoes in two successive frames to get an idea of their movement pattern. In the link to the video the car is segmented from the background on the basis of Optical Flow...
这篇关于基于光流的分段的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!