testd_ocr_class_boxT_testd_ocr_class_boxTestdOcrClassBoxTestdOcrClassBoxtestd_ocr_class_box (Operator)
Name
testd_ocr_class_boxT_testd_ocr_class_boxTestdOcrClassBoxTestdOcrClassBoxtestd_ocr_class_box
— Test an OCR classifier.
Warning
testd_ocr_class_boxtestd_ocr_class_boxTestdOcrClassBoxTestdOcrClassBoxtestd_ocr_class_box
is obsolete and is only provided for
reasons of backward compatibility. New applications should use the
MLP, SVM or CNN based operators instead.
Signature
void TestdOcrClassBox(const HObject& Character, const HObject& Image, const HTuple& OcrHandle, const HTuple& Class, HTuple* Confidence)
HTuple HRegion::TestdOcrClassBox(const HImage& Image, const HOCRBox& OcrHandle, const HTuple& Class) const
double HRegion::TestdOcrClassBox(const HImage& Image, const HOCRBox& OcrHandle, const HString& Class) const
double HRegion::TestdOcrClassBox(const HImage& Image, const HOCRBox& OcrHandle, const char* Class) const
double HRegion::TestdOcrClassBox(const HImage& Image, const HOCRBox& OcrHandle, const wchar_t* Class) const
(
Windows only)
HTuple HOCRBox::TestdOcrClassBox(const HRegion& Character, const HImage& Image, const HTuple& Class) const
double HOCRBox::TestdOcrClassBox(const HRegion& Character, const HImage& Image, const HString& Class) const
double HOCRBox::TestdOcrClassBox(const HRegion& Character, const HImage& Image, const char* Class) const
double HOCRBox::TestdOcrClassBox(const HRegion& Character, const HImage& Image, const wchar_t* Class) const
(
Windows only)
static void HOperatorSet.TestdOcrClassBox(HObject character, HObject image, HTuple ocrHandle, HTuple classVal, out HTuple confidence)
HTuple HRegion.TestdOcrClassBox(HImage image, HOCRBox ocrHandle, HTuple classVal)
double HRegion.TestdOcrClassBox(HImage image, HOCRBox ocrHandle, string classVal)
HTuple HOCRBox.TestdOcrClassBox(HRegion character, HImage image, HTuple classVal)
double HOCRBox.TestdOcrClassBox(HRegion character, HImage image, string classVal)
Description
The operator testd_ocr_class_boxtestd_ocr_class_boxTestdOcrClassBoxTestdOcrClassBoxtestd_ocr_class_box
tests the confidence with
which a character belongs to a given class. Any number of regions
of an image can be passed. For each character (region) in
CharacterCharacterCharactercharactercharacter
the corresponding name (class) ClassClassClassclassValclass
must be specified. The gray values are passed in ImageImageImageimageimage
.
When the operator has finished the parameter ConfidenceConfidenceConfidenceconfidenceconfidence
provides information about how sure a character belongs to the
(arbitrary chosen) class.
Execution Information
- Multithreading type: reentrant (runs in parallel with non-exclusive operators).
- Multithreading scope: global (may be called from any thread).
- Processed without parallelization.
Parameters
CharacterCharacterCharactercharactercharacter
(input_object) region(-array) →
objectHRegionHObjectHObjectHobject
Characters to be tested.
ImageImageImageimageimage
(input_object) singlechannelimage →
objectHImageHObjectHObjectHobject (byte / uint2)
Gray values for the characters.
OcrHandleOcrHandleOcrHandleocrHandleocr_handle
(input_control) ocr_box →
HOCRBox, HTupleHHandleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)
ID of the desired OCR-classifier.
ClassClassClassclassValclass
(input_control) string(-array) →
HTupleMaybeSequence[str]HTupleHtuple (string) (string) (HString) (char*)
Class (name) of the characters.
Default:
'a'
"a"
"a"
"a"
"a"
ConfidenceConfidenceConfidenceconfidenceconfidence
(output_control) real(-array) →
HTupleSequence[float]HTupleHtuple (real) (double) (double) (double)
Confidence for the character to belong to the class.
Result
If the parameters are correct, the operator
testd_ocr_class_boxtestd_ocr_class_boxTestdOcrClassBoxTestdOcrClassBoxtestd_ocr_class_box
returns the value 2 (
H_MSG_TRUE)
.
Otherwise an exception will be raised.
Possible Predecessors
read_ocrread_ocrReadOcrReadOcrread_ocr
,
trainf_ocr_class_boxtrainf_ocr_class_boxTrainfOcrClassBoxTrainfOcrClassBoxtrainf_ocr_class_box
,
traind_ocr_class_boxtraind_ocr_class_boxTraindOcrClassBoxTraindOcrClassBoxtraind_ocr_class_box
Module
OCR/OCV