Sikuli says empty page when reading text

Asked by julien abou fadel on 2020-08-24

I set up sikuli api on java eclipse then installed tesseract now I select a region and tell sikuli to read it but it says empty page tried to search the internet it says psm need to be set to 8 but i dont know how
anyone can help fix i am trying to read sequence of letters on white background and letters are either red or black

Question information

Language:
English Edit question
Status:
Answered
For:
Sikuli Edit question
Assignee:
No assignee Edit question
Last query:
2020-08-25
Last reply:
2020-08-25
julien abou fadel (jga123) said : #1

Edit the psm needs to be set to 10 ( single character per image ) but i dont know how to set it in sikuli

julien abou fadel (jga123) said : #3

Nice answer I am trying to automate a game and reading the letters isn't accurate all the time but I want
accuracy to be perfect SO i guess sikuli won't work for this game since I am getting inaccurate results any suggestion?

julien abou fadel (jga123) said : #4

I want to try to train the java program to recognize letters in my game. Any help how should i do that?

julien abou fadel (jga123) said : #5

Any help how I can have it recognize poker cards like heart spades clubs?

julien abou fadel (jga123) said : #6

It seems like I need to train it to recognize specific symbols and letters

RaiMan (raimund-hocke) said : #7

For OCR internally we use Tesseract, which can be trained for new fonts/symbols.

... but is beyond the scope of SikuliX support - visit the respective Tesseract docs/tutorial

julien abou fadel (jga123) said : #8

Dear RaiMan is it possible instead of training tesseract , to provide images of what it is expected to find and let it search for them and tell me if it found them in java using sikuli api?? is this an easier method since the input is either 2,3,4,5,6,7,8,9,10,J,Q,K,A and the colors is either clubs or spades or hearts or diamonds and can i specify the percentage match I need it to find like 92%?

julien abou fadel (jga123) said : #9

After I find the images can I have its location? is this process fast or slow if I want to find 13 images and there is pic of same image on the screen.

RaiMan (raimund-hocke) said : #10

Yes, that is all possible.

You have to look into the docs and for examples in the net.

I recommend to use the SikuliX IDE for your first trials (especially for capturing the needed images), before fiddling around with the Java level.

If you have specific questions about SikuliX features, come back here with a new question for every topic, best with your coding samples.

Can you help with this problem?

Provide an answer of your own, or ask julien abou fadel for more information if necessary.

To post a message you must log in.