Class ColorDeconvolutionNormalizer

java.lang.Object
qupath.lib.images.servers.transforms.ColorDeconvolutionNormalizer
All Implemented Interfaces:
BufferedImageOp, BufferedImageNormalizer

public class ColorDeconvolutionNormalizer extends Object implements BufferedImageNormalizer
Normalizes an image by applying color deconvolution to RGB input, rescaling intensities, and using color 'reconvolution' to generate a new RGB image.
Since:
v0.6.0
  • Method Details

    • create

      public static ColorDeconvolutionNormalizer create(ColorDeconvolutionStains stainsInput, ColorDeconvolutionStains stainsOutput, double... scales)
      Create a normalizer using color deconvolution and reconvolution.
      Parameters:
      stainsInput - stain vectors to apply to deconvolve the input image, which should relate to the original colors
      stainsOutput - stain vectors to apply for reconvolution, determining the output colors
      scales - optional array of scale factors to apply to each deconvolved channel. A scale factor of 1.0 will leave the channel unchanged, while a scale of 0.0 will suppress the channel.
      Returns:
    • filter

      public BufferedImage filter(BufferedImage img, BufferedImage output)
      Specified by:
      filter in interface BufferedImageOp