ReadText


Ready-to-use tool for reading text from images using the OCR technique.

Syntax

C++
C#
Python
 
def ReadText(
	inCharacters: list[Region],
	inOcrModel: OcrModel,
	/,
	*,
	inMinScore: float = 0
)
-> (
	outText: str,
	outCharacters: list[str | None],
	outScores: list[float],
	outIsTextValid: bool
)

Parameters

Name Type Range Default Description
Input value inCharacters list[Region] Character regions
Input value inOcrModel OcrModel OCR model specific to a particular font
Input value inMinScore float 0.0 - 1.0 0 Minimal score of reading a character
Output value outText str Read text
Output value outCharacters list[str | None] Array of characters. NIL indicates invalid read when inMinScore is set,
Output value outScores list[float] Reading scores for each character
Output value outIsTextValid bool Returns False if any character score is smaller than inMinScore