Class DocumentQualityAnalyzerConfiguration


  • public class DocumentQualityAnalyzerConfiguration
    extends java.lang.Object
    Document Quality Analyzer configuration.
    • Constructor Detail

      • DocumentQualityAnalyzerConfiguration

        public DocumentQualityAnalyzerConfiguration​(java.util.List<DocumentQualityThreshold> qualityThresholds,
                                                    java.util.List<DocumentQuality> qualityIndices,
                                                    boolean detectOrientation,
                                                    int maxImageSize,
                                                    int minEstimatedNumberOfSymbolsForDocument,
                                                    double minProcessedFraction,
                                                    double maxProcessedFraction,
                                                    int earlyStopIfNSymbolsFound,
                                                    int tileSize,
                                                    boolean returnQualityHeatmap)
        Constructs DocumentQualityAnalyzerConfiguration with the given params.
        Parameters:
        qualityThresholds - Quality thresholds to separate quality levels.
        qualityIndices - quality levels.
        detectOrientation - Enable orientation detection. Document orientation will be returned in `DocumentQualityAnalyzerResult.orientation`. Default is false
        maxImageSize - Maximum image size in pixels, if image is bigger, it will be resized. Default is 2000
        minEstimatedNumberOfSymbolsForDocument - if estimated number of symbols is less than this value, return that document is not found. Default is 20
        minProcessedFraction - at least this fraction of the image will be processed, range is from 0 to 1. Default is 0
        maxProcessedFraction - at most this fraction of the image will be processed, range is from 0 to 1. Default is 0.5
        earlyStopIfNSymbolsFound - If this number of symbols is found and minProcessedFraction of the image is processed, the processing stops. Default is 100
        tileSize - Image will be processed in tiles of this size; will be ignored if image is small. Default is 300
        returnQualityHeatmap - If true, will return the quality heatmap as a part of the result. In this case, the entire image will be processed and the minProcessedFraction will be ignored. Useful for debugging situations where the returned quality doesn't appear to match the perceived quality. Default is false
      • DocumentQualityAnalyzerConfiguration

        public DocumentQualityAnalyzerConfiguration()
        Constructs DocumentQualityAnalyzerConfiguration with default parameters.
    • Method Detail

      • getQualityThresholds

        public java.util.List<DocumentQualityThreshold> getQualityThresholds()
        Getter for qualityThresholds field. See constructor documentation for more information about the field.
        Returns:
        qualityThresholds
      • setQualityThresholds

        public void setQualityThresholds​(java.util.List<DocumentQualityThreshold> qualityThresholds)
        Setter for qualityThresholds field. See constructor documentation for more information about the field.
        Parameters:
        qualityThresholds - Value to set.
      • getQualityIndices

        public java.util.List<DocumentQuality> getQualityIndices()
        Getter for qualityIndices field. See constructor documentation for more information about the field.
        Returns:
        qualityIndices
      • setQualityIndices

        public void setQualityIndices​(java.util.List<DocumentQuality> qualityIndices)
        Setter for qualityIndices field. See constructor documentation for more information about the field.
        Parameters:
        qualityIndices - Value to set.
      • getDetectOrientation

        public boolean getDetectOrientation()
        Getter for detectOrientation field. See constructor documentation for more information about the field.
        Returns:
        detectOrientation
      • setDetectOrientation

        public void setDetectOrientation​(boolean detectOrientation)
        Setter for detectOrientation field. See constructor documentation for more information about the field.
        Parameters:
        detectOrientation - Value to set.
      • getMaxImageSize

        public int getMaxImageSize()
        Getter for maxImageSize field. See constructor documentation for more information about the field.
        Returns:
        maxImageSize
      • setMaxImageSize

        public void setMaxImageSize​(int maxImageSize)
        Setter for maxImageSize field. See constructor documentation for more information about the field.
        Parameters:
        maxImageSize - Value to set.
      • getMinEstimatedNumberOfSymbolsForDocument

        public int getMinEstimatedNumberOfSymbolsForDocument()
        Getter for minEstimatedNumberOfSymbolsForDocument field. See constructor documentation for more information about the field.
        Returns:
        minEstimatedNumberOfSymbolsForDocument
      • setMinEstimatedNumberOfSymbolsForDocument

        public void setMinEstimatedNumberOfSymbolsForDocument​(int minEstimatedNumberOfSymbolsForDocument)
        Setter for minEstimatedNumberOfSymbolsForDocument field. See constructor documentation for more information about the field.
        Parameters:
        minEstimatedNumberOfSymbolsForDocument - Value to set.
      • getMinProcessedFraction

        public double getMinProcessedFraction()
        Getter for minProcessedFraction field. See constructor documentation for more information about the field.
        Returns:
        minProcessedFraction
      • setMinProcessedFraction

        public void setMinProcessedFraction​(double minProcessedFraction)
        Setter for minProcessedFraction field. See constructor documentation for more information about the field.
        Parameters:
        minProcessedFraction - Value to set.
      • getMaxProcessedFraction

        public double getMaxProcessedFraction()
        Getter for maxProcessedFraction field. See constructor documentation for more information about the field.
        Returns:
        maxProcessedFraction
      • setMaxProcessedFraction

        public void setMaxProcessedFraction​(double maxProcessedFraction)
        Setter for maxProcessedFraction field. See constructor documentation for more information about the field.
        Parameters:
        maxProcessedFraction - Value to set.
      • getEarlyStopIfNSymbolsFound

        public int getEarlyStopIfNSymbolsFound()
        Getter for earlyStopIfNSymbolsFound field. See constructor documentation for more information about the field.
        Returns:
        earlyStopIfNSymbolsFound
      • setEarlyStopIfNSymbolsFound

        public void setEarlyStopIfNSymbolsFound​(int earlyStopIfNSymbolsFound)
        Setter for earlyStopIfNSymbolsFound field. See constructor documentation for more information about the field.
        Parameters:
        earlyStopIfNSymbolsFound - Value to set.
      • getTileSize

        public int getTileSize()
        Getter for tileSize field. See constructor documentation for more information about the field.
        Returns:
        tileSize
      • setTileSize

        public void setTileSize​(int tileSize)
        Setter for tileSize field. See constructor documentation for more information about the field.
        Parameters:
        tileSize - Value to set.
      • getReturnQualityHeatmap

        public boolean getReturnQualityHeatmap()
        Getter for returnQualityHeatmap field. See constructor documentation for more information about the field.
        Returns:
        returnQualityHeatmap
      • setReturnQualityHeatmap

        public void setReturnQualityHeatmap​(boolean returnQualityHeatmap)
        Setter for returnQualityHeatmap field. See constructor documentation for more information about the field.
        Parameters:
        returnQualityHeatmap - Value to set.