Tools,

Tesseract and German: eng reads no ä, ö, ü or ß

96%

of umlauts and ß right with -l deu

Get the code

One flag: 0.0% to 95.7%

Proofread pages from 15 German books, printed 1869 to 1935:

Model ä ö ü ß right Words right
-l eng, the default 0.0% 87.8%
-l deu 95.7% 96.3%

97.7% of letters right with eng, marks aside

12.2% of words wrong with eng

eng reads the letters, but its model has no ä, ö, ü or ß. It cannot print them, so it guesses a, ii or b.

What eng does to German words

Real words from these scans. Each time, deu read it right:

Printed eng read Times
für fiir 26
über iiber 25
daß dab 24
können knnen 17
hätte hatte 13

hätte became hatte, so "would have" turns into "had". über became iiber on 16 of 30 pages.

Old print sets ß as ſs

Two books, printed 1869 and 1895, set ß as two letters: a long s and a round s. The wiki text writes ß.

0 of 29 read as ß there, by any model

85 of 87 real ß glyphs read right by deu

deu prints dafs for daß on those pages, the shape it sees. Check old scans for fs by eye: Aufsatz has a real fs.

Install deu, then pass -l deu

This writes page.txt:

tesseract page.png page -l deu

In Python:

import pytesseract

print(pytesseract.image_to_string("page.png", lang="deu"))

Bigger models gain little, mixes lose letters

Each against plain deu, which took 1.3 seconds a page:

Setting ä ö ü ß right Sec a page
deu from tessdata_best 96.3% 3.7
-l deu+eng 93.2% 2.1
-l eng+deu 92.9% 2.4
script/Latin, for all Latin-alphabet languages 92.1% 2.4

Adding eng cost 27 or 31 umlauts and ß, in either order.

It read more words right, 97.0% against 96.3%. The biggest gain was a book with long Latin quotes. Add eng only for pages with many Latin or English words.

How I tested it
  • Pages: de.wikisource scans whose text was proofread (level 3) or also checked by a second person (level 4). Books picked by a seeded shuffle, not by me, 2 pages a book. Pages with notes, poems or tables were skipped.
  • Roman type only. Most de.wikisource books are Fraktur, so Tesseract eng had to find 92% of a page's letters, marks aside. 32 books failed. 12 more say Fraktur in their notes.
  • The 46 Fraktur pages of my Fraktur test scored 86.2% at most on that check.
  • Books printed 1850 to 1950 only.
  • 30 pages, 72,297 letters, 1,109 of them ä, ö, ü or ß.
  • Each scan is the wiki's page image: 22 at 1,920 px, 4 at 1,280 px, 4 at 960 px.
  • Umlauts and ß right: those letters read right, in order. Words right: proofread words read right, umlauts and all, in order.
  • Running heads and page numbers are not in the proofread text, so extra text costs nothing.
  • deu+eng and eng+deu gave different text on 10 of 30 pages, but almost the same score.
  • Tesseract 5.5.4, one thread. Models from tessdata_fast 4.1.0, the files Homebrew installs, and tessdata_best 4.1.0.

Our Actor: set Language to German

Our Apify Actor reads scans with the same deu file. Its Language input starts at English. On these 30 scans:

0.0% of umlauts and ß right, left at English

97.0% set to German, live build 0.1.65

Old build 0.1.44 got 0.0% and 89.4%: it read a two-column story across the columns, line by line. Build 0.1.65, live since Nov 11, reads them in order. Each number is a build's code, run on my Mac.

What I did not test
Sources

Two ways to skip the work

Run it yourself. Our Apify Actor turns scanned PDFs into Markdown, tables included.

Try the Actor

Or send us the scan. Tack, our AI, does the job for $29, up to 50 pages. First page free.

Get one page free

Questions people ask

Does Tesseract read German?

Yes, with the deu model. On 30 proofread book scans it read 95.7% of umlauts and ß right. The default eng read 0.0%.

Why does Tesseract read für as fiir?

It runs with eng, the default, and eng has no ä, ö, ü or ß. On these scans eng read für as fiir 26 times. Pass -l deu.

Is deu from tessdata_best worth it?

Only a little. It read 96.3% of umlauts and ß right, and it took 3.7 seconds a page, almost 3 times as long as deu.