我试图根据图像找到拉普拉斯算子的变体,目的是根据图像的模糊度得到一个数值.
这是一篇有用的帖子 http://www.pyimagesearch.com/2015/09/07/blur-detection-with-opencv/
cv2.Laplacian(image, cv2.CV_64F).var()
Run Code Online (Sandbox Code Playgroud)
我一直在努力实现同样的运气.我的起点是表示图像的字节[](img):
Mat mat = new Mat(img.getImageHeight(), img.getImageWidth(), CvType.CV_8UC3);
Imgproc.cvtColor(mat, mat, Imgproc.COLOR_BGR2GRAY);
mat.put(0, 0, putData.getFileContents());
Imgproc.Laplacian(mat,mat, CvType.CV_64F);
Run Code Online (Sandbox Code Playgroud)
任何帮助,将不胜感激.
基本上,我从一个图像开始,想要使用拉普拉斯算法得到一个代表图像模糊度的值.