我正在开发一个android应用程序,使用opencv和tesseract进行OCR。我用一个小的代码的guat.am基本OCR,如何关注致命信号11(SIGSEGV)
Bitmap bmp = Bitmap.createBitmap(ima.cols(), ima.rows(), Bitmap.Config.ARGB_8888);
Utils.matToBitmap(imagethre, bmp,true);
TessBaseAPI baseApi = new TessBaseAPI();
baseApi.setDebug(true);
baseApi.init(DATA_PATH, lang);
baseApi.setImage(bmp);
String recognizedText = baseApi.getUTF8Text();
这不是路径或郎或类似的东西的问题,因为这个工作,但有时,一些图片与其他的作品,但不..
我该如何遵循这个错误来知道发生了什么?
在代码的最后一行的应用程序崩溃我张贴
调试我现在已经看到应用程序崩溃时调用TessBaseApi.class,特别是这一行:
String text = nativeGetUTF8Text();
任何想法?
它是否对一些图像始终如一地工作,但始终对其他人失败?如果是这样,你应该发布成功和失败案例的样本图像。 – rmtheis