Sticker with various positions and orientations

  • 440 Views
  • Last Post 25 September 2018
Timo Neff posted this 12 August 2018

Hi, I am facing the following challenge:

  • A4 page (Portrait or Landscape)
  • 0 to N stickers placed containing multiple fields (ICR), which are supposed to be recognized and extracted
  • Sticker holds anchor and other elements, which can easily be found via search elements
  • Sticker can be at various positions with different text directions depending on the page orientation (horizontal / vertical (but always left-to-right))

Auto Orientation Corrections fails for the recognition of sticker as the majority of the text on the page can be in a different direction. I appreciate any kind of help / hint!

Order By: Standard | Newest | Votes
Ekaterina posted this 14 August 2018

Hello,

Please use “After document state changed” event or created the script rule by using  .Net methods.

Timo Neff posted this 15 August 2018

Hello Ekaterina, may you give a little further advise? 

Ekaterina posted this 04 September 2018

Hello,

Could you please send us your images and describe what region you want to extract?

Timo Neff posted this 07 September 2018

Hey Ekaterina, I am basically looking for the following functionality, let me quickly sketch something:

function postProcessing(page) {
int i = 2;
while(FlexiLayout not mached && i > 0) {
   page.rotate(90);
   if (FlexiLayout machted) {
      return recognize(page)
   }
   else {
      i--;
   }
}

So, basically the page would be turned up to three times (360°) and when the FlexiLayout was matched the recognition will be performed. Really looking forward for your help to implement it!

Best, Timo

Ekaterina posted this 25 September 2018

Hello,

We could give you more accurate advice if we had seen the images. Is it possible to provide some samples? 

Now we may suggest you the following scenario:

1) If on the level of FLS project you don't know, what will be orientation of the sticker field, then you may create 3 blocks based on the same regions and pass it into Document Definition as 4 different fields, named, say Block0, Block90 and Block270.

2) In the Document Definition Editor you may set up the same recognition options for all these fields except for "orientation" (see the screenshot). The "orientation" should be set as Horizontal for Block0, Vertical (bottom to top) for Block90 and Vertical (top to bottom) for the Block270.

3) Then you compare recognition results in these fields by the Script rule (you may evaluate the length of resulting text string, or accordance to a specific regular expression, for example), and select the best result as a final value for your sticker field.

Close