java - Forcing Tesseract to recognize only digits -
i developing ocr application android. @ point have observed needed recognize digits, trying ocr recognize digits , hyphens, , not letters or other type of character.
i have done this:
tessbaseapi.init(path, "eng"); tessbaseapi.setvariable(tessbaseapi.var_char_whitelist, "1234156787901299-");
but not getting accurate result. suggestions appreciated.
editted: complete code:
tessapi.setpagesegmode(tessbaseapi.oem_tesseract_cube_combined); tessapi.setvariable(tessbaseapi.var_char_whitelist, "0123456789"); tessapi.setvariable(tessbaseapi.var_char_blacklist,"abcdefghijklmnopqrstuvwxyzabcdefghijklmopqrstuvwxyz");
Comments
Post a Comment