Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

Intelligence Suite: Computer Vision: 'Image Template' + 'Image to Text'

Treyson
13 - Pulsar
13 - Pulsar

I am working on a project where we have PDFs that have a varying number of pages and I want to select the same section from each page, but (as far as I can tell) if I am just using the Image Template tool, I have to select each page uniquely, which is a bit of a burden and not dynamic. I notice that the Markup output of the Image Template tool is just some JSON (or XML IDK) so we should theoretically be able to rebuild this markup field to select the information from every page. When I did this though, the second I connected my Summary tool (below) to the input, I got this error that I think is pretty unique. It popped up the second I connected the tool, before any runs. The error was essentially an unexpected end of string error so I went through the JSON (or XML IDK) and everything looks in order.

 

I am curious if changing the markup field is an option and if the "T" input of the Image to Text tool HAS to be from the "Image Template" tool as the language in the documentation sort of points to. 

 

Treyson_0-1664998612090.png

 

Treyson Marks
Managing Partner
DCG Analytics
1 REPLY 1
CarliE
Alteryx Alumni (Retired)

Hi @Treyson ,

 

It does not have to be -- I actually did this myself as well. Its not the cleanest but attached is what I did. For some reason, you need to also have the description updated for it to work too.

 

"For annotating PDFs with computer vision tools, I have had the question can I use the same annotations on each page without annotating over and over again. The answer is yes, but it requires a lot of logic being that the the metadata has to be proper for it to work (description field for example) I have created a few macros to automate these steps.
 
  1. DynamicPDF_JSON.yxmc will append and update the json to change field names / page numbers and then concatenate the json for use
    2. GetPDF_description will parse all the pdf field names and types to then update the description field for markup."

Attached is a sample workflow for you to look at

 

Please make sure to mark as a solution if this solved your problem

Carli
Labels
Top Solution Authors