为了更好地为 OCR 过程做好准备,我想去除图像(通常是扫描图像)上的背景噪音。
这是例子:
magick.exe
命令是否有任何方法可以消除像这样的图像中的噪声?如果是这样,请举个例子。
已更新
我在 Windows 10 上使用 ImageMagick-7.0.7-Q16
最佳答案
在 ImageMagick 中使用 -connected-components 来降低噪声。 (Unix 语法)
convert \
3foBc.png -threshold 60% \
-define connected-components:verbose=true \
-define connected-components:area-threshold=5 \
-define connected-components:mean-color=true \
-connected-components 8 \
out.png
关于ImageMagick 去除背景噪音,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47989687/