Сравнение версий

Ключ

  • Эта строка добавлена.
  • Эта строка удалена.
  • Изменено форматирование.

...

Read barcode from PDF Version 9 (Python)

Группа действий: Машинное зрение 

Описание

Действие ищет в файле штрихкоды и считывает из них данные.

Иконка

Image Removed

Параметры

Входные параметры

Action group: Vision

...

Description

The action looks for barcodes in the file and reads data from them.

Icon

Image Added

Parameters

Input parameters

File Path - The path to the file where you want to find barcodes and extract data from them. Supported formatsПуть к файлу                     Путь к файлу, в котором нужно найти штрихкоды и извлечь из них данные. Поддерживаемые форматы: jpg, jpeg, bmp, png, pdf.

Номер страницы              Номер страницы файла, на которой нужно искать штрихкоды. Если поле не заполнено, поиск штрихкодов поиск штрихкодов будет осуществляться на всех страницах.

Тип штрихкода                 Тип штрихкода, который действие должно найти. Если выбрано «Определить автоматически», то будут найдены любые штрих коды в файле. Всплывающий список:

  • Определить автоматически
  • EAN13

  • UPC-A

  • UPC-E

  • CODE 128

  • QR code

  • DATAMATRIX

  • DATAMATRIX (GS1)

Порядковый номер         Порядковый номер найденного штрихкода, из которого действие должно вернуть данные . Если поле не заполнено, то действие вернет данные всех найденных штрихкодов. Нумерация начинается с 1.

Выходные параметры

Результат  Коллекция, содержащая данные, которые были извлечены из штрихкодов. Один элемент коллекции – значение одного штрихкода.

Настройки

Page number - The page number of the file on which you want to search for barcodes

Barcode type - The type of barcode the action should find. If "Detect automatically" is selected, any barcode in the file will be found

Order - The sequence number of the found barcode from which the action should return data. If this field is not filled in, the action will return the data of all barcodes found. The numbering starts from 1

Output parameters

Result - A collection containing data that has been extracted from barcodes. One element of the collection is the value of one barcode.

Settings

PropertyDescriptionTypeFilling exampleMandatory field
Parameters
File PathThe path to the file where you need to find barcodes and extract data from them. Supported formats

Свойство

Описание

Тип

Пример заполнения

Обязательность заполнения поля

Параметры

Путь к файлу

Путь к файлу, в котором нужно найти штрихкоды и извлечь из них данные. Поддерживаемые форматы
: jpg, jpeg, bmp, png, pdf.Robin.FilePath
Да

Yes

Номер страницы

Номер страницы файла, на которой нужно искать штрихкоды. Если поле не заполнено, поиск штрихкодов поиск штрихкодов будет осуществляться на всех страницах
Page numberThe number of the file page on which to search for barcodes. If the field is not filled in, the barcode search will be performed on all pages.Robin.Numeric
Нет

No

Тип штрихкода

Тип штрихкода, который действие должно найти. Если выбрано «Определить автоматически», то будут найдены любые штрихкоды в файле.

Robin.String

Да

Barcode typeThe type of barcode that the action should find. If «Detect automatically» is selected, any barcodes in the file will be found. 

Popup list:

    • Detect automatically
    • EAN13

    • UPC-A

    • UPC-E

    • CODE 128

    • QR code

    • DATAMATRIX

    • DATAMATRIX (GS1)

Robin.String
Yes
OrderThe sequence number of the barcode found, from which the action should return data. If the field is not filled in, the action will return the data of all found barcodes. The numbering starts from

Порядковый номер

Порядковый номер найденного штрихкода, из которого действие должно вернуть данные . Если поле не заполнено, то действие вернет данные всех найденных штрихкодов. Нумерация начинается с
1.Robin.Numeric
Нет

No
Результаты
Results

Результат

Коллекция, содержащая данные, которые были извлечены из штрихкодов. Один элемент коллекции – значение одного штрихкода
ResultA collection containing data that has been extracted from barcodes. One element of the collection is the value of one barcode.Robin.Collection

Особые условия использования 

  1. Если в файле есть штрихкод, который не прописан в алгоритм работы действия, то действие его проигнорирует. Неизвестный штрихкод не будет распознан, действие вернет пустую коллекцию. 

  2. Если штрихкоды повернуты под любым углом, то они будут распознаны.

  3. Робот вернет пустую коллекцию, если не найдено ни одного штрихкода.

Робот вернет ошибку, если:

  • в поле "Путь к файлу" подается недопустимый формат входного файла.
  • неверно указан номер страницы (вне диапазона количества страниц в документе)
  • порядковый номер выходит за диапазон количества найденных кодов

Робот не вернет ошибку, если:

  • в файле неизвестный штрихкод= в файле нет штрихкода. Вернется пустая коллекция.

Пример использования 

Задача

Существует изображение со штрихкодом, необходимо считать данные по шрихкоду. 

Image Removed

Решение 

Воспользоваться действием "Считать штрихкод из ПДФ". 

Реализация

...

Результат

ОШИБКА!!!Image Removed

Программный робот отработал успешно. Данные по шрихкоду распознаны. 



Special conditions of use

  1. If there is a barcode in the file that is not specified in the action's algorithm, the action will ignore it. An unknown barcode will not be recognized, the action will return an empty collection. 
  2. If the barcodes are rotated at any angle, they will be recognized.
  3. The robot will return an empty collection if no barcodes are found or an unknown barcode is in file.
  4. The barcode will not be recognized. The image has text, unnecessary information.Image Added
  5. The barcode will be recognized.Image Added
  6. Both barcodes will be recognized.Image Added

Example of use 

Task

There is an image with a barcode, you need to read the barcode data. 

Solution 

Use the "Read barcode from PDF" action. 

Implementation

  1. Move the "Read barcode from PDF" action to the workspace.
    Image Added

  2. Customize the parameters of the "Read barcode from PDF" action. Remember that the barcode will be read only if it belongs to the above barcode types from the dropdown list. In this case, it is type EAN13.
    Image Added

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

Result

The program robot completed successfully. The barcode data has been recognized. 

The result can be loaded into a collection by specifying a collection variable, or the result of this action can be input to another action that accepts the collection.

Thus, to display a result, you must either add an action that takes a collection as input, or specify a variable of type collection to be specified as a result of this action.

Image AddedImage Removed