使用以下语法,cv2.PCACompute
函数在OpenCV 2.4中运行良好:
import cv2
mean, eigvec = cv2.PCACompute(data)
该函数存在于OpenCV 3.1中,但引发以下异常:
^{pr2}$C++ documentation在解释如何从Python调用它方面没有太大帮助。我猜InputOutputArray
参数现在也是Python函数签名中的强制参数,但我无法找到使它们工作的方法。在
有没有办法让我恰当地称呼它?在
(注意:我知道有其他方法可以运行PCA,我可能会用其中一种。我只是好奇新的OpenCV绑定是如何工作的。)
简单回答:
详细信息:
让搜索计算机计算来源首先。然后查找this:
好的,现在我们读一下document:
这么说吧
等于
相关问题 更多 >
编程相关推荐