tesseract-ocr出错

转载请注明出自:http://blog.csdn.net/liuyanzhi08/article/details/9499267

安装好以后在命令行使用结果报错:

Tesseract Open Source OCR Engine with Leptonica
Error in findTiffCompression: function not present
Error in tiffGetCount: function not present
Error reading file ./test.png!

原因是安装了tesseract-orc所依赖的leptonica的时候在configure的时候没有加上pnglib的选项。
解决办法:重新configure和安装leptonica
./configure --with-libpng && make
没有试过其他的格式如(jpg, tiff)但是按照推理应该是这样
./configure --with-libjpg --with-libtiff  && make


参考:https://code.google.com/p/leptonica/issues/detail?id=56

你可能感兴趣的:(leptonica,tesseract-oc)