# ipfml.filters.kernels

Kernel to apply on images using convolution

Functions

`max_bilateral_diff`(window) | Bilateral difference kernel to use with convolution process on image
`min_bilateral_diff`(window) | Bilateral difference kernel to use with convolution process on image
`plane_max_error`(window) | Plane max error kernel to use with convolution process on image
`plane_mean`(window) | Plane mean kernel to use with convolution process on image

`ipfml.filters.kernels.``max_bilateral_diff`(window)
  Bilateral difference kernel to use with convolution process on image
    Apply difference pixel to pixel and keep max difference before applying mean

  Parameters: | window – the window part to use from image
  Returns: | mean of max difference of pixels

  Example:

      >>> from ipfml.filters.kernels import max_bilateral_diff
      >>> import numpy as np
      >>> window = np.arange(9).reshape([3, 3])
      >>> result = max_bilateral_diff(window)
      >>> result
      3.0

`ipfml.filters.kernels.``min_bilateral_diff`(window)
  Bilateral difference kernel to use with convolution process on image
    Apply difference pixel to pixel and keep min difference before applying mean

  Parameters: | window – the window part to use from image
  Returns: | mean of min difference of pixels

  Example:

      >>> from ipfml.filters.kernels import min_bilateral_diff
      >>> import numpy as np
      >>> window = np.arange(9).reshape([3, 3])
      >>> result = min_bilateral_diff(window)
      >>> result
      1.0

`ipfml.filters.kernels.``plane_max_error`(window)

  Plane max error kernel to use with convolution process on image

  Parameters: | window – the window part to use from image
  Returns: | Difference between max and min error from mean plane

  Example:

      >>> from ipfml.filters.kernels import plane_max_error
      >>> import numpy as np
      >>> window = np.arange(9).reshape([3, 3])
      >>> result = plane_max_error(window)
      >>> (result < 0.0001)
      True

`ipfml.filters.kernels.``plane_mean`(window)

  Plane mean kernel to use with convolution process on image

  Parameters: | window – the window part to use from image
  Returns: | Normalized residual error from mean plane

  Example:

      >>> from ipfml.filters.kernels import plane_mean
      >>> import numpy as np
      >>> window = np.arange(9).reshape([3, 3])
      >>> result = plane_mean(window)
      >>> (result < 0.0001)
      True