ropensci / tesseract

Bindings to Tesseract OCR engine for R
https://docs.ropensci.org/tesseract
244 stars 26 forks source link

Linux users should install tesseract-ocr & related first #36

Open olyerickson opened 5 years ago

olyerickson commented 5 years ago

Users installing on Linux machines may see:

Error opening data file /usr/share/tesseract-ocr/tessdata/eng.traineddata
Please make sure the TESSDATA_PREFIX environment variable is set to the parent directory of your "tessdata" directory.
Failed loading language 'eng'
Tesseract couldn't load any languages!

This is easily solved by first installing tesseract-ocr and related language packs (via apt-get or whatever).

englianhu commented 3 years ago

its working fine...

:~$ ## option 1
:~$ sudo apt-get install -y libtesseract-dev libleptonica-dev tesseract-ocr-eng
:~$ ## option 2
:~$ sudo add-apt-repository -r ppa:cran/tesseract
:~$ sudo apt-get install -y libtesseract-dev tesseract-ocr-eng
:~$ lsb_release -a
LSB Version:    core-11.1.0ubuntu2-noarch:security-11.1.0ubuntu2-noarch
Distributor ID: Ubuntu
Description:    Ubuntu 20.04.2 LTS
Release:        20.04
Codename:       focal