Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/image-processing/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Image processing 通过tesseract降低图像中的噪声以启用OCR_Image Processing_Imagemagick_Ocr_Tesseract - Fatal编程技术网

Image processing 通过tesseract降低图像中的噪声以启用OCR

Image processing 通过tesseract降低图像中的噪声以启用OCR,image-processing,imagemagick,ocr,tesseract,Image Processing,Imagemagick,Ocr,Tesseract,我正在尝试对这类图像进行OCR: 不幸的是,tesseract无法检索数字,因为字符周围有噪声点 我尝试使用ImageMagick来提高图像质量,但没有成功 示例: convert input.tif -level 0%,150% output.tif convert input.tif -colorspace CMYK -separate output_%d.tif 有没有办法有效地检索这类图像中的角色 非常感谢。简单(先扩张,然后侵蚀)将为您提供所需的输出。下面是相同的Pytho

我正在尝试对这类图像进行OCR:

不幸的是,tesseract无法检索数字,因为字符周围有噪声点

我尝试使用ImageMagick来提高图像质量,但没有成功

示例:

 convert input.tif -level 0%,150% output.tif

 convert input.tif -colorspace CMYK -separate output_%d.tif

有没有办法有效地检索这类图像中的角色

非常感谢。

简单(先扩张,然后侵蚀)将为您提供所需的输出。下面是相同的Python实现

img = cv2.imread(r'D:\Image\noiseOCR.png',0)
kernel = np.ones((3,3),np.uint8)
closing = cv2.morphologyEx(img, cv2.MORPH_CLOSE, kernel)

此图中的数字是最大的连接组件。因此,另一种方法是进行连接组件分析