Training doesn´t work 3.02 (Commandcorrection??)

286 views
Skip to first unread message

Awsomo :(

unread,
Apr 22, 2014, 9:07:35 AM4/22/14
to tesser...@googlegroups.com
Hi,

I have installed Tesseract v3.02 with Cowboxer as Boxtool on Win7 x64bit,
i´ve allready created a Boxfile from a tiff witch are both have the same name and are laydowned in the same Folder named Tessdata.
The main Problem i have now is that Tesseract reports that it cannot open the input file.

this are the two commands i use:

tesseract deu.handwriting.exp0.tif deu.handwriting.exp0] box.train

tesseract [deu].[handwriting].exp[0].tif [deu].[handwriting].exp[0] box.train.stderr


this is really a mess and hard to understand with my english knowlege.

What did i do wrong?
If anybody can give more information for Training of Tesseract 3.02
,would be really awesome.



Quan Nguyen

unread,
Apr 22, 2014, 11:04:39 PM4/22/14
to tesser...@googlegroups.com
The commands should be:
 
tesseract deu.handwriting.exp0.tif deu.handwriting.exp0 box.train
 
or
 
tesseract deu.handwriting.exp0.tif deu.handwriting.exp0 box.train.stderr

Awsomo :(

unread,
Apr 23, 2014, 12:57:35 PM4/23/14
to tesser...@googlegroups.com
"The commands should be:
 
tesseract deu.handwriting.exp0.tif deu.handwriting.exp0 box.train
 
or
 
tesseract deu.handwriting.exp0.tif deu.handwriting.exp0 box.train.stderr"


Thank you i tried ,  but it still reprots the message:

-->Tesseract Open Source OCR Engine v3.02 with Leptonica
Cannot open input file: deu.handwriting.exp0.tif<--


I have tried it with the files in this folder "tesseract-OCR\Tessdata" and on the  "Desktop \Tessdata" after deleting them from the other.

C:\Program Files\Tesseract-OCR\Tessdata>tesseract deu.handwriting.exp0.tif deu.handwri
ting.exp0 box.train.stderr
Tesseract Open Source OCR Engine v3.02 with Leptonica
Cannot open input file: deu.handwriting.exp0.tif

C:\Program Files (x86)\Tesseract-OCR\tessdata>tesseract deu.handwriting.exp0.ti
 deu.handwriting.exp0 box.train
Tesseract Open Source OCR Engine v3.02 with Leptonica
Cannot open input file: deu.handwriting.exp0.tif

also all types of renaming the box.and.tif Files like :
this
deu.handwriting.exp0.tif 
deu.handwriting.exp0.box
or
handwriting.exp0.tif
handwriting.exp0.box
or this like i first supposed the name should be..
exp0.tif
exp0.box
because i couldn´t find more information about the designation of the tiff and box files.

Are there any steps to do before, i might could miss?




Nick White

unread,
Apr 23, 2014, 1:58:22 PM4/23/14
to tesser...@googlegroups.com
On Wed, Apr 23, 2014 at 09:57:35AM -0700, Awsomo :( wrote:
> Thank you i tried , but it still reprots the message:
>
> -->Tesseract Open Source OCR Engine v3.02 with Leptonica
> Cannot open input file: deu.handwriting.exp0.tif<--

That error message is printed because it can't find that file. So
either it isn't named correctly, or it isn't in the directory you're
running it from.

Actually it also may be possible that the TIFF isn't valid; can you
upload a copy to compare against? Or just convert it to a PNG and
try that (replacing .tif with .png).

Nick

Awsomo :(

unread,
Apr 24, 2014, 9:41:04 AM4/24/14
to tesser...@googlegroups.com
Hi Nick, i tried all combinations of the name but i don´t really know what the exact name of the file should be,
 
    here are the files.
I used that path to my directory C:/User/alias/program files (x86)/Tesseract-OCR/Tessdata.


 


 

Nick White

unread,
Apr 24, 2014, 10:09:10 AM4/24/14
to tesser...@googlegroups.com
On Thu, Apr 24, 2014 at 06:41:04AM -0700, Awsomo :( wrote:
> Hi Nick, i tried all combinations of the name but i don´t really know what
> the exact name of the file should be,

OK, I see, in your case the exact name of the .tif file should be:
deu.handwriting.exp0.tif

And the .box file should be named:
deu.handwriting.exp0.box

The .tif looks fine, by the way, Tesseract can read it without
issues, so once you name the files properly all should be well.

Nick

Awsomo :(

unread,
Apr 25, 2014, 4:48:10 AM4/25/14
to tesser...@googlegroups.com
Thank you. That worked out so far,.  :) 

-no report the
-picture opens up after exicuting the command

but 

that should be generated in this step, i think.
Is the tr.file generated in a lib_folder or
do i have to use one of the option for Pagemodus maybe  to make a better 
and if thats so what is the syntaxs for that.
 

pagesegmode values are:
0 = Orientation and script detection (OSD) only.
1 = Automatic page segmentation with OSD.
2 = Automatic page segmentation, but no OSD, or OCR
3 = Fully automatic page segmentation, but no OSD. (Default)
4 = Assume a single column of text of variable sizes.
5 = Assume a single uniform block of vertically aligned text.
6 = Assume a single uniform block of text.
7 = Treat the image as a single text line.
8 = Treat the image as a single word.
9 = Treat the image as a single word in a circle.
10 = Treat the image as a single character.
-l lang and/or -psm pagesegmode must occur before anyconfigfile.

I tried it like that..

C:\Users\alias\Desktop\Tessdata>tesseract deu.handwriting.exp0.tif deu.handwri
ting.exp0 box.train 3
read_params_file: Can't open 3
Tesseract Open Source OCR Engine v3.02 with Leptonica
FAIL!
APPLY_BOXES: boxfile line 0/4 ((83,3290),(162,3445)): FAILURE! Couldn't find a m
atching blob
FAIL!
APPLY_BOXES: boxfile line 1/5 ((242,3302),(338,3457)): FAILURE! Couldn't find a
matching blob
FAIL!
APPLY_BOXES: boxfile line 2/6 ((384,3302),(480,3457)): FAILURE! Couldn't find a
matching blob
FAIL!
APPLY_BOXES: boxfile line 3/7 ((565,3306),(661,3461)): FAILURE! Couldn't find a
matching blob
FAIL!
APPLY_BOXES: boxfile line 4/8 ((702,3312),(798,3451)): FAILURE! Couldn't find a
matching blob
FAIL!
APPLY_BOXES: boxfile line 5/9 ((854,3312),(950,3451)): FAILURE! Couldn't find a
matching blob
FAIL!
APPLY_BOXES: boxfile line 6/0 ((986,3312),(1086,3451)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 7/1 ((1151,3312),(1219,3451)): FAILURE! Couldn't find
a matching blob
FAIL!
APPLY_BOXES: boxfile line 8/2 ((1272,3312),(1356,3451)): FAILURE! Couldn't find
a matching blob
FAIL!
APPLY_BOXES: boxfile line 9/3 ((1421,3324),(1505,3463)): FAILURE! Couldn't find
a matching blob
FAIL!
APPLY_BOXES: boxfile line 10/3 ((1409,3130),(1493,3269)): FAILURE! Couldn't find
 a matching blob
FAIL!
APPLY_BOXES: boxfile line 11/2 ((1265,3126),(1349,3265)): FAILURE! Couldn't find
 a matching blob
FAIL!
APPLY_BOXES: boxfile line 12/1 ((1133,3118),(1217,3257)): FAILURE! Couldn't find
 a matching blob
FAIL!
APPLY_BOXES: boxfile line 13/0 ((973,3118),(1081,3257)): FAILURE! Couldn't find
a matching blob
FAIL!
APPLY_BOXES: boxfile line 14/9 ((868,3104),(936,3251)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 15/8 ((716,3104),(788,3259)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 16/7 ((558,3104),(638,3259)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 17/6 ((399,3115),(487,3270)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 18/5 ((263,3115),(351,3270)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 19/4 ((79,3091),(167,3246)): FAILURE! Couldn't find a
matching blob
FAIL!
APPLY_BOXES: boxfile line 20/4 ((79,2843),(167,3010)): FAILURE! Couldn't find a
matching blob
FAIL!
APPLY_BOXES: boxfile line 21/5 ((243,2845),(347,3040)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 22/6 ((375,2860),(479,3039)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 23/7 ((527,2888),(631,3067)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 24/8 ((703,2900),(791,3067)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 25/9 ((855,2904),(943,3071)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 26/0 ((975,2918),(1067,3057)): FAILURE! Couldn't find
a matching blob
FAIL!
APPLY_BOXES: boxfile line 27/1 ((1131,2929),(1179,3052)): FAILURE! Couldn't find
 a matching blob
FAIL!
APPLY_BOXES: boxfile line 28/2 ((1244,2932),(1320,3059)): FAILURE! Couldn't find
 a matching blob
FAIL!
APPLY_BOXES: boxfile line 29/3 ((1398,2948),(1478,3079)): FAILURE! Couldn't find
 a matching blob
FAIL!
APPLY_BOXES: boxfile line 30/3 ((1382,2707),(1478,2874)): FAILURE! Couldn't find
 a matching blob
FAIL!
APPLY_BOXES: boxfile line 31/2 ((1250,2699),(1350,2850)): FAILURE! Couldn't find
 a matching blob
FAIL!
APPLY_BOXES: boxfile line 32/1 ((1164,2688),(1204,2843)): FAILURE! Couldn't find
 a matching blob
FAIL!
APPLY_BOXES: boxfile line 33/0 ((988,2708),(1112,2871)): FAILURE! Couldn't find
a matching blob
FAIL!
APPLY_BOXES: boxfile line 34/9 ((844,2692),(956,2855)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 35/8 ((691,2668),(803,2831)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 36/7 ((529,2646),(629,2797)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 37/6 ((373,2614),(473,2781)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 38/5 ((220,2598),(320,2765)): FAILURE! Couldn't find a
 matching blob
FAIL!
APPLY_BOXES: boxfile line 39/4 ((64,2598),(164,2765)): FAILURE! Couldn't find a
matching blob
FAIL!
APPLY_BOXES: boxfile line 40/A ((0,3508),(-1,3507)): FAILURE! Couldn't find a ma
tching blob
APPLY_BOXES:
   Boxes read from boxfile:      41
   Boxes failed resegmentation:      41
APPLY_BOXES: Unlabelled word at :Bounding box=(-1501,-889)->(-75,-23)
   Found 0 good blobs.
   1 remaining unlabelled words deleted.
Generated training data for 0 words

Awsomo :(

unread,
May 5, 2014, 4:21:36 AM5/5/14
to tesser...@googlegroups.com
ok, there was a problem with the Picture i used, tesseract couldn´t use it because of the size i think.
However now its working and generating the requested TR.Files to. 
Thanks to everybody who helped me to fix this problems so far.! 
Reply all
Reply to author
Forward
0 new messages