sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #56185
Re: [Question #694279]: Region.text() - number Recognition
Question #694279 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/694279
matteoa posted a new comment:
Hello Javier,
I've had the same problem and I managed to mitigate it with these functions:
OCR.globalOptions().variable("tessedit_char_whitelist", "PCBU0123456789ABCDEF")
OCR.globalOptions().variable("tessedit_char_blacklist", "abcdefGgHhIiLlMmNnOopQqRrSsTtuVvZzJjYyKkWw-!|")
OCR.globalOptions().configs("bazaar")
OCR.globalOptions().variable("load_system_dawg", "F")
OCR.globalOptions().variable("load_freq_dawg", "F")
OCR.globalOptions().psm(6)
OCR.globalOptions().variable("user_patterns_file", "C:\\Sikulix\\Util\\OCR.Pattern")
and the content of the file (strictly tailored for my need) is:
P\n\n\n\n
C\n\n\n\n
B\n\n\n\n
U\n\n\n\n
Here some info I used to get a better OCR:
https://stackoverflow.com/questions/17209919/tesseract-user-patterns
https://github.com/tesseract-ocr/tesseract/blob/master/doc/tesseract.1.asc#config-files-and-augmenting-with-user-data
I said "mitigate" since the problem got better but was not completely solved.
Hope this helps
--
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.