Image Processing
Use the Image Processing tool to perform a number of actions on images. The tool lets you align, threshold, scale, shift, and crop images. You can also balance their brightness and convert them to grayscale.
Alteryx Intelligence Suite Required
This tool is part of Alteryx Intelligence Suite. Intelligence Suite requires a separate license and add-on installer to Designer. After you install Designer, install Intelligence Suite and start your free trial.
Tool Components
Image Processing has 3 anchors (2 inputs and 1 output):
Input anchor: Use the input anchor to connect the images you want to process.
Optional input anchor: Connect annotations from the Image Template tool. You can use these annotations as anchor points for the Shift step.
Output anchor: Use the output anchor to pass processed images downstream.
Note—The "image_processed" column contains your processed images.
Configure the Tool
Add an Image Processing tool to the canvas.
Use the input anchor to connect the images you want to process.
From the Image field, select the images you want to process.
Select the Add Step button to open a dropdown that allows you to add any of these steps:
The tool processes each step in order from top to bottom. You can drag the steps you've already added to reorder them. Select the trash-can icons to remove individual steps.
Alignment
Brightness Balance
Crop
Enhance
Grayscale
OCR Optimization
Scale
Shift
Thresholding
Run the workflow
Advanced
Each step of the image processing has advanced configuration options.
Alignment
Use the Alignment step to rotate your images or scanned documents. This step can improve OCR results for scanned documents that are skewed.
Alignment has 2 modes:
Auto: Automatically rotate your scanned documents or images for your OCR workflows. Auto works best with images that contain text. Note that automatic rotation only works for images rotated by 45 degrees or less.
Custom: Use the slider to select the degree and direction of the rotation that the tool applies to images. Select the refresh icon to reset the slider. Use Custom when you know the exact degree of rotation or if you have images rotated by more than 45 degrees.
Brightness Balance
Automatically or manually adjust the brightness of images.
Convert multi-channel images to single channel. The Auto option allows the tool to automatically balance the brightness of images. If you select the Custom option, you can use the slider to specify how light or dark you want the image to be.
Crop
Remove parts of images.
To crop an image, choose how much of the image you want to keep. You can make that selection by indicating the width and height in pixels or percentages. Then use the anchor grid to select what portion of the image you want to keep after cropping.
Enhance
Increase image resolution and improve image quality. Use Enhance to improve the results of your computer vision tasks such as OCR. These are the available image enhancement models:
Text for OCR: For images that contain typed text, upscale the resolution by 400%. This option can improve your OCR results. Note that Text for OCR only applies enhancements to images that are less than or equal to 1000 × 1000 pixels. Larger images pass through the tool without enhancements.
Important
Note that Enhance might take longer to process than other steps because it relies on deep learning models.
Grayscale
Convert multi-channel images to single channel. You don't have to configure anything.
OCR Optimization
Optimize your scanned PDF files for Optical Character Recognition (OCR). Only use OCR Optimization on noisy documents with scanning artifacts, printed background texture, and non-white backgrounds. We don't recommend OCR Optimization for clean documents.
OCR Optimization has 3 modes:
Auto: The tool automatically decides whether it applies Heavy or Light processing on a per-document basis.
Heavy: Use for denser and noisier documents.
Light: Use for relatively clean documents.
If your document has a non-white background, select Some Text Has Non-White Background. For example, select this option if your document has white text on a blue background.
Scale
Resize images.
Choose how much bigger or smaller you want to make the images. You can specify the width and height in pixels or by percentage relative to the size of the original images.
You can also choose to lock the aspect ratio of your images, which means that their proportions won't change even if you change the height or width.
Shift
Automatically shift documents that were misaligned when scanned. Use Shift to improve OCR results for scanned documents. Follow these steps to use Shift:
Create an annotation in the Image Template tool to act as an anchor. Shift uses the anchor to align your other scanned documents. Note—Shift doesn’t work with Table Detection. Use only the annotations added in the manual annotation mode.
Connect the Image Template tool to the optional input anchor.
Add the Shift step.
Select Anchor under Shift to automatically shift your scanned documents.
Select the Anchor Name from the annotation created in step 1.
Run the workflow.
Thresholding
Set a threshold to convert images to a binary, like black and white, for each channel.
We provide several algorithms you can use to threshold your images. In most cases, we recommend that you use Adaptive Gaussian for images of text, like scanned pages of a book, and Binary for other images, like photographs. For a more in-depth discussion of thresholding, visit OpenCV's thresholding documentation.
Note—Adaptive thresholding methods require images to be single channel (in other words, grayscale). If you don't have a Grayscale step preceding a Thresholding step, we perform grayscaling for you, but we don't add a grayscale step in the Configuration window.