How to use tesseract ?

16,135 views
Skip to first unread message

grandMOJ

unread,
May 12, 2012, 8:20:17 PM5/12/12
to tesseract-ocr
Hello,

I'm interested in this software, but I still don't know how to use it
on Windows. I tried to find the answer on the web, but I failed.

Could anyone explain me the complete command-line, with all the
options (what I want to recognize is really hard), or give me a link
to a page which contains the very basic documentation, unavaible on
the FAQ ?

Thanks a lot.

Merve Temizer

unread,
May 13, 2012, 8:49:57 AM5/13/12
to tesser...@googlegroups.com

is command line command.

If you need to train tess:

http://code.google.com/p/tesseract-ocr/wiki/TrainingTesseract3


2012/5/13 grandMOJ <fares...@gmail.com>

--
You received this message because you are subscribed to the Google
Groups "tesseract-ocr" group.
To post to this group, send email to tesser...@googlegroups.com
To unsubscribe from this group, send email to
tesseract-oc...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/tesseract-ocr?hl=en

grandMOJ

unread,
May 13, 2012, 9:57:35 AM5/13/12
to tesseract-ocr
First, thanks a lot for answering.


So, to synthesize, that's my situation :

The tesseract folder is located on "C:\Program Files (x86)\Tesseract-
OCR", and the (.exe) path is "C:\Program Files (x86)\Tesseract-OCR
\tesseract.exe". The picture I have to submit in order to an OCR test
corresponds to "C:\Utilisateurs\Al-Fares\Bureau\test.tif". The output
containing the results may be a text file (I don't know the
modalities...).

Working with Windows7, when I press [win + R] I get the "execute"
interface, in which I can call a program with the appropriate command-
line. There, what do I have to write ? Something like :
"C:\Program Files (x86)\Tesseract-OCR\tesseract.exe" [arg 1] [arg 2]
[arg 3] etc.

Could you please customize the command-line with my personnal
settings, in order to really make it work ? I tried those :

tessetact.exe "C:\Utilisateurs\Al-Fares\Bureau\test.tif" output -l
tessetact.exe C:\Utilisateurs\Al-Fares\Bureau\test.tif output -l
tessetact.exe "C:\Utilisateurs\Al-Fares\Bureau\test.tif" output -l
lang<http://code.google.com/p/tesseract-ocr/wiki/
TrainingTesseract3tessera...>
tessetact.exe C:\Utilisateurs\Al-Fares\Bureau\test.tif output -l
lang<http://code.google.com/p/tesseract-ocr/wiki/
TrainingTesseract3tessera...>

All gave nothing interesting.


I'm very grateful that you decided to help me.

On May 13, 2:49 pm, Merve Temizer <mervet2...@gmail.com> wrote:
> tesseract image.tif output -l
> lang<http://code.google.com/p/tesseract-ocr/wiki/TrainingTesseract3tessera...>
>
> is command line command.
>
> If you need to train tess:
>
> http://code.google.com/p/tesseract-ocr/wiki/TrainingTesseract3<http://code.google.com/p/tesseract-ocr/wiki/TrainingTesseract3tessera...>
>
> 2012/5/13 grandMOJ <faresaye...@gmail.com>

Merve Temizer

unread,
May 14, 2012, 3:29:38 AM5/14/12
to tesser...@googlegroups.com
I do not have tesseract at my new pc and now i am on it.
 
But i can say something:
 
I am not sure if "win+R" provides an interface to run tesseract.
 
But i can advise you to "win+R" , type "cmd" in that little "win+R" window.
 
When you write "cmd" and enter, command line utility of windows 7 opens. A little black window.
 
In that window you will probably see
 
C:/Users/Your User Name>
 
You can type "cd.." to climb upper directories. You can "cd aDirectory" to move in.
 
Thus you must first "cd .." for several times to move up to pure "C:/"
 
Then to move in to C:\Program Files (x86)\Tesseract-OCR
 
by
 
"cd Program Files (x86)"
"cd Tesseract-OCR"
after all now you can
 
tessetact.exe "C:\Utilisateurs\Al-Fares\Bureau\test.tif" output -l eng
 
 
you must specify a language after "-l" parameter as i remember, like eng at the above command,
 
If you think to train tesseract for your own language you must do a training with the directions in the link i wrote before.
2012/5/13 grandMOJ <fares...@gmail.com>

grandMOJ

unread,
May 14, 2012, 1:37:36 PM5/14/12
to tesseract-ocr
Thanks a lot, it finally worked !

On May 14, 9:29 am, Merve Temizer <mervet2...@gmail.com> wrote:
> I do not have tesseract at my new pc and now i am on it.
>
> But i can say something:
>
> I am not sure if "win+R" provides an interface to run tesseract.
>
> But i can advise you to "win+R" , type "cmd" in that little "win+R" window.
>
> When you write "cmd" and enter, command line utility of windows 7 opens. A
> little black window.
>
> In that window you will probably see
>
> C:/Users/Your User Name>
>
> You can type "cd.." to climb upper directories. You can "cd aDirectory" to
> move in.
>
> Thus you must first "cd .." for several times to move up to pure "C:/"
>
> Then to move in to C:\Program Files (x86)\Tesseract-OCR
>
> by
>
> "cd Program Files (x86)"
> "cd Tesseract-OCR"
> after all now you can
>
> tessetact.exe "C:\Utilisateurs\Al-Fares\Bureau\test.tif" output -l eng
>
> you must specify a language after "-l" parameter as i remember, like eng at
> the above command,
>
> If you think to train tesseract for your own language you must do a
> training with the directions in the link i wrote before.
> 2012/5/13 grandMOJ <faresaye...@gmail.com>

Ravi Roshan

unread,
Dec 23, 2013, 2:28:34 AM12/23/13
to tesser...@googlegroups.com
********************************************************************************
You can go through this given site if you already install tesseract s/w...
http://tesseract-ocr.googlecode.com/svn/trunk/doc/tesseract.1.html

or you must first install the tesseract s/w through the below sites:
1. https://code.google.com/p/tesseract-ocr/downloads/detail?name=tesseract-ocr-setup-3.02.02.exe&can=2&q=
2. http://sourceforge.net/projects/tesseract-ocr/

after installation run this s/w through command prompt like :

Suppose you installed this s/w in a folder in c:/tesseract(folder).
take any image say abc.tif in the same folder then in command prompt you give command:
cd/
cd tesseact
cd tesseract abc.tif out

it will make a text file in the same folder in the name of out.txt with the content written in the image.
Hope this will help you.
**************************************************************************************************

Sheekha Jariwala

unread,
Jan 28, 2014, 12:25:27 PM1/28/14
to tesser...@googlegroups.com
I've installed Tesseract by using Windows Installer and after going through the steps mentioned above I get following error in cmd.
Tesseract Open Source OCR Engine v3.02 with Leptonica
Empty page!!
Empty page!!

Here's a screenshot of my error:


Version of Tesseract is 3.02.02.
I'll be really grateful for the help.

Nick White

unread,
Jan 28, 2014, 1:41:32 PM1/28/14
to tesser...@googlegroups.com
Hi Sheekha,

It would be more useful if you could attach the sample image that
causes that.

Have you looked at this page?
https://code.google.com/p/tesseract-ocr/wiki/ImproveQuality

It's likely your problem is caused by one of the issues mentioned
there.

Nick

On Tue, Jan 28, 2014 at 09:25:27AM -0800, Sheekha Jariwala wrote:
> I've installed Tesseract by using Windows Installer and after going through the
> steps mentioned above I get following error in cmd.
> Tesseract Open Source OCR Engine v3.02 with Leptonica
> Empty page!!
> Empty page!!
>
> Here's a screenshot of my error:
>
> [ErrorScreenshot]
>
>
> Version of Tesseract is 3.02.02.
> I'll be really grateful for the help.
>
> --
> --
> You received this message because you are subscribed to the Google
> Groups "tesseract-ocr" group.
> To post to this group, send email to tesser...@googlegroups.com
> To unsubscribe from this group, send email to
> tesseract-oc...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/tesseract-ocr?hl=en
>
> ---
> You received this message because you are subscribed to the Google Groups
> "tesseract-ocr" group.
> To unsubscribe from this group and stop receiving emails from it, send an email
> to tesseract-oc...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.

universal reseller

unread,
Feb 4, 2014, 9:12:12 PM2/4/14
to tesser...@googlegroups.com
​i got this error when i used poor quality image
please send the sample image you used?​

Reply all
Reply to author
Forward
0 new messages