← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #676086]: Ocr not always working

 

Question #676086 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/676086

matteoa posted a new comment:
Thanks for clarification!
I managed to switch to Sikulix 1.1.4, using VNC and screenshot taken by sikulix 1.1.3 and moving the images on a more modern pc, but with not a lot of better results.
The complete testing script I'm using is this one:

img1 = Image.create(capture(selectRegion()))
imgGreyResized = Image(Image(Image.convertImageToGrayscale(img1.get())).resize(3))
print imgGreyResized.text().encode('utf-8')

But the OCR results are not so good, the "Yes" is found as "YE!" and "NO" as "IND", or something like, sometimes it also works.
I also tried with resize(5) or 8, but saw no differences.
I was thinking about binarizing the image to 2 colors only with nearest neighbour algorithm, any suggestion?
Tesseract does it internally, I think, but maybe I could use a more specific algorithm for web pages.
There is the possibility to add a vocabulary of words to be used in a particular situation to the tesseract engine?
I'm thinking about a command to tell to tesseract "here there are numbers", "here there could be only yes or no" and so on..
Thanks for your, as usual, great support

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.