Tesseract 3.0.5 - Text2Image

1,615 views
Skip to first unread message

john brown

unread,
Oct 5, 2017, 10:03:13 AM10/5/17
to tesseract-ocr
Hello. I'm running Text2Image to automate some training data but I keep getting the following error:

Unable to open '/tmp/fonts.conf' for writing
Fontconfig error: Cannot load default config file
FcInitiReinitialize failed!!
Failed to read file: training_text.txt


Any ideas what is causing this? This is the following command I'm running

text2image --text=training_text.txt --outputbase=eng --fonts_dir=C:\\Windows\\Fonts --find_fonts --min_coverage=1.0 --render_per_font=false

Thanks

Zdenko Podobný

unread,
Oct 5, 2017, 11:31:10 AM10/5/17
to tesser...@googlegroups.com
try to check if /tmp  is writable for your user

Zdenko

--
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-ocr+unsubscribe@googlegroups.com.
To post to this group, send email to tesser...@googlegroups.com.
Visit this group at https://groups.google.com/group/tesseract-ocr.
To view this discussion on the web visit https://groups.google.com/d/msgid/tesseract-ocr/a6a2d566-9b79-438b-90bb-f3427ee74b69%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

john brown

unread,
Oct 5, 2017, 11:33:54 AM10/5/17
to tesseract-ocr
That's my issue, I don't understand what /tmp is. I'm on Windows 10 (Might be the first issue!)


On Thursday, 5 October 2017 16:31:10 UTC+1, zdenop wrote:
try to check if /tmp  is writable for your user

Zdenko

On Thu, Oct 5, 2017 at 4:03 PM, john brown <brown.j...@gmail.com> wrote:
Hello. I'm running Text2Image to automate some training data but I keep getting the following error:

Unable to open '/tmp/fonts.conf' for writing
Fontconfig error: Cannot load default config file
FcInitiReinitialize failed!!
Failed to read file: training_text.txt


Any ideas what is causing this? This is the following command I'm running

text2image --text=training_text.txt --outputbase=eng --fonts_dir=C:\\Windows\\Fonts --find_fonts --min_coverage=1.0 --render_per_font=false

Thanks

--
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.

Zdenko Podobný

unread,
Oct 6, 2017, 1:50:51 AM10/6/17
to tesser...@googlegroups.com
/tmp (on linux) is the (global) folder for storing temporary files, where usualy every user/service/tool has access. something like %temp% on windows. Maybe you can try to create c:\tmp if it helps...

Zdenko

To unsubscribe from this group and stop receiving emails from it, send an email to tesseract-ocr+unsubscribe@googlegroups.com.

To post to this group, send email to tesser...@googlegroups.com.
Visit this group at https://groups.google.com/group/tesseract-ocr.

john brown

unread,
Oct 6, 2017, 3:28:34 AM10/6/17
to tesseract-ocr
Ahhh I understand. Okay. i'll change the directories and see what happens. Stand by.

Zdenko

ShreeDevi Kumar

unread,
Oct 6, 2017, 4:16:45 AM10/6/17
to tesser...@googlegroups.com

To unsubscribe from this group and stop receiving emails from it, send an email to tesseract-ocr+unsubscribe@googlegroups.com.

To post to this group, send email to tesser...@googlegroups.com.
Visit this group at https://groups.google.com/group/tesseract-ocr.

john brown

unread,
Oct 6, 2017, 4:19:18 AM10/6/17
to tesseract-ocr
This is absolutely bizarre. I'm able to run and generate a  .box and .tif file when I run my rectified command in the command prompt. Now, I tried the exact same command using C# and it's now saving "Unable to read trainng_text.txt". 

john brown

unread,
Oct 6, 2017, 6:06:26 AM10/6/17
to tesseract-ocr
Okay. I've successfully finished the training process for 3.0.5 using the legacy engine. Now, I'm pretty sure 3.0.5 also supports the LSTM engine too? I can't seem to find anything on the training tesseract wiki page for using LSTM...

ShreeDevi Kumar

unread,
Oct 6, 2017, 7:20:12 AM10/6/17
to tesser...@googlegroups.com
3.0.x branch is for legacy engine.

LSTM support is only in master branch, for 4.0x
Currently master branch also supports legacy engine, though it may go away later.

See wiki pages regarding 4.0. There is a detailed page on training.

ShreeDevi
____________________________________________________________
भजन - कीर्तन - आरती @ http://bhajans.ramparivar.com

--
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-ocr+unsubscribe@googlegroups.com.
To post to this group, send email to tesser...@googlegroups.com.
Visit this group at https://groups.google.com/group/tesseract-ocr.

john brown

unread,
Oct 6, 2017, 7:31:43 AM10/6/17
to tesseract-ocr
Okay thanks, I had an inclining that was the case. 
Reply all
Reply to author
Forward
0 new messages