在opencv中,是否有Matlab的边缘(I,方法,阈值)等效的方法=' zerocross'?
我需要将以下行从MATLAB转换为CPP,并得到完全相同的结果:
im_zerocross =
double(edge(im,'zerocross',0));
任何帮助都将不胜感激。
I need to translate the following line from matlab to cpp and get the exact same result:
im_zerocross =
double(edge(im,'zerocross',0));
Any help would be greatly appreciated.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
MATLAB中的零交叉边缘检测器是OpenCV中Laplacian操作员的代名词。
它在图像中沿x和y方向找到了二阶导数。此结果中的每个零交叉都对应于图像中的边缘。
用法:
最后一个参数
cv2.cv_64f
是在float
数据类型中给出结果,类似于double> double> double
。通过此帖子以获取详细信息和相关代码
Zero crossing edge detector in MATLAB is synonymous to Laplacian operator in OpenCV.
It finds the second order derivatives along X and Y directions in the image. Every zero crossing in this result corresponds to an edge in the image.
Usage:
The last parameter
cv2.CV_64F
is to give the result infloat
data type similar todouble
in MATLAB.Go through this post for details and relevant code