Text based recognition using Sikuli

Asked by Varun Gupta on 2017-07-14

I am very new to Sikuli and using following jars with eclipse:


I want to use the text recgonition feature but I am oberving following withe the code:

  Region sc = new Screen(0);

[error] Image: could not be loaded: file:/C:/User:.png
[error] Image: Image not valid, but TextSearch is switched off!
[error] TextRecognizer: init: export tessdata not possible - run setup with option 3
[error] TextRecognizer not working: tessdata stuff not available at:
FindFailed: null
  Line 2535, in file Region.java

 at org.sikuli.script.Region.wait(Region.java:2535)
 at org.sikuli.script.Region.findText(Region.java:2640)
 at org.sikuli.script.Region.findText(Region.java:2651)
 at TestSikuli.main(TestSikuli.java:53)

C:\Users\Sikulix\SikulixTesseract\tessdata folder seems to be empty.
Let me know if I am following the right steps,pls share some examples with text recognition with Sikuli.
Prompt help on this will be appreciated.

Question information

English Edit question
Sikuli Edit question
No assignee Edit question
Last query:
Last reply:

This question was reopened

RaiMan (raimund-hocke) said : #1

use the latest SikuliX 1.1.1 and start here:

be sure to not mix latest SikuliX with older stuff.

For using the text features:
see faq 2436

Varun Gupta (varunanilgupta7) said : #2

Hi RaiMan,

Thanks for ur response!

Due to restriction I can not use SikuliX 1.1.1, I just have following jars with me:

1. I can the C:\Users\Sikulix\SikulixTesseract\tessdata folder empty and can not download the content from internet due to security reasons
2. Download and usage of sikuli setup jar is even not allowed ,is there any other way to get the content of C:\Users\Sikulix\SikulixTesseract\tessdata folder.
3. I just can use eclipse not even allowed to run setup.

Can you please provide any workaround to me?

RaiMan (raimund-hocke) said : #3

If you are not even allowed, to run an offline setup (manually download the artifacts before), then I cannot help you.

On the other hand:
When using Eclipse, then you might work as a Maven project (no setup needed)

Varun Gupta (varunanilgupta7) said : #4

Thanks RaiMan, that solved my question.

Varun Gupta (varunanilgupta7) said : #5

Thanks for the details RaiMan!!

One last question, will Maven project can get the tessdata folder required for Text recogintion ,if yes how?

RaiMan (raimund-hocke) said : #6

yes, Maven version 1.1.1+ has tessdata english bundled

Can you help with this problem?

Provide an answer of your own, or ask Varun Gupta for more information if necessary.

To post a message you must log in.