Aspose.OCR for Python via Java API docs
|
Base class for image processing commands. More...
Inherits BaseJavaClass.
Public Member Functions | |
__init__ (self) | |
add (self, filter) | |
Add filter to collection for further preprocessing. | |
getJavaClass (self) | |
Static Public Member Functions | |
auto_denoising () | |
Enables the use of an additional neural network to improve the image - reduce noise. | |
auto_dewarping () | |
Automatically corrects geometric distortions in the image. | |
auto_skew () | |
Enables the automatic image skew correction. | |
binarize () | |
Converts an image to black-and-white image. | |
binarize_and_dilate () | |
Dilation adds pixels to the boundaries of objects in an image. | |
contrast_correction () | |
Contrast correction filter. | |
invert () | |
Automatically inverts colors in a document image. | |
median () | |
The median filter run through each element of the image and replace each pixel with the median of its neighboring pixels. | |
resize (int width, int height) | |
Rescale image - upscale or downscale image resolution. | |
rotate (float angle) | |
Rotate original image. | |
scale (float ratio) | |
Rescale image - Upscale or downscale image resolution. | |
threshold (int value) | |
Create a binary image based on setting a threshold value on the pixel intensity of the original image. | |
to_grayscale () | |
Converts an image to grayscale image. | |
Static Public Attributes | |
str | JAVA_CLASS_NAME = "com.aspose.ocr.PreprocessingFilter" |
Base class for image processing commands.
__init__ | ( | self | ) |
add | ( | self, | |
filter | |||
) |
Add filter to collection for further preprocessing.
filter | PreprocessingFilter object. |
|
static |
Enables the use of an additional neural network to improve the image - reduce noise.
Useful for images with scan artifacts, distortion, spots, flares, gradients, foreign elements.
|
static |
Automatically corrects geometric distortions in the image.
Extremely resource intensive!
|
static |
Enables the automatic image skew correction.
|
static |
Converts an image to black-and-white image.
Binary images are images whose pixels have only two possible intensity values. They are normally displayed as black and white. Numerically, the two values are often 0 for black, and 255 for white. Binary images are produced by auto thresholding an image.
|
static |
Dilation adds pixels to the boundaries of objects in an image.
|
static |
Contrast correction filter.
getJavaClass | ( | self | ) |
|
static |
Automatically inverts colors in a document image.
|
static |
The median filter run through each element of the image and replace each pixel with the median of its neighboring pixels.
|
static |
Rescale image - upscale or downscale image resolution.
width | The new width of the image. |
height | The new height of the image. |
|
static |
Rotate original image.
angle | Angle of rotation. Value from -360 to 360. |
|
static |
Rescale image - Upscale or downscale image resolution.
InterpolationFilterType bilinear or nearest neighbor.
ratio | The scaling factor. Recommended value from 0.1 to 1 to shrink. From 1 to 10 to enlarge. |
|
static |
Create a binary image based on setting a threshold value on the pixel intensity of the original image.
value | The max value. |
|
static |
Converts an image to grayscale image.
Grayscale image have 256 level of light in image (0 to 255).
|
static |