ClassesClassesClassesClasses | | | | Operators

close_ocrclose_ocrCloseOcrclose_ocrCloseOcrCloseOcr (Operator)

Name

close_ocrclose_ocrCloseOcrclose_ocrCloseOcrCloseOcr — Deallocation of the memory of an OCR classifier.

Warning

close_ocrclose_ocrCloseOcrclose_ocrCloseOcrCloseOcr is obsolete and is only provided for reasons of backward compatibility. New applications should use the MLP, SVM or CNN based operators instead.

Signature

close_ocr( : : OcrHandle : )

Herror close_ocr(const Hlong OcrHandle)

Herror T_close_ocr(const Htuple OcrHandle)

Herror close_ocr(const HTuple& OcrHandle)

void CloseOcr(const HTuple& OcrHandle)

void HOperatorSetX.CloseOcr([in] VARIANT OcrHandle)

static void HOperatorSet.CloseOcr(HTuple ocrHandle)

Description

The operator close_ocrclose_ocrCloseOcrclose_ocrCloseOcrCloseOcr deallocates the memory of the classifier having the number OcrHandleOcrHandleOcrHandleOcrHandleOcrHandleocrHandle. Hereby all corresponding data will be deleted. However, if necessary, they can be saved in advance using the operator write_ocrwrite_ocrWriteOcrwrite_ocrWriteOcrWriteOcr. The number OcrHandleOcrHandleOcrHandleOcrHandleOcrHandleocrHandle will be invalid after the call; but later the system can use it again for new classifiers.

Attention

All data of the classifier will be deleted in main memory (not on the hard disk).

Parallelization

This operator modifies the state of the following input parameter:

The value of this parameter may not be shared across multiple threads without external synchronization.

Parameters

OcrHandleOcrHandleOcrHandleOcrHandleOcrHandleocrHandle (input_control, state is modified)  ocr_box HOCRBox, HTupleHTupleHOCRBox, HTupleHOCRBoxX, VARIANTHtuple (integer) (IntPtr) (Hlong) (Hlong) (Hlong) (Hlong)

ID of the OCR classifier to be deleted.

Example (C)

HTuple      OcrHandle,Class,Confidence;
Hlong        orc_handle;

read_ocr("testnet",&orc_handle);
/* image processing */
create_tuple(&OcrHandle,1);
set_i(OcrHandle,orc_handle,0);
T_do_ocr_multi(Character,Image,OcrHandle,&Class,&Confidence);
close_ocr(orc_handle);

Result

If the parameter OcrHandleOcrHandleOcrHandleOcrHandleOcrHandleocrHandle is valid, the operator close_ocrclose_ocrCloseOcrclose_ocrCloseOcrCloseOcr returns the value 2 (H_MSG_TRUE). Otherwise an exception will be raised.

Possible Predecessors

write_ocr_trainfwrite_ocr_trainfWriteOcrTrainfwrite_ocr_trainfWriteOcrTrainfWriteOcrTrainf

Possible Successors

read_ocrread_ocrReadOcrread_ocrReadOcrReadOcr

Module

OCR/OCV


ClassesClassesClassesClasses | | | | Operators