CleanRecognizerSession Method of the Engine Object

This method cleans the current recognition session. When processing documents, FineReader Engine tunes itself for recognition of the current type of document (concerning its brightness, text types, fonts, etc.). This information is used during one recognition session and helps to improve recognition quality. When you call the CleanRecognizerSession method, all information which was received during this self-tuning is removed.

By default, FineReader Engine cleans recognition session after recognition of each page (the IEngine::AutoCleanRecognizerSession property is TRUE) and in most cases, you do not need to call the CleanRecognizerSession method manually.

Below are the situations when you may need to call this method:

  • If you need to keep recognition session between pages, e.g., if you use the cache dictionary. In this case, you should set the AutoCleanRecognizerSession property to FALSE and clean recognition session manually by calling CleanRecognizerSession method when necessary (when you do no longer need the cache dictionary or if you are going to process a page with parameters (brightness, text types, fonts, etc.) that are extremely different from previous pages).
  • If you need to clean recognition session during recognition of one page, e.g., if the page contains blocks of text with some parameters (text types, fonts, etc.) that differ significantly from other text blocks' parameters.

Note that if the AutoCleanRecognizerSession property is FALSE, FineReader Engine, however, cleans its recognition session automatically in the following cases:

Syntax

HRESULT CleanRecognizerSession();
    
    

Return values

This method has no specific return values. It returns the standard return values of ABBYY FineReader Engine functions.

Remarks

This method call automatically cleans the cache dictionary.

See also

Engine

03.07.2024 8:50:10

Usage of Cookies. In order to optimize the website functionality and improve your online experience ABBYY uses cookies. You agree to the usage of cookies when you continue using this site. Further details can be found in our Privacy Notice.