Skip to content

[Fix]: Force use of legacy model for OSD

Jerome Flesch requested to merge Sqooba:fix/fix-osd-for-tesseract-4 into master

Created by: a-pagano

Orientation and script detection (OSD) doesn't work yet with the new LSTM models shipped with Tesseract 4.

Calling detect_orientation will thus fail when using tesseract 4.0 and both legacy and LSTM models are found in the TESSDATA_PREFIX directory.

The fix is to force the use of the old legacy model until support for OSD is available in the new models.

Merge request reports