Tesseract (software)

From Wikipedia, the free encyclopedia
Jump to navigation Jump to search
Tesseract
Tesseract OCR logo (Google).png
Tesseract 3.02 running on Gnome Terminal 3.8.0. "input_image.tif" is the input document which will be rendered as "output_text.txt" by Tesseract.
Tesseract 3.02 running on Gnome Terminal 3.8.0. "input_image.tif" is the input document which will be rendered as "output_text.txt" by Tesseract.
Original author(s) Ray Smith, Hewlett-Packard[1]
Developer(s) Google
Stable release
3.05.02 / June 19, 2018; 54 days ago (2018-06-19)[2]
Preview release
4.0.0-beta.3 / June 20, 2018; 53 days ago (2018-06-20)[2]
Repository Edit this at Wikidata
Written in C and C++
Operating system Linux, Windows, and macOS (x86)
Available in

Interface: English
Recognition:

Afrikaans, Albanian, Arabic, Azerbaijani, Basque, Belarusian, Bengali, Bulgarian, Catalan, Czech, Cherokee, Croatian, Danish, Dutch, English, Esperanto, Estonian, Finnish, French, Galician, German, Greek, Hindi, Hungarian, Indonesian, Italian, Japanese, Kannada, Korean, Latvian, Lithuanian, Malayalam, Macedonian, Maltese, Malay, Norwegian, Polish, Portuguese, Romanian, Russian, Serbian, Slovak, Slovenian, Spanish, Swahili, Swedish, Tagalog, Tamil, Telugu, Thai, Turkish, Ukrainian & Vietnamese (more can be added using included training files)
Type Optical character recognition
License Apache License v2.0
Website github.com/tesseract-ocr

Tesseract is an optical character recognition engine for various operating systems.[3] It is free software, released under the Apache License, Version 2.0,[1][4][5] and development has been sponsored by Google since 2006.[6]

In 2006 Tesseract was considered one of the most accurate open-source OCR engines then available.[5][7]

History[edit]

The Tesseract engine was originally developed as proprietary software at Hewlett Packard labs in Bristol, England and Greeley, Colorado between 1985 and 1994, with some more changes made in 1996 to port to Windows, and some migration from C to C++ in 1998. A lot of the code was written in C, and then some more was written in C++. Since then all the code has been converted to at least compile with a C++ compiler.[4] Very little work was done in the following decade. It was then released as open source in 2005 by Hewlett Packard and the University of Nevada, Las Vegas (UNLV). Tesseract development has been sponsored by Google since 2006.[8]

Features[edit]

Tesseract was in the top three OCR engines in terms of character accuracy in 1995.[9] It is available for Linux, Windows and Mac OS X. However, due to limited resources it is only rigorously tested by developers under Windows and Ubuntu.[4][5]

Tesseract up to and including version 2 could only accept TIFF images of simple one-column text as inputs. These early versions did not include layout analysis, and so inputting multi-columned text, images, or equations produced garbled output. Since version 3.00 Tesseract has supported output text formatting, hOCR[10] positional information and page-layout analysis. Support for a number of new image formats was added using the Leptonica library. Tesseract can detect whether text is monospaced or proportionally spaced.[5]

The initial versions of Tesseract could only recognize English-language text. Tesseract v2 added six additional Western languages (French, Italian, German, Spanish, Brazilian Portuguese, Dutch). Version 3 extended language support significantly to include ideographic (Chinese & Japanese) and right-to-left (e.g. Arabic, Hebrew) languages, as well as many more scripts. New languages included Arabic, Bulgarian, Catalan, Chinese (Simplified and Traditional), Croatian, Czech, Danish, German (Fraktur script), Greek, Finnish, Hebrew, Hindi, Hungarian, Indonesian, Japanese, Korean, Latvian, Lithuanian, Norwegian, Polish, Portuguese, Romanian, Russian, Serbian, Slovak (standard and Fraktur script), Slovenian, Swedish, Tagalog, Tamil, Thai, Turkish, Ukrainian and Vietnamese. V3.04, released in July 2015, added an additional 39 language/script combinations, bringing the total count of support languages to over 100. New language codes included: amh (Amharic), asm (Assamese), aze_cyrl (Azerbaijana in Cyrillic script), bod (Tibetan), bos (Bosnian), ceb (Cebuano), cym (Welsh), dzo (Dzongkha), fas (Persian), gle (Irish), guj (Gujarati), hat (Haitian and Haitian Creole), iku (Inuktitut), jav (Javanese), kat (Georgian), kat_old (Old Georgian), kaz (Kazakh), khm (Central Khmer), kir (Kyrgyz), kur (Kurdish), lao (Lao), lat (Latin), mar (Marathi), mya (Burmese), nep (Nepali), ori (Oriya), pan (Punjabi), pus (Pashto), san (Sanskrit), sin (Sinhala), srp_latn (Serbian in Latin script), syr (Syriac), tgk (Tajik), tir (Tigrinya), uig (Uyghur), urd (Urdu), uzb (Uzbek), uzb_cyrl (Uzbek in Cyrillic script), yid (Yiddish).[11]

Tesseract can be trained to work in other languages too.[5]

Tesseract can process right-to-left text such as Arabic or Hebrew, many Indic scripts as well as CJK quite well. Accuracy rates are shown in this presentation for Tesseract tutorial at DAS 2016, Santorini by Ray Smith.[12]

Tesseract is suitable for use as a backend and can be used for more complicated OCR tasks including layout analysis by using a frontend such as OCRopus.[13]

Tesseract's output will have very poor quality if the input images are not preprocessed to suit it: Images (especially screenshots) must be scaled up such that the text x-height is at least 20 pixels,[14] any rotation or skew must be corrected or no text will be recognized, low-frequency changes in brightness must be high-pass filtered, or Tesseract's binarization stage will destroy much of the page, and dark borders must be manually removed, or they will be misinterpreted as characters.[15]

4.0.0-beta.1[edit]

4.0.0-beta.1 version adds LSTM based OCR engine and models for many additional languages and scripts, bringing the total to 116 languages.[16]

Additionally scripts for 37 languages are supported so it is possible to recognize a language by using the script it is written in.

User interfaces[edit]

Tesseract configuration window in OCRFeeder

Tesseract is executed from the command-line interface.[17] While Tesseract is not supplied with a GUI, there are many separate projects which provide a GUI for it.[18] One common example is OCRFeeder.[19]

Reception[edit]

In a July 2007 article on Tesseract, Anthony Kay of Linux Journal termed it "a quirky command-line tool that does an outstanding job". At that time he noted "Tesseract is a bare-bones OCR engine. The build process is a little quirky, and the engine needs some additional features (such as layout detection), but the core feature, text recognition, is drastically better than anything else I've tried from the Open Source community. It is reasonably easy to get excellent recognition rates using nothing more than a scanner and some image tools, such as The GIMP and Netpbm."[3]

See also[edit]

References[edit]

  1. ^ a b Google (2008). "tesseract-ocr". Retrieved 2016-03-08. 
  2. ^ a b "Releases - tesseract-ocr/tesseract". Retrieved 24 June 2018 – via GitHub. 
  3. ^ a b Kay, Anthony (July 2007). "Tesseract: an Open-Source Optical Character Recognition Engine". Linux Journal. Retrieved 28 September 2011. 
  4. ^ a b c Vincent, Luc (August 2006). "Announcing Tesseract OCR". Archived from the original on October 26, 2006. Retrieved 2008-06-26. 
  5. ^ a b c d e Canonical Ltd. (February 2011). "OCR". Retrieved 2011-02-11. 
  6. ^ Announcing Tesseract OCR - The official Google blog
  7. ^ Willis, Nathan (September 2006). "Google's Tesseract OCR engine is a quantum leap forward". Retrieved 2008-07-18. 
  8. ^ Announcing Tesseract OCR - The official Google blog
  9. ^ Rice Stephen V., Frank R. Jenkins, and Thomas A. Nartker The Fourth Annual Test of OCR Accuracy, expervision.com, retrieved 21 May 2013
  10. ^ Tesseract Project (February 2011). "Issue 263: patch to enable hOCR output". Archived from the original on November 13, 2012. Retrieved 26 February 2011. 
  11. ^ "langdata - Source training data for Tesseract for lots of languages". Retrieved 6 November 2016. 
  12. ^ "Training LSTM networks on 100 languages and test results" (PDF). Retrieved 18 March 2018. 
  13. ^ Announcing the OCRopus Open Source OCR System (Thomas Breuel, OCRopus Project Leader).
  14. ^ "FAQ - tesseract-ocr - Frequently Asked Questions - An OCR Engine that was developed at HP Labs between 1985 and 1995... and now at Google. - Google Project Hosting". Code.google.com. Retrieved 2014-05-30. 
  15. ^ "ImproveQuality - tesseract-ocr - Advice on improving the quality of your output. - An OCR Engine that was developed at HP Labs between 1985 and 1995... and now at Google. - Google Project Hosting". Code.google.com. 2014-01-27. Retrieved 2014-05-30. 
  16. ^ "TESSERACT(1) Manual Page". Retrieved 15 March 2018. 
  17. ^ Google Code – Tesseract Readme
  18. ^ "3rdParty - tesseract-ocr - GUIs and Other Projects using Tesseract OCR". github.com. Retrieved 2017-03-30. 
  19. ^ Gnome.org (August 2010). "OCRFeeder". Retrieved 8 August 2010. 

External links[edit]