AttributeError:'module'对象没有属性'logPolar'opencv3.0

时间:2015-06-08 18:04:30

标签: opencv3.0

我正在尝试运行opencv3.0演示(./opencv/sources/samples/python2)并且一些函数正在返回:

  

AttributeError:'module'对象没有属性“对于facedetect.py和houghlines.py,他们只有'LINE_AA'。

在这些情况下,我刚刚从通话中删除了LINE_AA,它运行正常。

在:

cv2.putText(dst, s, (x+1, y+1), cv2.FONT_HERSHEY_PLAIN, 1.0, (0, 0, 0), thickness = 2, lineType=cv2.LINE_AA)

cv2.putText(dst, s, (x, y), cv2.FONT_HERSHEY_PLAIN, 1.0, (255, 255, 255), lineType=cv2.LINE_AA)

后:

cv2.putText(dst, s, (x+1, y+1), cv2.FONT_HERSHEY_PLAIN, 1.0, (0, 0, 0), thickness = 2)

cv2.putText(dst, s, (x, y), cv2.FONT_HERSHEY_PLAIN, 1.0, (255, 255, 255))

虽然,logpolar.py我也得到了:

追踪(最近一次呼叫最后一次):

File "logpolar.py", line 16, in <module>
img2 = cv2.logPolar(img, (img.shape[0]/2, img.shape[1]/2), 40, cv2.WARP_FILL_OUTLIERS)
AttributeError: 'module' object has no attribute 'logPolar'

在这种情况下,我不确定应该做什么。

提前致谢!

0 个答案:

没有答案