tesseractQueryState: Query the State of a Tesseract Object

tesseractQueryState.RdR Documentation

Query the State of a Tesseract Object

Description

These functions allow us to query the current state and settings of a tesseract OCR object.

There are other functions in other help pages that are related to setting and querying the state.

We can query the location of the tesseract data files where the training and configuration files are located. These can be set via the environment variable TESSDATA_PREFIX, or the datapath argument to tesseract and Init.

The oem allows us to query the OcrEngineMode that was set during the initialization.

GetInitLanguages queries the languages specified in the initialization.

IsValidWord queries whether a word is consider valid given the current settings and dictionary in use.

Usage

GetDatapath(api)
hasRecognized(api)
oem(api)
GetInitLanguages(api)

IsValidWord(api, word)

GetThresholdedImage(api)

Arguments

api

the instance of the TesseractBaseAPI-class in which to perform the operations.

word

a character vector of words whose validity we want to check

Author(s)

Duncan Temple Lang

See Also

tesseract


duncantl/Rtesseract documentation built on Sept. 8, 2024, 8:38 a.m.