# filters module - Generování 3D modelu otisku prstu 1.0 documentation

Hide navigation sidebar
Hide table of contents sidebar
Back to top
Toggle table of contents sidebar

# filters module

Filter library for the application

class filters.add_margin(img)

  Bases: `img_filter`

  Add margin to the image.

  apply(params)
  init(img)

class filters.bilateral(img)

  Bases: `img_filter`

  Bilateral filter from opencv.

  apply(params)

class filters.bilateral_scikit(img)

  Bases: `img_filter`

  Skimage denoise_bilateral filter. Averages pixels based on their distance and color similarity. Preserves edges while removing unwanted noise. Much slower than opencv implementation.

  apply(params)

class filters.binarize(img)

  Bases: `img_filter`

  Binarization filter from opencv.

  apply(params)
  init(img)

class filters.binarize_otsu(img)

  Bases: `img_filter`

  Otsu binarization filter from opencv.

  apply(_)
  init(img)

class filters.block_match(img)

  Bases: `img_filter`

  Block matching filter from bm3d.

  This filter is very slow and should be used only on small images

  apply(params)

class filters.dilate(img)

  Bases: `img_filter`

  Dilation morphological operation from OpenCV module.

  apply(params)

class filters.erode(img)

  Bases: `img_filter`

  Erosion morphological operation from OpenCV module.

  apply(params)

class filters.farid(img)

  Bases: `img_filter`

  Farid filter from filters. Finds edges of the image.

  apply(_)

class filters.gaussian(img)

  Bases: `img_filter`

  Gaussian blur filter from scikit-image. Easier to use than opencv version.

  apply(params)

class filters.hessian(img)

  Bases: `img_filter`

  Hessian filter from scikit-image filters.

  apply(params)

class filters.img_filter(img)

  Bases: `object`

  Parent class for all the filters.

class filters.invert(img)

  Bases: `img_filter`

  Invert the image using bitwise_not from opencv.

  apply(_)

class filters.median(img)

  Bases: `img_filter`

  Median blur filter from scikit-image. Using this over opencv version as that one is limited to 5x5 kernel.

  apply(params)

class filters.meijering(img)

  Bases: `img_filter`

  Meijering filter from scikit-image filters. Finds continuous ridges.

  apply(_)

class filters.nlmeans(img)

  Bases: `img_filter`

  Non-local means filter from scikit-image.

  apply(params)

class filters.sato(img)

  Bases: `img_filter`

  Meijering filter from scikit-image filters. Exctracts continuous ridges.

  apply(_)

class filters.scale_values(img)

  Bases: `img_filter`

  Scale values of the image to use the entire range of data type. This should remove the line height issues.

  apply(_)

class filters.total_variation(img)

  Bases: `img_filter`

  Scikit image denoise_tv_chambolle filter from scikit-image.

  Performs total variation denoising technique based on original Chambolle paper. This filter removes fine detail, but preserves details such as edges.

  apply(params)

class filters.unsharp_mask_pil(img)

  Bases: `img_filter`

  Unsharp mask filter from PIL.

  apply(params)

class filters.unsharp_mask_scikit(img)

  Bases: `img_filter`

  Unsharp mask filter from scikit.

  Apply blurring using gaussian filter, then subtract the blurred image from the original image. Radius parameter is the sigma parameter of the gaussian filter. Amount parameter regulates the strength of the unsharp mask. Better results than using this from opencv.

  apply(params)