ExtractText


Ready-to-use tool for extracting and splitting character to single characters.

Syntax

C++
C#
Python
 
def ExtractText(
	inImage: Image,
	inRoi: Rectangle2D,
	inRoiAlignment: CoordinateSystem2D,
	inSegmentationModel: TextSegmentation,
	/,
	*,
	diagTextRegion: Region | None = None,
	diagAlignedRoi: Rectangle2D | None = None
)
-> (
	outCharacters: list[Region],
	diagAlignedCharacters: list[Region]
)

Parameters

Name Type Default Description
Input value inImage Image An input image with text
Input value inRoi Rectangle2D Location of the text
Input value inRoiAlignment CoordinateSystem2D Adjusts the region of interest to the position of the inspected object
Input value inSegmentationModel TextSegmentation Model used for separating text from background
Output value outCharacters list[Region] Split characters aligned to ROI
Diagnostic input diagTextRegion Region | None None Region of text after extraction
Diagnostic input diagAlignedCharacters list[Region] Character regions preserving original image orientation
Diagnostic input diagAlignedRoi Rectangle2D | None None ROI rectangle after alignment