OpenCV 4.12.0
开源计算机视觉
加载中...
搜索中...
无匹配项
cv::cuda::BackgroundSubtractorMOG2 类参考抽象

基于高斯混合的背景/前景分割算法更多...

#include <opencv2/cudabgsegm.hpp>

cv::cuda::BackgroundSubtractorMOG2 的协作图

公共成员函数

virtual void apply (InputArray image, OutputArray fgmask, double learningRate, Stream &stream)=0
 
void getBackgroundImage (GpuMat &backgroundImage, Stream &stream)
 
virtual void getBackgroundImage (OutputArray backgroundImage, Stream &stream) const =0
 
- 继承自 cv::BackgroundSubtractorMOG2 的公共成员函数
virtual void apply (InputArray image, OutputArray fgmask, double learningRate=-1) CV_OVERRIDE=0
 计算前景掩码。
 
virtual double getBackgroundRatio () const =0
 返回算法的“背景比率”参数。
 
virtual double getComplexityReductionThreshold () const =0
 返回复杂度降低阈值。
 
virtual bool getDetectShadows () const =0
 返回阴影检测标志。
 
virtual int getHistory () const =0
 返回影响背景模型的最后帧数。
 
virtual int getNMixtures () const =0
 返回背景模型中的高斯分量数量。
 
virtual double getShadowThreshold () const =0
 返回阴影阈值。
 
virtual int getShadowValue () const =0
 返回阴影值。
 
virtual double getVarInit () const =0
 返回每个高斯分量的初始方差。
 
virtual double getVarMax () const =0
 
virtual double getVarMin () const =0
 
virtual double getVarThreshold () const =0
 返回像素-模型匹配的方差阈值。
 
virtual double getVarThresholdGen () const =0
 返回用于生成新混合分量的像素-模型匹配的方差阈值。
 
virtual void setBackgroundRatio (double ratio)=0
 设置算法的“背景比率”参数。
 
virtual void setComplexityReductionThreshold (double ct)=0
 设置复杂度降低阈值。
 
virtual void setDetectShadows (bool detectShadows)=0
 启用或禁用阴影检测。
 
virtual void setHistory (int history)=0
 设置影响背景模型的最后帧数。
 
virtual void setNMixtures (int nmixtures)=0
 设置背景模型中的高斯分量数量。
 
virtual void setShadowThreshold (double threshold)=0
 设置阴影阈值。
 
virtual void setShadowValue (int value)=0
 设置阴影值。
 
virtual void setVarInit (double varInit)=0
 设置每个高斯分量的初始方差。
 
virtual void setVarMax (double varMax)=0
 
virtual void setVarMin (double varMin)=0
 
virtual void setVarThreshold (double varThreshold)=0
 设置像素-模型匹配的方差阈值。
 
virtual void setVarThresholdGen (double varThresholdGen)=0
 设置用于生成新混合分量的像素-模型匹配的方差阈值。
 
- 继承自 cv::BackgroundSubtractor 的公共成员函数
virtual void getBackgroundImage (OutputArray backgroundImage) const =0
 计算背景图像。
 
- 继承自 cv::Algorithm 的公共成员函数
 Algorithm ()
 
virtual ~Algorithm ()
 
virtual void clear ()
 清除算法状态。
 
virtual bool empty () const
 如果算法为空(例如,在最开始或读取不成功之后),则返回 true。
 
virtual String getDefaultName () const
 
virtual void read (const FileNode &fn)
 从文件存储中读取算法参数。
 
virtual void save (const String &filename) const
 
void write (const Ptr< FileStorage > &fs, const String &name=String()) const
 
virtual void write (FileStorage &fs) const
 将算法参数存储到文件存储中。
 
void write (FileStorage &fs, const String &name) const
 

其他继承成员

- 继承自 cv::Algorithm 的静态公共成员函数
template<typename _Tp >
static Ptr< _Tpload (const String &filename, const String &objname=String())
 从文件中加载算法。
 
template<typename _Tp >
static Ptr< _TploadFromString (const String &strModel, const String &objname=String())
 从字符串加载算法。
 
template<typename _Tp >
static Ptr< _Tpread (const FileNode &fn)
 从文件节点读取算法。
 
- 继承自 cv::Algorithm 的保护成员函数
void writeFormat (FileStorage &fs) const
 

详细描述

基于高斯混合的背景/前景分割算法

该类通过建立和维护背景模型来区分前景像素和背景像素。任何不符合此模型的像素则被视为前景。该类实现了[327]中描述的算法。

另请参见
BackgroundSubtractorMOG2

成员函数文档

◆ apply()

virtual void cv::cuda::BackgroundSubtractorMOG2::apply ( InputArray image,
OutputArray fgmask,
double learningRate,
Stream & stream )
纯虚函数

◆ getBackgroundImage() [1/2]

void cv::cuda::BackgroundSubtractorMOG2::getBackgroundImage ( GpuMat & backgroundImage,
Stream & stream )
inline

◆ getBackgroundImage() [2/2]

virtual void cv::cuda::BackgroundSubtractorMOG2::getBackgroundImage ( OutputArray backgroundImage,
Stream & stream ) const
纯虚函数

此类的文档生成自以下文件