Extract data from a document Version 4 (Рython)

Action group: Robin OCR 


The action is obsolete. It can be replaced by the action "Extract data from a document Dbrain OCR".

Description

The action retrieves the data of the data field from the selected document.

Action icon


Parameters and their settings

PropertyDescriptionTypeFilling exampleMandatory field
Parameters
File pathThe path to the file to extract the data from. Supported formats: jpg, jpeg, bmp, pngRobin.FilePath
Yes
Document typeThe type of document to extract data fromRobin.String
Yes
Folder pathThe path to the folder where a copy of the source file with superimposed blocks will be saved, into which the recognition action divides it. To save it, you also need to fill in the «File name» fieldRobin.FolderPathC:\doc\imgNo
File nameThe name of the copy of the source file with superimposed blocks (without extension). The image will be created with the *.png extension. To save it, you also need to fill in the «Folder path» fieldRobin.String
No
OverwriteIf «true», and a file with the same name and extension exists in the specified folder, then a new file with blocks will overwrite it. If «false», the file will not be overwritten, and the action will return an errorRobin.BooleantrueNo
Results
Extracted textThe data of each field in the document extracted from the original imageRobin.Dictionary

Image with blocksThe path to the image file with superimposed blocksRobin.FilePath

Recognition confidenceThe accuracy of recognition of each field in the image is in the range from 0 to 1Robin.Dictionary

Special conditions of use

For each document view there is a set of fields that the robot will search for.If the image does not contain the fields it is looking for, the field value will be returned empty.  

The keys are returned in Russian. Now there is no possibility to select the language of dictionary keys for an action.

Passport fields:

  • IssuedBy
  • IssuedDate
  • IssuedCode
  • Signature

  • LName,

  • FName,

  • MName,

  • Sex,

  • Photo
  • BirthDate

  • BirthPlace

  • MRZ,

  • Number

Extract signature, photo fields as boolean fields. All other fields are string.

For residency:

  • Дата регистрации
  • Регион
  • Пункт
  • Район
  • Улица
  • Подразделение
  • Код подразделения

For SNILS:

  • Number
  • LName
  • FName
  • MName
  • BirthDate
  • BirthPlace
  • Sex
  • RegDate


The robot will return an error if:

  • The "Folder path" field is filled in and the "File name" field is not filled in.

  • The "File name" field is filled in and the "File path" is not filled in.

  • An invalid input file format is entered in the "File path" field.

  • There is already a file with the specified name on the specified path and the "overwrite" field = false.

Example of use 

Task

Extract the data fields from the SNILS document.


Solution

Use the "Extract data from a document" action. 

Implementation

  1. Move the "Extract data from a document" action to the workspace. 
  2. Set the parameters of the "Extract data from a document" action. 

  3. Click on the "Start" button in the top panel. 

Result

The program robot completed successfully.

 

Data from the SNILS document has been extracted. The image is saved to the specified folder with overlaid blocks. 


  • Нет меток