You are not logged in.

#1 2012-07-27 08:52:23

matttt
Member
Registered: 2012-07-27
Posts: 1

tesseract + libwebp problem

Hi all, I'm new.

When I exec tesseract (OCR) I get:
tesseract: error while loading shared libraries: libwebp.so.2: cannot open shared object file: No such file or directory

libwebp:
ls /usr/lib/libwebp.* -1
/usr/lib/libwebp.a
/usr/lib/libwebp.so
/usr/lib/libwebp.so.3
/usr/lib/libwebp.so.3.0.0

Offline

#2 2012-07-27 10:28:54

bslackr
Member
Registered: 2012-01-27
Posts: 131

Re: tesseract + libwebp problem

Same issue here.

Offline

#3 2012-07-27 19:15:19

Tristelune
Member
Registered: 2007-10-09
Posts: 86

Re: tesseract + libwebp problem

Hi, for me also the same. You can downgrade libwebp to version 0.1.3-2 to use
gimagereader again. At the moment I don't have much time. Could somebody
report the bug ? Given the error, I would try to report the problem in tesseract.

Offline

#4 2012-07-27 19:53:57

bslackr
Member
Registered: 2012-01-27
Posts: 131

Re: tesseract + libwebp problem

Bug reported here, add your vote.

Offline

#5 2012-07-28 10:06:46

cian1500ww
Member
Registered: 2011-09-12
Posts: 5

Re: tesseract + libwebp problem

I'm having the same problem, I was able to temporarily resolve it by symlinking /usr/lib/libwebp.so.2 to /usr/lib/libwebp.so

Offline

#6 2012-11-20 17:48:56

ezacaria
Member
Registered: 2007-12-10
Posts: 46

Re: tesseract + libwebp problem

Hi,

I just tried the current tesseract, and I do not encounter this error.

There is, however, another one.

I was not sure whether to post here, or to open a new topic, or to report a bug - so please bear with me smile

It seems that the location of the training data in the ftp servers has changed.
Currently we have the following in the MAKEPKG:

http://tesseract-ocr.googlecode.com/files/${l}.traineddata.gz

Which should read something like

http://tesseract-ocr.googlecode.com/files/tesseract-ocr-$pkgver.${l}.tar.gz

The current tesseract-data-eng package is incomplete:

pacman -Ql tesseract-data-eng
tesseract-data-eng /usr/
tesseract-data-eng /usr/share/
tesseract-data-eng /usr/share/tessdata/
tesseract-data-eng /usr/share/tessdata/eng.traineddata

It should contain all these files:

l ~/bin/tessdata/ | cut -d ' ' -f'5-'

168K Oct 17 16:55 eng.cube.bigrams
  38 Oct 17 16:55 eng.cube.fold
 181 Oct 17 16:55 eng.cube.lm
838K Oct 17 16:55 eng.cube.nn
 254 Oct 17 16:55 eng.cube.params
 13M Oct 17 16:55 eng.cube.size
2.4M Oct 17 16:55 eng.cube.word-freq
 996 Oct 17 16:55 eng.tesseract_cube.nn
 21M Oct 17 16:55 eng.traineddata

This causes a segfault:

tesseract doc.tiff output_base_file -l eng
Tesseract Open Source OCR Engine v3.02.02 with Leptonica
index >= 0 && index < size_used_:Error:Assert failed:in file ../ccutil/genericvector.h, line 512
Segmentation fault

A workaround is to download and unpack the complete training data package and overwrite the environment variable TESSDATA_PREFIX, e.g., if you unpack the files to reside in export TESSDATA_PREFIX=~/bin/tessdata:

export TESSDATA_PREFIX=~/bin

Then tesseract runs on the command line, but  variable does not seem to be taken over by yagf when in GUI mode. Luckily, there is a configuration option to specify the location of the tessdata directory.

Offline

#7 2013-01-08 10:54:08

lxz
Member
Registered: 2010-08-09
Posts: 4

Re: tesseract + libwebp problem

Thank you ezacaria, your solution worked like a charm. (downloading tesseract-ocr-3.02.eng.tar.gz manually and moving its files to tessdata)
From my point tesseract-data(-eng) is incomplete.
(Interestingly, this problem did not consistently appear with every type of input while using tesseract...)

Offline

#8 2013-01-23 12:32:27

explorer
Member
Registered: 2011-06-15
Posts: 38

Re: tesseract + libwebp problem

Does not find the folder "Directory contain tesseract languages". Where it is located by default? And do not want to run. How to fix?

Offline

Board footer

Powered by FluxBB