tess-two

Android Tesseract Error. Data file not found at

只谈情不闲聊 提交于 2021-01-29 10:56:41
问题 I'm studying android using NDK with opencv. I success using ndk. So I get usable data ( I mean the data was done by canny.) When I use Tesseract, Data file not found at /storage/emulated/0/tesseract/tessdata/eng.traineddata This Error is occured. I already checked adroid/app/src/main/assets/tessdata/eng.traineddata there are the traineddata.... I don't know why I get an error there. plz... help me please... public class ocrActivity extends AppCompatActivity { private static final String TAG =

extracting numbers from Bitmap in android using tess-two library

喜你入骨 提交于 2020-01-05 09:06:19
问题 I want to extract a number from a Bitmap. I'm using the tess-two library, but it does not recognize correctly. Example Code: @Override public void onClick(View v) { switch (v.getId()){ case R.id.b2: InputStream is = null; try { is = getApplicationContext().getAssets().open("zak.jpeg"); } catch (IOException e1) { e1.printStackTrace(); } final Drawable drw = Drawable.createFromStream(is, null); bmp = ((BitmapDrawable) drw).getBitmap(); TessBaseAPI baseApi = new TessBaseAPI(); bmp =BITMAP

Tess-Two (Tesseract OCR in Android) shows very inaccurate results

匆匆过客 提交于 2019-12-24 01:13:31
问题 I use the following function to perform offline OCR using Tesseract OCR's Android fork Tess-Two : private String startOCR(Uri imgUri) { try { ExifInterface exif = new ExifInterface(imgUri.getPath()); int exifOrientation = exif.getAttributeInt(ExifInterface.TAG_ORIENTATION, ExifInterface.ORIENTATION_NORMAL); int rotate = 0; switch(exifOrientation) { case ExifInterface.ORIENTATION_ROTATE_90: rotate = 90; break; case ExifInterface.ORIENTATION_ROTATE_180: rotate = 180; break; case ExifInterface

android - recognized text from tess-two library is wrong

醉酒当歌 提交于 2019-12-23 01:28:11
问题 I am trying to use the tess-two library to recognize text from imagae. Here is my code: load.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { // recognize text Bitmap temp = loadJustTakenImage(); //loads taken image from sdcard Bitmap rotatedImage = rotateIfNeeded(temp); // rotate method i found in some tutorial String text1 = recognizeText(rotatedImage); } }); Recognize text method: (tessdata folder is in Download with the eng.traineddata and other

Tess-two OCR not working

大兔子大兔子 提交于 2019-12-20 04:48:25
问题 im trying to get text from an image using tess-two on android. But its giving me a really bad result 01-16 12:00:25.339: I/Tesseract(native)(29038): Initialized Tesseract API with language=spa and like 30 seconds later it shows this as result string: {ga ., r¿ y“: A r M í :3 ' ‘Ev’.-:.. -: A 7 » w- ?" _ Á.» ¿"A ¿rw-V r mjÏfn 'n’n . Y ' "\'ZA".‘.¡ A‘ :‘ïvAv- « ‘ :"Éf‘Ï'" -Ï«l :‘,.v:...»- . ' RFI' .. ’ g)" 3;:- 1-;4', = * ¿,arifgggk mw; .1. , ' "53» "J 't‘ ‘ ¿Las ;.‘».L',-‘» ' ' 'N‘“ "“=: - '.

Tess-two OCR not working

女生的网名这么多〃 提交于 2019-12-20 04:47:56
问题 im trying to get text from an image using tess-two on android. But its giving me a really bad result 01-16 12:00:25.339: I/Tesseract(native)(29038): Initialized Tesseract API with language=spa and like 30 seconds later it shows this as result string: {ga ., r¿ y“: A r M í :3 ' ‘Ev’.-:.. -: A 7 » w- ?" _ Á.» ¿"A ¿rw-V r mjÏfn 'n’n . Y ' "\'ZA".‘.¡ A‘ :‘ïvAv- « ‘ :"Éf‘Ï'" -Ï«l :‘,.v:...»- . ' RFI' .. ’ g)" 3;:- 1-;4', = * ¿,arifgggk mw; .1. , ' "53» "J 't‘ ‘ ¿Las ;.‘».L',-‘» ' ' 'N‘“ "“=: - '.

Not able to add Tesseract OCR module to Android Studio

喜欢而已 提交于 2019-12-12 21:07:26
问题 I followed the step by step guide found here: https://www.codeproject.com/Articles/840623/Android-Character-Recognition At step 2 when I added tess-two as module dependency to app and synced gradle, it failed with the following error: Error:Project :app declares a dependency from configuration 'compile' to configuration 'default' which is not declared in the descriptor for project :libraries:tess-two. I have tried many combinations of settings.gradle and searched for hours, any help will be

android update project --path “path” error: target invalid (ubuntu)

白昼怎懂夜的黑 提交于 2019-12-12 05:16:46
问题 I am trying to build tesseract library in android studio. abhimanyu@MyPC:~/Documents/tess-two-master/tess-two$ /home/abhimanyu/Android/Sdk/tools/android update project --path . Error: The project either has no target set or the target is invalid. Please provide a --target to the 'android update' command. What path to specify then? plz help 回答1: You can install API level 8 of the Android platform, or include a --target parameter to avoid this error. But a better alternative is to not try to

tess-two import in android sdk build error in windows

天大地大妈咪最大 提交于 2019-12-11 04:51:59
问题 I have build the project vie steps in the git download page https://github.com/rmtheis/tess-two#build I have installed ndk/sdk an configured in my path environment, also i have add ndk path in project local.properties. Here is my project build log, after i had add the tess-two lib as externel project into my Information:Gradle tasks [clean, :app:compileDebugSources, :app:compileDebugAndroidTestSources, :tesstwo:compileDebugSources, :tesstwo:compileDebugAndroidTestSources] :app:clean :tesstwo

Android UnsatisfiedLinkError With Tesseract and OpenCV

放肆的年华 提交于 2019-12-10 22:26:02
问题 I have been trying to get OpenCV and the android version of tesseract (tess-two) to work with my android app. I am developing in Android Studio 1.4, the problem is that if I add the tess-two dependency alone, the app works fine and I can load the tess-two library fine. Next when I add the OpenCV dependency to the app, it breaks the support for the tess-two library and throws me this runtime error: Caused by: java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader[DexPathList[[zip file "