Skip to content

Workflow Guide font detection

Konstantin Baierer edited this page Mar 11, 2021 · 5 revisions

Optionally, this processor can determine the font family (e.g. Antiqua, Fraktur, Schwabacher) to help select the right models for text detection.

ocrd-typegroups-classifier annotates font families on page level, including the confidence value (separated by colon). Supported fontFamily values:

  • Antiqua
  • Bastarda
  • Fraktur
  • Gotico-Antiqua
  • Greek
  • Hebrew
  • Italic
  • Rotunda
  • Schwabacher
  • Textura
  • other_font
  • not_a_font

Note: ocrd-typegroups-classifier was trained on a very large and diverse dataset, with both geometric and color-space random augmentation (contrast, brightness, hue, even compression artifacts and 2 different binarization methods), so it works best on the raw, non-binarized RGB image.

Note: ocrd-typegroups-classifier comes with a non-OCR-D CLI that allows for the generation of "heatmaps" on the page to visualize which regions of the page are classified as using a certain font with a certain confidence, see the project's README for usage instructions.

Available processors

Processor Parameter Remarks Call
ocrd-typegroups-classifier -P network /path/to/densenet121.tgc Download densenet121.tgc from GitHub ocrd-typegroups-classifier -I OCR-D-IMG -O OCR-D-IMG-FONTS

Notes on parameter usage

E.g.

  • which parameters do you use with what values?
  • which parameters are insufficiently documented?
  • which aspects of a processor should be parameterizable but are not?

Notes on document-specific usage

E.g. which processors worked best with what material? -- feel free to post sample images here, too.

Welcome to the OCR-D wiki, a companion to the OCR-D website.

Articles and tutorials
Discussions
Expert section on OCR-D- workflows
Particular workflow steps
Recommended workflows
Workflow Guide
Videos
Section on Ground Truth
Clone this wiki locally